Default language.

Gathering statistics about the longest running API and SQL commands


The  continuously collects a list of the longest running APIs and SQL commands. Use the Longest Running API/SQL screen to perform the following tasks:

  • View the details of longest running API / SQL. 
  • Record the list of the longest API and SQL commands and view the list of recent commands.
  • Use this data as a debugging tool to identify an operation that takes excessive time.

You can perform these operations on a single server or across all servers in the server group. The following screenshot shows the longest running API/SQL tab of the AR System Management Console:

Longest-running-API.png

To gather statistics about the longest running SQL and API commands

  1. From the Loading Settings From Server list, select a server from where you want to load settings.
  2. From the Applicable To field, select either Server or All.
    The settings of the server you have selected from the Loading Settings From Server list, are applied to the server group or to a specific server you have selected.
  3. Perform the following optional steps:
    1. In the Number of Saved Operations field, specify the number of API or SQL commands that are running on a server. 
      The server retains the specified number of operations.
      Maximum Value—100
      Default value—20
      Recommended value—20

    1. In the Auto Save and Purge Interval (min) field, specify the time interval (minutes) to automatically record the list of commands. 
      The command list is not saved automatically.
      Default value—20 
    2. In the Minimum Elapsed Time (mSec) field, set the minimum duration of the longest API and SQL events saved in the memory buffer in milliseconds. 
      Any event shorter than this value is discarded.
    3. Select Enable Console Display.
      Displays API and SQL events in the console when an automatic save is triggered by the time specified in the Auto Save and Purge Interval (min) field.
    4. Select Enable Exceptional Logging.
      Enables exception logging, where all API and SQL calls that exceed the value specified in the Minimum Elapsed Time (mSec)
       field are immediately written to the arexception.log file.
      Default  value
      5000 ms (5 seconds)
  1. Click Apply Configuration to save the preferences.
  2. In the Save Current Options In Memory field, select from the following options:

    Option

    Description

    Completed API

    List of the longest API commands that are complete.

    Completed SQL

    List of the longest SQL commands that are complete.

    Pending API

    List of API commands that are currently in progress.

    Pending SQL

    List of SQL commands that are currently in progress.

  3. Click Save Now to list the longest API and SQL commands.
  4. In the Show field, select an option to view the data. The following options are available:
    1. API
    2. SQL
    3. ALL (Default)
  1. In the For field, select the time interval to view the data.
  2. Click Refresh to reload the table with specified preferences.
    The Open Longest APIs and Open Longest SQLs links open the corresponding forms showing more details of the server statistics. For more information, see Enabling-and-viewing-statistics-about-long-running-SQL-and-API-calls.

 

Tip: For faster searching, add an asterisk to the end of your partial query. Example: cert*