Confirm the team label appears on your metrics
Cost attribution uses labels that already exist on your telemetry. In this milestone, you query your metrics in Explore to confirm that the team label is present before you configure attribution.
To query metrics by team, complete the following steps:
Go to Explore.
Make sure the Prometheus data source for your stack is selected. Its name follows the pattern
grafanacloud-STACK_SLUG-prom.Switch to Code mode to write queries directly.
Enter a query that counts the collectors that report metrics for each
teamvalue.Click Run query to see the results.
The results show one series for each team, for example {team="payments-platform"}. The value is the number of collectors that send metrics for that team.
If no series appear, wait a few minutes for the collectors to poll Fleet Management and apply the pipeline. If you still see no team label, check that:
- The pipeline is active and matches your collectors.
- The collectors have a
teamattribute. - The
GCLOUD_RW_API_KEYenvironment variable is set on the collectors.
In the next milestone, you configure team as a cost attribution label.