Skip to main content

Jolokia 2.0 - JMX Notifications

·276 words·2 mins

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.

  • register / unregister : Register / unregister a notification client
  • add / 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.

Currently only the new Jolokia JavaScript client supports JMX notification. If you are interested in having it in other clients (e.g. Java), too, please let me know. I would be more than happy for coders jumping on the Jolokia bandwagon since there is still quite some stuff to do for 2.0.

The source code to this demo and the new Jolokia JavaScript client is on GitHub: https://github.com/jolokia-org/jolokia-client-javascript.

Related

Welcome to 2016 - the year Jolokia 2.0 will see the light of day

·830 words·4 mins
I hope you all had a good start into 2016 and have charged all your batteries during the time of stillness. Jolokia had a good start, too. During the holiday season I took the opportunity to continue to work on version 2.0 which now takes on form. If you have followed the history of Jolokia you know that work on 2.0 started early 2013 but advanced quite slowly for multiple reasons. Now its time to go out on a limb with announcing Jolokia 2.0 for 2016. A bit of pressure sometimes really helps ;-)

Jmx4Perl for everyone

·482 words·3 mins
As you might know, Jmx4Perl is the mother of Jolokia. But what might be not so known is, that Jmx4Perl provides a set of nice CLI tools for accessing Jolokia agents. However, installing Jmx4Perl manually is cumbersome because of its many Perl and also native dependencies. However, if you are a Docker user there is now a super easy way to benefit from this gems.

Jmx4Perl on OS X

·347 words·2 mins
The HTTP-JMX Bridge Jolokia allows easy access to JMX. It exposes all JMX information and operations via an REST-like interface and has tons of nifty features. Jmx4Perl on the other side is a client for Jolokia, which beside Perl access modules also provides quite some nice CLI tools for accessing and installing Jolokia. This post explains how install these tools on OS X.