Stackdriver monitoring questions

137 views
Skip to first unread message

David Tildesley

unread,
Mar 25, 2019, 6:30:19 PM3/25/19
to Google Stackdriver Discussion Forum

After playing with StackDriver monitoring I have the following observation based questions:

Context:

Applications send monitoring custom metrics to StackDriver Monitoring via client library. We want to get metrics "out of" StackDriver and publish on Pub-Sub topic so that we have flexibility to roll our own operational dashboards within operational UI. Publishing on Pub-Sub also allows us to create a BigQuery sink for the monitoring metrics using standard DataFlow template.

Issue:

  1. Unlike with StackDriver Logging, the StackDriver Monitoring does not provide an "export to pubsub sink" for monitoring metrics. This means we have to develop a custom component to poll for the time series metrics, retrieve and publish on pubsub. Please confirm or suggest alternatives.
  2. We want to infer an application uptime check from prescence or absence of application custom metrics in a time period and be able to tap into that uptime check "status" and publish in a message on pubsub but the api doesnt appear to provide this capability. Please confirm and suggest a workaround.
  3. Unless it is a tangible GCP resource there doesn't appear to be a way of creating an uptime check from a custom monitoring metric produced by an external (non GCP hosted) application in the StackDriver portal. Please confirm and  suggest a workaround.
  4. I can't find anywhere where it explicitly states that Cloud IoT supports IoT monitoring metrics channel automatically sent to StackDriver Monitoring. Please confirm.

Thanks in advance for any assistance offered.

Henry Pan

unread,
Mar 28, 2019, 5:35:00 PM3/28/19
to Google Stackdriver Discussion Forum
Similar issue also looking for advice.

Cheers

HP

Mary Koes

unread,
Mar 28, 2019, 5:48:37 PM3/28/19
to Henry Pan, Rory Petty, Google Stackdriver Discussion Forum
Re: Issue 1 - You are correct that we do not have an "export to pubsub" sink.  We did however recently write a solution around sending Monitoring data to another destination that might be useful.

Re: Issue 2 - Are you asking for alerts to be able to publish to PubSub or something else?  +Rory Petty 

Re: Issue 3 - I'm not sure I understand the use case.  Are you asking how to alert on a custom metric that comes from outside GCP?  Assuming it's written to the Monitoring API, this should work using metric threshold alerts.  

Re: Issue 4: I think there's another thread on this...  Metrics that are pushed to Stackdriver by IoT are listed here.  For other use cases, you may consider custom metrics (write against the API using libraries such as OpenCensus) or logs based metrics since logs are automatically pushed through to Stackdriver Logging.

Best,

Mary



--
© 2016 Google Inc. 1600 Amphitheatre Parkway, Mountain View, CA 94043
 
Email preferences: You received this email because you signed up for the Google Stackdriver Discussion Google Group (google-stackdr...@googlegroups.com) to participate in discussions with other members of the GoogleStackdriver community.
---
You received this message because you are subscribed to the Google Groups "Google Stackdriver Discussion Forum" group.
To unsubscribe from this group and stop receiving emails from it, send an email to google-stackdriver-d...@googlegroups.com.
To post to this group, send email to google-stackdr...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/google-stackdriver-discussion/35311450-a7a9-4931-a91c-bd4ac98dfc05%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Henry Pan

unread,
Mar 28, 2019, 5:55:46 PM3/28/19
to Mary Koes, Rory Petty, Google Stackdriver Discussion Forum
Wow, Mary,

Thanks for your quick response. Pls see my comments below in dark red for your reference:


Henry Pan

DevOps Architect | Dito

henr...@ditoweb.com | PHONE: (425) 802-3975

Dito Logo.png




On Thu, Mar 28, 2019 at 2:48 PM Mary Koes <mk...@google.com> wrote:
Re: Issue 1 - You are correct that we do not have an "export to pubsub" sink.  We did however recently write a solution around sending Monitoring data to another destination that might be useful. Cool. Allows me to take a look.

Re: Issue 2 - Are you asking for alerts to be able to publish to PubSub or something else?  +Rory Petty  I'm thinking to publish the alerts in BigQuery -> Stadio for better in deep analysis & graphics.

Re: Issue 3 - I'm not sure I understand the use case.  Are you asking how to alert on a custom metric that comes from outside GCP?  Assuming it's written to the Monitoring API, this should work using metric threshold alerts. 
 
I'm asking to setup custom metric alert that comes from logs collected by stackdriver. Would you pls share the docs on using metric threshold alerts?

Re: Issue 4: I think there's another thread on this...  Metrics that are pushed to Stackdriver by IoT are listed here.  For other use cases, you may consider custom metrics (write against the API using libraries such as OpenCensus) or logs based metrics since logs are automatically pushed through to Stackdriver Logging. OK. I'll learn from that.

Best,

Mary


Rory Petty

unread,
Mar 28, 2019, 6:05:04 PM3/28/19
to Henry Pan, Mary Koes, Google Stackdriver Discussion Forum
Issue #2
We have Cloud PubSub as an alert notification provider on our roadmap. For now, you can use the Webhook to send alert notifications to a Cloud Function or an API endpoint that you write, and you can call the BigQuery API to write data there.

Issue #3
That sounds like SD Logs-based Metrics unless I'm misunderstanding something

Thanks,
Rory


Henry Pan

unread,
Mar 28, 2019, 6:06:59 PM3/28/19
to Rory Petty, Mary Koes, Google Stackdriver Discussion Forum
Saluting Rory for jumping in to save me:>)


Thanks


Henry Pan

DevOps Architect | Dito

henr...@ditoweb.com | PHONE: (425) 802-3975

Dito Logo.png


Reply all
Reply to author
Forward
0 new messages