castlecraft_engineer.abstractions.event_consumer
¶
castlecraft_engineer.abstractions.event_consumer
¶
EventStreamConsumer
¶
Bases: ABC
Abstract base class for consuming events from an external stream and publishing them to an internal EventBus.
Source code in src/castlecraft_engineer/abstractions/event_consumer.py
run()
abstractmethod
async
¶
Starts the consumer loop to listen for and process events. This method should typically run indefinitely until shutdown is requested.
shutdown()
abstractmethod
async
¶
Initiates a graceful shutdown of the consumer. Implementations should ensure pending work is handled and resources are released.