Search code examples
google-cloud-platformgoogle-app-enginemonitoringmetricsgoogle-cloud-monitoring

How to track App Engine metrics by endpoint?


I'd like to track metrics for my App Engine app segmented by endpoint:

  • views/second by page
  • requests/second by endpoint
  • response times by endpoint

I've found metrics that look like they'd be helpful, like http/server/response_count and http/server/response_latencies but there doesn't seem to be a way to group them by endpoint. How can I do this?


Solution

  • I found that I could get what I wanted by creating log-based metrics:

    enter image description here

    The trick is to add a label based on the path (protoPayload.resource):

    enter image description here

    Now group by path in the metrics explorer:

    enter image description here