Re: Transactions involving multiple postgres foreign servers, take 2

From: Kyotaro Horiguchi <horikyota(dot)ntt(at)gmail(dot)com>
To: tsunakawa(dot)takay(at)fujitsu(dot)com
Cc: ashutosh(dot)bapat(dot)oss(at)gmail(dot)com, masahiko(dot)sawada(at)2ndquadrant(dot)com, sawada(dot)mshk(at)gmail(dot)com, masao(dot)fujii(at)oss(dot)nttdata(dot)com, amit(dot)kapila16(at)gmail(dot)com, m(dot)usama(at)gmail(dot)com, ikedamsh(at)oss(dot)nttdata(dot)com, pgsql-hackers(at)lists(dot)postgresql(dot)org, sulamul(at)gmail(dot)com, alvherre(at)2ndquadrant(dot)com, thomas(dot)munro(at)gmail(dot)com, ildar(at)adjust(dot)com, horiguchi(dot)kyotaro(at)lab(dot)ntt(dot)co(dot)jp, chris(dot)travers(at)adjust(dot)com, robertmhaas(at)gmail(dot)com, ishii(at)sraoss(dot)co(dot)jp
Subject: Re: Transactions involving multiple postgres foreign servers, take 2
Date: 2020-10-20 07:29:58
Message-ID: 20201020.162958.1740063912300427553.horikyota.ntt@gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

At Tue, 20 Oct 2020 04:23:12 +0000, "tsunakawa(dot)takay(at)fujitsu(dot)com" <tsunakawa(dot)takay(at)fujitsu(dot)com> wrote in
> From: Kyotaro Horiguchi <horikyota(dot)ntt(at)gmail(dot)com>
> > > Furthermore, FDW is not cancellable in general. So, I don't see a point in
> > trying hard to make only commit be cancelable.
> >
> > I think that it is quite important that operators can cancel any
> > process that has been stuck for a long time. Furthermore, postgres_fdw
> > is more likely to be stuck since network is involved so the usefulness
> > of that feature would be higher.
>
> But lower than practical performance during normal operation.
>
> BTW, speaking of network, how can postgres_fdw respond quickly to cancel request when libpq is waiting for a reply from a down foreign server? Can the user continue to use that session after cancellation?

It seems to respond to a statement-cancel signal immediately while
waiting for a coming byte. However, seems to wait forever while
waiting a space in send-buffer. (Is that mean the session will be
stuck if it sends a large chunk of bytes while the network is down?)

After receiving a signal, it closes the problem connection. So the
local session is usable after that but the fiailed remote sessions are
closed and created another one at the next use.

regards.

--
Kyotaro Horiguchi
NTT Open Source Software Center

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message gkokolatos 2020-10-20 07:30:39 Re: Commitfest manager 2020-11
Previous Message Michael Paquier 2020-10-20 07:22:09 Re: speed up unicode decomposition and recomposition