Enabling App Metrics
Set the FLOGO_HTTP_SERVICE_PORT environment variable to point to the port number of the HTTP service that provides APIs for collecting app metrics. This enables the runtime HTTP service.
Procedure
Enabling statistics collection using environment variables
Procedure
Example: retrieve specific metrics for an app
The following is an example of how you would run the above steps for a fictitious app named REST_Echo.
FLOGO_HTTP_SERVICE_PORT=7777 FLOGO_APP_METRICS=true ./REST_Echo-darwin-amd64 curl -X GET http://localhost:7777/app/metrics/flows {"app_name":"REST_Echo","app_version":"1.0.0","flows":[{"started":127639,"completed":126784,"failed":0,"avg_exec_time":0,"min_exec_time":0,"max_exec_time":4,"flow_name":"PostBooks"}]} curl -X GET http://localhost:7777/app/metrics/flow/PostBooks/activities {"app_name":"REST_Echo","app_version":"1.0.0","tasks":[{"started":127389,"completed":126908,"failed":0,"avg_exec_time":0,"min_exec_time":0,"max_exec_time":4,"flow_name":"PostBooks","task_name":"Return"}]}
Copyright © Cloud Software Group, Inc. All rights reserved.