Download the PHP package rabbitevents/redis-transport without Composer
On this page you can find all versions of the php package rabbitevents/redis-transport. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Table of contents
Download rabbitevents/redis-transport
More information about rabbitevents/redis-transport
Files in rabbitevents/redis-transport
Download rabbitevents/redis-transport
More information about rabbitevents/redis-transport
Files in rabbitevents/redis-transport
Vendor rabbitevents
Package redis-transport
Short Description Redis Streams transport for RabbitEvents
License MIT
Package redis-transport
Short Description Redis Streams transport for RabbitEvents
License MIT
Please rate this library. Is it a good library?
Informations about the package redis-transport
RabbitEvents Redis Streams Transport
Redis Streams transport driver for RabbitEvents.
This package enables RabbitEvents to publish events to and consume events from Redis Streams, providing durable event streaming, consumer groups, acknowledgement (XACK), and retry handling.
Requirements
- PHP >= 8.4
ext-redis(recommended) or compatible clientrabbitevents/foundation^10.0
Installation
Configuration
Add the redis connection to your config/rabbitevents.php:
Configuration Options
| Option | Type | Default | Description |
|---|---|---|---|
driver |
string |
redis |
The connection driver. |
host |
string |
127.0.0.1 |
Redis server hostname or IP. |
port |
int |
6379 |
Redis server port. |
password |
string\|null |
null |
Authentication password (if configured). |
database |
int |
0 |
Redis logical database index (0-15). Default is 0. |
timeout |
float |
3.0 |
Connection timeout in seconds. |
stream |
string |
events |
The Redis Stream key name used as the event topic. |
consumer |
string |
hostname |
Unique consumer identifier within the consumer group. |
Usage
Publishing Events
Publishing events remains identical to standard RabbitEvents:
Listening to Events
Run the RabbitEvents worker with the Redis connection:
Or specify events directly:
Architecture & Guarantees
- Topic: a Redis Stream (
eventsby default, config keystream) that publishers append every event to. - Queue: a consumer group (
XGROUP) on the topic stream, plus the queue's own direct streamrabbitevents:queue:{queue}with a group of the same name. A worker reads both with oneXREADGROUP. - Messages for one queue (retries released by a listener, messages put back with
requeue,rabbitevents:retry) are appended to that queue's direct stream, so other consumer groups on the topic don't receive them. - Requeue: a stream entry can't be returned, so
reject($message, requeue: true)andrequeue($messages)append a copy to the direct stream and acknowledge the original. Order is kept. - Acknowledgement:
XACKin the stream the entry was read from. - Wildcards: AMQP-style patterns (
user.*,order.#); entries of other events are acknowledged and skipped.
Reliability & Failed Messages
- Failed messages: RabbitEvents 10.x moves a message that failed all its tries to
{queue}.failed. With this transport it is a queue fed only through its direct stream (rabbitevents:queue:{queue}.failed);rabbitevents:failed,retry,forgetandflushwork as with RabbitMQ. - No delayed retries: Redis Streams can't delay a delivery, so a released message is retried right away regardless of
--sleep. - Message ID & Context Propagation: RFC 4122 v4 UUID message IDs and Laravel
Contextpropagation work as with RabbitMQ. - Deduplication: transport-independent; see the optional
rabbitevents/deduplicationpackage.
License
The MIT License (MIT). Please see License File for more information.
All versions of redis-transport with dependencies
PHP Build Version
Package Version
Requires
php Version
^8.4
ext-json Version *
rabbitevents/foundation Version ^10.0
illuminate/support Version ^11.0|^12.0|^13.0
illuminate/container Version ^11.0|^12.0|^13.0
ext-json Version *
rabbitevents/foundation Version ^10.0
illuminate/support Version ^11.0|^12.0|^13.0
illuminate/container Version ^11.0|^12.0|^13.0
The package rabbitevents/redis-transport contains the following files
Loading the files please wait ...