Singletons
thoth.ingestion.singletons
¶
Singleton management for ingestion worker services.
This module provides singleton instances for shared services to avoid circular imports between worker.py and flows modules.
get_source_registry() -> SourceRegistry
¶
Return the global SourceRegistry singleton (creates on first call).
Returns:
| Type | Description |
|---|---|
SourceRegistry
|
SourceRegistry instance. |
get_job_manager() -> JobManager
¶
Return the global JobManager singleton (creates on first call).
Returns:
| Type | Description |
|---|---|
JobManager
|
JobManager instance. |
get_task_queue() -> TaskQueueClient
¶
Return the global TaskQueueClient singleton (creates on first call).
Returns:
| Type | Description |
|---|---|
TaskQueueClient
|
TaskQueueClient instance (reads queue config from env). |