pythonnats.ionats-jetstream

Can NATS keep messages in memory if no workers are online at the moment (producer-consumers pattern)?


I would like to use NATS to distribute tasks among several worker-processes. Everything works as expected if I have at least one worker "online", but if there are no worker-processes, messages are just thrown away, when I turn on one worker I got no messages (which were created when it was not online).

I know how to do it with RabbitMQ, but is it possible to do it with NATS?

I do project in Python, producer-process in aiohttp, worker-processes are also in Python and do some CPU-heavy tasks.


Solution

  • By this day official Python connector does not support NATS/Jetsream issue-209