From 4a103f5675acdfe4a594ea0ec15ed44f6d8d4c0d Mon Sep 17 00:00:00 2001 From: HibiKier <775757368@qq.com> Date: Wed, 31 Dec 2025 09:23:51 +0800 Subject: [PATCH] fix: update snapshot caching to store the entire snapshot object instead of its model dump --- zhenxun/services/auth_snapshot/service.py | 2 +- zhenxun/utils/http_utils.py | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/zhenxun/services/auth_snapshot/service.py b/zhenxun/services/auth_snapshot/service.py index fadaab0e..441e1852 100644 --- a/zhenxun/services/auth_snapshot/service.py +++ b/zhenxun/services/auth_snapshot/service.py @@ -425,7 +425,7 @@ class PluginSnapshotService: await CacheRoot.set( CacheType.PLUGIN_SNAPSHOT, cache_key, - snapshot.model_dump(), + snapshot, expire=PLUGIN_REDIS_TTL, ) except Exception: diff --git a/zhenxun/utils/http_utils.py b/zhenxun/utils/http_utils.py index f482cfa3..9cc837dc 100644 --- a/zhenxun/utils/http_utils.py +++ b/zhenxun/utils/http_utils.py @@ -64,7 +64,7 @@ async def _(): _client = get_async_client( headers=get_user_agent(), follow_redirects=True, - limits=httpx.Limits(max_connections=200, max_keepalive_connections=100), + limits=httpx.Limits(max_connections=500, max_keepalive_connections=200), timeout=httpx.Timeout(10), **client_kwargs, )