Management and Monitoring the Connector
Monitoring the Connector’s States
The PubSub+ connector provides an ability to monitor its internal states through exposed endpoints provided by Spring Boot Actuator.
An actuator shares information through the endpoints reachable over HTTP/HTTPS. The endpoints that are available are configured in the connector configuration file. Based on the version of the connector, the files differ:
management: simple: metrics: export: enabled: true endpoints: web: exposure: include: "health,metrics,loggers,logfile,channels,env,workflows,leaderelection,bindings,info"
The above sample configuration enables metrics collection through the configuration parameter of management.simple.metrics.export.enabled
set to true
and then shares them through the HTTP/HTTPS endpoint together with other sections configured for the current PubSub+ connector.
The above example configuration enables metrics collection through the configuration parameter of management.metrics.export.simple.enabled
set to true
and then shares them through the HTTP/HTTPS endpoint together with other sections configured for the current PubSub+ connector.
Exposed HTTP/HTTPS Endpoints
The set of endpoints exposed through the HTTP/HTTPS endpoint.
- Exposed Actuator endpoints are available if you query the endpoints using the (for example, using
https://localhost:8090/actuator/<some_endpoint>
) and are also available to the PubSub+ Connector Manager . - The operator may choose to not expose all or some of these endpoints. If so the Actuator endpoints that are not exposed are not visible if you query the endpoints (i.e., using the
https://localhost:8090/actuator/<some_endpoint>
) nor the Connector Manager.
The simple metrics registry is only to be used for testing. It is not a production-ready means of collecting metrics. In production, use a dedicated monitoring system (for example, Datadog, Prometheus, etc.) to collect metrics.
The Actuator endpoint now contains information about the PubSub+ connector’s internal states shared over the following HTTP/HTTPS endpoint:
GET: /actuator/
The following shows an example of the data shared with the configuration above:
"_links": { "self": { "href": "/actuator", "templated": false }, "workflows": { "href": "/actuator/workflows", "templated": false }, "workflows-workflowId": { "href": "/actuator/workflows/{workflowId}", "templated": true }, "leaderelection": { "href": "/actuator/leaderelection", "templated": false }, "health-path": { "href": "/actuator/health/{*path}", "templated": true }, "health": { "href": "/actuator/health", "templated": false }, "metrics": { "href": "/actuator/metrics", "templated": false }, "metrics-requiredMetricName": { "href": "/actuator/metrics/{requiredMetricName}", "templated": true } } }