Uploaded image for project: 'Red Hat Process Automation Manager'
  1. Red Hat Process Automation Manager
  2. RHPAM-3784

[GSS] (7.10.x) Prometheus exporter 7.10.1 : kie_server_container_started_total gives wrong count

    XMLWordPrintable

Details

    Description

      The counter "kie_server_container_started_total" should show the total number of containers with statut "STARTED", whereas "kie_server_container_running_total" should also take into account containers with status "DEACTIVATED". Unfortunatly, "kie_server_container_started_total" counts DEACTIVATED containers as well. Here is the GET /server/containers output:

      {
       "type": "SUCCESS",
       "msg": "List of created containers",
       "result": {
       "kie-containers": {
       "kie-container": [
       {
       "container-id": "org.redhat:project1:1.0.0",
       "release-id": {
       "group-id": "org.redhat",
       "artifact-id": "project1",
       "version": "1.0.0"
       },
       "resolved-release-id": {
       "group-id": "org.redhat",
       "artifact-id": "project1",
       "version": "1.0.0"
       },
       "status": "DEACTIVATED",
       "scanner": {
       "status": "DISPOSED",
       "poll-interval": null
       },
       "config-items": [],
       "messages": [
       {
       "severity": "INFO",
       "timestamp": {
       "java.util.Date": 1625857435391
       },
       "content": [
       "Container org.redhat:project1:1.0.0 deactivated successfully."
       ]
       }
       ],
       "container-alias": null
       },
       {
       "container-id": "org.redhat:project1:1.1.0",
       "release-id": {
       "group-id": "org.redhat",
       "artifact-id": "project1",
       "version": "1.1.0"
       },
       "resolved-release-id": {
       "group-id": "org.redhat",
       "artifact-id": "project1",
       "version": "1.1.0"
       },
       "status": "STARTED",
       "scanner": {
       "status": "DISPOSED",
       "poll-interval": null
       },
       "config-items": [],
       "messages": [
       {
       "severity": "INFO",
       "timestamp": {
       "java.util.Date": 1625857438530
       },
       "content": [
       "Container org.redhat:project1:1.1.0 successfully created with module org.redhat:project1:1.1.0."
       ]
       }
       ],
       "container-alias": null
       }
       ]
       }
       }
      }

      When looking at the Prometheus output for this configuration, one gets:

      kie_server_container_started_total = 2
       kie_server_container_running_total = 2

      instead of

       

      kie_server_container_started_total = 1
       kie_server_container_running_total = 2
       
      

       

      Attachments

        Activity

          People

            rhn-support-fspolti Filippe Spolti
            rhn-support-omolinab Oscar Molina
            Jakub Schwan Jakub Schwan
            Votes:
            0 Vote for this issue
            Watchers:
            6 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: