Issues with stackdriver monitoring of pubsub metrics?

423 views
Skip to first unread message

Hrish

unread,
Feb 7, 2018, 3:38:43 AM2/7/18
to Google Cloud Pub/Sub Discussions
According to https://cloud.google.com/monitoring/api/resources#tag_pubsub_subscription the subscription_id is a label for all resource types of pubsub_subscription.

However, querying the monitoring API for a list of metric descriptors for "pubsub.googleapis.com/subscription/num_undelivered_messages" returns zero labels. This is using the Python SDK. Is this expected? How do I filter a particular metric under this resource using the subscription_id?

Alex Mordkovich

unread,
Feb 7, 2018, 10:25:31 AM2/7/18
to Hrish, Google Cloud Pub/Sub Discussions
Hi Hrishikesh,
The pubsub.googleapis.com/subscription/num_undelivered_messages metric should indeed have a subscription_id metric label, and I'm seeing that in the Stackdriver UI it does indeed. I suggest you pose this question on https://stackoverflow.com/questions/tagged/google-cloud-monitoring+python or open an issue at https://github.com/GoogleCloudPlatform/google-cloud-python/issues.

On Wed, Feb 7, 2018 at 3:38 AM, Hrishikesh Barua <tal...@gmail.com> wrote:
According to https://cloud.google.com/monitoring/api/resources#tag_pubsub_subscription the subscription_id is a label for all resource types of pubsub_subscription.

However, querying the monitoring API for a list of metric descriptors for "pubsub.googleapis.com/subscription/num_undelivered_messages" returns zero labels. This is using the Python SDK. Is this expected? How do I filter a particular metric under this resource using the subscription_id?

--
You received this message because you are subscribed to the Google Groups "Google Cloud Pub/Sub Discussions" group.
To unsubscribe from this group and stop receiving emails from it, send an email to cloud-pubsub-discuss+unsub...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/cloud-pubsub-discuss/684c5a00-87ed-4da3-8822-9acf11de65c4%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply all
Reply to author
Forward
0 new messages