@@ -35,10 +35,6 @@ interface ExpressRequest {
3535
3636/**
3737 * Interceptor to add Sentry tracing capabilities to Nest.js applications.
38- *
39- * @deprecated `SentryTracingInterceptor` is deprecated.
40- * If you are using `@sentry/nestjs` you can safely remove any references to the `SentryTracingInterceptor`.
41- * If you are using another package migrate to `@sentry/nestjs` and remove the `SentryTracingInterceptor` afterwards.
4238 */
4339class SentryTracingInterceptor implements NestInterceptor {
4440 // used to exclude this class from being auto-instrumented
@@ -73,10 +69,7 @@ class SentryTracingInterceptor implements NestInterceptor {
7369 return next . handle ( ) ;
7470 }
7571}
76- // eslint-disable-next-line deprecation/deprecation
7772Injectable ( ) ( SentryTracingInterceptor ) ;
78- // eslint-disable-next-line deprecation/deprecation
79- export { SentryTracingInterceptor } ;
8073
8174/**
8275 * Global filter to handle exceptions and report them to Sentry.
@@ -122,50 +115,6 @@ class SentryGlobalFilter extends BaseExceptionFilter {
122115Catch ( ) ( SentryGlobalFilter ) ;
123116export { SentryGlobalFilter } ;
124117
125- /**
126- * Global filter to handle exceptions in NestJS + GraphQL applications and report them to Sentry.
127- *
128- * @deprecated `SentryGlobalGraphQLFilter` is deprecated. Use the `SentryGlobalFilter` instead. The `SentryGlobalFilter` is a drop-in replacement.
129- */
130- class SentryGlobalGraphQLFilter {
131- private static readonly _logger = new Logger ( 'ExceptionsHandler' ) ;
132- public readonly __SENTRY_INTERNAL__ : boolean ;
133-
134- public constructor ( ) {
135- this . __SENTRY_INTERNAL__ = true ;
136- }
137-
138- /**
139- * Catches exceptions and reports them to Sentry unless they are HttpExceptions.
140- */
141- // eslint-disable-next-line @typescript-eslint/no-unused-vars
142- public catch ( exception : unknown , host : ArgumentsHost ) : void {
143- // neither report nor log HttpExceptions
144- if ( exception instanceof HttpException ) {
145- throw exception ;
146- }
147- if ( exception instanceof Error ) {
148- // eslint-disable-next-line deprecation/deprecation
149- SentryGlobalGraphQLFilter . _logger . error ( exception . message , exception . stack ) ;
150- }
151- captureException ( exception ) ;
152- throw exception ;
153- }
154- }
155- // eslint-disable-next-line deprecation/deprecation
156- Catch ( ) ( SentryGlobalGraphQLFilter ) ;
157- // eslint-disable-next-line deprecation/deprecation
158- export { SentryGlobalGraphQLFilter } ;
159-
160- /**
161- * Global filter to handle exceptions and report them to Sentry.
162- *
163- * This filter is a generic filter that can handle both HTTP and GraphQL exceptions.
164- *
165- * @deprecated `SentryGlobalGenericFilter` is deprecated. Use the `SentryGlobalFilter` instead. The `SentryGlobalFilter` is a drop-in replacement.
166- */
167- export const SentryGlobalGenericFilter = SentryGlobalFilter ;
168-
169118/**
170119 * Set up a root module that can be injected in nest applications.
171120 */
@@ -179,7 +128,6 @@ class SentryModule {
179128 providers : [
180129 {
181130 provide : APP_INTERCEPTOR ,
182- // eslint-disable-next-line deprecation/deprecation
183131 useClass : SentryTracingInterceptor ,
184132 } ,
185133 ] ,
@@ -191,7 +139,6 @@ Module({
191139 providers : [
192140 {
193141 provide : APP_INTERCEPTOR ,
194- // eslint-disable-next-line deprecation/deprecation
195142 useClass : SentryTracingInterceptor ,
196143 } ,
197144 ] ,
0 commit comments