Allow customizing the “100 events in 24h” threshold for Slow DB Query detection
- Dominant language
- Python
- Stars
- 44.8k
- Forks
- 4.9k
- Avg merge
- 22h 21m
- Merged PRs (30d)
- 586
Description
### Problem Statement
A customer reported that they rely on Sentry’s “Slow DB Query” performance issue detector in their project. Currently, the detection logic requires that the same SELECT query appears as a “slow” span in 100 events within a 24-hour window (with default span duration ≥ 500 ms) before an issue is created. This makes it difficult for them to surface slower queries that occur less frequently, but which are still problematic in their use case.
While Sentry allows adjusting the duration threshold via Project Settings → Performance, it does not allow lowering or removing the 100-events requirement. The customer noted that offering this configurability would help teams with lower traffic or more specialized queries to still benefit from Sentry’s slow query detection.
### Solution Brainstorm
_No response_
### Product Area
Performance
Contributor guide
Research direction
Start by locating Sentry’s Slow DB Query performance issue detector and the logic enforcing 100 matching events within 24 hours. Read its existing tests and project performance settings, then define the configuration path and test coverage needed for a customizable or disabled event threshold.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- python
- Domain
- performance
- Issue type
- Feature
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 30/100