Some months ago I read a blog post which had a comparison of different (Java) application servers, with focus on the time it took to start/restart the servers after deploying a new/changed piece of code, and a discussion of the lost developer productivity all this restarting caused.
I forgot to bookmark the blog post; I've tried Google, but I am not able to find the original article.
Has anyone else seen/read this article, or have links to similar articles/statistics?
I think you are looking for the "Survey Results: Java EE Containers – Heaven or Hell?" from the JavaRebel JRebel guys.
There are a number of articles about this, so it's hard to know specifically which one you're referring to.
That being said, it really depends on the tech stack. If you want a full J2EE implementation versus just a J2EE container, then the startup times will be very different.
For example, Tomcat can be started in seconds. On my machine in about 1-2 seconds. Of course this is a J2EE container. It doesn't include features such as EJB's. But these days, who really needs that.
Full J2EE implementations like JBoss and Weblogic for example will require much longer server startup times. Generally in the half a minute to some minutes.
Again, you really need to decide exactly what part of the J2EE stack you want, and if you're not going to fully use it, then Tomcat is great for quick startups.
As well, even if you use Tomcat for development, doesn't mean you need to use it for production. That isn't to say it isn't a good production server, it's just lighterweight.
Let's start with the idea that application should be deployed in complete form only for integration testing. That happens may be twice a day. All other times you do unit and local integration testing (i.e. JUnit test with actual database connection), and those tests have next to zero startup time.
My dev activity is like this:
- write (mocked) unit tests and code at the same time; run unit tests may be 20 times before the code works as I expect
- write local integrated tests for major cases; run the tests may be 3 or 5 times before I'm sure it's ok
- package the whole application and do a walk-through of the scenario via UI once or twice
In the time allocation like that AS startup time doesn't take much of my performance.
So instead of complaining about AS it's better to make an effort to organize the development process in the first place.
来源:https://stackoverflow.com/questions/1455397/comparison-of-application-server-startup-times