# HG changeset patch # User Olaf Wintermann # Date 1664095907 -7200 # Node ID 144332e23ffdcad1995c1a3acb3d76dbdbbfed13 # Parent c6c5638e97b8170bad022fc7ad1127e90f455a48 reduce log warnings in case pg_check_connection fails diff -r c6c5638e97b8 -r 144332e23ffd src/server/plugins/postgresql/resource.c --- a/src/server/plugins/postgresql/resource.c Sun Sep 25 10:47:49 2022 +0200 +++ b/src/server/plugins/postgresql/resource.c Sun Sep 25 10:51:47 2022 +0200 @@ -51,9 +51,9 @@ // test connection PGconn *test_connection = PQconnectdb(connection); - if(pg_check_connection(LOG_WARN, rpname, test_connection)) { - log_ereport(LOG_WARN, "Resource pool %s: Connection check failed", rpname); - } + // pg_check_connections logs errors, so we don't really need to handle + // any error here + pg_check_connection(LOG_WARN, rpname, test_connection); if(test_connection) PQfinish(test_connection); PgResourcePool *pg = pool_malloc(pool, sizeof(PgResourcePool));