Configuring Custom Monitoring of an Application Component
ServiceStage allows you to obtain monitoring data based on custom metrics.
You can configure custom metric monitoring during or after application component deployment.
Precautions
- Currently, only Gauge metrics of Prometheus can be obtained.
- Before setting custom metric monitoring for an application component, you must understand Prometheus and provide the GET API for obtaining custom metric data in your application component so that ServiceStage can obtain custom metric data using this API.
Procedure
When the component type is Common and the runtime system is Docker, perform the following operations:
- Access the page for setting custom metric monitoring for an application component.
- To set custom metric monitoring during component configuration in the application component deployment, go to 2.
- To set custom metric monitoring after an application component is deployed, go to 3.
- On the Configure Component page:
- Specify the following parameters to set custom metric monitoring for the application component.
Parameter
Description
Mandatory
Report Path
URL provided by the exporter for ServiceStage to obtain custom metric data.
Example: /metrics
Yes
Report Port
Port provided by the exporter for ServiceStage to obtain custom metric data.
Example: 8080
Yes
Monitoring Metrics
Name of the custom metric provided by the exporter.
Example: ["cpu_usage","mem_usage"]
- If this parameter is not set, ServiceStage collects data of all custom metrics.
- If you set this parameter, for example, to ["cpu_usage","mem_usage"], ServiceStage collects the data of the specified cpu_usage and mem_usage metrics.
No
- Click Next to complete the component deployment.
- Specify the following parameters to set custom metric monitoring for the application component.
- Log in to ServiceStage and choose Application Management > Application List to view all applications.
- Click an application. The Overview page is displayed.
- On the Environment View tab, select an environment to view the application components that have been deployed in the environment.
- Click an application component. The Overview page is displayed.
- Choose O&M Configurations and set the following parameters.
Parameter
Description
Mandatory
Report Path
URL provided by the exporter for ServiceStage to obtain custom metric data.
Example: /metrics
Yes
Report Port
Port provided by the exporter for ServiceStage to obtain custom metric data.
Example: 8080
Yes
Monitoring Metrics
Name of the custom metric provided by the exporter.
Example: ["cpu_usage","mem_usage"]
- If this parameter is not set, ServiceStage collects data of all custom metrics.
- If you set this parameter, for example, to ["cpu_usage","mem_usage"], ServiceStage collects the data of the specified cpu_usage and mem_usage metrics.
No
- Click Re-deployment to complete the setting.
After the configuration and deployment are complete, you can view the monitoring metric data on the AOM console. For details, see Metric Monitoring.
For other types of components, perform the following operations:
- Access the page for setting custom metric monitoring for an application component.
- To set custom metric monitoring during component configuration in the application component deployment, go to 6.
- To set custom metric monitoring after an application component is deployed, go to 2.
- Log in to ServiceStage and choose Application Management > Application List to view all applications.
- Click an application. The Overview page is displayed.
- On the Environment View tab, select an environment to view the application components that have been deployed in the environment.
- Click an application component. The Overview page is displayed. Choose Upgrade.
- Choose Advanced Settings > O&M Monitoring. On the O&M Policy tab, set the following parameters.
Parameter
Description
Mandatory
Report Path
URL provided by the exporter for ServiceStage to obtain custom metric data.
Example: /metrics
Yes
Report Port
Port provided by the exporter for ServiceStage to obtain custom metric data.
Example: 8080
Yes
Monitoring Metrics
Name of the custom metric provided by the exporter.
Example: ["cpu_usage","mem_usage"]
- If this parameter is not set, ServiceStage collects data of all custom metrics.
- If you set this parameter, for example, to ["cpu_usage","mem_usage"], ServiceStage collects the data of the specified cpu_usage and mem_usage metrics.
No
- Complete the setting of the custom metric monitoring.
- If the custom metric monitoring policy is set during component configuration, and click Next.
- If the custom metric monitoring policy is set after the application component is deployed, and click Re-deployment.
After the configuration and deployment are complete, you can view the monitoring metric data on the AOM console. For details, see Metric Monitoring.
Feedback
Was this page helpful?
Provide feedbackThank you very much for your feedback. We will continue working to improve the documentation.See the reply and handling status in My Cloud VOC.
For any further questions, feel free to contact us through the chatbot.
Chatbot