Postgres
Adds instrumentation for Postgres. (default)
This integration only works in the Node.js and Bun runtimes.
Import name: Sentry.postgresIntegration
This integration is enabled by default when performance monitoring is enabled. If you'd like to modify your default integrations, read this.
The postgresIntegration adds instrumentation for the pg library to capture spans using @opentelemetry/instrumentation-pg.
Copied
Sentry.init({
integrations: [Sentry.postgresIntegration()],
});
Type: boolean
Available since: 10.40.0
When true, the integration does not create spans for pg.connect or pg.pool.connect calls. Use this to reduce trace noise when connection setup is not useful to monitor. Default is false.
Copied
Sentry.init({
integrations: [Sentry.postgresIntegration({ ignoreConnectSpans: true })],
});
pg:>=8 <9
Was this helpful?
Help improve this content
Our documentation is open source and available on GitHub. Your contributions are welcome, whether fixing a typo (drat!) or suggesting an update ("yeah, this would be better").
Our documentation is open source and available on GitHub. Your contributions are welcome, whether fixing a typo (drat!) or suggesting an update ("yeah, this would be better").