2

I have an legacy in house business application which is running in one JVM and there are many performance issues with it more specifically regarding Heap Usage and Running Concurrent Threads, at the core of it, it's an scheduling application wherein the user can schedule some task from front end and when time arrives the task get's fired up, all code is home grown and we are not using any third party scheduler for scheduling purpose, now my goal is to enhance performance of the application and there are some options which i can try, like using scheduling mechanism like Quartz or distribute application to different jvms, challenge i have here is that i have never being exposed to this kind of situation of re-architecting the application and so am not sure where to start from, i know SO is not right place to ask this type of question but am not sure how to approach and any help/suggestions would be highly appreciated.

Rachel
  • 100,387
  • 116
  • 269
  • 365
  • Why would you think multiple JVMs would help performance? Especially when you mention something about heap usage and threads. Do you mean you want to try and make this a distributed application running across multiple physical servers? – Brian Roach Nov 11 '11 at 18:19
  • @BrianRoach: I am new to profiling stuff and still learning about it and so I might not have answers to many common sense questions – Rachel Nov 11 '11 at 18:31

2 Answers2

3

From reading your post I don't get the impression that you've really grasped what the underlying cause of your performance problems are. The first step in addressing any such problem should be to identify the cause before proposing a solution. I'd begin by asking some pretty high level questions.

  • How many concurrent tasks/threads do you currently execute?
  • Are the jobs CPU or IO bound?
  • What software stack is the app running on?
  • What hardware is the app running on?

By distributing the application across multiple JVMs you will invariably add complexity, which is fine, provided it's a valid and required solution.

mmccomb
  • 13,516
  • 5
  • 39
  • 46
  • I agree with you, it's a java web application and application is running on Linux x64 machine, i am still in the process of getting my profiler configured so that i can actually analysis the system in more detail but jprofiler configuration for remote server is not that straight, atleast for me though. – Rachel Nov 11 '11 at 18:27
2

I suggest you exercise the application with a realistic workload so that the server is busy and profile it to find CPU, memory and resource bottleneck.

IMHO: Separating JVM might be an option if you are using more than 1 - 8 GB of heap AND Full GC times are an issue. If you are using much less than it, its unlikely to help.

DON'T jump to any conclusions about which solution should be until you have a very good understanding of the problem or you can end up spending a lot of time optimising the wrong things and possibly making it worse.

Peter Lawrey
  • 525,659
  • 79
  • 751
  • 1,130
  • I agree and that is the reason am trying to get jprofiler installed so that i can profile remotely installed application to study the statistics but having some hard time configuring jprofiler - http://stackoverflow.com/q/8053484/164299 – Rachel Nov 11 '11 at 18:24
  • Can you run the application on your pc? I have my profiler in my IDE and when I want to profile an application or unit test I click the profile button next to run. – Peter Lawrey Nov 11 '11 at 18:27
  • yes i can run the application on my localpc, but profiler is not working on my local application between my local application is not having complete populated data. – Rachel Nov 11 '11 at 18:27
  • It only has to have a realistic sample of data. – Peter Lawrey Nov 11 '11 at 18:29
  • First of all, I tried to get profiler to run on my local machine but it didn't worked and so tried to running into remote app but still having some configuration issues and it is really giving me hard time, worst part is i have already spend enough time on it and am heading no where also i have followed the same steps mentioned in manual and so am not sure as to what is actually missing out. – Rachel Nov 11 '11 at 18:30
  • Perhaps you can try VisualVM, is not as good but its free and built in. You shouldn't need to do anything to configure it. If you have a JProfiler license you should be able to ask them for help/support. – Peter Lawrey Nov 11 '11 at 18:32
  • It is better than VisualVM, but at this point VisualVM is better than nothing. – Peter Lawrey Nov 11 '11 at 18:35
  • You can. But I would try to use it locally first if you can, it will slow down any application it attaches to. (More than other profilers do) To have a basic understand of your application, you need to be able to run it locally. – Peter Lawrey Nov 11 '11 at 18:43
  • i have local instance of application running but visualVM is not recognizing it? – Rachel Nov 11 '11 at 21:06
  • also can you pointme to some useful resources where i can get some more related information? – Rachel Nov 11 '11 at 21:20
  • Your VisualVM process needs to be running as the same user. – Peter Lawrey Nov 11 '11 at 22:23