getsentry / getsentry/sentry-rust
Enforce 1000 queued-logs hard cap in LogsBatcher
- Dominant language
- Rust
- Stars
- 752
- Forks
- 190
- Avg merge
- 1h 21m
- Merged PRs (30d)
- 5
Description
The logs buffering spec requires SDKs to enforce a hard limit of 1000 queued logs and to send no more than 100 logs per envelope (see [develop docs](https://develop.sentry.dev/sdk/telemetry/logs/#buffering)).
In [`sentry-core/src/logs.rs`](https://github.com/getsentry/sentry-rust/blob/5975043daabe826b31ce293629298f10d8e2cb7b/sentry-core/src/logs.rs), `LogsBatcher` already flushes at 100 logs per envelope but currently does not enforce a 1000-item queue cap. We should add this cap so logs above the limit are dropped instead of allowing unbounded queue growth.
Contributor guide
No contributing guide indexed for this repository
Assessment
This issue has not been assessed yet.