Configuring events for webMethods API Gateway destination

Configure the webMethods API Gateway destination so that the events and performance metrics data can be published to webMethods API Gateway.

About this task

By default, error events, lifecycle events, policy violation event, and performance data are published to webMethods API Gateway.

Procedure

  1. Open the menu options and select Administration.
  2. Select Destinations.
  3. Select API Gateway to configure the event types for this destination.
  4. In Event types, select the type of events to publish to webMethods API Gateway.

    The available event types are

    • Error Occurs each time an API invocation results in an error.
    • Lifecycle Occurs each time an webMethods API Gateway is started or shut down.
    • Policy violation Occurs each time an API invocation violates the policy enforcement that was set for the API.
  5. Select Report performance data to publish performance metrics data.
  6. In the Publish interval box, provide a time interval (in minutes) how often the webMethods API Gateway must publish performance metrics. Enter a value from 1 through 60. The default is 60 minutes.
  7. In the Audit log data section, select the management areas for which the audit logs are recorded in the webMethods API Gateway destination.

    Audit logs provide a record of system transactions, events, and occurrences in webMethods API Gateway. You can configure audit login to show the following events:

    • API management
    • Application management
    • Team management
    • Group management
    • Package management
    • Promotion management
    • Approval management
    • Alias management
    • Analytics management
    • Policy management
    • Plan management
    • User management
    Note: By default, audit logging is enabled for all listed management areas in the webMethods API Gateway destination.
  8. Click Save

What to do next

When you see that you are not able to parameterize custom indices for transaction events in webMethods API Gateway.

Custom indices can be configured for transaction events in the webMethods API Gateway under Destinations > Elasticsearch > Configuration page. But parameterizing custom indices is not supported in API Gateway. For example, appending the current date to the index name. Consider an index name attendant, it must be appended with the current date that is txnData_12_08_2020 and rolled up daily.

Resolution

You can achieve this use case by using the Elasticsearch aliases and rollover APIs of Elasticsearch.

A sample use case is as follows

Create an alias in the Elasticsearch server, for example txnData and an index rollover like txnData_12_08_2020, txnData_12_08_2020. The alias txnData points to all the indices txnData_12_08_2020, txnData_12_08_2020. One of the indices in the list is write-enabled and that are the latest and the rest of the indices is read-only.

webMethods API Gateway sends the events to txnData alias and that alias defines the index that it writes the data to, based on the date.