Generating a Chart from Operational Metrics Obtained from Service Operational Data

The following use case illustrates how to generate a chart from Operational Metrics obtained from Service Operational Data.

Configuration

  1. Perform the Policy Manager / Envision Integration Installation. At the end of this process you will have configured Envision, Policy Manager, and Network Director container instances. This process also includes using Add Container in the Policy Manager Management Console to register the Network Director container.
  2. Launch the Akana Administration Console for the Network Director container instance, and change the following configuration properties via the Configuration tab:
    1. com.soa.metrics: metrics.rollup.reporter.requireMetricsPolicy set to true.

      Changing the metrics rollup configuration

    2. com.soa.monitor.usage: set values as shown below.

      Changeing the monitor usage configuration

  3. Restart the Network Director container instance.
  4. Launch the Policy Manager Management Console and create a physical service using the file at this URL: http://petstore.swagger.io/v2/swagger.json.
  5. Select Virtualize Service, and virtualize the physical service in the Network Director container.
  6. Go to Policies > Operational and use Add Policy to create an Operational Metrics Policy and configure it based on the illustration below.

    Adding the Operational Metrics policy

  7. Attach a Detailed Auditing Policy (found in the root Policies folder) and an Operational Metrics Policy to the virtual service.
  8. Send requests to the virtual service.

    Send requests to the virtual service

  9. View the usage logs for the service.

    Viewing the usage logs

    Usage data details

  10. View the recorded logs in MongoDB in the AUDIT_LOG collection.

    Viewing the logs in MongoDB

  11. METRICDATASEC should be aggregating the logs per second. To see this, view the following collections: API Operational Metric Data Set, API Contract Metric Data Set, and API User Metric Data Set.

    Viewing the User Metric data set

    Viewing the Operational Metric data set

    Viewing the Contract Metric data set

  12. METRICDATAMIN should be aggregating the logs per minute on the basis of METRICDATASEC. To see this, view the following collections: API Operational Metric Data Set, API Contract Metric Data Set, and API User Metric Data Set.
  13. Send requests to various operations.

    Sending requests to generate data

  14. View the usage logs in MongoDB. The logs should contain the fields and information as per the Operational policy configuration made above

    Viewing the usage logs in MongoDB

  15. Launch the Envision Console and make a chart using the collections API Operational Metric Data Set, API Contract Metric Data Set, and API User Metric Data Set. The charts should show appropriate data:
    • API Operational Metric Data Set

      Making a chart in Envision

      Chart axis properties

      Chart preview

  16. In the same way, verify charts for the API Contract Metric Data Set and API User Metric Data Set.

Back to top