Enabling open tracing for API management

Enable open tracing for API Connect so that you can monitor the API management capability with the Operations Dashboard in IBM Cloud Pak® for Integration.

Before you begin

Verify that the Operations Dashboard is installed.

Procedure

  1. Change to the namespace where you installed API Connect to support the API management capability.
  2. Update the API Connect Cluster CR and add an openTracing section:
    1. Access the operand by clicking Installed Operators > API Connect > API Connect Cluster > instance > YAML.
    2. In the spec section, add the following statements to the gateway section:

      For a list of the open tracing mappings for each 2020.4 release, see Open Tracing image mapping per release.

          openTracing:
            imageAgent: >-
              cp.icr.io/cp/icp4i/od/icp4i-od-agent:1.0.19-amd64@sha256:37e27adfb970f62d60dcaecb78df9679d938ecb5b02efdbdb926e0e623bd0268
            imageCollector: >-
              cp.icr.io/cp/icp4i/od/icp4i-od-collector:1.0.19-amd64@sha256:8ea27f936a6f703d42b8347d474042ffcfa7fdb7f9b447884eb8fdb5a5c70868
            odTracingDataHostname: od-store-od.tracing.svc
            odTracingNamespace: operations-db
            odTracingRegistrationHostname: icp4i-od.tracing.svc

      The following example shows the updated gateway section:

      apiVersion: apiconnect.ibm.com/v1beta1
      kind: APIConnectCluster
      metadata:
        annotations:
          kubectl.kubernetes.io/last-applied-configuration: >
            {"apiVersion":"apiconnect.ibm.com/v1beta1","kind":"APIConnectCluster","metadata":{"annotations":{},"name":"apic","namespace":"apic"},"spec":{"appVersion":"10.0.0.0","license":{"accept":true,"use":"nonproduction"},"profile":"n3xc4.m16"}}
        creationTimestamp: '2021-12-15T18:31:50Z'
        generation: 5
        name: apic
        namespace: apic
        resourceVersion: '15638661'
        selfLink: /apis/apiconnect.ibm.com/v1beta1/namespaces/apic/apiconnectclusters/apic
        uid: 6b62f622-6b4e-4030-981f-1713a9c3db33
      spec:
        appVersion: 10.0.1.4-ifix1-eus
        gateway:
          adminUser: {}
          apicGatewayPeeringTLS: {}
          apicGatewayServiceTLS: {}
          gatewayEndpoint: {}
          gatewayManagerEndpoint: {}
          openTracing:
            imageAgent: >-
              cp.icr.io/cp/icp4i/od/icp4i-od-agent:1.0.19-amd64@sha256:37e27adfb970f62d60dcaecb78df9679d938ecb5b02efdbdb926e0e623bd0268
            imageCollector: >-
              cp.icr.io/cp/icp4i/od/icp4i-od-collector:1.0.19-amd64@sha256:8ea27f936a6f703d42b8347d474042ffcfa7fdb7f9b447884eb8fdb5a5c70868
            odTracingDataHostname: od-store-od.tracing.svc
            odTracingNamespace: operations-db
            odTracingRegistrationHostname: icp4i-od.tracing.svc
        imagePullSecrets:
          - ibm-entitlement-key
          - ibm-entitlement-key
        imageRegistry: cp.icr.io/cp/apic
        license:
          accept: true
          metric: VirtualProcessorCore
          use: nonproduction
        profile: n3xc4.m16
    3. Save your changes.
  3. Register API Connect with the Operations Dashboard:
    1. Click Operations Dashboard > Manage > Registration Process.
    2. Approve the request, and then follow the instructions to create the necessary secret.
    3. Verify that the API Connect Gateway pod now includes 3 containers, which indicates that tracing is now enabled.

      See the apic-gw-0 pod in the following example:

      oc get pods -n apic
      NAME                                                              READY   STATUS      RESTARTS   AGE
      apic-a7s-client-84c6f5f984-thzjd                                  1/1     Running     0          14d
      apic-a7s-ingestion-676b486477-2zbs8                               1/1     Running     0          14d
      apic-a7s-mtls-gw-bb54f54c-lp97f                                   1/1     Running     0          14d
      apic-a7s-storage-coord-7c8789cc8c-gnhlb                           1/1     Running     0          14d
      apic-a7s-storage-data-0                                           1/1     Running     0          14d
      apic-a7s-storage-master-0                                         1/1     Running     0          14d
      apic-configurator-6rxhn                                           0/1     Completed   0          14d 
      apic-gw-0                                                         3/3     Running     0          3m36s 
      apic-gw-datapower-monitor-76ffdf6cb5-c5spx                        1/1     Running     0          4m22s
      apic-gw-od-registration-job-chbpd                                 0/1     Completed   0          3h47m