Hello,
I posted similar last week but post didn't appear. I want to know how to tell how many messages are in a PubSub topic.
In the GCloud admin console it only displays the subscriber count, but nothing about messages.
In CLI console I can list topics but they don't display message count.
In Stack Overflow others asked the same question 2 years ago and seems still not resolved.
In Github there in issue #8 about similar issue and after many months discussion only response was product team would have to add the feature to get message count but no update since last year.
Viewing message count in topics is a basic feature of any queue system, and available in SQS, Kinesis, Kafka, RabbitMQ, etc. I can't believe this wouldn't exist in PubSub. So far the only answer I've found is some monitoring setting for unconsumed messages in Stackdriver but no instructions exactly what to do. Best I can find???
https://cloud.google.com/monitoring/api/metrics
Is there some documented resource that explains step-by-step how to get the message count in a PubSub topic?
Thanks,
Mike