Data queues on IBM i servers are *DTAQ type objects. You can use this kind of object for communicating different jobs on the same system or for communicating between jobs on different systems. This point is important because you do not need to build interfaces for transferring information from one system to another. A data queue is a powerful program-to-program interface.
You find this type of object only on IBM i servers. If you must communicate between IBM i and other platforms, you must use IBM WebSphere MQ.
The data queues objects have the following characteristics:
- The data queue allows for fast communication between jobs. Therefore, it is an excellent
way to synchronize and pass data between jobs. - Many jobs can simultaneously access the data queues.
- Messages on a data queue are in free format. Fields are not required as they are in database files.
- The data queue can be used for either synchronous or asynchronous processing.
- The messages on a data queue can be ordered in one the following ways:
- – Last-in first-out (LIFO): The last (newest) message that is placed on the data queue is the first message that is taken off the queue.
- – First-in first-out (FIFO): The first (oldest) message that is placed on the data queue is the first message that is taken off the queue.
- – Keyed. Each message on the data queue has a key that is associated with it. A message can be taken off the queue only by specifying the key that is associated with it.
- The operational system has all the commands for accessing to data queues; for other programming languages, there are many forms for accessing this resource.
The data queue classes support the following data queues:
- Sequential data queues: Entries on a sequential data queue on the server are removed in FIFO or LIFO sequence.
- Keyed data queues: Entries on a keyed data queue are removed according to key value.