My application requires events to be fired based on some specific activities that happen. I’m trying to determine if I should create my own event handling system using the Java EventObject with custom listeners similar to Java AWT Or should I use a JMS implementation? I was considering either apache’s Qpid or ActiveMQ solution. I’m exploring these options at the moment and was wondering if anyone has experience with Qpid or ActiveMQ and can offer some advise (e.g., pros, cons to consider, etc) Also, if anyone has any suggestions for building a simple event handling system… if it’s even worth while to consider this over a JMS based solution.
My application requires events to be fired based on some specific activities that happen.
Share
Simple event listeners (as used in Java AWT) require that events are handled immediately, within the same virtual machine, and typically within the same thread.
JMS (for instance using ActiveMQ) allows events to be handled at a later time (optionally buffering messages in persistent storage), and in other virtual machines / threads. That flexibility comes at the price of additional complexity and lower efficiency.