<div><br></div><div dir="auto">Hi,</div><div dir="auto"><br></div><div dir="auto">After investigating the code I found that the patch you provided is fixing the problem only for simple query. In extended query the issue still exist.</div><div dir="auto"><br></div><div dir="auto">Do you know where is the right place to add the transaction failure verification in extended query process? </div><div dir="auto"><div class="gmail_quote" dir="auto"><div dir="ltr" class="gmail_attr">On Mon, 9 May 2022 at 16:17 Tatsuo Ishii <<a href="mailto:ishii@sraoss.co.jp">ishii@sraoss.co.jp</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-style:solid;padding-left:1ex;border-left-color:rgb(204,204,204)">The patch (plus more fix) has been committed to master and 4.3 stable<br>
branches.<br>
<br>
<a href="https://www.pgpool.net/pipermail/pgpool-committers/2022-May/008592.html" rel="noreferrer" target="_blank">https://www.pgpool.net/pipermail/pgpool-committers/2022-May/008592.html</a><br>
<a href="https://www.pgpool.net/pipermail/pgpool-committers/2022-May/008591.html" rel="noreferrer" target="_blank">https://www.pgpool.net/pipermail/pgpool-committers/2022-May/008591.html</a><br>
<br>
The patches will appear in the next release (May 19, 2022).<br>
<br>
I have not pushed to other stable branches because the fix is not<br>
small and I wanted to minimize risks.<br>
<br>
> Thanks a lot for the patch have a great weekend<br>
> <br>
> On Sat, 7 May 2022 at 13:35 Tatsuo Ishii <<a href="mailto:ishii@sraoss.co.jp" target="_blank">ishii@sraoss.co.jp</a>> wrote:<br>
> <br>
>> > Hi,<br>
>> ><br>
>> > Still thinking.<br>
>> ><br>
>> > Best reagards,<br>
>> > --<br>
>> > Tatsuo Ishii<br>
>> > SRA OSS, Inc. Japan<br>
>> > English: <a href="http://www.sraoss.co.jp/index_en.php" rel="noreferrer" target="_blank">http://www.sraoss.co.jp/index_en.php</a><br>
>> > Japanese:<a href="http://www.sraoss.co.jp" rel="noreferrer" target="_blank">http://www.sraoss.co.jp</a><br>
>> ><br>
>> ><br>
>> >> Hi,<br>
>> >><br>
>> >> Any news about this thread?<br>
>> >><br>
>> >> Thanks,<br>
>> >> Avi.<br>
>> >><br>
>> >> On Mon, 25 Apr 2022 at 11:13 Avi Raboah <<a href="mailto:avi.raboah@gmail.com" target="_blank">avi.raboah@gmail.com</a>> wrote:<br>
>> >><br>
>> >>> It will be perfect thanks a lot!<br>
>> >>><br>
>> >>> On Mon, 25 Apr 2022 at 10:47 Tatsuo Ishii <<a href="mailto:ishii@sraoss.co.jp" target="_blank">ishii@sraoss.co.jp</a>> wrote:<br>
>> >>><br>
>> >>>> > No, it doesn't.<br>
>> >>>> > In that case when you make the select statement, piggy internal<br>
>> queries<br>
>> >>>> > failed and the session rebooted<br>
>> >>>><br>
>> >>>> I see it now.<br>
>> >>>><br>
>> >>>> test=# begin;<br>
>> >>>> BEGIN<br>
>> >>>> test=*# insert into ttt values(1);<br>
>> >>>> ERROR:  relation "ttt" does not exist<br>
>> >>>> LINE 1: insert into ttt values(1);<br>
>> >>>>                     ^<br>
>> >>>> test=!# select * from t1;<br>
>> >>>> FATAL:  Backend throw an error message<br>
>> >>>> DETAIL:  Exiting current session because of an error from backend<br>
>> >>>> HINT:  BACKEND Error: "current transaction is aborted, commands<br>
>> ignored<br>
>> >>>> until end of transaction block"<br>
>> >>>> server closed the connection unexpectedly<br>
>> >>>>         This probably means the server terminated abnormally<br>
>> >>>>         before or while processing the request.<br>
>> >>>> The connection to the server was lost. Attempting reset: Succeeded.<br>
>> >>>><br>
>> >>>> I think pgpool could remember that current transaction is in abort<br>
>> >>>> status and does not issue the piggyback query when the selec is<br>
>> >>>> issued. Let me see what we can do for this.<br>
>><br>
>> I have come up with a patch. In this patch pgpool checks if current<br>
>> transaction is in abort status. If so, it does not accept new query at<br>
>> all and just reply back frontend with the message:<br>
>><br>
>> "current transaction is aborted, commands ignored until end of transaction<br>
>> block"<br>
>><br>
>> until commit or abort command is sent from frontend. After applying<br>
>> the patch the example session above looks like this:<br>
>><br>
>> test=# begin;<br>
>> BEGIN<br>
>> test=*# insert into ttt values(1);<br>
>> ERROR:  relation "ttt" does not exist<br>
>> LINE 1: insert into ttt values(1);<br>
>>                     ^<br>
>> test=!# select * from t1;<br>
>> ERROR:  current transaction is aborted, commands ignored until end of<br>
>> transaction block<br>
>><br>
>> The patch was tested in master branch, but I believe it can be<br>
>> applied to 4.3 stable branch as well.<br>
>><br>
>> Best reagards,<br>
>> --<br>
>> Tatsuo Ishii<br>
>> SRA OSS, Inc. Japan<br>
>> English: <a href="http://www.sraoss.co.jp/index_en.php" rel="noreferrer" target="_blank">http://www.sraoss.co.jp/index_en.php</a><br>
>> Japanese:<a href="http://www.sraoss.co.jp" rel="noreferrer" target="_blank">http://www.sraoss.co.jp</a><br>
>><br>
</blockquote></div></div>