October 10

For Real Hot Deploy For Java

While Java 1.4 promised hot deploy, many implementations of application servers have fallen quite flat on their collective faces in delivering on this promise. Then along comes JavaRebel. A nice little library that actually makes this time consuming and frustrating problem a non-issue. Check out some of the features:

  • Changing, adding and removing class/interface methods
  • Changing, adding and removing class fields
  • Changing, adding and removing class constructors
  • Overriding existing methods
  • Creating new classes or renaming old ones (as long as some other class superclass doesn’t change)
  • Changing method parameter or return types or field type without changing its name
  • Changing, adding and removing class/interface constant fields is supported, but will not get reinitialized and thus is only useful for primitive types and Strings

(taken, liberally, from their page here)

Yes, there is a performance penalty with this, so DO NOT EVER use something like this is a production environment, but it can make your life as a java developer, especially in a local environment, a bit more productive and a lot less infuriating (but, er, we never get mad at Java, because Java is infallible!)

Comments

  1. Craig Andrews said on October 10th, 2007

    One word: neat! I love how languages share cool things with each other. This sounds like a concept ported from Python.

    I have a significant problem with it though - the license quite frankly sucks. There are similar features slated for Java 1.7, which will be Free Software, so I’d keep my eye out for that as a better solution.

  2. David Palmer said on October 15th, 2007

    Ported from Python. Actually, not quite. Java has had this notion of hot deploy since 1.4. The problem was that that no one cared to truly implement it smartly.

    Also, zealotry in the license is probably not terribly appropriate in that to be professional is to get the job done, not further a political crusade. If this gets the job done, and gets it done well, then its a sound and appropriate tool.

  3. Craig Andrews said on October 15th, 2007

    I didn’t know - I said it “sounds like a concept ported from Python.” Thanks for the information.

    In terms of licenses, what you call zealotry, I call passion for making the right decision. I’m of the opinion (and it is within your right to disagree, of course) that Free Software is always superior to proprietary software. We differ in that you believe if the tool works, then use it; I believe that the tool must live forever, be copyable, maintainable, and extensible without the authority of whoever it was who originally made it. For example, if I based my company on this technology, then the company stopped releasing new versions (went out of business, for example) or raised the price or took the product in a new direction or perhaps stopped supporting my hardware/software platform, I’m out of luck. But if the product was Free, then I’m not in nearly as much trouble - I can just pay someone (a company or individual) to make the product work for me. The tool not only works - but works for *me,* and indefinitely.

    The tool doesn’t need to just work and work well, in my opinion - a tool which I cannot use is hardly a tool at all.

Add a comment

Browse posts by month

Browse by author

We're hiring!

Come take a look at careers with Molecular