Skip to content

feat(client-reports): Add transport loss recorder#1158

Open
szokeasaurusrex wants to merge 2 commits into
szokeasaurusrex/client-report-aggregatorfrom
szokeasaurusrex/transport-report-recorder
Open

feat(client-reports): Add transport loss recorder#1158
szokeasaurusrex wants to merge 2 commits into
szokeasaurusrex/client-report-aggregatorfrom
szokeasaurusrex/transport-report-recorder

Conversation

@szokeasaurusrex

@szokeasaurusrex szokeasaurusrex commented Jun 10, 2026

Copy link
Copy Markdown
Member

Add a public ClientReportRecorder handle for transports to record lost Sentry data without exposing the full client-report aggregator.

Pass the recorder through TransportOptions when the SDK client builds a transport. Recorded losses are aggregated into future client_report envelope items, so transports can report drops without sending extra requests.

Keep backwards-compatible transport construction paths working by using a no-op recorder when no client-report aggregator is available. Built-in transports will start calling the recorder in follow-up PRs.

Resolves #1148
Resolves RUST-223

@szokeasaurusrex szokeasaurusrex force-pushed the szokeasaurusrex/transport-report-recorder branch from d773421 to a3a0645 Compare June 10, 2026 15:16
@szokeasaurusrex szokeasaurusrex changed the title WIP: ClientReportRecorder feat(client-reports): Add transport loss recorder Jun 10, 2026
@linear-code

linear-code Bot commented Jun 10, 2026

Copy link
Copy Markdown

RUST-223

@github-actions

github-actions Bot commented Jun 10, 2026

Copy link
Copy Markdown
Messages
📖 Do not forget to update Sentry-docs with your feature once the pull request gets approved.

Generated by 🚫 dangerJS against e8d437b

@szokeasaurusrex szokeasaurusrex force-pushed the szokeasaurusrex/transport-report-recorder branch 2 times, most recently from b06abcc to 11aeb31 Compare June 10, 2026 15:28
@szokeasaurusrex szokeasaurusrex marked this pull request as ready for review June 10, 2026 15:29
@szokeasaurusrex szokeasaurusrex requested a review from lcian as a code owner June 10, 2026 15:29
Comment thread sentry-core/src/client/client_reports/recorder.rs
@szokeasaurusrex szokeasaurusrex force-pushed the szokeasaurusrex/transport-report-recorder branch 2 times, most recently from 70d4273 to 2c18ec2 Compare June 12, 2026 10:08
@szokeasaurusrex szokeasaurusrex force-pushed the szokeasaurusrex/client-report-aggregator branch 2 times, most recently from 08adad0 to ce47300 Compare June 12, 2026 12:37
@szokeasaurusrex szokeasaurusrex force-pushed the szokeasaurusrex/transport-report-recorder branch from 2c18ec2 to d6c1636 Compare June 12, 2026 12:37
cursor[bot]

This comment was marked as resolved.

Comment thread sentry-core/src/client/client_reports/mod.rs
@szokeasaurusrex szokeasaurusrex force-pushed the szokeasaurusrex/client-report-aggregator branch from ce47300 to cd4d502 Compare June 12, 2026 13:38
@szokeasaurusrex szokeasaurusrex force-pushed the szokeasaurusrex/transport-report-recorder branch from 397f1c3 to dd2269e Compare June 12, 2026 13:38

@cursor cursor Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Cursor Bugbot has reviewed your changes and found 1 potential issue.

Fix All in Cursor

❌ Bugbot Autofix is OFF. To automatically fix reported issues with cloud agents, enable autofix in the Cursor dashboard.

Reviewed by Cursor Bugbot for commit dd2269e. Configure here.

Comment thread sentry-core/src/client/envelope_sender.rs
@szokeasaurusrex szokeasaurusrex force-pushed the szokeasaurusrex/transport-report-recorder branch from dd2269e to c349e74 Compare June 12, 2026 13:41
@szokeasaurusrex szokeasaurusrex force-pushed the szokeasaurusrex/client-report-aggregator branch 2 times, most recently from 2fd0c53 to 3f24715 Compare June 12, 2026 15:28
@szokeasaurusrex szokeasaurusrex force-pushed the szokeasaurusrex/transport-report-recorder branch from c349e74 to 1c48443 Compare June 12, 2026 15:28
Add a public `ClientReportRecorder` handle for transports to record lost Sentry data without exposing the full client-report aggregator.

Pass the recorder through `TransportOptions` when the SDK client builds a transport. Recorded losses are aggregated into future `client_report` envelope items, so transports can report drops without sending extra requests.

Keep backwards-compatible transport construction paths working by using a no-op recorder when no client-report aggregator is available. Built-in transports will start calling the recorder in follow-up PRs.

Resolves [#1148](#1148)
Resolves [RUST-223](https://linear.app/getsentry/issue/RUST-223)
@szokeasaurusrex szokeasaurusrex force-pushed the szokeasaurusrex/client-report-aggregator branch from 3f24715 to 3438068 Compare June 12, 2026 15:49
@szokeasaurusrex szokeasaurusrex force-pushed the szokeasaurusrex/transport-report-recorder branch from 1c48443 to e8d437b Compare June 12, 2026 15:49
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant