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

AwsLambdaInstrumentor doesn't handle function exception, inconsistently flushes trace/metrics #2246

Closed
tammy-baylis-swi opened this issue Feb 17, 2024 · 1 comment · Fixed by #2245
Labels
bug Something isn't working

Comments

@tammy-baylis-swi
Copy link
Contributor

tammy-baylis-swi commented Feb 17, 2024

Describe your environment

Steps to reproduce
I built an Otel Python lambda layer using contents of this repo's main branch. I equipped an AWS Lambda function with this layer, then I invoked to immediately raise Exception. A local instance of Otel Collector exporting to console/logging/debug received traces from the function sometimes and never received some custom metrics.

What is the expected behavior?
All traces and any custom metrics should be generated and exported, even if lambda function raises exception.

Some of the other instrumentors handle exceptions and adjust + still report telemetry. For example: requests, asgi (via try-except to set attributes and finally to export telemetry).

What is the actual behavior?
Some traces and no custom metrics are exported when lambda function raises exception.

Additional context

@tammy-baylis-swi
Copy link
Contributor Author

Please may I be assigned to this. I'm working on a fix in #2245.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
1 participant