OTLP Endpoints - Amazon CloudWatch
Services or capabilities described in Amazon Web Services documentation might vary by Region. To see the differences applicable to the China Regions, see Getting Started with Amazon Web Services in China (PDF).

OTLP Endpoints

OpenTelemetry Protocol (OTLP) is a general-purpose telemetry data delivery protocol designed for the OpenTelemetry. CloudWatch OpenTelemetry endpoints are HTTP 1.1 endpoints. You need to configure your OpenTelemetry collector to start sending open telemetry data to CloudWatch. For more information, see Getting started. The endpoint authenticates callers using Signature 4 authentication. For more information, see Amazon Signature Version 4 for API requests.

Traces endpoint

The traces endpoint follows the pattern https://xray.Amazon Region.amazonaws.com/v1/traces. For example, for the US West (Oregon) (us-west-2) Region, the endpoint will be https://xray.us-west-2.amazonaws.com/v1/traces.

You need to configure your OpenTelemetry collector to start sending traces to CloudWatch. To get started, see Getting started.

Logs endpoint

The logs endpoint follows the pattern https://logs.Amazon Web Services Region.amazonaws.com/v1/logs. For example, for the US West (Oregon) (us-west-2) Region, the endpoint will be https://logs.us-west-2.amazonaws.com/v1/logs. You can use the above endpoint to forward logs to an existing LogGroup and LogStream. For more information on setting up LogGroup to ingest log data, see Amazon CloudWatch Logs concepts. You must configure LogGroup and LogStream when you invoke CloudWatch Logs OpenTelemetry endpoint by setting x-aws-log-group and x-aws-log-stream HTTP headers to LogGroup and LogStream name respectively. For more information, see Getting started.

Endpoint limits and restrictions

The table lists the common endpoint limits and restrictions for traces and logs.

Limit Endpoint Additional information

Required collector extension

sigv4authextension

To send traces to OTLP endpoint you must use sigv4authextension

Supported protocol

HTTP

The endpoint supports only HTTP and doesn't support gRPC

Supported OTLP versions

OTLP 1.x

Payload format

binary, json

The endpoint accepts requests using binary and json formats

Compression methods

gzip, none

The endpoint only supports gzip and none compression methods

The table lists the endpoint limits and restrictions for traces.

Limit Traces endpoint Additional information

Maximum uncompressed bytes / request

5 MB

The OTLP endpoint will reject requests larger than 5MB when payload is uncompressed.

Maximum events / request

10,000 spans

The max allowed number of spans in one request is 10,000. Exceeding this limit will cause rejection of the API call.

Single resource and scope size

16 KB

Each unique resource and corresponding scope should not exceed 16 KB of size. Exceeding this limit for any resource will cause rejection of the entire API call.

Single span maximum size

200 KB

Spans more than 200KB will be rejected by the endpoint.

Span created timestamps

2 hours in the future and 14 days in the past

None of the spans in the batch can be more than two hours in the future or more than 14 days in the past.

Maximum time gap in events / request

24 hours

The table lists the endpoint limits and restrictions for logs.

Limit Logs endpoint Additional information

Maximum uncompressed bytes / request

1 MB

The OTLP endpoint will reject requests larger than 1MB when payload is uncompressed.

The maximum request size is 1,048,576 bytes after decompression and deserialization of binary data serialized by Protocol buffers. This size is calculated as the sum of all event messages in UTF-8, plus 26 bytes for each log record.

Request per second

5000

5000 transactions per second per account per Region You can request an increase to the per-second throttling quota by using the Service Quotas service.

Maximum events / request

10,000 logs

The max allowed number of spans in one request is 10,000. Exceeding this limit will cause rejection of the API call.

Single resource and scope size

16 KB

Each unique resource and corresponding scope should not exceed 16 KB of size. Exceeding this limit for any resource will cause rejection of the entire API call.

Single LogEvent size

1 MB

LogEvent size is calculated as sum of sizes for each LogRecord, Scope and Resource. This quota can't be changed.

Logs created timestamps

2 hours in future and 14 days old

The log records in the batch does not have to be in a chronological order. However, the log records in the batch cannot be more than 2 hours in the future and cannot be more than 14 days in the past. Also, none of the log records can be earlier than the retention period of the log group.

Maximum time gap in events / request

24 hours

Note

The account limits for Logs are shared across the SDK and the new Logs endpoint.