Skip to content

Commit 44cc44f

Browse files
committed
Updated readme.
1 parent ec75232 commit 44cc44f

File tree

1 file changed

+5
-5
lines changed

1 file changed

+5
-5
lines changed

README.md

+5-5
Original file line numberDiff line numberDiff line change
@@ -21,17 +21,17 @@ Let's see the example with the redis broker and redis async result:
2121
# broker.py
2222
import asyncio
2323

24-
from taskiq_redis import ListQueueBroker, RedisAsyncResultBackend
24+
from taskiq_redis import RedisAsyncResultBackend, RedisStreamBroker
2525

26-
redis_async_result = RedisAsyncResultBackend(
26+
result_backend = RedisAsyncResultBackend(
2727
redis_url="redis://localhost:6379",
2828
)
2929

3030
# Or you can use PubSubBroker if you need broadcasting
31-
broker = ListQueueBroker(
31+
# Or ListQueueBroker if you don't want acknowledges
32+
broker = RedisStreamBroker(
3233
url="redis://localhost:6379",
33-
result_backend=redis_async_result,
34-
)
34+
).with_result_backend(result_backend)
3535

3636

3737
@broker.task

0 commit comments

Comments
 (0)