How signalbot processes messages
mainSignalbot operates using a producer-consumer model:
- Producer: A single process that monitors the linked account via a websocket connection for new messages.
- Consumers: Multiple workers that pick up tasks created by the producer. For every registered handler, the producer creates a task, and a consumer executes it.
Scaling: If your bot's handlers perform blocking operations, you should increase the number of consumers to ensure the bot remains reactive.
Storage Warning: If you do not provide a Redis instance or a SQLite database name in your Config, signalbot will use in-memory storage. This will cause all state to be lost upon restart. To use in-memory storage without warnings, add {'type': 'in-memory'} to your config.