File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
The moose likes Servlets and the fly likes JSP Efficiency vs ASP Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Java » Servlets
Bookmark "JSP Efficiency vs ASP" Watch "JSP Efficiency vs ASP" New topic

JSP Efficiency vs ASP

Mark Modaressi

Joined: May 05, 2001
Posts: 6
After doing a search I read an article on ZDNet testing Cold Fusion, JSP, ASP, and PHP. According to their results the JSP setup allowed only 13 pages per second vs an average of around 30 for the other languages.
Here's the article:,14179,2646052,00.html
Does anyone know why that is? I thought that JSP pages were compiled by the server unlike ASP. I assumed that would be enough to speed things up.

Mark Modaressi<BR><A HREF="" TARGET=_blank rel="nofollow"></A><BR><A HREF="" TARGET=_blank rel="nofollow">K2K Motorsports</A>
ernest fakudze
Ranch Hand

Joined: Aug 27, 2001
Posts: 216
These are the sort of questions that start wars between ASP,PHP,CFM heads and us JSP developers: lol. Anyway, i took a look at your article and at first glance I looked at the date. It was written way back in October 2000, I think.
Having said that though, I'd like to throw in a few possible explanations to your question. I am new in JSP myself but I know what I know now. So here are my ideas:
1. They say that Tomcat (which was used for the test) is not the fastest JSP containers out there. In fact, many people don't recommend you to use it for sites that will have a heavy load.
2. Even though JSPs are copiled by the server, they still run inside the Java Virtual Machine and I'm sure you are aware of the speed issues in Java.
So to conclude: I think the results would be different if they had tested JSP using another container like JRun. It surprises me as to why the testers did not consider this.

In a time of drastic change it is the learners who inherit the future. The learned usually find themselves equipped to live in a world that no longer exists.<br />Eric Hoffer
Mark Modaressi

Joined: May 05, 2001
Posts: 6
Thanks, I'm new to JSP myself. I"ve worked with ASP, but it feels like a baby language... not enough structure. Still though, the results are really low compared to the others. Do you think that Tomcat could cost that much?
Where would I be able to obtain a copy of JRun?
ernest fakudze
Ranch Hand

Joined: Aug 27, 2001
Posts: 216
I don't think that Tomcat is entirely to blame for the poor perfromance of JSP. I'm sure there were other factors as well. I'm sure that Tomcat 4 is faster and more robust than previous versions.
Where to get JRun: Go to Next time you don't know where to get something just go to and search for it!
William Brogden
Author and all-around good cowpoke

Joined: Mar 22, 2000
Posts: 13037
The Orion server has been demonstrated to be much faster than Tomcat (admitedly the old version)
Andre Moo

Joined: Sep 29, 2001
Posts: 22
Yes, Alas, JSP's will never be as fast as ASP or ColdFusion regardless of which container you use.
However, Oracle's OC4J container which is actually based on Orion and can be downloaded from Oracle is bloody damned fast compared to Tomcat. JRun is unfortunately not very stable but it is from Allaire/Macromedia and so has a nice web admin interface similar to that of their ColdFusion web admin interface.
Interestingly, the next version of ColdFusion is due to be Java based! Since ColdFusion is highly analagous to JSP it is not hard to see how it will all be done. CFM templates compiled into Servlets with a bunch of JSP Tag libraries to represent the CFML tags etc. Infact, the JRun JSP Tag library, which is one of the best around in my opinion was undoubtably highly influenced by the ColdFusion tags in the CFML language and the Standard Tag Library being produced by Sun or JCP was highly influenced by the JRun JSP Tag Library!
So basically, Sun are trying to acheive with JSP's what ColdFusion has had all the time: highly intuitive XML based markup tags which make things like DB access etc. a snap. ColdFusion also supports COM objects and Java Servlets! - which makes it all the more sadder to see that its market share will continually decrease in the months to come thanks to the likes of ASP on the one side and J2EE technologies on the other side.
Farewell my old friend ColdFusion, hello my new friend J2EE carried away there.
Joe Pardi
Ranch Hand

Joined: Oct 03, 2001
Posts: 47
Keep in mind the difference between performance and scalability. Very important when comparing JSP and ASP. While ASP might be a slightly better performer than JSP, its scalability is not close due to the two architectures. ASP suffers from request-time interpretation and apartment-threading which kills its scalability. JSP is architected on top of servlets and gets the benefit of that architecture.
My experience has been that any difference in performance is negligible as compared to the scalability gains as well as other nice features of JSP.
matt hooker
Ranch Hand

Joined: Jul 26, 2001
Posts: 46
Also, remember where the ASP technology comes from, that alone should see it kicked into touch. ColdFusion though is pretty damn neat, and PHP - superb. It should never really be a question of playing one off against another though .. each should be taken on its individual merits on a case by case basis. Wouldn't it be boring if we only had one technology to play with .... I hope they all (with the possible exception of ASP) live long and prosper. I have enjoyed working with all of them (and don't forget PERL)

Its not what you do, its the way you say you've done it.
Huiming Gu

Joined: May 16, 2001
Posts: 13
I did both ASP, JSP, servlet, EJB, but not familar with PHP and Perl and coldfusion.
My feeling is that:
<b>1. Performace:</b> If the JSP is running on Standard virtual machine and without taking the advantage of servlet and javabean. Then ASP is faster than JSP. But if one can use some special tuned virtual machine like Hotspots server and take advantage of precompiled code like servlet and javabean. Then the performance is around the same or may be JSP page is faster.
<b>2. Easiness of developing:</b> ASP is more easy to develop. But its code is almost none reuseable.
<b>3. Scability</b> JSP and J2EE is much better. Java is OOP programming language. ASP is only an script language.
<b>4. Server administration:</b> ASP server is much easier. But it is not stable(For example it is easy to cause memory leaking problem) and not safe(For example: CodeRed, Nimda).
In general my feeling is that the target market of J2EE is middle to large web application. Target market of ASP and IIS is tiny to middle web application.
I agree. Here's the link:
subject: JSP Efficiency vs ASP
It's not a secret anymore!