I checked how enabling/disabling Transaction Search affects the trace map
This page has been translated by machine translation. View original
I'm from the Retail App Co-Creation Department in Osaka, this is Iwata.
In a project I'm handling, CloudWatch Logs trace maps weren't quite working as intended. After investigating the cause, I discovered that the Transaction Search enable/disable setting was the culprit. So I decided to check how trace data and trace maps change depending on Transaction Search settings and OTLP endpoint usage.
Environment
The environment used for this investigation is as follows:
- ADOT Collector image: public.ecr.aws/aws-observability/aws-otel-collector:v0.47.0
- open-telemetry/api: 1.9.0
- open-telemetry/context: 1.5.0
- open-telemetry/exporter-otlp: 1.4.0
- open-telemetry/opentelemetry-auto-laravel: 1.5.0
- open-telemetry/sdk: 1.14.0
- open-telemetry/sem-conv: 1.38.0
Let's Try It
Now let's proceed. First, following the same steps as in the blog post below, I launched a Laravel Breeze application on EC2 and sent trace data to X-Ray via the ADOT Collector.
Simply sending trace data to X-Ray using the AWS X-Ray exporter
The ADOT Collector configuration file is as follows:
...omitted
exporters:
...omitted
awsxray:
endpoint: https://xray.ap-northeast-3.amazonaws.com
region: ap-northeast-3
...omitted
service:
pipelines:
traces:
receivers: [otlp]
exporters: [awsxray]
After briefly operating Laravel Breeze and checking the trace map from the CloudWatch console, I saw the following display:

The DB operations are separated into two parts: sql UPDATE and sql SELECT. Also, the icons are not showing up as DB icons.
When I retrieved the raw trace data from the X-Ray management console, it was as follows (partially omitted):
Trace Data
{
"Id": "1-53c6850c-cfdea120e995f3ee360a4e6f",
"Duration": 0.024,
"LimitExceeded": false,
"Segments": [
{
"Id": "e05f9dc612515c60",
"Document": {
"id": "e05f9dc612515c60",
"name": "my-laravel-app",
"start_time": 1774512291.3431795,
"trace_id": "1-53c6850c-cfdea120e995f3ee360a4e6f",
"end_time": 1774512291.3670502,
"fault": false,
"error": false,
"throttle": false,
"http": {
"request": {
"url": "http://15.152.32.13:8000/profile",
"method": "GET",
"user_agent": "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/146.0.0.0 Safari/537.36",
"client_ip": "104.28.206.119"
},
"response": {
"status": 200,
"content_length": 0
}
},
"aws": {
"ec2": {
"availability_zone": null,
"instance_id": "ec2b89f83bcccb07cea30e7a5e6e9b50",
"instance_size": null,
"ami_id": null
},
"xray": {
"auto_instrumentation": true,
"sdk_version": "1.14.0",
"sdk": "opentelemetry for php"
}
},
"metadata": {
"default": {
"otel.resource.telemetry.sdk.name": "opentelemetry",
"otel.resource.telemetry.distro.version": "1.2.1",
...omitted
}
},
"subsegments": [
{
"id": "a2f5cad3a284f850",
"name": "sql SELECT",
"start_time": 1774512291.351203,
"end_time": 1774512291.356583,
"fault": false,
"error": false,
"throttle": false,
"aws": {
"ec2": {
"availability_zone": null,
"instance_id": "ec2b89f83bcccb07cea30e7a5e6e9b50",
"instance_size": null,
"ami_id": null
},
"xray": {
"auto_instrumentation": true,
"sdk_version": "1.14.0",
"sdk": "opentelemetry for php"
}
},
"metadata": {
"default": {
"db.system.name": "pgsql",
"db.query.text": "select * from \"sessions\" where \"id\" = ? limit 1",
"db.namespace": "laravel",
"db.operation.name": "SELECT"
}
},
"namespace": "remote"
},
{
"id": "a83cfc6216b85b8a",
"name": "sql UPDATE",
"start_time": 1774512291.364767,
"end_time": 1774512291.3666172,
"fault": false,
"error": false,
"throttle": false,
"aws": {
"ec2": {
"availability_zone": null,
"instance_id": "ec2b89f83bcccb07cea30e7a5e6e9b50",
"instance_size": null,
"ami_id": null
},
"xray": {
"auto_instrumentation": true,
"sdk_version": "1.14.0",
"sdk": "opentelemetry for php"
}
},
"metadata": {
"default": {
"db.system.name": "pgsql",
"db.query.text": "update \"sessions\" set \"payload\" = ?, \"last_activity\" = ?, \"user_id\" = ?, \"ip_address\" = ?, \"user_agent\" = ? where \"id\" = ?",
"db.namespace": "laravel",
"db.operation.name": "UPDATE"
}
},
"namespace": "remote"
},
{
"id": "622e564376219c0a",
"name": "AppModelsUser::get",
"start_time": 1774512291.3586502,
"end_time": 1774512291.3596728,
"fault": false,
"error": false,
"throttle": false,
"aws": {
"ec2": {
"availability_zone": null,
"instance_id": "ec2b89f83bcccb07cea30e7a5e6e9b50",
"instance_size": null,
"ami_id": null
},
"xray": {
"auto_instrumentation": true,
"sdk_version": "1.14.0",
"sdk": "opentelemetry for php"
}
},
"metadata": {
"default": {
"laravel.eloquent.operation": "get",
"db.statement": "select * from \"users\" where \"id\" = ? limit 1",
...omitted
}
},
"subsegments": [
{
"id": "682014d76df8ec38",
"name": "sql SELECT",
"start_time": 1774512291.3587203,
"end_time": 1774512291.35942,
"fault": false,
"error": false,
"throttle": false,
"aws": {
"ec2": {
"availability_zone": null,
"instance_id": "ec2b89f83bcccb07cea30e7a5e6e9b50",
"instance_size": null,
"ami_id": null
},
"xray": {
"auto_instrumentation": true,
"sdk_version": "1.14.0",
"sdk": "opentelemetry for php"
}
},
"metadata": {
"default": {
"db.system.name": "pgsql",
"db.query.text": "select * from \"users\" where \"id\" = ? limit 1",
"db.namespace": "laravel",
"db.operation.name": "SELECT"
}
},
"namespace": "remote"
}
]
}
]
}
},
{
"Id": "28f516fe3ccab724",
"Document": {
"id": "28f516fe3ccab724",
"name": "sql SELECT",
"start_time": 1774512291.3587203,
"trace_id": "1-53c6850c-cfdea120e995f3ee360a4e6f",
"end_time": 1774512291.35942,
"parent_id": "682014d76df8ec38",
"inferred": true
}
},
{
"Id": "0a84c54318042c81",
"Document": {
"id": "0a84c54318042c81",
"name": "sql UPDATE",
"start_time": 1774512291.364767,
"trace_id": "1-53c6850c-cfdea120e995f3ee360a4e6f",
"end_time": 1774512291.3666172,
"parent_id": "a83cfc6216b85b8a",
"inferred": true
}
},
{
"Id": "234bb4b933dba604",
"Document": {
"id": "234bb4b933dba604",
"name": "sql SELECT",
"start_time": 1774512291.351203,
"trace_id": "1-53c6850c-cfdea120e995f3ee360a4e6f",
"end_time": 1774512291.356583,
"parent_id": "a2f5cad3a284f850",
"inferred": true
}
}
]
}
Enabling Transaction Search and sending trace data to X-Ray using AWS X-Ray exporter
Next, I enabled Transaction Search from the CloudWatch console and then operated Laravel Breeze in the same way as before, checking the trace map from the CloudWatch console. This time, the display was as follows:

