Details
-
New Feature
-
Status: Done
-
High
-
Resolution: Done
-
None
-
0.5
-
Platform Sprint 33, 01 - Core
-
Yes
-
Yes
-
Implex
Description
Use story
As PMM User I need to add my external serverless service on the node I've already have pmm-agent running so that I can collect metrics from service running on the remote node
We expect this will cover 10% of all use cases
Use case
As a User, I have some service, like S3 running as SaaS. The service exposes metrics about itself but there are no metrics about Node this service running and we don't have access to it
We expect user have some Node where s/he can run pmm-admin command
From pmm-amin I need a command to add this S3 to my PMM monitoring
User Interactions
assumption: pmm-admin config command was already executed and Node0 , but this can be any node with configured pmm-admin
We addon separate command to force people to make a difference between this case and Use case 1
pmm-admin add external-serverless [<external-name>] [<url>]
pmm-admin add external-serverless --external-name=S3 --url=http://aws.com:8967/stat
Expected result:
1) in PMM we have remote Node = S3 and External Service with Service Name = S3
2) Serverless service will be monitored from pmm-server , so no other nodes are needed.
3)Added service will not inherit labels (standard and custom) from Node0 or PMM-Server
4) Monitoring added to the standard resolution.
5) Agent is visible in inventory page
6) PMM_SERVER_URL/prometheus contains metrics from external exporter.
Flags:
- all flags to specify where to find an exporter to be scraped
- --external-name - to specify the fixed name used for remote node and for external service.
- --group should be used here as well.
- one of
- --url - to specify Full URL to the endpoint
- --address
- --host and --port
- in last two cases --metrics-path will be "/metrics" by default
- If --url passed --address, --host, --port and --metrics-path should be ignored
How to demonstate:
- Run one of the exporters from the https://prometheus.io/docs/instrumenting/exporters/
- Run `pmm-admin add external-serverless --external-name=S3 --url=http://aws.com :8967 /stat`
- Open Inventory Page
- Check nodes tab and see Remote node with name S3 with address aws.com
- Check services tab and see External service with name S3
- Check agents tab and see external agent with listening port 8967
- Open Prometheus UI(PMM_SERVER_URL/prometheus)
- Open Service -> Config and check that new external exporter is added to config list
- Find some related metrics to the exporter on advanced data exploration dashboard in Grafana.
Out of scope:
Check connection to external exporter.
pmm-admin inventory command is not required, because we already have ability to add external serverless via pmm-admin inventory.
reusing the same remote node