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

Instrument NestJS event listeners #13167

Closed
Tracked by #12504 ...
nicohrubec opened this issue Aug 2, 2024 · 2 comments · Fixed by #14307
Closed
Tracked by #12504 ...

Instrument NestJS event listeners #13167

nicohrubec opened this issue Aug 2, 2024 · 2 comments · Fixed by #14307
Assignees
Labels
Package: nestjs Issues related to the Sentry Nestjs SDK

Comments

@nicohrubec
Copy link
Contributor

nicohrubec commented Aug 2, 2024

https://docs.nestjs.com/techniques/events#listening-to-events

Uses an @OnEvent decorator that we can hook into.

@nicohrubec nicohrubec mentioned this issue Aug 2, 2024
@nicohrubec nicohrubec self-assigned this Aug 2, 2024
@nicohrubec nicohrubec added the Package: nestjs Issues related to the Sentry Nestjs SDK label Aug 2, 2024
@nicohrubec nicohrubec removed their assignment Sep 4, 2024
@chargome chargome self-assigned this Nov 7, 2024
@chargome
Copy link
Member

Follow-up: With #14307 we only instrument event handlers per se and do not handle more complex operations like propagating traceId across events as the current solution seems to work fine. If the need for this comes up in the future we could look into patching the event queue (assuming there is one available in event-emitter) and enriching the events there directly.

Copy link
Contributor

A PR closing this issue has just been released 🚀

This issue was referenced by PR #14307, which was included in the 8.39.0 release.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Package: nestjs Issues related to the Sentry Nestjs SDK
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants