?
Solved

JSP, is it slow?

Posted on 2004-04-06
6
Medium Priority
?
383 Views
Last Modified: 2010-04-01
I have an application that is currently developed as an MS Access project connected to an MS SQL Server.  My intention is to redevlop this as a web based application and I thought I'd give JSP a go.  I've set up a Tomcat 5.0 development server and made a couple of test pages to see how it feels.  I'm using the Microsoft SQL server driver for JDBC to connect to my database to run a couple of simple to queries and iterate through a recordset to display the results.  I like to use stored procedures rather than sending SQL strings to the server so I'm using a CallableStatement and defining the parameters for it.

The problem is it seems to be running very slowly, regardless of the complexity of the query or the size of the returned recordset.  Is this a general problem with JSP?  Would it be faster if I ran the code in a servlet rather than in the .jsp page?

My application currently makes lots of calls to the SQL server for things like drop boxes, list boxes and so I'm a little ancious about this apparent lack of speed.  Would you recomend I stick to JSP or would PHP or ASP be a better option.

Any tips on the performance of jsp with SQL server(or even other DBMSs) and recomendations on other platforms would be much appreciated.

Thanks,

Tom
0
Comment
Question by:TommyV10
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 3
6 Comments
 
LVL 6

Accepted Solution

by:
jarasa earned 1000 total points
ID: 10767307
Hi.

I can't believe you say that your application in MS-Access goes faster that JSP or ASP, it could be if you are getting all the data and show it all on your window. but you must consider that that's not the way it suppose to work a web application, you're supposed to pick data in little pieces over the web and that why is supposed to be faster.

About the use of PHP or ASP it won't make much difference with ASP you could probably get a faster development since you already come from Mircrosoft way of programing but it won't be easy to put that software on othere plataform.

With the Prepared Statements, well the DB is the one that makes all the effort so the time to bring the data to the web server will depend on the amount of row you pass, youhave to consider pagging the recorsets etc.

I believe is a big change to pass from a Client\Server environment to a Web one you must change your point of view of all the THING but let me tell you you won't be dissapointed. Think about an J2EE Application with and EJB architechture and connection pool to your DB.

Java is Wonderfull it's worth all the time you give to it, but is not easy to make high performance to many thing to consider. On the Servlet question just notice that JSP is compilled into a servlet so it won't make much difference at the end, just the compilation time but that's the first time you call it.

Have Fun and Enjoy

Javier
0
 
LVL 6

Expert Comment

by:jarasa
ID: 10767377
About the tips for performance, well I guess there are too many, think about using application scope to save the drop down boxes data in session so all the users can acces them. Most of them pass to use the users session to store the most useful data.

Javier
0
 
LVL 28

Expert Comment

by:rrz
ID: 10767442
>made a couple of test pages to see how it feels.    
Please show us one.
0
 
LVL 1

Author Comment

by:TommyV10
ID: 11047644
Sorry, I forgot about this one.

Thank you jarasa for you tips and comments.  I have taken your advice and am now looking at developing under a J2EE environment.  It is a big step, but so far you are right, I'm not dissapointed.
0
 
LVL 6

Expert Comment

by:jarasa
ID: 11047667
I'm glad to hear that tommy. and thanks for the Points.

:c))

Javier

0

Featured Post

What does it mean to be "Always On"?

Is your cloud always on? With an Always On cloud you won't have to worry about downtime for maintenance or software application code updates, ensuring that your bottom line isn't affected.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

This month, Experts Exchange’s free Course of the Month is focused on CompTIA IT Fundamentals.
Ready to get certified? Check out some courses that help you prepare for third-party exams.
In this video we outline the Physical Segments view of NetCrunch network monitor. By following this brief how-to video, you will be able to learn how NetCrunch visualizes your network, how granular is the information collected, as well as where to f…
Monitoring a network: how to monitor network services and why? Michael Kulchisky, MCSE, MCSA, MCP, VTSP, VSP, CCSP outlines the philosophy behind service monitoring and why a handshake validation is critical in network monitoring. Software utilized …

765 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question