[pgpool-committers: 3896] pgpool: Fix problem described in [pgpool-hackers: 2125].

Tatsuo Ishii ishii at postgresql.org
Wed Mar 29 13:22:12 JST 2017

Fix problem described in [pgpool-hackers: 2125].

Two problems are fixed:

- The writing_transaction flag is not reset at transaction
  committed/aborted. Before it was done in CommandComplete but now it
  is possible that we need to check the flag before a command complete
  message arrives. So at Execute, it is taken care by
  handle_query_context() which used to be a static function in
  CommandComplete.c. Also the session context memory is always cleared
  before start a session context.

- Ready for query Re-sync code path in read_kind_from_backend did not
  work. The pending message corresponding to the ready for query
  message could be a sync message, which does not have query
  context. But before we checked if there's a query context
  exists. The check is bogus and removed.



Modified Files
src/context/pool_session_context.c        | 3 +++
src/include/protocol/pool_proto_modules.h | 2 ++
src/protocol/CommandComplete.c            | 3 +--
src/protocol/pool_process_query.c         | 4 ++--
src/protocol/pool_proto_modules.c         | 5 ++++-
5 files changed, 12 insertions(+), 5 deletions(-)

More information about the pgpool-committers mailing list