» Sign in
  
Jump to HP Home Jump to Product & Services Jump to Support & Drivers Jump to Solutions Jump to How to buy
» Contact HP
 » Advanced Search
Jump to HP Home

Performance tuning Java™: tuning guidelines

Developer & Solution Partner Program (DSPP)


A site for HP Partners

 »  DSPP home

Benefits & Services
 »  Marketing & Sales
 »  Technical
 »  Collaboration

Resources & Downloads
 »  Technologies & Tools
 »  HP Products
 »  HP Solutions
 »  Software downloads

 »  Specialized programs

 »  Events
 »  Newsletters

Partner information
 »  Find a partner
 »  Find a partner solution

Shortcuts for
 »  Independent software vendors
 »  Integrators & Consultants

About DSPP
 »  Why join?
 »  Membership benefits

 »  Latest updates

 »  Contact us

 »  Site map

How to proceed


This section describes tasks involved in performance analysis and tuning. Execute these tasks to improve the performance of your Java™ applications. If you are not generally familiar with performance tuning, you may want to start with the Training & Tutorials section.

A performance problem can occur anywhere in the collection of programs, computers, data stores and networks that comprise the full solution. Therefore we recommend using a top-down analysis that moves from examining system-wide performance to focusing on a specific program. Start by analyzing the collection of computers that make up the entire system and then work downward to a single JVM process. It sounds simplistic, but performance tuning is an iterative process of looking for performance bottlenecks and then, once found, removing them.

  Performance tuning Java™ on HP-UX  
» Tuning home
Tuning guidelines
» HP-UX setup
» Tuning steps
» Other problems
» Tools
» White papers
» Training & Tutorials
» Java™ SDK/RTE
» References/related links
» Java™ topic
   

It is important at the outset to understand what result you are trying to achieve and to have some repeatable way to measure performance, such as a test sequence that reports average response time for completing a typical user task. When performance tuning, you will probably want to have a short duration test that allows you to quickly test the effect of a particular tweak, as well as a longer duration test that more closely represents the usage of the system in production.

Below is a list of recommended tasks for tuning your application. They are described in detail in the linked pages.

  1. System-based tasks:

    1. Create a model (picture) of the overall architecture by describing all computers in the system and the data and control flows between them.

    2. If any one computer seems to be the constraint (bottleneck) on the overall application performance, check the operating system setup on that computer to see how the operating system is configured.

    3. Note how the JVM is being used. (See also step 2.2 below for the application-related tuning of the JVM.)

    4. Understand any middleware you are using and the available options for tuning it.

  2. Application based tasks:

    A vital rule of performance tuning is to make only one change at a time. Otherwise you can never be quite sure which change in options or configuration caused a subsequently observed change in performance. After each change evaluate the result using your benchmark test to see if performance improved. You may also want to monitor the application with one or more of the performance analysis tools to see the effects of the change in detail.

    1. Run the application and create a baseline level of performance. A perhaps obvious prerequisite to this step is a working application. If you encounter any defects while tuning, you will need to get them fixed before resuming the performance work. Depending on the magnitude of the changes that make up the fix, you may need to back up a few steps in your tuning effort.

    2. Use the tuning steps information, making one change at a time. After each change, re-evaluate the performance of your test case to see if you are making progress.

    3. Most applications have command line options and you should investigate them to understand their effect on performance. Run the application with each option. You may also need to run combinations of options. Make only one change at a time before re-evaluating the result, and document each change. Choose the optimal set of options and continue future tuning with those.

      While tuning you may turn on logging or debugging flags to assist in analyzing application execution. When running the application for performance evaluation, ensure that all such options are set to the values typically used in a production environment.

    4. Check for other problems. These include pathological symptoms you may see for CPU, disk, memory, network, JVM, and application issues. The linked page contains suggestions for correcting these problems. Again, after each change re-evaluate the performance of your test case to see if you are making progress.

Ideally, after completing these steps your application performance will meet your requirements. If the performance is not yet acceptable, then you need to run through the steps again, paying close attention to areas where the application falls behind. For instance, perhaps you observe that cpu usage on the database server is 100%. You might add capacity there or rework your database indexing scheme for more efficient searches.

Look for the squeakiest wheel and grease it. (And then the next squeakiest, and so on...)

» Back to top








Printable version

Privacy statement Using this site means you accept its terms Trademark acknowledgment Contact us
HP Confidential © 2008 Hewlett-Packard Development Company, L.P.