This week's giveaway is in the Android forum.
We're giving away four copies of Android Security Essentials Live Lessons and have Godfrey Nolan on-line!
See this thread for details.
The moose likes Performance and the fly likes Cause of an application running slow in java ?. Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Android Security Essentials Live Lessons this week in the Android forum!
JavaRanch » Java Forums » Java » Performance
Bookmark "Cause of an application running slow in java ?." Watch "Cause of an application running slow in java ?." New topic
Author

Cause of an application running slow in java ?.

Praveen Kumar
Ranch Hand

Joined: Nov 06, 2006
Posts: 133
Hi Ranchies,

Recently I faced one interview question " Suppose if the application performance is slow, how you will troubleshoot and what things you will trouble shoot first".


I replied with DB normalization and JVM. I told we can some tools like Jprofile and Jmeter

Please let me know how we will troubleshoot and what are the available tools to do that one.


Thanks
Praveen
fred rosenberger
lowercase baba
Bartender

Joined: Oct 02, 2003
Posts: 11172
    
  16

you should always use a profiler first. It will tell you where you application is really slow, letting you focus on what is really needed.


There are only two hard things in computer science: cache invalidation, naming things, and off-by-one errors
steve souza
Ranch Hand

Joined: Jun 26, 2002
Posts: 860
If I asked this question I would want to hear the candidate answer it in a scientific well thought out manner. If they quickly said all the things they would change about their code without properly emphasizing their knowledge of profiling, and an understanding that premature optimization is a sin, then in my view they have failed the question.

Profiling the code is the first step. I would elaborate on how you would do this (for example what tools and approach you would use to prove that you have done it before). I would then add doing any steps like DB normalization is premature, until you have found your bottlenecks, and explain why. You should tune where the profiling leads you. Having made it clear you just don't start tuning without evidence, you could then add typical performance improvement areas. IO subsystems such as the database, file, network are typically prime candidates for performance problems. You could add some examples of how you could detect and improve each of these. An example of a database check that can help a lot is to ensure that your tables have the proper indexes.

http://www.jamonapi.com/ - a fast, free open source performance tuning api.
JavaRanch Performance FAQ
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Cause of an application running slow in java ?.
 
Similar Threads
Separating JMS Producer/Consumer on JBoss 4.0.2
Where can I find jmap for Windows/JDK 1.5?
Migration of web application from WSAD 5.1.2 to RAD 6.0
web.xml
PrinterJob - error