Deal with "terminating connection due to idle-in-transaction timeout" error.
authorTatsuo Ishii <ishii@sraoss.co.jp>
Thu, 6 Dec 2018 08:20:32 +0000 (17:20 +0900)
committerTatsuo Ishii <ishii@sraoss.co.jp>
Thu, 6 Dec 2018 08:24:40 +0000 (17:24 +0900)
commit5517e44a570855bfa02b50040313c65dcbd6eb1e
tree007878b3f55cadf61dddb201f938daf8ed7fedd1
parent4b21d36a8c9213362df4e27a31bb3177a21ff583
Deal with "terminating connection due to idle-in-transaction timeout" error.

If idle_in_transaction_session_timeout parameter is set to reasonably
short in postgresql.conf, the fatal error easily occurs and the
connection from Pgpool-II to backend is terminated. This leads to
Pgpool-II either hang (if only one of PostgreSQL equips equips the
parameter) or unwanted failover (if all PostgreSQL equips with the
parameter), and both are not good. So intercept the message and send
the same message to frontend then exit to terminate the connection to
frontend. This is similar treatment as the error "connection was
terminated due to conflict with recovery, User was holding a relation
lock for too long."

Per bug 448.
src/include/protocol/pool_proto_modules.h
src/protocol/pool_process_query.c