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

fix: losing this context on register handler function for hapi #2540

Closed
wants to merge 1 commit into from

Conversation

Cheprer
Copy link

@Cheprer Cheprer commented Nov 19, 2024

Which problem is this PR solving?

  • When someone is using also a wrapper on the return function from register handler, due to wrapping by opentelemetry before it without retain the context, the following wrapper loses it.

Short description of the changes

  • Use apply to retain the this context of the original function.

@Cheprer Cheprer requested a review from a team as a code owner November 19, 2024 13:51
Copy link

linux-foundation-easycla bot commented Nov 19, 2024

CLA Signed


The committers listed above are authorized under a signed CLA.

@github-actions github-actions bot added pkg:instrumentation-hapi pkg-status:unmaintained This package is unmaintained. Only bugfixes may be acceped until a new owner has been found. labels Nov 19, 2024
Copy link
Contributor

This package does not have an assigned component owner and is considered unmaintained. As such this package is in feature-freeze and this PR will be closed with 14 days unless a new owner or a sponsor (a member of @open-telemetry/javascript-approvers) for the feature is found. It is the responsibility of the author to find a sponsor for this feature.
Are you familiar with this package? Consider becoming a component owner.

@Cheprer
Copy link
Author

Cheprer commented Jan 2, 2025

Hi @pichlermarc can we move on with this. What is needed here please?

@pichlermarc
Copy link
Member

@Cheprer this is already fixed in the latest version AFAIK. #2625

@Cheprer
Copy link
Author

Cheprer commented Jan 15, 2025

@pichlermarc nice, shame that someone else did the same thing again, where this could be merged and fixed much sooner.

@Cheprer Cheprer closed this Jan 15, 2025
@pichlermarc
Copy link
Member

@pichlermarc nice, shame that someone else did the same thing again, where this could be merged and fixed much sooner.

Yes, you're right. I really try to do my best but I have to hande too many threads a day on GitHub and Slack - so on my end things tend to fall through the cracks especially on instrumentation packages like @opentelemetry/instrumentation-hapi that have been abandoned for a while.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working pkg:instrumentation-hapi pkg-status:unmaintained This package is unmaintained. Only bugfixes may be acceped until a new owner has been found.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants