JMS advanced message filters

Overview

The following types, which are specific to the registerNotification method, provide advanced filtering for clients that subscribe to the 5620-SAM-topic-xml-filtered topic. The filtering reduces the number of event messages that the NFM-P sends to a client. See Advanced JMS message filters for more information.

filter-set

A filter-Set element can contain multiple filter elements that are processed using the Boolean OR function. If no filters are specified, no events are returned.

Figure 6-9, Advanced filter example with leaf and composite elements is an example of an advanced message filter that has two filters in the filter set. Each filter contains leaf and composite filter elements.

The first filter specifies the abstract service.Service class to filter service events, and the filter elements specify events that meet the following criteria:

The second filter specifies the forwarding of events associated with any port on card 1 of NE 10.20.40.218 that has a compositeEquipmentState other than:

Figure 6-9: Advanced filter example with leaf and composite elements
<filter-Set>
   <filter class="service.Service">
      <and>
         <equal name="subscriberId" value="22"/>
         <greater name="serviceId" value="10"/>
         <or>
            <equal name="administrativeState" value="2"/>
            <equal name="aggrOperationalState" value="3"/>
            <equal name="tier" value="2"/>
         </or>
      </and>
   </filter>
   <filter>
      <and>
         <wildcard name="objectFullName" value="network:10.20.40.218:shelf-1:cardSlot-1:card:daughterCardSlot-1:daughterCard:%"/>
         <not>
            <in class="equipment.Equipment" name="compositeEquipmentState" value="5,6,7,9"/>
         </not>
      </and>
   </filter>
</filter-Set>
resultFilter-Set

Result filters are applied to the class properties of the events to restrict the events that are included in an event vessel. A result filter is specified using the resultFilter-Set type in the registerNotification method.

The class tag allows a class of ManagedObject, which is the base class for all classes, to be specified. The class value must be unique in the resultFilter-Set element.

Note: The children element is not valid in a resultFilter-Set element because child attributes are not sent in a JMS message.

Only AttributeValueChangeEvent, ObjectCreationEvent, or ObjectDeletionEvent attributes of an AlarmInfo object may be suppressed in an event vessel when a result filter is defined.

If no AttributeValueChangeEvent, ObjectCreationEvent, or ObjectDeletionEvent attributes of an AlarmInfo object match the result filter, then the entire event is suppressed and is not included in the event vessel. Including the following in a result filter ensures that events are not suppressed because of unmatched attributes:

<resultFilter>
    <attribute>objectFullName</attribute>
</resultFilter>

The following figure shows the first resultFilter element applied to all ManagedObject classes except for equipment.Port and fm.AlarmObject; only the objectFullName class property is to be returned. The second resultFilter element applies to equipment.Port objects only. The third resultFilter applies to fm.AlarmObject objects only.

Figure 6-10: resultFilter-Set element example
<resultFilter-Set>
   <resultFilter>
      <attribute>objectFullName</attribute>
   </resultFilter>
   <resultFilter class="equipment.Port">
      <attribute>objectFullName</attribute>
      <attribute>operationalState</attribute>
      <attribute>administrativeState</attribute>
   </resultFilter>
   <resultFilter class="fm.AlarmObject">
      <attribute>affectedObjectFullName</attribute>
      <attribute>severity</attribute>
      <attribute>operatorAssignedUrgency</attribute>
      <attribute>additionalText</attribute>
   </resultFilter>
</resultFilter-Set>
extraTags

By default, JMS event vessels do not include the JMS header properties of the contained events. In order to return event header properties, you must specify the properties using the extraTags type during filter registration. The header properties are then included in the body of each associated event that has the header property.

If a JMS event does not have a specified header property, the property is excluded from the event body. If an eventName value is omitted, the specified JMS header property is returned for each event that has the property.

See Table 4-5, Filterable event classes for a list of filterable event classes.

The following figure shows each StatsEvent message is to include the MTOSI_osTime JMS header property in its body. All events are to include the fullClassName property. However, since a StatsEvent message does not have a fullClassName property, it is not included in the StatsEvent message body

Figure 6-11: extraTags element example, registerNotification method
<extraTags>
   <tag name="MTOSI_osTime" eventName="StatsEvent" />
   <tag name="fullClassName" />
</extraTags>