Jolokia 2.0 - JMX Notifications
This screencast gives a live demo of the forthcoming JMX notification support in Jolokia 2.0.
Jolokia supports currently two notification modes. In all modes, the Jolokia agent itself subscribe to a JMX notification locally and then dispatches the notifications to its clients.
- Pull Mode : Here, the agent keeps the notification received for a client in memory and sends it back on an JMX request to a Jolokia specific MBean. A client typically queries this notification MBean periodically.
- SSE Mode : Server Sent Events are a W3C standard for pushing events from an HTTP server to a client. With this mode the Jolokia agents directly pushes any notification it receives to the client. The advantage is of course a much lower latency compared to the pull mode, but SSE is not available for Internet Explorer, including 11. What a pity.
The Jolokia protocol has been extended with the top level action
notification and subcommands.
unregister: Register / unregister a notification client
remove: Add / remove a listener subscription
list: list all subscriptions for a client
ping: Keep subscription alive
open: Use for creating a back channel. E.g. the SSE mode keeps this GET request for pushing back an event stream.