Skip to content

Commit

Permalink
refactor(back): remove deprecated Sentry enableTracing option
Browse files Browse the repository at this point in the history
  • Loading branch information
tsa96 committed Jan 5, 2025
1 parent dbe2662 commit 2bc1815
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions apps/backend/src/instrumentation.ts
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ import { Environment } from './app/config';

const dsn = process.env['SENTRY_DSN'];
const enableTracing = process.env['SENTRY_ENABLE_TRACING'] === 'true';
const sampleRate = +process.env['SENTRY_TRACE_SAMPLE_RATE'];
const sampleRate = enableTracing ? +process.env['SENTRY_TRACE_SAMPLE_RATE'] : 0;

const integrations: Integration[] = [nestIntegration()];

Expand All @@ -39,7 +39,6 @@ if (process.env['SENTRY_ENABLE_NODE_PROFILING'] === 'true') {
const opts: NodeOptions = {
dsn,
environment: process.env['SENTRY_ENV'],
enableTracing,
tracesSampleRate: sampleRate,
profilesSampleRate: sampleRate,
debug: false,
Expand Down

0 comments on commit 2bc1815

Please sign in to comment.