feat: backend orkestrasyonunu ve arac entegrasyonlarini genislet
This commit is contained in:
@@ -1,14 +1,18 @@
|
||||
from contextlib import suppress
|
||||
|
||||
from app.automation.scheduler import AutomationScheduler
|
||||
from app.telegram.bot import TelegramBotService
|
||||
|
||||
|
||||
class RuntimeServices:
|
||||
def __init__(self) -> None:
|
||||
self.telegram_bot: TelegramBotService | None = None
|
||||
self.automation_scheduler: AutomationScheduler | None = None
|
||||
|
||||
async def shutdown(self) -> None:
|
||||
if self.automation_scheduler is not None:
|
||||
with suppress(Exception):
|
||||
await self.automation_scheduler.stop()
|
||||
if self.telegram_bot is not None:
|
||||
with suppress(Exception):
|
||||
await self.telegram_bot.stop()
|
||||
|
||||
|
||||
Reference in New Issue
Block a user