Revert "feat: turn off prepared statements" (#2448)
This commit is contained in:
@@ -1,6 +1,5 @@
|
||||
import os
|
||||
import threading
|
||||
import uuid
|
||||
from contextlib import asynccontextmanager, contextmanager
|
||||
from typing import Any, AsyncGenerator, Generator
|
||||
|
||||
@@ -166,15 +165,6 @@ class DatabaseRegistry:
|
||||
if not is_async:
|
||||
base_args["pool_use_lifo"] = settings.pool_use_lifo
|
||||
|
||||
elif is_async:
|
||||
base_args.update(
|
||||
{
|
||||
"prepared_statement_name_func": lambda: f"__asyncpg_{uuid.uuid4()}__",
|
||||
"statement_cache_size": 0,
|
||||
"prepared_statement_cache_size": 0,
|
||||
}
|
||||
)
|
||||
|
||||
return base_args
|
||||
|
||||
def _wrap_sqlite_engine(self, engine: Engine) -> None:
|
||||
|
||||
Reference in New Issue
Block a user