Event Queues"

From Documentation
m ((via JWB))
Line 18: Line 18:
 
=Version History=
 
=Version History=
 
{{LastUpdated}}
 
{{LastUpdated}}
{| border='1px' | width="100%"
+
{| class='wikitable' | width="100%"
 
! Version !! Date !! Content
 
! Version !! Date !! Content
 
|-
 
|-

Revision as of 02:58, 12 January 2022

An event queue is an event-based publish-subscribe solution for the application information delivery and messaging. It provides asynchronous communication for different modules/roles in a loosely-coupled and autonomous fashion.

By publishing, a module (publisher) sends out messages without explicitly specifying or having knowledge of intended recipients. By subscribing, a receiving module (subscriber) receives messages that the subscriber has registered an interest in, without explicitly specifying or knowing the publisher. Eventqueue-concept.jpg

ZK generalizes the event queue to support the server push. The use is straightforward: specifying the scope of a given event queue as EventQueues.APPLICATION (or EventQueues.SESSION, but rare). For example,

EventQueue que = EventQueues.lookup("chat", EventQueues.APPLICATION, true);

For more information about event queues, please refer to the Event Handling: Event Queues section.

For the information about low-evel API, please refer to Asynchronous Tasks section, if the task can execute asynchronously; or Synchronous Tasks if it must execute synchronously.

Version History

Last Update : 2022/01/12


Version Date Content
5.0.6 November 2010 The event queue won't start any working threads and they are serializable, so it is safe to use them in a clustering environment.



Last Update : 2022/01/12

Copyright © Potix Corporation. This article is licensed under GNU Free Documentation License.