Can duration be set to 0 using EventRateCounter in Spectrum?
search cancel

Can duration be set to 0 using EventRateCounter in Spectrum?


Article ID: 239738


Updated On:


CA Spectrum DX NetOps


When creating a custom Event and using an EventRateCounter, a duration needs to be set so that it knows the time period over which to check for the number of specified events that have occurred. However, if setting this EventRateCounter on a custom event raised by a job who's time-frame to completion is indeterminate, ie. there is no certainty as to the Job complete duration, then the duration cannot be set to a fixed period.

For example, if a current Rule is:

0xfff00001 E 20 R CA.EventCondition, "(regexp({v 4}, {S \"Failed\"}))" , "0xfff00006  -:-"

And it is updated with an EventRateCounter where the duration is set to 600, then it will be configured to check for 3 occurrences over a period of 600 seconds (10 mins):

0xfff00001 E 20 R CA.EventCondition, "(regexp({v 4}, {S \"Failed\"}))" , "0xfff00006  -:-"

0xfff00006 E 30 R CA.EventRateCounter, 3, 600, 0xfff06154

But if the event is raised by a job in an unknown timeframe, then can the duration be set to infinite or not at all?


DX NetOps Spectrum 20.2 or later


No, the duration field is necessary since the EventRateCounter rule specifies if a certain condition occurs in a set number of times over a defined period of time. Our TechDocs describes this in further detail:

TechDocs : DX NetOps 21.2 Spectrum : About Defining Event Rules

So you can't get rid of the duration, otherwise the rule would never reset.

Maybe set the duration to something like 24 hours which make the seconds value = 86400. Note, if the SpectroSERVER is restarted, or the events are reloaded under VNM -> SpectroSERVER control, then the counter will be reset to 0.

If it retries 3 times and fails within the 24 hour period then the alarm should be raised.