Data caching

Started by Anant ngoover 3 years ago4 messages
#1Anant ngo
anant.ietf@gmail.com

Hello

Is there a postgres extension or project related to
application-level/foreign-table data caching ? The postgres_fdw extension
fetches data from foreign table for each command.

I have seen previous messages in archive about caching in form of global
temp tables, query cache etc. There are good discussions about
whether support should be built-in but did not find any implementation.

I have seen the 44 postgres extensions that come pre-installed with ubuntu
16.04 but none of them do this.

Thanks.
Anant.

#2Bruce Momjian
bruce@momjian.us
In reply to: Anant ngo (#1)
Re: Data caching

On Thu, Aug 18, 2022 at 04:12:45PM +0530, Anant ngo wrote:

Hello

Is there a postgres extension or project related to application-level/
foreign-table data caching ? The postgres_fdw extension fetches data from
foreign table for each command.

I have seen previous messages in archive about caching in form of global temp
tables, query cache etc. There are good discussions about whether support
should be built-in but did not find any implementation.

I have seen the 44 postgres extensions that come pre-installed with ubuntu
16.04 but none of them do this.

You can do foreign-table data caching via materialized views:

https://momjian.us/main/blogs/pgblog/2017.html#September_1_2017

Also, this is more of a question for pgsql-general@postgresql.org.

--
Bruce Momjian <bruce@momjian.us> https://momjian.us
EDB https://enterprisedb.com

Indecision is a decision. Inaction is an action. Mark Batterson

#3Anant ngo
anant.ietf@gmail.com
In reply to: Anant ngo (#1)
Fwd: Data caching

Hello

Is there a postgres extension or project related to
application-level/foreign-table data caching ? The postgres_fdw extension
fetches data from foreign table for each command.

I have seen previous messages in archive about caching in form of global
temp tables, query cache etc. There are good discussions about
whether support should be built-in but did not find any implementation.

I have seen the 44 postgres extensions that come pre-installed with ubuntu
16.04 but none of them do this.

Thanks.
Anant.

#4Adrian Klaver
adrian.klaver@aklaver.com
In reply to: Anant ngo (#3)
Re: Fwd: Data caching

On 8/18/22 09:39, Anant ngo wrote:

Hello

Is there a postgres extension or project related to
application-level/foreign-table data caching ? The postgres_fdw
extension fetches data from foreign table for each command.

I have seen previous messages in archive about caching in form of global
temp tables, query cache etc. There are good discussions about
whether support should be built-in but did not find any implementation.

Cursors?

https://www.postgresql.org/docs/current/sql-declare.html

"A cursor created with WITH HOLD is closed when an explicit CLOSE
command is issued on it, or the session ends. In the current
implementation, the rows represented by a held cursor are copied into a
temporary file or memory area so that they remain available for
subsequent transactions."

I have seen the 44 postgres extensions that come pre-installed with
ubuntu 16.04 but none of them do this.

Thanks.
Anant.

--
Adrian Klaver
adrian.klaver@aklaver.com