If you have deployed the processing unit using TIBCO BusinessEvents Monitoring and Management (MM), you can turn the profiler on and off using the MM Console.
Set the following properties in the Cluster Deployment Descriptor (CDD) Processing Unit tab, for all processing units (engines) whose RTC performance you want to profile.
|
|
|
|
|
|
|
|
|
|
Optional, if be.engine.profile.*.file is specified.
If be.engine.profile.*.file is specified and be.engine.profile.Agent_Class_Name.file is not specified, then the file name is the value of be.engine.profile.*.file, with the Agent_Class_Name appended.
If the properties be.engine.profile.*.file and be.engine.profile.Agent_Class_Name.files are not specified the following occurs:
The file name is be-profile.csv, followed by an underbar, followed by the Agent_Class_Name: be-profile_Agent_Class_Name.csv
|
|
|
Default name is be-profile.csv and it is located under the current working directory, if file name is not specified.
|
|
|
When the duration period ends, the profiler continues to collect statistics for the current RTC until the RTC is completed, then outputs data and stops. So the RTC in progress is always completed, even if the profiler is directed to stop during an RTC.
|
|
|
When the duration period ends, the profiler continues to collect statistics for the current RTC until the RTC is completed, then outputs data and stops. So the RTC in progress is always completed, even if the profiler is directed to stop during an RTC.
If you set duration to a value of zero or less (<= 0), then profiling continues until the agents stop or profiler is explicitly turned of using a function or Hawk method.
When be.engine.profile.Agent_Class_Name.duration and be.engine.profile.*.duration are both present, the duration specified in be.engine.profile.Agent_Class_Name.duration takes precedence.
|
|
|
|
|
|
When be.engine.profile.Agent_Class_Name.level and be.engine.profile.*.level are both present, the level specified in be.engine.profile.Agent_Class_Name.level takes precedence.
|
This section assumes you understand how to use TIBCO BusinessEvents functions. It tells you which functions to use and the effect of each function.
To turn the profiler on In your rule or rule function, use the following function to turn on the profiler:
The above function turns on the TIBCO BusinessEvents Profiler and starts collecting data for the specified duration for the agent in which the rule or rule function that calls this function is executed. The profiler starts collecting data at the beginning of next RTC.
Profile data is output to the specified file in comma-separated value format at the end of the duration period, unless the profiler is turned off before the end of the duration, in which case it is output at the end of the RTC that completes after the profiler is turned off.
long duration: See
be.engine.profile.Agent_Class_Name.duration (Here
Agent_Class_Name is the current agent in which the rule or rule function that calls this function is executed.)
To turn the profiler off In your rule or rule function, use the following function to turn off the profiler:
The above function turns off the TIBCO BusinessEvents profiler and writes the profile data to a file for the agent in which the rule or rule function that calls this function is included (the file is output at the end of the RTC that completes after the profiler is turned off). There is no effect if the profiler is not on.
Before you Begin Ensure that the property
hawk.enabled is set to true in the CDD at the cluster level before the TIBCO BusinessEvents engine starts.
To turn the profiler on Use the following method to turn on the profiler:
The above method turns on the TIBCO BusinessEvents profiler for the specified agent. The profiler starts collecting data at the beginning of next RTC for the specified duration.
This method works the same way as the Engine.Profiler.startCollectingToFile() function (see
To Turn Profiler On and Off Using Functions), except that it requires you to specify an agent class.
String session: If you want to monitor multiple agents, execute the method once for each, specifying the agent class name in each case. If there is only one agent, the session parameter is optional.
To turn the profiler off In your rule or rule function, use the following function to turn off the profiler:
The above method turns off the TIBCO BusinessEvents profiler and writes the profile data into a file for the specified agent when the current RTC has completed. You must execute the method once for each session, as needed.