Subscriptions for Event Analytics are defined as metadata attributes for rules in this format:
Note that the metadata attribute name ("subscription") must be unique within a rule. If you need to specify more than one subscription for a rule, you can add a suffix to the attribute name. All metadata attributes with a name starting with "subscription" are considered to contain subscription strings.
@subscription1(subscription string) @subscription2(subscription string) @subscription3(subscription string)
Another option is to use one metadata attribute having several subscription strings separated by the semicolon character (";") as metadata value.
@subscription(subscription string; subscription string; subscription string)
This metadata can only exist inside a rule. However several rules may of course need the same subscription. While it works to duplicate the subscriptions (since they are merged), a more organized approach could be to create a "dummy" rule that only contains subscription metadata attributes.
The following is an example of some subscription rules:
rule "Subscriptions_Item" @subscription1(M3:MITMAS:CUD) @subscription2(M3:MITBAL:CUD) then end rule "Subscriptions_Order" @subscription(M3:OOHEAD:CUD;M3:OOLINE:CUD) then end