Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions src/memos/graph_dbs/polardb.py
Original file line number Diff line number Diff line change
Expand Up @@ -173,7 +173,7 @@ def __init__(self, config: PolarDBGraphDBConfig):
user=user,
password=password,
dbname=self.db_name,
connect_timeout=60, # Connection timeout in seconds
connect_timeout=10, # Connection timeout in seconds
keepalives_idle=120, # Seconds of inactivity before sending keepalive (should be < server idle timeout)
keepalives_interval=15, # Seconds between keepalive retries
keepalives_count=5, # Number of keepalive retries before considering connection dead
Expand Down Expand Up @@ -247,7 +247,7 @@ def _warm_up_connections_by_all(self):

@contextmanager
def _get_connection(self):
timeout = getattr(self, "_connection_wait_timeout", 5)
timeout = self._connection_wait_timeout
if timeout <= 0:
self._semaphore.acquire()
else:
Expand Down Expand Up @@ -1919,7 +1919,7 @@ def search_by_embedding(
else:
pass

logger.info(" search_by_embedding query: %s user_name: %s", query, user_name)
logger.info(" search_by_embedding query: %s", query)

with self._get_connection() as conn, conn.cursor() as cursor:
if params:
Expand Down