Configuring the transformer definition file

The transformer definition file maps the XML event sources to their related XSLT files, and directs the probe and the gateway to use the XSLT file associated to the XML event source.

The transformers.xml transformer definition file, located in the $OMNIHOME/java/conf directory, defines how the messages that the probe reads, or that the gateway sends, are transformed. This file is divided into two logical sections, one for the probe (southbound) and one for the gateway (northbound).

After creating an XSLT file for each event source, you create a transformer entry in the transformer definition file. This enables the transformer module to use the specified XSLT file when transforming events for that event source.

By default, the probe section enables the following transformations:
  • messages received on a topic name of cbe are transformed by the cbe2nvpairs XSLT file
  • messages received on a topic name of wef are transformed by the wef2nvpairs XSLT file
  • messages received on a topic name of wbe are transformed by the wbe2nvpairs XSLT file
  • messages received on a topic name of netcool are transformed by the netcool2nvpairs XSLT file
By default, the gateway section enables the following transformations:
  • Netcool® events that have an identifier of cbeEvents are transformed into CBE events (using the netcool2cbe XSLT file) and published to the JMS using the topic cbe
  • Netcool events that have an identifier of wefEvents are transformed into WEF events (using the netcool2wef XSLT file) and published to the JMS using the topic wef
  • Netcool events that have an identifier of netcoolEvents are published to the JMS using the topic netcool (without using an XSLT transformer)
Each entry takes the following format:
<tns:transformer name="transformer_name" type="southbound | northbound" 
endpoint="event_endpoint" className="class_name">

<tns:property name="property_name" type="property_type" value="property_value" 
description="description"/> 

</tns:transformer> 
where:
  • transformer_name specifies the name of the transformer definition for an event source.
  • type specifies the type of transformer being defined.

    This is either southbound for transformers used by the probe, or northbound for transformers used by the gateway.

  • event_endpoint maps the endpoint from which the event arrived to an XSLT transformer and determines the endpoint to which the event source sends events.
  • class_name is the name of the class to be used.
  • property_name is the name of a property to be set in the transformation.

    For XSLT transformers, this is the name of the XSLT file to use.

  • property_type identifies the type of entry that is set by the property_name field.

    For an XSLT file name, this would be string.

  • property_value is the field that specifies the path to the XSLT file created for the event source.
  • description specifies the description for the XSLT file created for the event source.

Sample transformer file

The following is a sample transformer file with transformers for various event sources:
<?xml version="1.0" encoding="UTF-8" ?>   
- <tns:transformers 
    xmlns:tns="http://item.tivoli.ibm.com/omnibus/netcool/transformer"
    xmlns:xsd="http://www.w3.org/2001/XMLSchema">  

< !-- Southbound (probe) transformer definitions -->

< tns:transformer name="cbe2nvpairs" type="southbound" endpoint="cbe" 
   className="com.ibm.tivoli.netcool.integrations.transformer.XSLTTransformer">
        
< tns:property name="xsltFilename" type="java.lang.String" value="${OMNIHOME}/java
  /conf/cbe2nvpairs.xsl" description="XSLT file for converting CBE events to
  name/value pairs"/>

< /tns:transformer>

< tns:transformer name="wef2nvpairs" type="southbound" endpoint="wef" 
    className="com.ibm.tivoli.netcool.integrations.transformer.XSLTTransformer">

< tns:property name="xsltFilename" type="java.lang.String" value="${OMNIHOME}/
    java/conf/wef2nvpairs.xsl" description="XSLT file for converting WEF events
    to name/value pairs"/>

< /tns:transformer>

< tns:transformer name="netcool2nvpairs" type="southbound" endpoint="netcool" 
   className="com.ibm.tivoli.netcool.integrations.transformer.XSLTTransformer">

< tns:property name="xsltFilename" type="java.lang.String" value="${OMNIHOME}/
    java/conf/netcool2nvpairs.xsl" description="XSLT file for converting Netcool
    events to name/value pairs"/>

< /tns:transformer>

< !-- Northbound (gateway) transformer definitions -->

< tns:transformer name="netcool2wef" type="northbound" endpoint="wef" 
    className="com.ibm.tivoli.netcool.integrations.transformer.XSLTTransformer">

< tns:property name="xsltFilename" type="java.lang.String" value="${OMNIHOME}/
    java/conf/netcool2wef.xsl" description="XSLT file for converting Netcool 
    events to WEF events"/>

< /tns:transformer>

< tns:transformer name="netcool2cbe" type="northbound"  endpoint="cbe" 
    className="com.ibm.tivoli.netcool.integrations.transformer.XSLTTransformer">

< tns:property name="xsltFilename" type="java.lang.String" value="${OMNIHOME}/
    java/conf/netcool2cbe.xsl" description="XSLT file for converting Netcool 
    events to CBE events"/>

< /tns:transformer>

< tns:transformer name="netcoolEvents" type="northbound" endpoint="netcool" 
    className="com.ibm.tivoli.netcool.integrations.transformer.
    EmptyTransformer">

< /tns:transformer>

< /tns:transformers>
You can prevent events from an event source being transformed by specifying an empty transformer for that event source. The following example shows the entry for an event source with empty transformer details:
<tns:transformer name="empty" id="empty" className="com.micromuse.common.
     transformer.EmptyTransformer"/> 
  </tns:transformers>