12 lines
322 B
Python
12 lines
322 B
Python
from taskiq import TaskiqScheduler
|
|
from taskiq.schedule_sources import LabelScheduleSource
|
|
from taskiq_aio_pika import AioPikaBroker
|
|
|
|
import backend.config
|
|
|
|
taskiq_broker = AioPikaBroker(backend.config.RABBITMQ_URL)
|
|
scheduler = TaskiqScheduler(
|
|
broker=taskiq_broker,
|
|
sources=[LabelScheduleSource(taskiq_broker)]
|
|
)
|