-
-
Notifications
You must be signed in to change notification settings - Fork 1.6k
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(nestjs): add SentryGlobalGenericFilter
and allow specifying application ref in global filter
#13673
feat(nestjs): add SentryGlobalGenericFilter
and allow specifying application ref in global filter
#13673
Conversation
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.
Looks good, thanks for that! The new e2e did not pass yet, did you try running it locally?
I can't seem to properly run the tests locally. I followed the |
@Sjoertjuh thanks, I'll check that today and get back to you |
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.
@Sjoertjuh looks good already, only the file formatting failed (yarn lint:prettier && yarn lint:biome
)
This PR adds the external contributor to the CHANGELOG.md file, so that they are credited for their contribution. See #13673 Co-authored-by: chargome <[email protected]>
Currently, a hybrid nestjs application should create its own global filter, since there is no way to use both http and graphql exception filters from sentry. This adds a new filter that uses the correct filter based on the context.
The new filter should also be usable for http-only and graphql-only applications, so it could be possible to deprecate the other filters.
These changes also allow the application ref to be set in the
SentryGlobalFilter
, which can be nice if the filter is registered withapp.useGlobalFilters()