Unlike before, the icons have changed to database icons.
Here is the raw trace data that could be seen from the X-Ray console. *Note: Some parts are omitted.
Trace Data
{
"Id": "1-88f29afa-8f86b11888aa3151f68cf500",
"Duration": 0.021,
"LimitExceeded": false,
"Segments": [
{
"Id": "6ab4586454f292e6",
"Document": {
"id": "6ab4586454f292e6",
"name": "my-laravel-app",
"start_time": 1774514254.843955,
"trace_id": "1-88f29afa-8f86b11888aa3151f68cf500",
"end_time": 1774514254.8653238,
"fault": false,
"error": false,
"throttle": false,
"http": {
"request": {
"url": "http://15.152.32.13:8000/profile",
"method": "GET",
"user_agent": "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/146.0.0.0 Safari/537.36",
"client_ip": "104.28.206.119"
},
"response": {
"status": 200,
"content_length": 0
}
},
"aws": {
"xray.fault": false,
"xray.error": false,
"ec2": {
"instance_id": "ec2b89f83bcccb07cea30e7a5e6e9b50"
},
"span.kind": "LOCAL_ROOT",
"xray.throttle": false,
"xray": {
"auto_instrumentation": true,
"sdk_version": "1.14.0",
"sdk": "opentelemetry for php"
}
},
"annotations": {
"aws.local.service": "my-laravel-app",
"span.name": "GET /profile",
"aws.local.operation": "GET /profile",
"span.kind": "SERVER",
"aws.local.environment": "ec2:default"
},
"metadata": {
"telemetry.distro.version": "1.2.1",
"http.url": "http://15.152.32.13:8000/profile",
...略
},
"subsegments": [
{
"id": "18e4ea7cecf719c1",
"name": "sql SELECT",
"start_time": 1774514254.8507657,
"end_time": 1774514254.855846,
"fault": false,
"error": false,
"throttle": false,
"aws": {
"xray.error": false,
"xray.fault": false,
"ec2": {
"instance_id": "ec2b89f83bcccb07cea30e7a5e6e9b50"
},
"span.kind": "CLIENT",
"xray.throttle": false,
"xray": {
"auto_instrumentation": true,
"sdk_version": "1.14.0",
"sdk": "opentelemetry for php"
}
},
"sql": {
"sanitized_query": "select * from \"sessions\" where \"id\" = ? limit 1",
"database_type": "pgsql"
},
"annotations": {
"aws.local.service": "UnknownService",
"span.name": "sql SELECT",
"aws.local.operation": "UnmappedOperation",
"span.kind": "CLIENT",
"aws.remote.service": "pgsql",
"aws.local.environment": "ec2:default",
"aws.remote.operation": "SELECT"
},
"metadata": {
"cloud.provider": "aws",
"telemetry.extended": "true",
"db.system.name": "pgsql",
"db.query.text": "select * from \"sessions\" where \"id\" = ? limit 1",
"PlatformType": "AWS::EC2",
"db.namespace": "laravel",
"db.operation.name": "SELECT",
"cloud.platform": "aws_ec2",
"host.id": "ec2b89f83bcccb07cea30e7a5e6e9b50"
},
"namespace": "remote"
},
{
"id": "44f651602133afb6",
"name": "AppModelsUser::get",
"start_time": 1774514254.857517,
"end_time": 1774514254.8585784,
"fault": false,
"error": false,
"throttle": false,
"aws": {
"xray.error": false,
"xray.fault": false,
"ec2": {
"instance_id": "ec2b89f83bcccb07cea30e7a5e6e9b50"
},
"xray.throttle": false,
"xray": {
"auto_instrumentation": true,
"sdk_version": "1.14.0",
"sdk": "opentelemetry for php"
}
},
"sql": {
"sanitized_query": "select * from \"users\" where \"id\" = ? limit 1"
},
"annotations": {
"aws.local.service": "UnknownService",
"span.name": "AppModelsUser::get",
"span.kind": "INTERNAL",
"aws.local.environment": "ec2:default"
},
"metadata": {
"laravel.eloquent.operation": "get",
"cloud.provider": "aws",
"db.statement": "select * from \"users\" where \"id\" = ? limit 1",
...略
},
"subsegments": [
{
"id": "592f3f4438b9f803",
"name": "sql SELECT",
"start_time": 1774514254.857585,
"end_time": 1774514254.858355,
"fault": false,
"error": false,
"throttle": false,
"aws": {
"xray.error": false,
"xray.fault": false,
"ec2": {
"instance_id": "ec2b89f83bcccb07cea30e7a5e6e9b50"
},
"span.kind": "CLIENT",
"xray.throttle": false,
"xray": {
"auto_instrumentation": true,
"sdk_version": "1.14.0",
"sdk": "opentelemetry for php"
}
},
"sql": {
"sanitized_query": "select * from \"users\" where \"id\" = ? limit 1",
"database_type": "pgsql"
},
"annotations": {
"aws.local.service": "UnknownService",
"span.name": "sql SELECT",
"aws.local.operation": "UnmappedOperation",
"span.kind": "CLIENT",
"aws.remote.service": "pgsql",
"aws.local.environment": "ec2:default",
"aws.remote.operation": "SELECT"
},
"metadata": {
"cloud.provider": "aws",
"telemetry.extended": "true",
"db.system.name": "pgsql",
"db.query.text": "select * from \"users\" where \"id\" = ? limit 1",
...略
},
"namespace": "remote"
}
]
},
{
"id": "d775e8b609d3d783",
"name": "sql UPDATE",
"start_time": 1774514254.863247,
"end_time": 1774514254.864997,
"fault": false,
"error": false,
"throttle": false,
"aws": {
"xray.error": false,
"xray.fault": false,
"ec2": {
"instance_id": "ec2b89f83bcccb07cea30e7a5e6e9b50"
},
"span.kind": "CLIENT",
"xray.throttle": false,
"xray": {
"auto_instrumentation": true,
"sdk_version": "1.14.0",
"sdk": "opentelemetry for php"
}
},
"sql": {
"sanitized_query": "update \"sessions\" set \"payload\" = ?, \"last_activity\" = ?, \"user_id\" = ?, \"ip_address\" = ?, \"user_agent\" = ? where \"id\" = ?",
"database_type": "pgsql"
},
"annotations": {
"aws.local.service": "UnknownService",
"span.name": "sql UPDATE",
"aws.local.operation": "UnmappedOperation",
"span.kind": "CLIENT",
"aws.remote.service": "pgsql",
"aws.local.environment": "ec2:default",
"aws.remote.operation": "UPDATE"
},
"metadata": {
"cloud.provider": "aws",
"telemetry.extended": "true",
"db.system.name": "pgsql",
"db.query.text": "update \"sessions\" set \"payload\" = ?, \"last_activity\" = ?, \"user_id\" = ?, \"ip_address\" = ?, \"user_agent\" = ? where \"id\" = ?",
"PlatformType": "AWS::EC2",
"db.namespace": "laravel",
"db.operation.name": "UPDATE",
"cloud.platform": "aws_ec2",
"host.id": "ec2b89f83bcccb07cea30e7a5e6e9b50"
},
"namespace": "remote"
}
]
}
},
{
"Id": "0d605ba209a1dfff",
"Document": {
"id": "0d605ba209a1dfff",
"name": "sql UPDATE",
"start_time": 1774514254.863247,
"trace_id": "1-88f29afa-8f86b11888aa3151f68cf500",
"end_time": 1774514254.864997,
"parent_id": "d775e8b609d3d783",
"inferred": true,
"sql": {
"sanitized_query": "update \"sessions\" set \"payload\" = ?, \"last_activity\" = ?, \"user_id\" = ?, \"ip_address\" = ?, \"user_agent\" = ? where \"id\" = ?",
"database_type": "pgsql"
},
"annotations": {
"aws.local.service": "pgsql",
"aws.local.operation": "UPDATE"
},
"origin": "Database::SQL"
}
},
{
"Id": "357fcf660a4daf86",
"Document": {
"id": "357fcf660a4daf86",
"name": "sql SELECT",
"start_time": 1774514254.857585,
"trace_id": "1-88f29afa-8f86b11888aa3151f68cf500",
"end_time": 1774514254.858355,
"parent_id": "592f3f4438b9f803",
"inferred": true,
"sql": {
"sanitized_query": "select * from \"users\" where \"id\" = ? limit 1",
"database_type": "pgsql"
},
"annotations": {
"aws.local.service": "pgsql",
"aws.local.operation": "SELECT"
},
"origin": "Database::SQL"
}
},
{
"Id": "2d5db2cd21a6a423",
"Document": {
"id": "2d5db2cd21a6a423",
"name": "sql SELECT",
"start_time": 1774514254.8507657,
"trace_id": "1-88f29afa-8f86b11888aa3151f68cf500",
"end_time": 1774514254.855846,
"parent_id": "18e4ea7cecf719c1",
"inferred": true,
"sql": {
"sanitized_query": "select * from \"sessions\" where \"id\" = ? limit 1",
"database_type": "pgsql"
},
"annotations": {
"aws.local.service": "pgsql",
"aws.local.operation": "SELECT"
},
"origin": "Database::SQL"
}
}
]
}
Unlike before, the subsegment Document now includes information like "origin": "Database::SQL". Is this why the icon changed to a database? There are also additional annotations and other information.
Enable Transaction Search and Send Trace Data to X-Ray with OTLP Exporter
Finally, let's try sending trace data to the X-Ray OTLP endpoint with Transaction Search enabled. Change the ADOT Collector configuration file as follows:
...omitted
exporters:
otlphttp:
traces_endpoint: https://xray.ap-northeast-3.amazonaws.com/v1/traces
compression: gzip
auth:
authenticator: sigv4auth
...omitted
extensions:
sigv4auth:
region: ap-northeast-3
service: xray
service:
extensions: [sigv4auth]
pipelines:
traces:
receivers: [otlp]
exporters: [otlphttp]
After operating Laravel Breeze again and checking the trace map from the CloudWatch console, the display changed as follows:

