Re: [HACKERS] Concurrent ALTER SEQUENCE RESTART Regression

From: Andres Freund <andres(at)anarazel(dot)de>
To: Robert Haas <robertmhaas(at)gmail(dot)com>
Cc: Peter Eisentraut <peter(dot)eisentraut(at)2ndquadrant(dot)com>, Michael Paquier <michael(dot)paquier(at)gmail(dot)com>, PostgreSQL mailing lists <pgsql-hackers(at)postgresql(dot)org>, Noah Misch <noah(at)leadboat(dot)com>, Jason Petersen <jason(at)citusdata(dot)com>, PostgreSQL mailing lists <pgsql-bugs(at)postgresql(dot)org>
Subject: Re: [HACKERS] Concurrent ALTER SEQUENCE RESTART Regression
Date: 2017-05-24 03:25:17
Message-ID: 20170524032516.rsggec2yrd4cqvv2@alap3.anarazel.de
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-bugs pgsql-hackers

On 2017-05-23 22:47:07 -0400, Robert Haas wrote:
> On Mon, May 22, 2017 at 11:42 AM, Andres Freund <andres(at)anarazel(dot)de> wrote:
> > Ooops.
> >
> > Two issues: Firstly, we get a value smaller than seqmin, obviously
> > that's not ok. But even if we'd error out, it'd imo still not be ok,
> > because we have a command that behaves partially transactionally
> > (keeping the seqmax/min transactionally), partially not (keeping the
> > current sequence state at -9).
>
> I don't really agree that this is broken.

Just a quick clarification question: You did notice that nextval() in S1
after the rollback returned -9, despite seqmin being 0? I can see
erroring out being acceptable, but returning flat out wrong values....?

- Andres

In response to

Responses

Browse pgsql-bugs by date

  From Date Subject
Next Message digoal 2017-05-24 06:33:23 BUG #14668: BRIN open autosummarize=on , database will crash
Previous Message csjy_tsb 2017-05-24 02:52:55 BUG #14667: Question on money type as the key of partitioned table

Browse pgsql-hackers by date

  From Date Subject
Next Message Thomas Munro 2017-05-24 03:58:49 Re: Causal reads take II
Previous Message Bruce Momjian 2017-05-24 03:25:07 Shortened URLs for commit messages