Skip to content

Greater flexibility when creating alert conditions #54732

Closed

Description

@lobsterkatie

Problem Statement

Right now, when creating a conditional alert, you have two choices: match all conditions, or match any condition. This prevents conditions like if animal = dog and fur = brown and breed in [catahoula, pit bull, chow] and if (animal = dog and fur = brown) or (animal = cat and fur = white) from being applied.

One example use case, submitted by a user, is to have one of the conditions be a match to one of several different tags (similar to my first example above), but one can imagine more complex conditions being desired.

Right now, the only workarounds are a) use the SDK to add an alert-specific tag to events which should trigger the rule, b) create multiple rules, which are almost but not quite the same, or c) build an internal integration to forward the alert data to some other service, which can then run the full conditions. Obviously, none of these is great.

Solution Brainstorm

Simpler solutions, which would handle the user's case in the linked issue:

  • In addition to a match being able to be equals, starts with, contains, etc., add an is one of option, which then would take a comma separated list of values.
  • Similar to the above, but add a matches regex option.

More complicated solution:

  • Allow combining conditions more flexibly with ANDs and ORs. I get that in theory this could allow a user to create a frankenstein rule out of rules which really should be separate, but it would allow for a one-rule-per-resulting-action paradigm, which actually IMHO isn't a terrible way to think about alerts.

Product Area

Alerts

Activity

  1. getsantry commented on Aug 14, 2023

    @getsantry
    Contributor

    Routing to @getsentry/product-owners-alerts for triage ⏲️

  2. changed the title [-]Great flexibility when creating alert conditions[/-] [+]Greater flexibility when creating alert conditions[/+] on Aug 14, 2023
  3. jalaziz commented on Oct 21, 2023

    @jalaziz

    Our team would absolutely love this.

    We want to be able to create an alert rule for some subset of environments, but ALSO use event attribute filters to enforce a level filter.

    Unfortunately, it seems the only option is creating multiple alert rules which gets very painful quickly as we have multiple services that all the same alert rules.

  4. moved this to Waiting for: Product Owner in GitHub Issues with 👀on Oct 21, 2023
  5. moved this from Waiting for: Product Owner to No status in GitHub Issues with 👀on Oct 26, 2023
  6. karol-wons-deel commented on May 2, 2024

    @karol-wons-deel

    Upvoting this idea 👍
    At deel.com we also wanted to build an alerting system based on URL regex matches

  7. moved this to Waiting for: Product Owner in GitHub Issues with 👀 2on May 2, 2024
  8. 22 remaining items

  9. moved this from Waiting for: Product Owner to No status in GitHub Issues with 👀 3on Sep 8, 2025
  10. liam-eci commented on Oct 21, 2025

    @liam-eci

    @saponifi3d, great news. When can we expect to see these improvements? Any prediction helps. This is causing a lot of duplications on our alert rules - and the system is limited to 100 rules.

  11. moved this to Waiting for: Product Owner in GitHub Issues with 👀 3on Oct 21, 2025
  12. saponifi3d commented on Oct 21, 2025

    @saponifi3d
    Contributor

    @liam-eci 👋 helloooo from the OR conditions ticket!

    so.. 😅... my manager dislikes this answer too, but.. I'm not really sure about when we'll be able to flip this on.

    We've started internally testing and getting some great feedback. That also means, more things for us to do before we release to a wider audience. Also, we're a little nervous about some larger changes because we want to make sure to get this right; so we're going to make a post with screen shots and ask y'all for feedback too (I believe that will be up later today).

    Hopefully it helps know that we're on the last mile of the project, and y'all will be able to see some of these things soon. 🫶

  13. moved this from Waiting for: Product Owner to No status in GitHub Issues with 👀 3on Oct 21, 2025
  14. ReneGreen27 commented on Oct 22, 2025

    @ReneGreen27

    Upvote for OR conditions contained in internal ticket #164451

  15. moved this to Waiting for: Product Owner in GitHub Issues with 👀 3on Oct 22, 2025
  16. moved this from Waiting for: Product Owner to No status in GitHub Issues with 👀 3on Oct 22, 2025
  17. souredoutlook commented on May 22, 2026

    @souredoutlook
    Contributor

    We shipped the ability to do the following:

    match being able to be equals, starts with, contains, etc., add an is one of option, which then would take a comma separated list of values.

    Image

    We also support multiple IF THEN blocks per alert.

    Closing as done.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions