Calvin,
For SBG, I would do all the rules under default $SPECROOT/CsVendor/gen_app_gw
directory. The reason being for SBG integration only event registration is
supported in custom area and I personally prefer to keep all the files together
to avoid confusion at a later point of time.
Regarding alarm Set and clear, have you ever tried SeverityMaps, it will make
your life easier.
Just as an example of SeverityMaps from my SBG integration
$SPECROOT\SS\CsVendor\gen_app_gw\EventDisp
#If volAlertSeverity (varbind 111) is info (1) - just log the event.
# If volAlertType (varbind 106) = 1 or 2 raise alarm based on volAlertSeverity,
if 0 clear alarm, if something else just log the event.
0x04cd2010 E 20 R { 100 } CA.EventCondition, "( { v 111 } == { I 1 } )",
"0x04cd2013 -:-", \
"( { v 106 } == { I 1 } || { v 106 } == { I 2 }
)", "0x04cd2011 -:-", \
"{ v 106 } == { I 0 }", "0x04cd2012 -:-", \
"default", "0x04cd2013 -:-"
0x04cd2011 E 20 A { v 111 gen_app_gw.volSevMap },0x04cd2010,100
0x04cd2012 E 10 C 0x04cd2010,100
0x04cd2013 E 10
$SPECROOT\SS\CsVendor\gen_app_gw\SeverityMaps\volSevMap
2 1
3 1
4 2
5 3
Saurabh Bohra
O: 860-766-0842 | M: 860-385-3597 | e-mail: [email protected]
From: Calvin Lane [mailto:[email protected]]
Sent: Thursday, May 31, 2012 12:18 PM
To: spectrum
Subject: [spectrum] Event Rules Help
Hello everyone,
I need some help with event rules. This is currently what I have in the
$SPECROOT/custom/Events/EventDisp file:
0x0210cd2 R CA.SplitDataUsingPattern,
2,".+\\.(.*?\\..*?\\..*?\\..*?)\\..*?$<file:///\\..*%3f$>", 0xfff01005, 500
0xfff01005 R CA.EventCondition, "default" , "0xfff01006 1-99:101-199,501:8"
This works well in that the first line parses the network address out of
varbind 2, using the SplitDataUsingPattern custom rule created by Mike Doyle,
and assigns it to variable value 501 in event 0xfff01005. Next, event
0xfff01006 is created and variable value 501 is assigned to variable value 8.
Then in my EventAdmin EventDisp file for the SBGW, I have 0xfff01006 registered
so that when this event comes in, it asserts an alarm against the model that
matches the network address in variable value 8.
All of this works well. Now I need to make a few minor adjustments. I need to
either set or clear the alarm based on one of 15 values for varbind 1. I
know how to build the logic, I'm just not sure if I should do it in the
$SPECROOT/custom/Events/EventDisp file or in the EventModel EventDisp file in
SBGW.
This is how I think it should look:
0x0210cd2 R CA.SplitDataUsingPattern,
2,".+\\.(.*?\\..*?\\..*?\\..*?)\\..*?$<file:///\\..*%3f$>", 0xfff01005, 500 \
"({v 1} == {I 1} || {v 1} == {I 3} || {v 1} == {I 6}|| {v 1} == {I 7}|| {v 1}
== {I 9}|| {v 1} == {I 13}|| {v 1} == {I 14}|| {v 1} == {I 15})" , "0xfff01008
1-99:101-199,501:8", \
"({v 1} == {I 2})" , "0xfff01009 1-99:101-199,501:8", \
"default" , "0xfff01010 1-99:101-199,501:8"
I will create the sets and clears in ECE and then register 0xfff01008,
0xfff01009, and 0xfff01009 in the EventAdmin EventDisp file. Can someone
verify that this will do what I'm expecting? And if not, suggest the correct
format. Thanks in advance for any assistance.
Calvin
* --To unsubscribe from spectrum, send email to
[email protected]<mailto:[email protected]> with the body: unsubscribe spectrum
[email protected]<mailto:[email protected]>
---
To unsubscribe from spectrum, send email to [email protected] with the body:
unsubscribe spectrum [email protected]