-
Notifications
You must be signed in to change notification settings - Fork 93
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
ref(rate-limits): Rate limit envelopes instead of metrics for sampled…
…/indexed items (#3716) Partially Implements: #3662 (does not move rate limits to after aggregation). Changes: - Data in an envelope is always considered to be both Indexed and Non-Indexed, for example: Until a transaction is removed from an envelope it is considered to be both `Transaction` and `TransactionIndexed`. Only dynamic sampling, when dropping the transaction from the envelope, emits one outcome with the `TransactionIndexed` category. - A few tests asserted the old/wrong behaviour of only emitting a single outcome, e.g. when an inbound filter filters a transaction we used to only get a `Transaction` outcome but not a `TransactionIndexed`, these tests have been aligned. - When checking rate limits for an envelope, quota on the 'base' category (e.g. `Transaction`) is now consumed. - Metrics now remember whether they were extracted from a sampled envelope item. - Metrics are immediately rate limited using the same rate limits as the ones used for the envelope. - Metrics from sampled envelopes will not be rate limited again. - Improved cached rate limits with a new type struct, which surfaced a bug that they weren't always correctly expired (fixed). Future Improvements: - Move metrics rate limiting to after aggregation - Stream line metrics rate limiting from 4 (cached transactions/spans, transactions/spans, cached metric_buckets, metric_bucket) different checks to 2 (cached, non-cached)
- Loading branch information
Showing
29 changed files
with
1,645 additions
and
830 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.