15 lines
472 B
TypeScript
15 lines
472 B
TypeScript
// Import with `import * as Sentry from "@sentry/node"` if you are using ESM
|
|
const Sentry = require("@sentry/node");
|
|
const { nodeProfilingIntegration } = require("@sentry/profiling-node");
|
|
|
|
Sentry.init({
|
|
dsn: process.env.SENTRY_DSN,
|
|
integrations: [
|
|
nodeProfilingIntegration(),
|
|
],
|
|
// Tracing
|
|
tracesSampleRate: 1.0, // Capture 100% of the transactions
|
|
|
|
// Set sampling rate for profiling - this is relative to tracesSampleRate
|
|
profilesSampleRate: 1.0,
|
|
}); |