舍弃flask。请求增加H2协议。

This commit is contained in:
2025-11-18 22:09:19 +08:00
parent 37f91c4b8c
commit e90dbf14e9
10 changed files with 170 additions and 130 deletions

View File

@@ -169,7 +169,7 @@ class DeviceInfo:
if getattr(self, "_add_executor", None) is None:
from concurrent.futures import ThreadPoolExecutor
import os
max_workers = max(2, min(6, (os.cpu_count() or 4) // 2))
max_workers = int(os.getenv("DEVICE_ADD_WORKERS", "6"))
self._add_executor = ThreadPoolExecutor(
max_workers=max_workers,
thread_name_prefix="dev-add"