-
Notifications
You must be signed in to change notification settings - Fork 180
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
feat: AWS lambda programatic wrap #1308
base: main
Are you sure you want to change the base?
feat: AWS lambda programatic wrap #1308
Conversation
instrumentation/aws_lambda/lib/opentelemetry/instrumentation/aws_lambda/wrap.rb
Outdated
Show resolved
Hide resolved
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks, @joshwestbrook! It's great to see the lambda instrumentation getting some use and I like your adjustment to make it more flexible for different scenarios.
Since @xuan-cao-swi initially wrote this, I'd like him to also take a look before we merge.
Awesome, thanks for taking a look at this @kaylareopelle! |
Thanks @joshwestbrook , I think it looks good. Would you mind add some test case around the |
Our company uses container images for deploying our lambda functions and use herokuish Procfile entries as our entrypoints for the images.
This means it takes a ton of jiggery-pokery to get this working for our situation because:
_HANDLER
environment variable actually contains our Procfile entry (which calls the lambda RIC under the hood with the handler that's expected by this wrapper)This PR introduces an alternative way of instrumenting by programmatically wrapping an arbitrary handler method for scenarios where using lambda layers aren't an option (such as ours).
Example: