Custom Dimensions in AWS API Gateway Metrics

0

As part of our application monitoring and performance analysis, we heavily rely on AWS API Gateway for managing our API traffic. While the existing metrics provided by API Gateway are valuable, we have encountered a need to further enhance our monitoring capabilities by incorporating custom dimensions into the metrics.

Specifically, we would like to associate additional contextual information with API Gateway metrics by adding custom dimensions, such as user identity, geographic location, or any other relevant attributes specific to our application's requirements.

However, based on my current knowledge, I understand that API Gateway metrics have a predefined set of dimensions available, and I couldn't find explicit documentation regarding the support for custom dimensions in API Gateway metrics.

To optimize our monitoring and gain deeper insights into our API Gateway performance, we kindly request a guidance on the following:

  1. Is it possible to add custom dimensions to API Gateway metrics?
  2. If custom dimensions are supported, what is the process or API for adding them to API Gateway metrics?
  3. Are there any limitations or best practices we should be aware of when using custom dimensions in API Gateway metrics?
1 Answer
0

API Gateway has the predefined set of metrics that it supports and you can't change that. However, you can enable Access logs in API Gateway and include in there other context variables. You can then use CloudWatch Logs subscriptions to generate metrics out of these logs.

profile pictureAWS
EXPERT
Uri
answered a year ago
  • Hi, Uri, Thanks for your answer. I explored the same option for my requirement using CloudWatch Metric Filter. I replicated the default metrics provided by AWS API gateway semantically to have the same set of metrics. But the number of dimensions provided by ATM by CloudWatch Metric Filters is only up to 3. Our business use case needs at least 15 dimensions. Is there a way I can increase the number of dimensions supported by Metric Filters? I posted a question regards to the stated - https://repost.aws/questions/QUCPsZPwxFT5WspyG7PdUM_g/number-of-dimensions-support-for-metric-filters-in-aws-cloudwatch I'm open to suggestions as to how can I instrument AWS API Gateway Metrics with custom dimensions with no restriction of up to 15 dimensions.

You are not logged in. Log in to post an answer.

A good answer clearly answers the question and provides constructive feedback and encourages professional growth in the question asker.

Guidelines for Answering Questions