39 lines
1.1 KiB
Python
39 lines
1.1 KiB
Python
"""In-memory хранилище сессий с TTL и лимитами.
|
|
|
|
Каждая операция — в отдельном файле, общее состояние — в state.py.
|
|
Импорт как единый пакет:
|
|
|
|
from upload.backend.session import create_session, add_file, get_files
|
|
"""
|
|
|
|
from .create_session import create_session
|
|
from .add_file import add_file
|
|
from .get_files import get_files, file_count
|
|
from .store_result import store_result, get_result
|
|
from .store_csv import store_csv, get_csv
|
|
from .ttl import touch, pause_ttl, resume_ttl
|
|
from .cancel import request_cancel, get_cancel_event
|
|
from .cleanup import cleanup
|
|
from .state import TTL_SECONDS, MAX_FILE_BYTES, MAX_SESSION_BYTES, configure
|
|
|
|
__all__ = [
|
|
"create_session",
|
|
"add_file",
|
|
"get_files",
|
|
"file_count",
|
|
"store_result",
|
|
"get_result",
|
|
"store_csv",
|
|
"get_csv",
|
|
"touch",
|
|
"pause_ttl",
|
|
"resume_ttl",
|
|
"request_cancel",
|
|
"get_cancel_event",
|
|
"cleanup",
|
|
"configure",
|
|
"TTL_SECONDS",
|
|
"MAX_FILE_BYTES",
|
|
"MAX_SESSION_BYTES",
|
|
]
|