[pgpool-general: 7039] Re: PREPARE STATMENTS

Matthew MacDonald mmacdonald at intertalksystems.com
Tue May 26 21:47:17 JST 2020


Hi Bo,

Can you explain the rationale for sending prepared statements to only the
primary node?  If a prepared statement contains an UPDATE or INSERT - will
this result in the back-end databases being out-of-sync if native
replication is being used, since the query is only sent to the primary node?

Thanks,

MATTHEW MACDONALD


On Tue, May 26, 2020 at 4:44 AM Bo Peng <pengbo at sraoss.co.jp> wrote:

> hello,
>
> On Fri, 22 May 2020 17:58:00 +0200
> Franco Ricci <franco.ricc at gmail.com> wrote:
>
> > I’s possible specify which server should execute a "prepared statement"?
> > I noticed in pgpool 4.1 that ordinary query are routed on master or
> slave server according query action (SELECT, UPDATE etc.).
> > If I create a PREPARE STATEMENT this query is routed always on master
> server and never executed on slave even if statements is only a SELECT
> query!
> >
> > There is a way to programmatic set which is the server that has to
> server a prepared statement?
>
> No.
> Pgpool doesn't load balance "prepared statement".
> "Prepared statement" should be sent to primary only.
>
> > _______________________________________________
> > pgpool-general mailing list
> > pgpool-general at pgpool.net
> > http://www.pgpool.net/mailman/listinfo/pgpool-general
>
>
> --
> Bo Peng <pengbo at sraoss.co.jp>
> SRA OSS, Inc. Japan
> _______________________________________________
> pgpool-general mailing list
> pgpool-general at pgpool.net
> http://www.pgpool.net/mailman/listinfo/pgpool-general
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.sraoss.jp/pipermail/pgpool-general/attachments/20200526/dc95801b/attachment.html>


More information about the pgpool-general mailing list