The nodes in the trace map have been consolidated into one, and the display has changed to pgsql.
Here's the raw trace data that can be confirmed from the X-Ray management console. *Some parts have been omitted.
Trace data
{
"Id": "1-7f7dc45a-03cd27a1a88eb45b62903d06",
"Duration": 0.023,
"Segments": [
{
"Id": "24923bf0173b98b0",
"Document": {
"id": "24923bf0173b98b0",
"name": "my-laravel-app",
"start_time": 1774513468.0129948,
"trace_id": "1-7f7dc45a-03cd27a1a88eb45b62903d06",
"end_time": 1774513468.0363288,
"http": {
"request": {
"url": "http://15.152.32.13:8000/profile",
"method": "GET",
"user_agent": "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/146.0.0.0 Safari/537.36",
"client_ip": "104.28.206.119"
},
"response": {
"status": 200
}
},
"aws": {
"span.kind": "LOCAL_ROOT"
},
"annotations": {
"aws.local.service": "my-laravel-app",
"span.name": "GET /profile",
"aws.local.operation": "GET /profile",
"span.kind": "SERVER",
"aws.local.environment": "generic:default"
},
"metadata": {
"telemetry.distro.version": "1.2.1",
"code.function.name": "Illuminate\\Foundation\\Http\\Kernel::handle",
"process.runtime.version": "8.5.3",
...omitted
},
"subsegments": [
{
"id": "cc9b80530d219589",
"name": "App\\Models\\User::get",
"start_time": 1774513468.0284073,
"end_time": 1774513468.0293968,
"sql": {
"sanitized_query": "select * from \"users\" where \"id\" = ? limit 1"
},
"annotations": {
"aws.local.service": "my-laravel-app",
"span.name": "App\\Models\\User::get",
"span.kind": "INTERNAL",
"aws.local.environment": "generic:default"
},
"metadata": {
"telemetry.distro.version": "1.2.1",
"code.function.name": "Illuminate\\Database\\Eloquent\\Builder::getModels",
...omitted
},
"subsegments": [
{
"id": "e6ed1a06b48ad6fa",
"name": "pgsql",
"start_time": 1774513468.028477,
"end_time": 1774513468.029147,
"aws": {
"span.kind": "CLIENT"
},
"sql": {
"sanitized_query": "select * from \"users\" where \"id\" = ? limit 1",
"database_type": "pgsql"
},
"annotations": {
"aws.local.service": "my-laravel-app",
"span.name": "sql SELECT",
"aws.local.operation": "UnmappedOperation",
"span.kind": "CLIENT",
"aws.remote.service": "pgsql",
"aws.local.environment": "generic:default",
"aws.remote.operation": "SELECT"
},
"metadata": {
"telemetry.distro.version": "1.2.1",
"telemetry.extended": "true",
"service.name": "my-laravel-app",
"telemetry.distro.name": "opentelemetry-php-instrumentation",
...omitted
},
"namespace": "remote"
}
]
},
{
"id": "930ca9eefb7bdc86",
"name": "pgsql",
"start_time": 1774513468.0343292,
"end_time": 1774513468.035979,
"aws": {
"span.kind": "CLIENT"
},
"sql": {
"sanitized_query": "update \"sessions\" set \"payload\" = ?, \"last_activity\" = ?, \"user_id\" = ?, \"ip_address\" = ?, \"user_agent\" = ? where \"id\" = ?",
"database_type": "pgsql"
},
"annotations": {
"aws.local.service": "my-laravel-app",
"span.name": "sql UPDATE",
"aws.local.operation": "UnmappedOperation",
"span.kind": "CLIENT",
"aws.remote.service": "pgsql",
"aws.local.environment": "generic:default",
"aws.remote.operation": "UPDATE"
},
"metadata": {
"telemetry.distro.version": "1.2.1",
"telemetry.extended": "true",
"service.name": "my-laravel-app",
"telemetry.distro.name": "opentelemetry-php-instrumentation",
"process.runtime.version": "8.5.3",
"os.type": "linux",
"db.query.text": "update \"sessions\" set \"payload\" = ?, \"last_activity\" = ?, \"user_id\" = ?, \"ip_address\" = ?, \"user_agent\" = ? where \"id\" = ?",
...omitted
},
"namespace": "remote"
},
{
"id": "60e2bbd4a3f0f047",
"name": "pgsql",
"start_time": 1774513468.0211809,
"end_time": 1774513468.026461,
"aws": {
"span.kind": "CLIENT"
},
"sql": {
"sanitized_query": "select * from \"sessions\" where \"id\" = ? limit 1",
"database_type": "pgsql"
},
"annotations": {
"aws.local.service": "my-laravel-app",
"span.name": "sql SELECT",
"aws.local.operation": "UnmappedOperation",
"span.kind": "CLIENT",
"aws.remote.service": "pgsql",
"aws.local.environment": "generic:default",
"aws.remote.operation": "SELECT"
},
"metadata": {
"telemetry.distro.version": "1.2.1",
"telemetry.extended": "true",
"service.name": "my-laravel-app",
"telemetry.distro.name": "opentelemetry-php-instrumentation",
"process.runtime.version": "8.5.3",
"os.type": "linux",
"db.query.text": "select * from \"sessions\" where \"id\" = ? limit 1",
...omitted
},
"namespace": "remote"
}
]
}
},
{
"Id": "2a11cf113752e453",
"Document": {
"id": "2a11cf113752e453",
"name": "pgsql",
"start_time": 1774513468.0211809,
"trace_id": "1-7f7dc45a-03cd27a1a88eb45b62903d06",
"end_time": 1774513468.026461,
"parent_id": "60e2bbd4a3f0f047",
"inferred": true,
"sql": {
"sanitized_query": "select * from \"sessions\" where \"id\" = ? limit 1",
"database_type": "pgsql"
},
"annotations": {
"aws.local.service": "pgsql",
"aws.local.operation": "SELECT"
},
"origin": "Database::SQL"
}
},
{
"Id": "148bd0f702dfc786",
"Document": {
"id": "148bd0f702dfc786",
"name": "pgsql",
"start_time": 1774513468.0343292,
"trace_id": "1-7f7dc45a-03cd27a1a88eb45b62903d06",
"end_time": 1774513468.035979,
"parent_id": "930ca9eefb7bdc86",
"inferred": true,
"sql": {
"sanitized_query": "update \"sessions\" set \"payload\" = ?, \"last_activity\" = ?, \"user_id\" = ?, \"ip_address\" = ?, \"user_agent\" = ? where \"id\" = ?",
"database_type": "pgsql"
},
"annotations": {
"aws.local.service": "pgsql",
"aws.local.operation": "UPDATE"
},
"origin": "Database::SQL"
}
},
{
"Id": "01ce7cfd3f442f47",
"Document": {
"id": "01ce7cfd3f442f47",
"name": "pgsql",
"start_time": 1774513468.028477,
"trace_id": "1-7f7dc45a-03cd27a1a88eb45b62903d06",
"end_time": 1774513468.029147,
"parent_id": "e6ed1a06b48ad6fa",
"inferred": true,
"sql": {
"sanitized_query": "select * from \"users\" where \"id\" = ? limit 1",
"database_type": "pgsql"
},
"annotations": {
"aws.local.service": "pgsql",
"aws.local.operation": "SELECT"
},
"origin": "Database::SQL"
}
}
]
}
The name of the subsegment's Document has changed from sql UPDATE or sql SELECT to pgsql. This seems to be reflected in the trace map display.
By the way, here's a summary of the differences explained by AI:
Summary
┌────────────────────────────┬────────────────────┬──────────────────────────────┐
│ Aspect │ X-Ray SDK │ OTLP │
├────────────────────────────┼────────────────────┼──────────────────────────────┤
│ DB segment name │ sql SELECT/UPDATE │ pgsql (connection name) │
├────────────────────────────┼────────────────────┼──────────────────────────────┤
│ Platform │ AWS::EC2 │ Generic │
├────────────────────────────┼────────────────────┼──────────────────────────────┤
│ EC2 metadata │ Detailed │ Omitted │
├────────────────────────────┼────────────────────┼──────────────────────────────┤
│ aws.local.service (child) │ UnknownService │ my-laravel-app (propagated) │
├────────────────────────────┼────────────────────┼──────────────────────────────┤
│ Metadata amount │ Compact for child │ Full attribute set for child │
└────────────────────────────┴────────────────────┴──────────────────────────────┘
Switching to OTLP improves service name propagation, but EC2-specific information is lost and segment naming conventions change.
Looking at the trace data, it indeed matches this explanation.
Conclusion
It was surprising that the trace map changes not only depending on whether you use X-Ray's standard endpoint or OTLP endpoint when sending trace data, but also just by enabling/disabling Transaction Search. With the X-Ray daemon and X-Ray SDK already set for deprecation in the X-Ray-related technology space, it's expected that things will continue to evolve according to OTEL standards going forward. It seems better to actively use the OTLP endpoint in the future.