Questions tagged [aws-xray]

AWS X-Ray allows developers to analyze the behavior of distributed applications by providing request tracing, exception collection, and profiling capabilities.

Documentation: https://aws.amazon.com/documentation/xray/

371 questions
4
votes
2 answers

aws-xray-sdk on a lambda function

I see that I can enable x-ray tracing on my lambda function just by checking a checkbox (or setting Tracing: Active if using SAM). That adds a high level logging. If I want more detailed logging, my understanding is that I need to add: from…
Diego
  • 34,802
  • 21
  • 91
  • 134
4
votes
2 answers

Exclude query parameters from API Gateway's X-Ray tracing logs

I have an AWS Lambda function which has many integrations with an AWS API Gateway API. The API has Enable X-Ray Tracing checked and traces are correctly populating. Under "AWS X-Ray Dashboard > Traces > Trace overview", I group the traces by "URL".…
Sean Pianka
  • 2,157
  • 2
  • 27
  • 43
4
votes
1 answer

Lambda AWS X-Ray. Python SDK - Deactivate Locally

I have a Flask app running as an AWS Lambda Function deployed with Zappa and would like to activate X-Ray to get more information for the different functions. Activating X-Ray with Zappa was easy enough - it only requires adding this line in the…
Thomas D. Frøysa
  • 692
  • 1
  • 8
  • 26
4
votes
3 answers

AWS lambda nodejs showing error while using X-RAY

I have following code: var AWSXRay = require('aws-xray-sdk'); var AWS = AWSXRay.captureAWS(require('aws-sdk')); const client = AWSXRay.captureAWSClient(new AWS.DynamoDB.DocumentClient({region : 'eu-west-1'})); exports.handler =…
ABCD
  • 730
  • 1
  • 13
  • 31
4
votes
1 answer

AWS Xray: How to check if Xray Segment is open?

To create a sub-segment aws-xray requires that a valid segment is opened. By default remote lambda execution opens a segment for you and you just have to add a subsegment but while running locally we need to open segment manually before adding…
NoorJafri
  • 1,787
  • 16
  • 27
4
votes
1 answer

AWS X-Ray ERROR:aws_xray_sdk.core.context:cannot find the current segment/subsegment

We recently added X-Ray to our code by having: from aws_xray_sdk.core import xray_recorder from aws_xray_sdk.core import patch_all patch_all() While this runs fine on AWS Lambda, but when trying to run locally during calling ElasticSearch we got…
James Lin
  • 25,028
  • 36
  • 133
  • 233
4
votes
2 answers

AWS SAM X-Ray Tracing: Active vs PassThrough

What is the difference between Active and PassThrough in Tracing parameter of AWS::Serverless::Function? Is PassThrough the default value?
niqui
  • 1,562
  • 1
  • 16
  • 28
4
votes
0 answers

Correct way to instrument a Jersey client

My goal is to instrument a Jersey client to collect data on HTTP response/execution time, and I had thought I had the right approach by implementing a JAX-RS ClientRequestFilter and a ClientResponseFilter with code in each to record the start and…
hayduke
  • 121
  • 8
4
votes
1 answer

Exclude Path from being traced in AWS X-Ray

Tracing certain paths, like a health check, don't provide much value to us. We want to ensure we aren't paying for AWS XRay traces against health endpoints. I am trying to exclude such paths with sampling rules, but it is not working.I have…
user3464189
  • 183
  • 1
  • 1
  • 11
4
votes
2 answers

AWSXRay.captureAsyncFunc() from Lambda - am I missing something?

I'm trying to get a custom X-Ray segment reporting, but I'm not seeing anything in the trace. My code looks something like this: var AWSXRay = require('aws-xray-sdk-core'); AWSXRay.captureAsyncFunc('callSoapService', subsegment => { …
3
votes
1 answer

Not seeing manually created nested AWS XRay subsegments in AWS console

I'm trying to instrument a web server written in Go that provides REST API, that runs in a container on AWS ECS. I'm running the server in Debug in VSCode for now, working on a proof of concept that would show traces for the different endpoints,…
sdanzig
  • 4,510
  • 1
  • 23
  • 27
3
votes
1 answer

How does one setup AWS X-Ray with NestJS

I'm working in a NestJS app, and I wish to setup AWS X-Ray on it. I'm new to NestJS, and I'm not clear on how to do this. In an Express app, the AWS docs say you do this: var app = express(); var AWSXRay =…
J86
  • 14,345
  • 47
  • 130
  • 228
3
votes
0 answers

AWS XRay Filter Expression name CONTAINS

I'm looking at the AWS documentation here and there is a string keyword for name and a string operator CONTAINS. What I am trying to do is put these together, to match all services that contain a substring (to be able to see a specific…
3
votes
1 answer

Why do I have a .NET Core API performance issue using IHttpClientFactory when ramping up users?

I have a .NET Core WebAPI my React UI is calling to Authenticate Users. It calls a 3rd Party API for this. Everything works fine but we have started to do Performance testing on it and it is not scaling well when we ramp up the Users attempting to…
Ctrl_Alt_Defeat
  • 3,933
  • 12
  • 66
  • 116
3
votes
1 answer

How can I find the trace ID my lambda is under?

I want to be able to easily find the trace ID (and segment ID) for my lambda's execution in logs. I realise this is available on the REPORT logs that the lambda does automatically, but that logs doesn't fit my custom format for indexing and…
Joseph Whiting
  • 548
  • 6
  • 12
1 2
3
24 25