Skip to content

Commit

Permalink
reenable otel
Browse files Browse the repository at this point in the history
  • Loading branch information
JoeKarow committed Nov 10, 2023
1 parent bd5bcee commit d362171
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 4 deletions.
4 changes: 2 additions & 2 deletions apps/app/instrumentation.node.ts
Original file line number Diff line number Diff line change
Expand Up @@ -10,10 +10,10 @@ import { config } from 'dotenv'
config({ path: '../../.env' })
const otelTraceOptions = process.env.OTEL_SERVER ? { url: process.env.OTEL_SERVER } : undefined

if (!process.env.VERCEL) console.log('Initializing OpenTelemetry...')
// if (!process.env.VERCEL) console.log('Initializing OpenTelemetry...')

if (otelTraceOptions) {
console.log(`Using custom server: ${otelTraceOptions.url}`)
console.log(`Using custom OpenTelemetry server: ${otelTraceOptions.url}`)
}

const sdk = new NodeSDK({
Expand Down
2 changes: 1 addition & 1 deletion apps/app/next.config.mjs
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ const nextConfig = {
},
experimental: {
// outputFileTracingRoot: path.join(__dirname, '../../'),
// instrumentationHook: true,
instrumentationHook: true,
webpackBuildWorker: true,
},
eslint: {
Expand Down
2 changes: 1 addition & 1 deletion apps/app/sentry.server.config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ Sentry.init({

// Setting this option to true will print useful information to the console while you're setting up Sentry.
debug: !!process.env.SENTRY_DEBUG,
// instrumenter: 'otel',
instrumenter: 'otel',
integrations: [
new Sentry.Integrations.RequestData(),
new Sentry.Integrations.Prisma({ client: prisma }),
Expand Down

0 comments on commit d362171

Please sign in to comment.