WebSphere Business Monitor, Version 6.2.0
Operating Systems: AIX, HP-UX, Linux, Solaris, Windows
WebSphere Business Monitor provides an API to emit events to WebSphere Business Monitor that is implemented using Representational State Transfer (REST) Services. You can use the API to send XSD style events. The XSD type is a generic XML Schema Definition. The business information defined by the XSD definition is received by the API and placed in the xs:any slot of a Common Base Event and forwarded to WebSphere Busniess Monitor. The event part definitions that you create in a monitor model to process these events must always start with cbe:CommonBaseEvent and navigate into content that is placed in the xs:any slot of the Common Base Event. For a direct link to all resources and methods, see the quick summary.
The event emitter service API is a public API that you can use to send events that can be consumed by Monitor. You have to define the XSD that describes the structure of the business information and the API handles generating the event and forwarding it to Monitor. The REST implementation allows for easy to use HTTP services that are language- and platform-independent, stateless, scalable, and easily parsed. The service can be invoked by any HTTP client application, and define an expected response in the form of a JavaScript Object Notation (JSON) object. The JSON format can be easily parsed and consumed by JavaScript and other products, tools, and languages, which allows you greater flexibility in leveraging WebSphere Business Monitor in your own environment.
The service takes a HTTP POST URI as input. Results are returned in JSON and any error messages and status indicators are returned in the HTTP response as JSON output.
The format of the event emitter service URI is as follows:
http://{host}:{port}/rest/bpm/events
where:
The event emitter service EAR file (EmitterRestServices.ear) is configured as follows when it is deployed for a stand alone installation
where:
You can look up the JNDI name "monitor/emitter/defaultURL" in your emitter application to invoke the emitter service instead of specifying the URL in the emitter application code.
You can deploy multiple copies of the service. The EmitterRestServices.ear is available in the was_root/installableApps.wbm directory. You can deploy multiple copies of the ear file if you you wish to use more than one emitter. When you deploy multiple copies you must provide a unique Application name, a unique context root, and modify the resource reference to contain the jndi name of configured emitter that you wish to use.
For example you can deploy a second ear file that is configured to use the CEI default emitter. You can change the following during deployment
You can deploy another ear file that is configured to use an asynchronous emitter. You can change the following during deployment
In an ND environment, if the EmitterRestServices.ear is installed on a different server/cluster than the CEI Emitter factory, you must set the RESTEmitterFactory resource entry to point to the correct location of the emitter factory.
In a secure ND environment, after deploying the EmitterRestServices.ear , you must assign the appropriate security role mapping.
The data sent or returned by the HTTP methods listed above has one of the following content types ([RFC 2045][RFC 2046]):
When a client sends an HTTP request with payload, the HTTP content-type header should be set to describe the payload format. If no content type is set, the default content type is not set by the Business Monitor server. , but by the browser if the client is a browser or dashboard. If using a Java Therefore, clients must be explicit and set either text/xml or application/atom+xml, depending on whether clients are sending a single payload directly in the HTTP request body or multiple event payloads.
To access the URI, use the following Web address from the emitter applicaton: http://monitor_server:monitor_server_port/rest/bpm/events or you can also use the configured URL to access the Web Address as explained below.
Where:
monitor_server is the host name of the Business Monitor server
monitor_server_port is the port where the REST servlet is running
REST_URI is the actual URI of the REST service
Monitor also configures a URL with a jndi name of monitor/emitter/default for a standalone installation which specifies the default address: http://monitor_server:monitor_server_port/rest/bpm/events when Monitor security is not enabled and https://monitor_server:monitor_server_port/rest/bpm/events when Monitor security is enabled.
You can look up the URL jndi in your emitter application to access the address where the emitter servie is available. This method of looking up the Web address of the service will shield the emitter application from any changes in the Web Address. You can add URL definitions as you deploy more copies of the event service.
For errors recognized during processing of a WBM REST request, an appropriate HTTP status code ([RFC 2616]) is returned to the calling client (e.g., 200 OK or 404 Not Found, see the individual operations for details). Additional error information is provided depending on the error type. For WBM exceptions, the corresponding WBM error number and error message is returned. For severe errors (HTTP status code 500 Internal Server Error), additional programmer’s details are returned. They can be propagated to IBM service personnel if required.
The following specifications provide additional helpful information: