mirror of
https://github.com/langgenius/dify.git
synced 2026-10-04 13:47:55 +08:00
12 lines
350 B
Python
12 lines
350 B
Python
"""Infrastructure adapters for document-sync requests."""
|
|
|
|
from collections.abc import Callable
|
|
|
|
|
|
class CeleryDocumentSyncDispatcher:
|
|
def __init__(self, *, delay: Callable[[str, str], object]) -> None:
|
|
self._delay = delay
|
|
|
|
def dispatch(self, *, dataset_id: str, document_id: str) -> None:
|
|
self._delay(dataset_id, document_id)
|