Creating deployment descriptor files
The JMon application’s JAR file must contain a deployment descriptor file. Inside the correlator, the JVM processes the application’s deployment descriptor file and uses it as a guide to the event types and monitor classes to load. The name of the deployment descriptor file must be jmon-jar.xml.
When you use Apama Studio Java support to develop your JMon application, Apama Studio generates the deployment descriptor file for you. If you develop your JMon application outside Apama Studio, there are two ways to create a deployment descriptor file:
Insert Java annotations in your source files and run a utility to generate the deployment descriptor file. The annotations you can insert are defined in the
java.apama.jmon.annotation package.
Of course, you can use the utility to generate the deployment descriptor file and then manually edit the result. If you then run the utility again, you would lose any manual changes you had made.
The technique you use is largely a matter of personal preference — hand-coded or machine-generated. If you have a very large application with many event types and monitors, you might prefer to insert the annotations and generate the deployment descriptor file. If you have a small application, you might find it easier to write the deployment descriptor file.