File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
The moose likes Performance and the fly likes increasing perfromance for 100 users. Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Spring in Action this week in the Spring forum!
JavaRanch » Java Forums » Java » Performance
Bookmark "increasing perfromance for 100 users." Watch "increasing perfromance for 100 users." New topic
Author

increasing perfromance for 100 users.

vijaya vardhanreddy
Greenhorn

Joined: Aug 09, 2012
Posts: 2
Hi All this is vijay regarding performance for java web application.we are using Extjs as front end and jboss server, and mysql as backend.For loading grid contains 100000 DB for single user loading the grid from the DB the query is taking 4 seconds.But for the 100 users it is taking 50 seconds.why not for 100 users it is less than 10 seconds.we have to minimize the time less than the 10 seconds.for performance testing we are using the jmeter tool.and we are also using the mule server as ESB.
Viktor Kubinec
Ranch Hand

Joined: Jan 28, 2012
Posts: 34
First you should find the reason why do you have such performance for 100 users. Try to use some JVM monitoring tool (jconsole,jprofiler,visualVM) to monitor your web app and ESB. Try to find out whether the bottleneck is your app or the ESB.

One of the reasons why the performance is going down with more users could be running out of memory. When you run out of memory(which can happen with more users) then GC is running more often and consuming lot of cpu time. In this case you could try to extend java memory settings.
fred rosenberger
lowercase baba
Bartender

Joined: Oct 02, 2003
Posts: 11406
    
  16

Your first steps are always to determine where the bottlenecks are. Is your DB slow? is it the computation you are doing? is your algorithm O(n^2) (or something even worse)?

You can spend months and thousands of dollars chasing what you think is the problem, and make incremental improvements, or you can figure out where the real issue is and focus on it. To do this, you need some kind of profiler that tells you where the delays are.


There are only two hard things in computer science: cache invalidation, naming things, and off-by-one errors
Winston Gutkowski
Bartender

Joined: Mar 17, 2011
Posts: 8008
    
  22

vijaya vardhanreddy wrote:For loading grid contains 100000 DB...

I'm not exactly sure whether that's 100,000 rows; but if it is, might this not be a place to start looking?

100,000 rows is an awful lot of data; and if you multiply that by 100 users you may be talking about a LOT of network traffic.

As the others have said, tracking down bottlenecks is not easy; but that's the statement that leapt out at me immediately.
Is there some reason you need to get 100,000 rows?
Does every user need to get all 100,000 rows every time?
Could query results be cached in some way? Most db's have techniques for throttling or caching the amount of data that's returned for any given query; or maybe your application could rationalize requests in some way.

At the end of the day, if you absolutely must do it, then you must; and perhaps throwing some money at a bigger network pipe, or more server memory might ease the problem. However, when I see figures like that I always worry about scalability.

My 2 cents. FWIW.

Winston


Isn't it funny how there's always time and money enough to do it WRONG?
Articles by Winston can be found here
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: increasing perfromance for 100 users.