Getting Started: Profiling Your Application
The Profiler provides a number of internal settings that let you tune profiling to
your needs. For example, you may decrease the profiling overhead at the cost
of some reduction in the amount of generated information. However, it may take
some time to understand the meaning and use of the numerous settings available
in Profiler.
For many applications, certain default settings are sufficient in most situations.
For this reason, Profiler offers two major profiling options. You can start profiling
(or change its type on-the-fly) by choosing a simple predefined profiling task,
which has most of the settings preset to generally optimal values and requires
minimum or no tuning. Alternatively, you can create your own custom profiling
configuration, where you are free to modify any of the available settings.
Running NetBeans Profiler the First Time
To achieve accurate profiling results, you must have calibration data for each Java platform that will be used for profiling.
If you are running NetBeans Profiler for the first time, or if valid calibration data is unavailable for the Java platform, NetBeans Profiler will prompt you to run the calibration.
For more on obtaining calibration data, see Calibrating NetBeans Profiler.
How to start profiling an application
- Open your project in the IDE.
- Choose Profile -> Profile Main Project (
)
from the main menu.
- Choose a profiling command from the list in the Select Profiling Task dialog box.
- Click Run.
When you click Run, the target application launches and the selected profiling command starts.
The Profiler window opens in the IDE.
To see the results of the profiling command, click the Live Results button
(
) in the Profiler window
to open the Profiling Results tab.
To stop the profiling command, choose Profile > Stop from the Profile menu or click the
Stop button (
). If you start the application with the Profiler, when
you stop the profiling command the application also stops.
See also