Monitor services in API Gateway Manager

This topic explains how to monitor example services using the API Gateway Manager monitoring tools. For example, real-time monitoring metrics, message traffic monitoring, and performance statistics.

Note   API Gateway Manager is designed as an operational diagnostics tool only. API Gateway Analytics is recommended for monitoring and reporting of large volumes of historical data. For more details, see the API Gateway Analytics User Guide.

Ensure the API Gateway is running

You must first ensure that the API Gateway, Admin Node Manager, and API Gateway tools are running. For more details, see the following:

Ensure monitoring is enabled

Real-time monitoring and traffic monitoring are enabled by default. If necessary, you can enable these settings as follows:

  1. In the Policy Studio tree, select the Server Settings node, and select Monitoring > Traffic Monitor.
  2. In the Traffic Monitor settings, ensure Enable Traffic Monitor is selected.
  3. Select Monitoring > Real Time Monitoring, and ensure Enable Real Time Monitoring is selected.
  4. Click the Deploy icon in the Policy Studio toolbar to deploy these settings to the API Gateway. Alternatively, press F6.
Note   Enabling traffic monitoring may have a negative impact on performance. If you wish to maximize performance, you can disable these settings. For more details, see Traffic monitoring settings.

View real-time monitoring

You can view a wide range of monitoring data in the API Gateway Manager. For example, this includes message status, message traffic, filter execution path, message content, system, services, and remote hosts. You can view real-time traffic monitoring summary data on the main Dashboard tab in the TRAFFIC section. The following example shows the number of messages that have been passed by the API Gateway on to a service:

Real-time monitoring

Each time you send test messages through the API Gateway to an example service (for example, using API Tester or the Send Request (SR) tool), the message status is displayed in the TRAFFIC section.

View traffic monitoring

You can use the traffic monitoring tools in API Gateway Manager for operational diagnostics and root cause analysis. The Traffic view provides a web-based message log of the HTTP, HTTPS, JMS, and FTP traffic processed by the API Gateway. You can perform tasks such as the following:

  • Filter messages on a range of criteria (for example, transaction ID, service name, or remote host)
  • Drill down to view message contents
  • View performance statistics (for example, number of requests, average bytes sent, or average duration)

For example, you can click the Traffic button in the API Gateway Manager to view summary information for each message sent to the API Gateway. Alternatively, you can click one of the summary charts displayed on the Dashboard (for example, Messages passed or Messages failed). This displays the message traffic automatically filtered according to your selection.

The following simple example shows the details displayed on the Traffic tab for Messages passed by the API Gateway:

Message monitoring

Filter message traffic

In the SELECTION pane on the left of the Traffic tab, you can click the Apply button to filter the messages displayed based on a range of criteria. For example, the default filters include REQUEST FROM (Client or API Gateway), MAX RESULTS PER SERVER, TRANSACTION STATUS, and TIME INTERVAL.

You can click Add Filter to search on different criteria (for example, Service Name, Remote Host, Authentication Subject, Transaction ID, and Operation). The API Gateway inserts a transaction ID in all HTTP and HTTPS traffic in a header named X-CorrelationID. When you have selected your search criteria, click the Apply button.

View message content

When you click a selected message listed on the Traffic tab, this displays the message filter execution path and the contents of each request message and response message. The following example displays the message path for a simple Google Search message:

Message path

The following example shows the corresponding message content for the selected message displayed below:

Message content

You can click Save Request or Save Response to download the message contents and save them to a file.

View performance statistics

The Performance tab displays performance statistics for the HTTP and HTTPS traffic processed by the API Gateway. For example, these include the number of requests, average bytes sent, and average duration. For example, the Performance page is displayed as follows:

Performance statistics

Filter performance statistics

You can click the Apply in the left pane to filter the performance statistics displayed based on different criteria. By default, the statistics are grouped by path name, with a time interval of 1 day. You can select different criteria from the GROUP BY and TIME INTERVAL lists. When you have selected your search criteria, click the Apply button.

Detect malformed messages

Messages with malformed content or an incorrect relative path are blocked by the API Gateway and displayed on the Dashboard tab in the TRAFFIC section as follows:

Message blocked

You can click the chart to display the list of blocked messages automatically filtered on the Traffic tab. Click a message in the list to display the filter execution path and message content. The following example shows the execution path of a malformed message that has been blocked by the API Gateway:

Message blocked

Note   When a blocked message has failed in API Gateway, this means that a filter executed in a policy has returned a failure status. When a blocked message generates an exception, this means that a filter executed in a policy has aborted (thrown an exception). For more details on filters and policies, see the API Gateway Policy Developer Guide.

Monitor real-time metrics

The Monitoring view enables you to monitor successes, failures, exceptions, and real-time metrics for the following:

  • System: Metrics for memory, disk space, and CPU.
  • API Services: Metrics for messages and processing times.
  • API Methods: Metrics for messages and processing times.
  • Clients: Metrics for messages.
  • Remote Hosts: Metrics for transactions, bytes sent and received, and response times.

For example, on the System tab, when you click a panel in the ALL SYSTEMS section at the top, a graph for the selected setting is displayed below. The following example shows the graph displayed for the System CPU Avg (Max) setting selected on the right:

System data

You can drill down to view metrics for specific components at the bottom (for example, for a specific API Gateway group or instance, service, client, method, or remote host). You can also configure the metrics time window on the right (for example, 10 minutes, 10 hours, or 5 days).

Configure dynamic trace, logging, and monitoring

You can click the Settings > Dynamic tab to configure trace, logging, and monitoring settings on-the-fly. These are dynamic settings, which means that you do not need to refresh or deploy to the API Gateway. For example, you can specify these settings for an API Gateway system, instance, service, interface, or path. For more details, see Configure API Gateway logging and events.

Related Links