Skip to main content

Enabling Activity Monitoring

Enabling Activity Monitoring

You can monitor activity for a single namespace or for multiple namespaces that are running on the same instance of InterSystems IRIS. To enable activity monitoring, follow this procedure:

  1. For each namespace that you want to monitor:

    1. Add the Ens.Activity.Operation.Local business operation to the production in the namespace.

    2. Configure the following settings for the operation:

      StorageNamespace

      Namespace where InterSystems IRIS stores the statistics that it collects.

      RecordStatsInterval

      How frequently in seconds InterSystems IRIS moves the statistics that it collects from temporary storage to the Activity Monitor database tables. You can view and query the statistics only after they are written to a table. A value less than or equal to 0 indicates that InterSystems IRIS does not store the statistics.

    3. Configure the remaining settings. For more information, see Settings in All Business Operations.

    4. Enable the operation.

    5. To enable statistics collection for all configuration items in the production, call the EnableStatsForProduction()Opens in a new tab method or, to enable statistics collection for individual configuration items, call the EnableStatsForConfig()Opens in a new tab method. For example, to enable statistics collection for all production configuration items in the MYDEMO namespace, enter the following in the Terminal:

      set $namespace="MYDEMO"
      do ##class(Ens.Util.Statistics).EnableStatsForProduction()
      
  2. If your business service calls SendRequest methods directly, you must add the statistics recording APIs as described in Writing Custom Code to Record Activity. If your business service uses OnProcessInput, you can skip this step.

  3. Create or select an existing interoperability-enabled namespace to use for data collecting. If you are only collecting activity data from a single namespace, you can select that namespace to collect the data or you can create a new one. If you are collecting data from multiple namespaces, we recommend that you create a new namespace and only use it for collecting the statistics.

  4. Make it possible to use Analytics to access to the data by enabling Analytics in the namespace’s default web application. To do this:

    1. Select System Administration > Security > Applications > Web Applications.

    2. Select the default web application for the namespace. For example, if the namespace is WATCHACTIVITY, the default web application is typically /csp/watchactivity.

    3. Select the Analytics check box.

    4. Select Save.

FeedbackOpens in a new tab