Event Queues"

From Documentation
m ((via JWB))
m
 
Line 14: Line 14:
 
For more information about event queues, please refer to the [[ZK Developer's Reference/Event Handling/Event Queues|Event Handling: Event Queues]] section.
 
For more information about event queues, please refer to the [[ZK Developer's Reference/Event Handling/Event Queues|Event Handling: Event Queues]] section.
  
For the information about low-evel API, please refer to [[ZK Developer's Reference/Server Push/Asynchronous Tasks|Asynchronous Tasks]] section, if the task can execute asynchronously; or [[ZK Developer's Reference/Server Push/Synchronous Tasks|Synchronous Tasks]] if it must execute synchronously.
+
For the information about low-level API, please refer to [[ZK Developer's Reference/Server Push/Asynchronous Tasks|Asynchronous Tasks]] section, if the task can execute asynchronously; or [[ZK Developer's Reference/Server Push/Synchronous Tasks|Synchronous Tasks]] if it must execute synchronously.
  
 
=Version History=
 
=Version History=

Latest revision as of 03:21, 1 February 2024

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-level API, please refer to Asynchronous Tasks section, if the task can execute asynchronously; or Synchronous Tasks if it must execute synchronously.

Version History

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 : 2024/02/01

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