Integration Server 11.1 | Integration Server Administrator's Guide | Configuring Integration Server for Streaming | Event Specifications
 
Event Specifications
 
Creating Event Specification
An event specification describes the events that Integration Server sends and receives. The event specification defines the structure of the event, identifies the topic to which events are published, and indicates how to encode and decode the event data. Event specifications allow the details of the event structure to be shared, improving collaboration among developers. For producers, the event specification captures what is being sent and where it is being sent. For consumers, the event specification captures what is being received and where it is being received from.
Each event specification is associated with a streaming connection alias that Integration Server uses to send or receive the event. As part of the input for sending an event, the pub.event:send service specifies the event specification which indicates not only what event the service sends, but also which connection will be used to send the event and the destination (topic) to which the event is sent. An event trigger, which is an event consumer, identifies the provider from which it receives events by selecting a streaming connection alias. The event trigger also specifies the topic from which it receives events and the structure of those events by selecting an event specification.
Each event sent to the streaming provider is made up of a key, a value, and a header. An event specification defines the types for the keys and values. The type identifies how Integration Server encodes and decodes the data provided in the event key and value. Key and value types are defined separately, allowing a key to be encoded/decoded differently than a value.
Integration Server sends events to the streaming provider as byte arrays. Event triggers receive events as byte arrays.
The structure of an event can be simple enough to be represented by a String or an Integer. Or the event structure can be more complex. If the event key type or value type is XML or JSON, you can use an IS document type, JSON document type, or an XML document type as the schema definition for the key type or value type, respectively. Integration Server uses the document type to direct the conversion of event data supplied as XML or JSON to and from IData. Integration Server validates the structure of the event against the document type, discarding invalid events with an error. If you do not identify a document type to direct data conversion, Integration Server performs generic format validation when converting the XML or JSON to IData. If the XML or JSON is not well-formed, contains syntax errors, or is empty, Integration Server considers the event to be invalid and discards it.
Note:
Unlike IS specifications, event specifications are not Integration Server namespace elements.