Apama Documentation : Developing Apama Applications : Developing Apama Applications in Java : Developing and Deploying JMon Applications : Creating deployment descriptor files : Defining event types in deployment descriptor files
Defining event types in deployment descriptor files
The deployment descriptor file must define an event element for each event type class in your JMon application's JAR file. Each event element must contain the following two elements:
*event-name — The name by which this event type is to be defined within the correlator. The correlator has a single namespace. Consequently, this name must be unique across all applications. For example, Tick or SimpleApp.Tick. If you specify a package qualified name, it is the qualified name that must be unique.
*event-class — The name of the Java class in which this event type is defined. This must correspond to the fully qualified name of the class, for example, Tick if the event type class is defined within the default Java package, or com.apama.example.types.Tick if the event type class is defined in the com.apama.example.types package. The file, for example, Tick.java, is expected to be located within a folder structure that maps to the packaging, as per standard Java convention.
The event element can optionally contain a third element. This is the description element. Specify a description of the event type. For example:
<event>
   <event-name>Tick</event-name>
   <event-class>Tick</event-class>
   <description>Event that signals a stock trade</description>
</event>
JMon and EPL share a single namespace for event types. After an event type is loaded into the correlator, using either JMon or EPL, it is available for use in either environment. However, within a JMon application, you cannot instantiate variables of an event type defined in EPL.
When you try to inject an event type definition that has the same name as a loaded event type, the correlator checks whether the two definitions are duplicates. If they are, the correlator ignores the duplicate you are trying to load. If the definitions are different, the correlator generates an injection error.
Copyright © 2013-2016 Software AG, Darmstadt, Germany.

Product LogoContact Support   |   Community   |   Feedback