Skip to content

Change default error unwrap limit for SDK #1080

@giortzisg

Description

@giortzisg

The current behavior of the SDK is to silently limit the max number of errors that can we unwrapped to only 10. From a quick investigation, these are the envelope sizes that we get based on the number of errors unwrapped:

std lib errors*
Depth     max=unlimitedmax=1       max=5       max=10      max=20
1         0.5KB       0.5KB       0.5KB       0.5KB       0.5KB
3         0.8KB       0.6KB       0.8KB       0.8KB       0.8KB
5         1.2KB       0.6KB       1.2KB       1.2KB       1.2KB
10        2.3KB       0.6KB       1.2KB       2.3KB       2.3KB
20        5.1KB       0.6KB       1.2KB       2.3KB       5.1KB
50        19.4KB      0.6KB       1.2KB       2.3KB       5.1KB
100       62.9KB      0.6KB       1.2KB       2.3KB       5.1KB

*pkg/errors (with stacktrace attached on each error)
*
*Depth     max=unlimitedmax=1       max=5       max=10      max=20
1         0.9KB       0.9KB       0.9KB       0.9KB       0.9KB
3         2.6KB       1.0KB       2.6KB       2.6KB       2.6KB
5         4.3KB       1.0KB       2.6KB       4.3KB       4.3KB
10        8.8KB       1.0KB       2.6KB       4.5KB       8.8KB
20        19.3KB      1.0KB       2.6KB       4.5KB       9.1KB
50        62.4KB      1.0KB       2.6KB       4.5KB       9.1KB
100       173.6KB     1.0KB       2.7KB       4.6KB       9.1KB

Based on envelope limits found here

https://develop.sentry.dev/sdk/data-model/envelopes/#size-limits, we can change the default to 100.

Metadata

Metadata

Assignees

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions