Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

OpenTelemetry X-Ray: Traces without hierarchy #2719

Open
jeusdi opened this issue Apr 24, 2024 · 0 comments
Open

OpenTelemetry X-Ray: Traces without hierarchy #2719

jeusdi opened this issue Apr 24, 2024 · 0 comments

Comments

@jeusdi
Copy link

jeusdi commented Apr 24, 2024

I've configured opentelemetry on my lambdas using ADOT OpenTelemetry AWS distribution.

I mean, I'm using javaagent + collector layer attached to my lambdas, following this documentation.

That means that I'm using openTelemetry agent + collector and I'm autoinstrumention my code using agent.

After that, my traces are generated, but not aligned on X-Ray console.

I mean, opentelemetry agent is instrumenting my mongo and S3 access. Lambda traces are also generated.

So, I'm getting traces for:

  • lambda context executation traces
  • S3 access traces
  • mongodb access traces

However, traces appear not related between them:

enter image description here

I don't quite figure out how to create relation between them in order to putt all it together.

I've took a look on logs. Following traces are generated:

[otel.javaagent 2024-04-24 07:59:05:633 +0000] [main] INFO io.opentelemetry.exporter.logging.LoggingSpanExporter - 'update espaidoc.document' : 6628bbc902c4d22192672fe5958a00cd eb8b0f340609ba59 CLIENT [tracer: io.opentelemetry.mongo-3.1:1.32.0-adot-lambda1-alpha] AttributesMap{data={db.operation=update, db.mongodb.collection=document, db.name=espaidoc, thread.id=1, thread.name=main, db.connection_string=mongodb://pe-0-endurance-mongodb-dev-cluster.r6c5pur.mongodb.net:27017, net.peer.name=pe-0-endurance-mongodb-dev-cluster.r6c5pur.mongodb.net, db.system=mongodb, net.peer.port=27017, db.statement={\"update\": \"document\", \"ordered\": \"?\", \"writeConcern\": {\"w\": \"?\"}, \"txnNumber\": \"?\", \"$db\": \"?\", \"$clusterTime\": {\"clusterTime\": \"?\", \"signature\": {\"hash\": \"?\", \"keyId\": \"?\"}}, \"lsid\": {\"id\": \"?\"}, \"updates\": [{\"q\": {\"_id\": \"?\"}, \"u\": {\"_id\": \"?\", \"logicId\": \"?\", \"location\": {\"location\": \"?\", \"type\": \"?\"}, \"status\": {\"state\": \"?\"}, \"md5Checksum\": \"?\", \"_class\": \"?\"}, \"upsert\": \"?\"}]}}, capacity=128, totalAddedValues=10}
[otel.javaagent 2024-04-24 07:59:05:620 +0000] [main] INFO io.opentelemetry.exporter.logging.LoggingSpanExporter - 'S3.HeadObject' : 6628bbc95db57510853694261956a4d1 4c10b44d043a4612 CLIENT [tracer: io.opentelemetry.aws-sdk-2.2:1.32.0-adot-lambda1-alpha] AttributesMap{data={aws.agent=java-aws-sdk, http.method=HEAD, aws.requestId=1Y3J5K61D9ZHSV5X, net.peer.name=s3.eu-west-1.amazonaws.com, rpc.method=HeadObject, net.peer.port=443, http.url=https://s3.eu-west-1.amazonaws.com/espaidoc-des/frontoffice-apigateway-0.0.1-SNAPSHOT-aws.jar, rpc.system=aws-api, thread.id=1, thread.name=main, http.status_code=200, aws.bucket.name=espaidoc-des, http.response_content_length=50984457, rpc.service=S3}, capacity=128, totalAddedValues=14}
XRAY TraceId: 1-6628bbc9-0439f53a54534f10181c6da0\tSegmentId: 0111f4aa09e348cc\tSampled: true

Any ideas?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant