Enabling method trace and adjusting the path display

IBM® Cloud Application Performance Management, Advanced Private with diagnostic data enables users to have a Request Traces dashboard. If method data is collected, calls to methods are shown. The Method Trace widget displays request instances and their nested requests. You can enable method trace to include calls to methods in the nested requests. You can also adjust the configuration of the Request Stack Trace widget to show more than the default 50 characters of each file path.

About this task

Method trace is disabled by default. Complete the first procedure to enable method trace for display in the Request Traces dashboard. You can enable method trace by changing a setting in the configuration file.

Complete the second procedure to adjust the number of characters shown for the file path in the Request Stack Trace widget.

Procedure

  • To enable method trace, edit the instrumenter_settings.rb settings:
    1. Locate the instrumenter_settings.rb file in the Ruby agent installation, for example, install_dir/install-images/kkm/dchome/appClassName/config where appClassName is the Ruby application class name, and install_dir is the installation directory of Ruby agent. The default installation directory is /opt/ibm/apm/agent.
    2. Open instrumenter_settings.rb in a text editor.
    3. Set the following property to 10000.
      max_method_to_instrument
      The value can be higher, but a much higher value might cause performance issues. (See also Increasing the JVM heap size.)
    4. Restart the Ruby on Rails applications to begin method data collection.
    For more information about all the instrumenter_settings.rb properties, see Configuring the diagnostics data collector.
  • To adjust the file path display size in the Request Stack Trace widget, edit the dfe.properties file:
    1. Locate the dfe.properties file in the Ruby agent installation, for example, install_dir/lx8266/km/bin/dfe.properties
      where install_dir is the installation directory of Ruby agent. The default installation directory is /opt/ibm/apm/agent.
    2. Open dfe.properties in a text editor.
    3. Change the maximum size of the file path to display in each stack trace element by adjusting the value of the following property:
      dfe.stacktrace.filepath.maxsize
    4. Restart the Ruby agent.