Skip to content

Limit occurrence of repeated errors #46670

Closed

Description

@nemesifier

Problem Statement

If a critical infrastructure component goes down (say a DB cluster becomes unreachable due to network issues), an application will start generating a lot of errors.

When this happens, small organizations which do not have staff available 24/7 can incur in the very unpleasant situation in which this repeated error happens during a holiday or weekend while the staff is off and consumes not only the entire error quota, but also the on-demand spend.

Solution Brainstorm

To avoid this, it would be really great if there was a way we could tell sentry to discard the same occurrence of the same error if there's more occurrences of X times within X hours. For example, I wouldn't want to receive more than 200 instances of an error within 24 hours. By the time I wake up I will find out and intervene.

Activity

  1. getsantry commented on Mar 31, 2023

    @getsantry
    Contributor

    Assigning to @getsentry/support for routing, due by Friday, March 31st at 5:00 pm (sfo). ⏲️

  2. getsantry commented on Mar 31, 2023

    @getsantry
    Contributor

    Routing to @getsentry/telemetry-experience for triage, due by Tuesday, April 4th at 17:00 (vie). ⏲️

  3. getsantry commented on Apr 3, 2023

    @getsantry
    Contributor

    Routing to @getsentry/enterprise for triage, due by Tuesday, April 4th at 5:00 pm (sfo). ⏲️

  4. matejminar commented on Apr 3, 2023

    @matejminar
    Member

    Hey Enterprise team, can you please take a look? I would expect spike protection to kick in / solve this.

  5. nemesifier commented on Apr 3, 2023

    @nemesifier
    Author

    AFAIK spike protection will work only the first few hours but afterwards as the average of the collected errors increases it will allow the errors to be collected.

  6. souredoutlook commented on Apr 3, 2023

    @souredoutlook
    Contributor

    @nemesisdesign we're working on rolling out Spike Protection 2.0 #44155 @Dhrumil-Sentry can add some additional details

  7. leedongwei commented on Apr 4, 2023

    @leedongwei
    Contributor

    @nemesisdesign we have a new heuristic for Spike Protection that raises the limit less. Here's an example of its behaviour during an extended incident.
    Screenshot 2023-04-04 at 1 08 00 PM

    This should help to put an upper-bound on the consumption of your quota and on-demand during a long incident. This new Spike Protection will be rolled out next week and it should solve your issue.

    On the feature request:

    I wouldn't want to receive more than 200 instances of an error within 24 hours.

    We are highly unlikely to build a tool to do exactly this. To identify an incoming event as the 201th instance of an error, Sentry would need to unpack, process, fingerprint and cross-reference it - which is essentially all the computationally expensive work. The final step of storing and querying is cheap.

    We would not be sustainable as a business if we do not count usage for the expensive parts of the pipeline.

    The best way to protect your quota/on-demand during an incident is through client-side sampling, spike protection and spend allocation - which happens much earlier in the pipeline.

  8. github-actions commented on Apr 26, 2023

    @github-actions
    Contributor

    This issue has gone three weeks without activity. In another week, I will close it.

    But! If you comment or otherwise update it, I will reset the clock, and if you label it Status: Backlog or Status: In Progress, I will leave it alone ... forever!


    "A weed is but an unloved flower." ― Ella Wheeler Wilcox 🥀

  9. locked and limited conversation to collaborators on May 19, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions