Important
Enable the AWS CloudWatch Metric Streams integration to monitor all CloudWatch metrics from your AWS services, including custom namespaces. Individual integrations are no longer our recommended option.
New Relic infrastructure integrations include an integration for reporting your Amazon API Gateway data to New Relic. This document explains how to activate this integration and describes the data that can be reported.
Tip
API Gateway v1 metrics are available exclusively through the API polling integration for Amazon API Gateway. API Gateway v2 metrics are streamed through CloudWatch Metric Streams.
Features
Amazon's API Gateway is a fully managed service that allows you to create, publish, maintain, monitor, and secure APIs at any scale. With the New Relic API Gateway integration, you get more data about how your API layer is working behind the scenes. You'll receive metric data about the number of API calls, the requests served, the number of errors, latency counts, and more.
You can monitor and alert on your API Gateway data directly from New Relic, and query data and create dashboards.
Requirements
API Gateway will not send "Call count by resource", "4xx error by resource" and "5xx errors by resource" metrics unless you have explicitly enabled detailed CloudWatch metrics.
Tip
Enabling these metrics may add additional charges to your Amazon CloudWatch account pricing.
To enable CloudWatch metrics, use either of these options:
- Go to the AWS Management Console, select the Settings option for CloudWatch, then select the option to enable detailed CloudWatch metrics.
- Call the
stage:update
action of the Amazon API Gateway REST API to update themetricsEnabled
property totrue
.
Activate integration
To enable this integration follow standard procedures to Connect AWS services to New Relic.
Configuration and polling
You can change the polling frequency and filter data using configuration options.
Default polling information for the Amazon API gateway integration:
- New Relic polling interval: 5 minutes
- Amazon CloudWatch data interval: 1 minute
Find and use data
To find your integration data in the infrastructure UI, go to one.newrelic.com > All capabilities > Infrastructure > AWS and select one of the API Gateway integration links.
You can query and explore your data using the ApiGatewaySample
event type.
For more on how to use your data, see Understand and use integration data.
Metric data
This New Relic infrastructure integration collects the following Amazon API Gateway data:
Metric | Description |
---|---|
| The number of client-side errors captured |
| The number of server-side errors captured. |
| The number of requests served from the API cache. |
| The number of requests served from the backend when API caching is enabled. |
| The number of calls to API methods. |
| The time in milliseconds between when API Gateway relays a request to the backend and when it receives a response from the backend. |
| The time in milliseconds between when API Gateway receives a request from a client and when it returns a response to the client. The latency includes the integration latency and other API Gateway overhead. |
Dimensions
You can use the dimensions in the following table to filter API Gateway metrics.
Dimensions | Description |
---|---|
| Filters API Gateway metrics for an API of the specified API name. |
| Filters API Gateway metrics for an API method of the specified API, stage, resource, and method. |
| Filters API Gateway metrics for an API stage of the specified API and stage. |