![]() JRebel comes with a wide range of library and server support, so that it can, for example, reload the Hibernate context if you modify an entity class.Ī less known feature of JRebel is that one can also hook into class reload events from the framework side. Unlike the built-in class reloading, JRebel also works without the debug mode.īecause of the number of advanced libraries that are built, the improved class reloading is not enough. You can add new methods, and new classes and lambdas, and do rather advanced refactorings and your new code still gets reloaded. Compared to the built-in features of JDK, it allows you to go from “it sometimes works” to “it almost always works”. JRebel is a Java agent that greatly improves the class reloading possibilities of JVM. Also, many developers tend to avoid debug mode for performance reasons. Injecting any less-trivial change using the default JDK tooling will fail. This is handy and robust when trying to fix your algorithm in instance methods, but useless most of the time. ![]() JDK’s built-in code hot swap in debug mode is the easiest one to take into use, but is limited in its features. If you are running the application in debug mode, you can apply new method bodies to classes using basic IDE features. Limited built-in hot-swap feature in JDKīy default, the JVM has limited support for hot-swapping new code into a running application. Thus, many professional Java developers utilize some extra tooling to improve their development turnaround time – the time from saving your code change to seeing the new result on the screen. Even if it takes just a couple of seconds, it’s enough for you to lose focus and switch to something else. A full restart of your Java application can take from seconds to even minutes. JVM is known for its great peak performance when serving large numbers of users, but our tooling isn’t by default that well optimized to take new changes into use while developing. Something that I still don’t get is that many Java developers spend a lot of it (time and money) while waiting to see their latest code changes in action.
0 Comments
Leave a Reply. |