We've been running some load tests to see how JBoss compares to an
Apache web server. The numbers just don't seem to add up. Apache beats
the socks out of JBoss by a ration of 1:10. On Apache, we're
continuously requesting for a simple HTML page and on JBoss, we're
requesting for a simple JSP page with no processing on it.
What am I missing here? The numbers seem off. Is my App server not
tuned right or that is all I can expect from this server?
Please help.
Owen Jacobson - 11 Sep 2007 21:20 GMT
> We've been running some load tests to see how JBoss compares to an
> Apache web server. The numbers just don't seem to add up. Apache beats
[quoted text clipped - 6 lines]
>
> Please help.
A better test would be to serve static HTML from both servers -- JSPs,
even JSPs with only static content, are programs that must be
evaluated, not static resources. Even at that, though, you'll likely
discover that JBoss is noticably slower than Apache HTTPD. JBoss also
provides a very wide range of application services to build on that
are simply not available under HTTPD, including the entire EJB2 and
(depending on version) EJB3 specifications.
Tuning JBoss is something of a black art, too; the easiest way to get
a performance boost initially is to increase the -Xms and -Xmx JVM
parameters at JBoss startup time to give it a larger heap to play
with. The return on investment from that falls off fairly rapidly
after about 1 gigabyte of heap, though, after which you're into
tweaking the behaviour of specific components and removing unused
components.
Owen
Arne Vajhøj - 15 Sep 2007 03:44 GMT
> We've been running some load tests to see how JBoss compares to an
> Apache web server. The numbers just don't seem to add up. Apache beats
[quoted text clipped - 4 lines]
> What am I missing here? The numbers seem off. Is my App server not
> tuned right or that is all I can expect from this server?
The numbers seems as expected to me.
A HTML page is static content. It gets cached, so basically
the Apache HTTP just returns some bytes from memory without
even looking at it.
A JSP page is dynamic content. It get compiled to Java code that
get compiled to Java byte code that get JIT compiled to native code.
But it is still code being executed. And JBoss needs to do quite
some work to setup the proper environment (various objects). The
container does not know that you do not intend to use that stuff
in the page.
Arne