Exporting sample packets and schemas
You can export sample packets and schemas of events and actions for testing purposes or to provide IBM® components (such as Business Monitor) with the information required for integration with Decision Server Events.
About this task
Event data payloads sent to the event runtime and action data payloads sent from the event runtime are called packets. You can find example packets and schemas in the output (bin) folder of your event project, which are called generated resources in Event Explorer. The example packets and schemas are automatically built as you change them, so they are always up to date.
Actions
- The example packets and schemas files are located in:
- Output folder of your event project: <project name>/bin/packets/actions/
- Generated resources in Event Explorer: <project name>/generated resources/packets/actions/
- There is an example packet XML file named for each action. The example for each action is in either 2.2 or 6.2 packet format, depending on which format is configured for the action. If the action is configured to produce Common Base Event format, there is an _CBE.XML file containing an example common base event.
- If the action is configured to produce Common Base Event format,
there is an _CBE.XSD file containing the action schema for the common
base event payload (not for the whole common base event). Important: The target namespace for the schema must contain the event runtime host name. You might have to edit the schema to change the targetNamespace= attribute at the top of the schema.If the action is not configured to produce Common Base Event format, there is an .XSD file containing the schema for the action packet in either 2.2 or 6.2 packet format, depending on which format is configured for the action.
Events
- The example packets and schemas files are located in:
- Output folder of your event project: <project name>/bin/packets/events/
- Generated resources in Event Explorer: <project name>/generated resources/packets/events/
- There are example packets and schemas named for each event in the three subfolders (v2.2, v6.2, and CBE).
- If the event is configured to produce Common Base Event format,
the .XSD file in the Common Base Event subfolder contains the event
schema for the common base event payload (not for the whole common
base event).Important: The target namespace for the schema must contain the event runtime host name. You might have to edit the schema to change the targetNamespace= attribute at the top of the schema.In addition, the .cbe file contains an event definition file that you can use to configure Business Monitor to send events to the event runtime.
- The event runtime accepts event packets in either 2.2 or 6.2 format. You can find example packets and schemas for these formats in the v2.2 and v6.2 subfolders.
Exporting sample packets and schema definitions
Before you begin
Procedure
Example exports
The following example shows an Decision Server Events packet from an action:
<connector xmlns="http://wbe.ibm.com/6.2/Action/Deny-Authorization" name="Transaction Server" version="6.2">
<connector-bundle id="AE6740B6_4231_4DCF_9EB1_8EC207B9E021" name="Deny Authorization" type="Action">
<Transaction-Processing-Instruction>
<transaction_id type="String">String_transaction_id_55</transaction_id>
<transaction_processing_instruction type="String">DENY</transaction_processing_instruction>
</Transaction-Processing-Instruction>
<Transaction-Processing-Instruction>
<transaction_id type="String">String_transaction_id_16</transaction_id>
<transaction_processing_instruction type="String">DENY</transaction_processing_instruction>
</Transaction-Processing-Instruction>
</connector-bundle>
<system>AdvESB.pot.com</system>
<timestamp>2008-11-20T15:53:11Z</timestamp>
<loginfo>Test values</loginfo>
</connector>
The following example shows an Decision Server Events packet schema from an action:
<schema xmlns="http://www.w3.org/2001/XMLSchema" targetNamespace="http://wbe.ibm.com/6.2/Action/Deny-Authorization" xmlns:tns="http://wbe.ibm.com/6.2/Action/Deny-Authorization">
<annotation>
<documentation>Changes might be lost. Autogenerated (20090916_1759) .</documentation>
</annotation>
<element name="connector">
<complexType>
<sequence>
<element name="connector-bundle">
<complexType>
<sequence>
<element maxOccurs="unbounded" minOccurs="0" name="Transaction-Processing-Instruction">
<complexType>
<sequence>
<element maxOccurs="1" minOccurs="0" name="transaction_id">
<complexType>
<simpleContent>
<extension base="string">
<attribute fixed="String" name="type" type="string" use="optional"/>
</extension>
</simpleContent>
</complexType>
</element>
<element maxOccurs="1" minOccurs="0" name="transaction_processing_instruction">
<complexType>
<simpleContent>
<extension base="string">
<attribute fixed="String" name="type" type="string" use="optional"/>
</extension>
</simpleContent>
</complexType>
</element>
</sequence>
</complexType>
</element>
</sequence>
<attribute fixed="Deny Authorization" name="name" type="string" use="required"/>
<attribute fixed="Action" name="type" type="string" use="required"/>
<attribute name="id" type="string" use="optional"/>
<attribute name="stream" type="string" use="optional"/>
<attribute name="workflow" type="string" use="optional"/>
</complexType>
</element>
<element minOccurs="0" name="system" type="string"/>
<element minOccurs="0" name="timestamp" type="dateTime"/>
<element minOccurs="0" name="loginfo" type="string"/>
</sequence>
<attribute name="name" type="string" use="optional"/>
<attribute name="folder" type="string" use="optional"/>
<attribute fixed="6.2" name="version" type="string" use="required"/>
</complexType>
</element>
</schema>