pg.ddx.io  pgsql-bugs@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Tom Lane <tgl@sss.pgh.pa.us>
To: David G. Johnston <david.g.johnston@gmail.com>
Cc: Cherio <cherio@gmail.com>
Cc: pgsql-bugs@lists.postgresql.org
Subject: Re: BUG #17810: Update from 13.09 to 13.10 breaks SQLs with VACUUM
Date: Mon, 27 Feb 2023 15:21:16 -0500
Message-ID: <415818.1677529276@sss.pgh.pa.us> (raw)
In-Reply-To: <CAKFQuwb+kV2MEFriTF5YywC1ZWXS825w2Om+1-DxeAyfEzDjrA@mail.gmail.com>
References: <17810-8eb7b4e1b7a68e1a@postgresql.org>
	<371962.1677515656@sss.pgh.pa.us>
	<CAKHqFkJsF8TOm0UV+-4=M98hc_D5qqqxFu3AY-mOyKrPuMMswQ@mail.gmail.com>
	<CAKHqFkJfO3-TA4YL_O0yw8EaKTGY9+2HFAiRgHpEu8q1abvesg@mail.gmail.com>
	<391334.1677520801@sss.pgh.pa.us>
	<CAKHqFkL3Ms6NzZ9_9UbpN3Qr0UKHdHisRH=JkeGYirYRhg0R7g@mail.gmail.com>
	<392516.1677521462@sss.pgh.pa.us>
	<CAKHqFkJGNLbbgY_=_4Gk9JioCOSh5iY++cGOfdB3_r+YNUW1wA@mail.gmail.com>
	<CAKFQuwb+kV2MEFriTF5YywC1ZWXS825w2Om+1-DxeAyfEzDjrA@mail.gmail.com>

"David G. Johnston" <david.g.johnston@gmail.com> writes:
> As for your usage of "conn.setAutocommit(true)" - IIUC that is irrelevant
> to this entire discussion.  You've chosen to bundle up multiple statements
> into a single Statement.execute(string) call which obeys the rules of the
> simple query protocol - multiple statements:

I doubt it.  We closed the not-in-transaction-block loophole decades
ago for simple query protocol.  What's at stake here is what happens
when a series of extended-protocol commands are given without Sync
between them, which we interpret as a request to run them all in the
same transaction.  I'm a bit surprised that the JDBC driver is choosing
to issue them that way, because it implies (at least) that it's parsing
the string enough to break it down into separate SQL commands.  But
we'd not be having this conversation if that weren't happening.
Anyway, that scenario *should* be subject to the same rules as multiple
statements in one simple-query message, only it wasn't up till now.

> Is there room for improved communication on the minor-release change in
> behavior?  Probably.

Yeah, I wish I could have that release note back :-(.  We don't really
have any mechanism for updating release notes after the fact.  I could
go and fix it in the git repo, but nobody would see it until after the
next quarterly releases which seems a bit too late.

> As for discussing reverting this in the back-branches given new evidence
> and scenarios, that is possible and I've yet to go back and fully review
> that discussion thread in light of this new information.

I think there's zero chance we'd revert the bug fix at this point.
If we'd realized that the JDBC driver behaves this way, we might have
debated a little harder about whether this really had to be fixed in
the back branches --- but it's done now, and it is a bug fix.

			regards, tom lane





view thread (14+ messages)  latest in thread

Message-ID: <415818.1677529276@sss.pgh.pa.us>
Permalink:  ../415818.1677529276@sss.pgh.pa.us/
Also on:    postgresql.org/message-id/415818.1677529276@sss.pgh.pa.us

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients using the --to and --cc options:
  reply via email

  To: pgsql-bugs@postgresql.org
  Cc: tgl@sss.pgh.pa.us, david.g.johnston@gmail.com, cherio@gmail.com, pgsql-bugs@lists.postgresql.org
  Subject: Re: BUG #17810: Update from 13.09 to 13.10 breaks SQLs with VACUUM
  In-Reply-To: <415818.1677529276@sss.pgh.pa.us>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox