You can edit the prometheus.yaml file or add ServiceMonitor to configure a data collection rule. Then, Prometheus Monitoring can use the rule to monitor an application.


The Prometheus agent is installed for an application. For more information, see Get started with Prometheus Service.


  1. Log on to the ARMS console.
  2. In the left-side navigation pane, click Prometheus Monitoring.
  3. In the upper-left corner of the Prometheus Monitoring page, select the region where your Container Service for Kubernetes (ACK) clusters reside. Find the cluster that you want to manage and click Settings in the Actions column.
  4. Configure data collection rules for ARMS Prometheus Monitoring to monitor the application in the following scenarios:
    • To monitor the business data of the application deployed in the cluster, such as order information, you can click Add ServiceMonitor on the Service Discovery tab. In the Add ServiceMonitor dialog box, reference the following content to enter the text and click OK:
      kind: ServiceMonitor
        #  Enter a unique name.
        name: tomcat-demo
        #  Enter a namespace.
        namespace: default
        - interval: 30s
          #  Enter the value of the Name field for Port of Prometheus Exporter in the service.yaml file.
          port: tomcat-monitor
          #  Enter the value of the Path field for Prometheus Exporter.
          path: /metrics
          any: true
          #  The namespace of Demo.
            # Enter the value of the Label field in the service.yaml file to find the service.yaml file.
            app: tomcat
    • To monitor business data outside the cluster, such as the number of Redis connections, you can reference the following content to enter the text on the Prometheus Settings tab and click Save:
        scrape_interval:     15s
        evaluation_interval: 15s
        - job_name: 'prometheus'
          - targets: ['localhost:9090']