Re: Having query cache in core - Mailing list pgsql-hackers

From Tatsuo Ishii
Subject Re: Having query cache in core
Date
Msg-id 20180509.090404.962998183482647780.t-ishii@sraoss.co.jp
Whole thread Raw
In response to Re: Having query cache in core  (Heikki Linnakangas <hlinnaka@iki.fi>)
Responses Re: Having query cache in core
List pgsql-hackers
> On 07/05/18 05:47, Tom Lane wrote:
>> Tatsuo Ishii <ishii@sraoss.co.jp> writes:
>>> Does anybody think having in-memory query result cache in core is a
>>> good idea?
>> No.
> 
> Agreed.
> 
> You could probably write an extension for that, though. I think the
> planner hook and custom scans give you enough flexibility to do that
> without modifying the server code.

I have simulated the idea and I wonder how to implement the query
result cache on the streaming standby servers because no DML/DDL are
executed on standby servers, that makes it impossible to invalidate
the query cache. Probably the only way to allow to use the query cache
is,

1) Let invalidate the query cache on the primary server.

2) The cache storage needed to be on the external cache server like
   memcached.

Best regards,
--
Tatsuo Ishii
SRA OSS, Inc. Japan
English: http://www.sraoss.co.jp/index_en.php
Japanese:http://www.sraoss.co.jp


pgsql-hackers by date:

Previous
From: Craig Ringer
Date:
Subject: Re: Setting libpq TCP keepalive parameters from environment
Next
From: Michael Paquier
Date:
Subject: Re: Having query cache in core