JRebel - Have one's cake and eat it!

I've started developing web-applications with PHP about 10 years ago...

  • What I really liked about PHP-development: edit your source, save it, reload the page in your browser and see instantly what you've done.
  • What I really hated about PHP-development: edit your source, save it, reload the page in your browser and see instantly what you've done... but I didn't see that my change (maybe a small refactoring) broke some dependency in a complete different page which threw an error at runtime after moving the application into production.

So PHP-development was love & hate combined into one: I really loved the quick turnarounds, but I hated the missing support from a compiler which could tell me in advance that problems might be ahead... so I usually didn't do any refactorings, because it simply meant lots of problems and the code grew and became a spaghetti mess over the while which was even harder to change and so on... a vicious circle.

PHP: quick turnarounds, but constantly growing spaghetti code...

Since I moved into the Java-universe many years ago, I really enjoy all the IDE & compiler support which comes with type-safety everyday. Refactorings are a no-brainer and a constantly growing (and changing) code base is always in a very good shape, because it is so easy to keep your code clean... making a change which wouldn't work because of a simple typo or wrong method-call is always prohibited by the help of the compiler... Refactoring is pure fun, whereas it was a matter of fear before. I never want to miss all this comfort again.

But something which frustrated me from the first day on the Java-island: the turnarounds between making a change and seeing what the results are. Changing the source, compiling, packaging, deploying, restarting, waiting... simply to recognize that the result is not what I wanted... so once again: changing, compiling, packaging, deploying, restarting, waiting... the whole process takes minutes instead of one second. What a pitty...

Java: always clean (and safe) code, but endless turnarounds...

Sometimes you're forced to choose between two obvious opposing options in this world: 

  • ...do I want to have a clean, refactorable and safe code-base (as provided by Java), but horrible turnaround times?
    or
  • ...do I want constantly growing spaghetti code (which always breaks in production when you're on vacation), but instant turnarounds (as provided by PHP)?

Is there no chance to have one's cake and eat it?

Usually the answer is no, but sometimes wonders happen... and this wonder is called JRebel in the Java-universe. JRebel gives you zero turnarounds (works as advertised) while you're working in your type-safe and compiler-supported IDE of your choice.

I've used JRebel for Jease-Development since last year and it was a mind-blowing improvement regarding turnarounds. It saved me already several days of life... But there were still some cases where I had to restart Tomcat from time to time, because JRebel wasn't able to pick up (and hotdeploy) the changes (e.g. changing method-signatures in Java and make them available in JSPs). No big deal, but remembering the good old PHP-times this wasn't perfect either.

This was before I've worked with JRebel 3.0...

I've started to use JRebel 3.0 right from the release and now the only time when I have to restart Tomcat is when I change the persistent attributes of my content-types (so the object-database can pick up the changes properly).  All the other changes simply work by saving the changed source and reload the browser. I've never had to restart Tomcat for the whole weekend constantly changing and moving code between Java-classes and JSPs. That's what I call perfect!

JRebel: always clean (and safe) code and instant turnarounds...

Turnaround times like PHP combined with all the comfort and safety of Java... that is an absolute amazing development-experience which makes you more productive than with any competing technology. JRebel is one master-piece of software I would buy (if I had too), but the nice guys from Zeroturnaround granted me an OSS-license for Jease-Development. Thanks so much!

If you've never worked with JRebel before, just start right away... it will save you tons of time... maybe you can invest the time in supporting an open-source-project of your choice.

Last modified on 2010-04-19 by Maik Jablonski

Java with Ease

1970-01-01

Java is a very productive development environment if you choose and combine the right tools and patterns.

Jease is the result of my personal quest bringing tools and patterns together which make the life of a web-developer as simple as it can be.