Don't ignore sync message from frontend when query cache is enabled.
authorTatsuo Ishii <ishii@postgresql.org>
Mon, 5 Sep 2016 23:08:32 +0000 (08:08 +0900)
committerTatsuo Ishii <ishii@postgresql.org>
Mon, 5 Sep 2016 23:08:32 +0000 (08:08 +0900)
commitf9f098f83335020361cd2234d65bafb95f048344
tree3a4999692700bc65239d3b43c52df511a19f9d7d
parent58708b562c7a3d3e7c506a1fcb3d41e708a02bd3
Don't ignore sync message from frontend when query cache is enabled.

While returning cached query result, sync message sent from frontend
is discarded. This is harmless because "ready for query" messages is
sent to frontend afterward. Problem is, AccessShareLock held by
previous parse message processing is not released until sync message
is received by the backend. Fix is, forwarding the sync message to
backend and discarding "ready for query" message returned from
backend.

Per [pgpool-hackers: 1787].
src/query_cache/pool_memqcache.c