What moves and what does not
Squasher stores Sentry data in the same tables, with the same OpenTelemetry attribute names, as data
from OpenTelemetry and the Squasher SDKs. Queries, dashboards, and alerts work the same way for all of
them. Squasher renames old attribute names, such as
db.system and http.method, to the current
OpenTelemetry names, and keeps the original.
Run both tools side by side
Keep Sentry running while you check Squasher. Use one or both of these:- Connect your Sentry organization. Each new Sentry issue opens an incident in Squasher, and Sentry keeps all its data. See Connect a Sentry organization.
- Move one service at a time. Point one app or one environment at Squasher, and leave the rest on Sentry. Compare the two for a week that includes a deploy.
Point the Sentry SDK at Squasher
Set the DSN to this value in every Sentry SDK:sq_pk_...), not a Sentry key. The ingest key selects your project, so
the number at the end of the DSN can be any number. Sentry SDKs need a number there.
- JavaScript
- Python
- Other SDKs
instrument.ts
@sentry/browser, @sentry/nextjs, and the other JavaScript SDKs. In
the browser, read the key from your public environment variables.Squasher reads gzip and
deflate compressed envelopes, so you can keep request compression on in
the Sentry SDK. An envelope can be at most 1 MiB, before and after decompression. Brotli (br)
and zstd envelopes return 415. Older SDKs that send to /api/<project>/store/ also work.tunnel option to a Squasher URL, you can keep it or remove it. With a
tunnel, the SDK sends each envelope to the tunnel URL as it is.
sentry-cli works with Squasher too. send-event and monitors run send to the DSN, and
sourcemaps upload and the Sentry bundler plugins upload source maps to https://api.squasher.ai.
See Upload with sentry-cli or a Sentry bundler plugin.
Issues and logs of the same error
Squasher opens issues only from Sentry error events, as Sentry does. A Sentry SDK also sends some errors as a log or as a failed span: for example, the Python logging integration sendslogging.error() as an error event and as a log. Squasher stores the log and the span, but they do
not open a second issue or count twice toward your error quota.
Replace the Sentry SDK
In a JavaScript app, you can remove the Sentry SDK and install a Squasher SDK instead: Next.js, Node.js, or Browser. The calls map like this:
Then delete the Sentry config files, such as
sentry.server.config.ts and the withSentryConfig
wrapper in next.config.js.
Connect a Sentry organization
When you connect a Sentry organization, Sentry sends issue updates to Squasher. A new Sentry issue opens an incident in your Squasher project, and the incident resolves when the Sentry issue resolves. Open in Sentry on the incident opens the issue in Sentry. Agents can also read Sentry issues and their latest events through the API. Each Squasher project connects to one Sentry project. To connect in the dashboard, open Integrations, select Connect on the Sentry card, and approve the installation in Sentry. If the organization has more than one project, choose it in Sentry project on the card when Squasher opens again. If the Sentry card shows Manual setup, organization connect is not available yet, and the API returns503. Point the Sentry SDK at Squasher instead.
To connect with the REST API instead, use a credential with the project:write permission, which
an ingest key does not have. These examples read it from SQUASHER_TOKEN.
1
Create a connection link
action.url. The link works for 10 minutes.2
Install the app in Sentry
Open the link, choose your Sentry organization, and approve the installation. If the
organization has one project, Squasher connects it and opens the Squasher dashboard.
3
Choose the Sentry project
If the organization has more than one project, Squasher opens the dashboard with a
selection_token in the URL, and the Sentry card shows a project picker. To choose through
the API instead, send the token and the slug of the Sentry project:4
Check the connection
status is connected.DELETE to the same URL. Squasher then ignores new Sentry events, but it cannot
remove the app from Sentry. Uninstall the app in your Sentry organization settings too.
Check parity
Compare the service that you moved, over the same number of days before and after the switch:- The number of error events each day.
- The top issues. The same errors must not be split into many issues or merged into one.
- The
releaseandenvironmentvalues on each event. - The notifications. Each important error must reach the same channel as before.
Turn off Sentry
- Recreate the Sentry alert rules as notification routes.
- Point the source map step in your CI at Squasher, or replace it with
squasher sourcemaps upload. See Source maps. - Create a heartbeat monitor for each Sentry cron monitor, with a
name that gives the same slug (for example
Nightly Syncfornightly-sync). Sentry check-ins then signal it, and it alerts when a job fails or does not check in. - If you connected a Sentry organization, disconnect it and uninstall the app in Sentry.
- Remove the Sentry SDK, or keep it pointed at Squasher.
Give the migration to a coding agent
Next steps
Next.js SDK
Replace the Sentry SDK in a Next.js app.
OpenTelemetry
Send errors, traces, and logs from any language.
Set up notifications
Send new issues and incidents to your team.
Read AI triage
Learn what the triage summary tells you.