[pgpool-committers: 6632] pgpool: Fix bug with query cache.

Tatsuo Ishii ishii at sraoss.co.jp
Tue Mar 31 16:59:51 JST 2020


Fix bug with query cache.

If an execute message is issued right after Sync message and query
cache hits, Pgpool-II hangs in inject_cached_message() because there's
no data to be read from backend. Fix is, change the code block which
checks the data availability in backend to the beginning of the loop
from the end of the loop. Also teach is_cache_empty() to call
pool_is_suspend_reading_from_frontend() so that if we suspend reading
from frontend. If so, return that cache is empty even if there's data
in frontend cache to receive a ready for query message from backend.

Branch
------
master

Details
-------
https://git.postgresql.org/gitweb?p=pgpool2.git;a=commitdiff;h=c947114af74384422fcdc301bcc346e3920cba82

Modified Files
--------------
src/protocol/pool_process_query.c | 23 +++++++++++++----------
src/query_cache/pool_memqcache.c  | 30 +++++++++++++++---------------
2 files changed, 28 insertions(+), 25 deletions(-)



More information about the pgpool-committers mailing list