example way of instrumenting server + client component (spoiler alert: it sucks)
additionally send sentry-constructed otel spans to local OTLP exporter
:rocket:
This description was created by Ellipsis for commit 2d11b2618d99349574f761b7f0efefb9895700b8
Summary:
Integrated Sentry for error tracking and performance monitoring, including configurations for client, server, and edge environments, and updated user instrumentation and global error handling.
Key points:
Added Sentry integration for error tracking and performance monitoring.
Configured Sentry for client (packages/webapp/sentry.client.config.ts), server (packages/webapp/sentry.server.config.ts), and edge (packages/webapp/sentry.edge.config.ts) environments.
Updated packages/webapp/next.config.mjs to include Sentry configuration.
Modified packages/webapp/app/dashboard/clusters/page.tsx to instrument user data on the server and client sides.
Added global error handling in packages/webapp/app/global-error.tsx.
Updated packages/webapp/app/server/user/index.ts to include user instrumentation functions.
Created packages/webapp/components/Instrumentation.tsx for client-side user instrumentation.
Updated dependencies in packages/webapp/package.json to include Sentry and OpenTelemetry packages.
Modified .gitignore to include Sentry config file.
Removed turbopack from the dev script in packages/webapp/package.json due to incompatibility with Sentry.
add sentry
sentry init wizard result
sentry doesn't work with turbopack: https://github.com/getsentry/sentry-javascript/issues/8105
fix esm import warnings
example way of instrumenting server + client component (spoiler alert: it sucks)
additionally send sentry-constructed otel spans to local OTLP exporter
Summary:
Integrated Sentry for error tracking and performance monitoring, including configurations for client, server, and edge environments, and updated user instrumentation and global error handling.
Key points:
packages/webapp/sentry.client.config.ts
), server (packages/webapp/sentry.server.config.ts
), and edge (packages/webapp/sentry.edge.config.ts
) environments.packages/webapp/next.config.mjs
to include Sentry configuration.packages/webapp/app/dashboard/clusters/page.tsx
to instrument user data on the server and client sides.packages/webapp/app/global-error.tsx
.packages/webapp/app/server/user/index.ts
to include user instrumentation functions.packages/webapp/components/Instrumentation.tsx
for client-side user instrumentation.packages/webapp/package.json
to include Sentry and OpenTelemetry packages..gitignore
to include Sentry config file.turbopack
from thedev
script inpackages/webapp/package.json
due to incompatibility with Sentry.Generated with :heart: by ellipsis.dev