Download the PHP package byjg/redis-queue-client without Composer
On this page you can find all versions of the php package byjg/redis-queue-client. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Download byjg/redis-queue-client
More information about byjg/redis-queue-client
Files in byjg/redis-queue-client
Package redis-queue-client
Short Description A minimal redis queue client using the components of byjg/message-queue-client
License MIT
Informations about the package redis-queue-client
Redis Queue Client
It creates a simple abstraction layer to publish and consume messages from the Redis using the component byjg/message-queue-client.
For details on how to use the Message Queue Client see the documentation
Usage
Publish
Consume
The consume method will wait for a message and call the callback function to process the message. If there is no message in the queue, the method will wait until a message arrives.
If you want to exit the consume method, just return Message::ACK | Message::EXIT
from the callback function.
Possible return values from the callback function:
Message::ACK
- Acknowledge the message and remove from the queueMessage::NACK
- Not acknowledge the message and remove from the queue. If the queue has a dead letter queue, the message will be sent to the dead letter queue.Message::REQUEUE
- Requeue the messageMessage::EXIT
- Exit the consume method
Protocols:
Protocol | URI Example | Notes |
---|---|---|
Redis | redis://user:pass@host:port | Default port: 6379. |
Dependencies
All versions of redis-queue-client with dependencies
ext-curl Version *
ext-redis Version *
byjg/message-queue-client Version ^5.0