|
|
@@ -21,7 +21,9 @@ class SemaphoreConnectionPool:
|
|
|
logger.info(
|
|
|
f"Connecting with {int(self.postgres_configuration_settings.max_connections * 0.9)} connections to `asyncpg.create_pool`."
|
|
|
)
|
|
|
-
|
|
|
+ logger.info(
|
|
|
+ f"{self.connection_string}"
|
|
|
+ )
|
|
|
self.semaphore = asyncio.Semaphore(
|
|
|
int(self.postgres_configuration_settings.max_connections * 0.9)
|
|
|
)
|
|
|
@@ -32,7 +34,7 @@ class SemaphoreConnectionPool:
|
|
|
max_size=self.postgres_configuration_settings.max_connections,
|
|
|
statement_cache_size=self.postgres_configuration_settings.statement_cache_size,
|
|
|
timeout=0, # 获取连接超时 60 秒
|
|
|
- command_timeout=None, # 单个查询超时 30 秒(可选)
|
|
|
+ command_timeout=120, # 单个查询超时 30 秒(可选)
|
|
|
)
|
|
|
|
|
|
logger.info(
|