From 487e49c1c1e5289f349fcd228e77e87da2d19787 Mon Sep 17 00:00:00 2001 From: Windpicker-owo <3431391539@qq.com> Date: Tue, 9 Dec 2025 22:03:52 +0800 Subject: [PATCH] =?UTF-8?q?refactor(engine):=20=E7=A7=BB=E9=99=A4SQLite?= =?UTF-8?q?=E5=92=8CPostgreSQL=E9=85=8D=E7=BD=AE=E4=B8=AD=E7=9A=84?= =?UTF-8?q?=E6=9F=A5=E8=AF=A2=E7=BC=93=E5=AD=98=E7=A6=81=E7=94=A8=E8=AE=BE?= =?UTF-8?q?=E7=BD=AE=E4=BB=A5=E4=BC=98=E5=8C=96=E6=80=A7=E8=83=BD?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/common/database/core/engine.py | 5 ----- 1 file changed, 5 deletions(-) diff --git a/src/common/database/core/engine.py b/src/common/database/core/engine.py index d9c7a02a6..0b1f724d4 100644 --- a/src/common/database/core/engine.py +++ b/src/common/database/core/engine.py @@ -114,9 +114,6 @@ def _build_sqlite_config(config) -> tuple[str, dict]: "check_same_thread": False, "timeout": 60, }, - # ⚠️ 禁用 SQLAlchemy 查询编译缓存以阻断可能的 tuple 膨胀 - # 观察到长时间运行后 tuple 数量飙升,先通过关闭缓存止血 - "query_cache_size": 0, } logger.debug(f"SQLite配置: {db_path}") @@ -165,8 +162,6 @@ def _build_postgresql_config(config) -> tuple[str, dict]: "pool_timeout": config.connection_timeout, "pool_recycle": 3600, "pool_pre_ping": True, - # ⚠️ 禁用 SQLAlchemy 查询编译缓存以阻断可能的 tuple 膨胀 - "query_cache_size": 0, } if connect_args: