-
Notifications
You must be signed in to change notification settings - Fork 143
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
Django Middleware not working on AWS Lambda #175
Comments
Hey, Thank you very much for reporting the issue. Can you provide any logs from Lambda that are related to the errors that are happening? Thanks, |
I don't have much logs from lambda except that the subsegments are sent to lambda. It's @haotianw465 that confirmed the issue with the parent_id. You might find some useful information in AWS Support case. |
Thanks for giving me the support case number. I've filed a request to access the support case and I will get back to you as soon as I get more information about it. |
Any updates on this @chanchiem ? |
Hi levesquejf, This developer is unfortunately no longer on this project - This seems to have been missed in the shuffle - apologies! We'll get this prioritized to take a look. |
Hi @levesquejf, The longer term strategy is to include two segments when serving requests via a web framework in Lambda, one representing the Lambda function (like we have today) and one generated for the middleware like we do in other environments. Related is this issue for node.js. |
@willarmiros Do you have any quick short-term workaround for this issue? What is the ETA for a fix in the SDK? |
Calling our internal
This creates a new facade segment with the appropriate trace ID and segment ID, which will be able to properly parent subsequent subsegments. Can't provide an official timeline on a fix but we will prioritize it as soon as we can. |
We are having this same issue. I noticed the fix for Flask, is there a workaround for Django? |
Hi @rajbeard , calling |
Hello, As it turns out, we weren't having this issue. What was actually happening was our |
I tried to use the Django middleware with an app deployed on Lambda (using Zappa with ELB, not API Gateway) but it’s not working. If the middleware is enabled, the subsegments are sent to the Lambda X-Ray Daemon but they are discarded because the parent_id is not good (according to AWS Support & AWS X-Ray teams).
Without the middleware, it is possible to use patch_db() to get the SQL queries inside X-Ray.
SDK Version: 2.4.2
Django Version: 2.2.5
The text was updated successfully, but these errors were encountered: