Skip to content

Commit 262adae

Browse files
authored
Merge branch 'main' into lambdadocchnage
2 parents 778bef0 + 9daedda commit 262adae

File tree

2 files changed

+13
-4
lines changed

2 files changed

+13
-4
lines changed

src/docs/getting-started/lambda/lambda-js.mdx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@ Find the supported regions and amd64(x86_64)/arm64 layer ARN in the table below
2929

3030
|Supported Regions |Lambda layer ARN format | Contents |
3131
|---------------------|-------------------------|----------|
32-
| ap-northeast-1<br/>ap-northeast-2<br/>ap-south-1<br/>ap-southeast-1<br/>ap-southeast-2<br/>ca-central-1<br/>eu-central-1<br/>eu-north-1<br/>eu-west-1<br/>eu-west-2<br/>eu-west-3<br/>sa-east-1<br/>us-east-1<br/>us-east-2<br/>us-west-1<br/>us-west-2 | arn:aws:lambda:<region\>:901920570463:layer:aws-otel-nodejs-<architecture\>-ver-1-8-0:2 |Contains [OpenTelemetry for JavaScript v1.8.0](https://github.com/open-telemetry/opentelemetry-js/releases/tag/stable%2Fv1.8.0) with [Lambda instrumentation v0.34.0](https://github.com/open-telemetry/opentelemetry-js-contrib/releases/tag/instrumentation-aws-lambda-v0.34.0) <br/><br/> Contains the [ADOT Collector for Lambda v0.25.0](https://github.com/aws-observability/aws-otel-collector/releases/tag/pkg%2Flambdacomponents%2Fv0.25.1)|
32+
| ap-northeast-1<br/>ap-northeast-2<br/>ap-south-1<br/>ap-southeast-1<br/>ap-southeast-2<br/>ca-central-1<br/>eu-central-1<br/>eu-north-1<br/>eu-west-1<br/>eu-west-2<br/>eu-west-3<br/>sa-east-1<br/>us-east-1<br/>us-east-2<br/>us-west-1<br/>us-west-2 | arn:aws:lambda:<region\>:901920570463:layer:aws-otel-nodejs-<architecture\>-ver-1-8-0:2 |Contains [OpenTelemetry for JavaScript v1.8.0](https://github.com/open-telemetry/opentelemetry-js/releases/tag/v1.8.0) with [Lambda instrumentation v0.34.0](https://github.com/open-telemetry/opentelemetry-js-contrib/releases/tag/instrumentation-aws-lambda-v0.34.0) <br/><br/> Contains the [ADOT Collector for Lambda v0.25.0](https://github.com/aws-observability/aws-otel-collector/releases/tag/pkg%2Flambdacomponents%2Fv0.25.1)|
3333

3434
### Enable auto-instrumentation for your Lambda function
3535
To enable the AWS Distro for OpenTelemetry in your Lambda function, you need to add and configure the layer, and then enable tracing.

src/docs/getting-started/x-ray.mdx

Lines changed: 12 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -186,14 +186,23 @@ exporters:
186186

187187
The attributes in this section are translated into the AWS resource field `cloudwatch_logs`. This resource field is used to correlate Cloudwatch Log Groups with the segments associated with it. This correlation can be explored when analyzing individual traces in the X-Ray console.
188188

189+
If an attribute is not specified, then the exporter's aws_log_groups field will be used if available.
190+
189191
| OTel Attributes env var | X-Ray data model field | Notes |
190192
|-------------------------|---------------------------|---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|
191193
| aws.log.group.arns | cloudwatch_logs.arn | |
192-
| aws.log.group.names | cloudwatch_logs.log_group | If both `aws.log.group.arns` and `aws.log.group.names` are defined, precedence is given to `aws.log.group.arns` |
194+
| aws.log.group.names | cloudwatch_logs.log_group | Precedence is given in the order of `aws.log.group.arns`, `aws.log.group.names`, then the exporter config's `aws_log_groups`.|
195+
196+
##### Using Config to set Cloud Watch Log Group Names
197+
198+
```yaml lineNumbers=true
199+
awsxray:
200+
aws_log_groups: ["group1", "group2"]
201+
```
193202

194-
Obs.: These resource attributes are of type array and cannot be set using the OTEL_RESOURCE_ATTRIBUTES environment variable. Currently you have to setup this resource attribute programatically.
203+
Obs.: These resource attributes are of type array and cannot be set using the OTEL_RESOURCE_ATTRIBUTES environment variable. Currently you have to setup this resource attribute programatically or by config.
195204

196-
See [AWS X-Ray Segment Documents](https://docs.aws.amazon.com/xray/latest/devguide/xray-api-segmentdocuments.html) for more information on the AWS X-Ray data model. See [OpenTelemetry data model spec](https://github.com/open-telemetry/opentelemetry-specification) for more information on OpenTelemetry data model. See [X-Ray Logging Configuration](https://docs.aws.amazon.com/xray/latest/devguide/xray-sdk-java-configuration.html#xray-sdk-java-configuration-logging) for references of expected log pattern.
205+
See [AWS X-Ray Segment Documents](https://docs.aws.amazon.com/xray/latest/devguide/xray-api-segmentdocuments.html) for more information on the AWS X-Ray data model. See [OpenTelemetry data model spec](https://github.com/open-telemetry/opentelemetry-specification) for more information on OpenTelemetry data model. See [X-Ray Logging Configuration](https://docs.aws.amazon.com/xray/latest/devguide/xray-sdk-java-configuration.html#xray-sdk-java-configuration-logging) for references of expected log pattern. See [AWS X-Ray Tracing Exporter](https://github.com/open-telemetry/opentelemetry-collector-contrib/tree/main/exporter/awsxrayexporter) for more information on the exporter's config.
197206

198207
### Enable The Customized X-Ray Annotations
199208
By using OpenTelemetry SDK, we can add the customized attributes for each trace subsegment. By default, these OpenTelemetry

0 commit comments

Comments
 (0)