How to prevent Alert Management Rule from running multiple times and updating duplicate work notes?

Abdul13
Tera Contributor

Hi All, 

 

I’m working on a requirement in ServiceNow Event Management (EM Alerts) and facing an issue with multiple executions of the same sunflow.

Requirement:

  • A Alert Management Rule is triggered when an EM Alert is created or updated.

  • Based on Dynatrace root cause analysis, the sub-flow should:

    • Add a single work note to the alert

    • Complete all processing only once

    • If the same alert triggers the rule multiple times, it should not create duplicate work notes

    • If a new root cause is identified later, the logic may run again.

  • Problem

    • The Alert Management Rule runs when an alert matches the conditions. However, for the same alert, the rule (and the associated subflow) runs multiple times (for example, 5–7 times).

      Inside the subflow, we are using an Update Record action to update Work Notes. The requirement is to update Work Notes only once with the message "** Dynatrace identified ..." and skip the update if the same text already exists.

      We have written script logic to prevent duplicate updates, but it is still adding the same work note multiple times.

      I believe this is happening because Alert Management Rules execute very quickly, and multiple executions occur before the Work Notes/journal entry is committed, causing the duplicate check to fail.

      Abdul13_2-1765809173029.png
    •  
    • Abdul13_1-1765809080354.png

       

Thank you

5 REPLIES 5

JosephSan
Tera Expert

Hi, could changing the execution limit parameter to 1 be a solution for your problem ?