Re: BUG #15460: Error while creating index or constraint
Peter Geoghegan <pg@bowt.ie>
From: Peter Geoghegan <pg@bowt.ie>
To: Tom Lane <tgl@sss.pgh.pa.us>
Cc: paul.vanderlinden@mapcreator.eu, PostgreSQL mailing lists <pgsql-bugs@lists.postgresql.org>,
Heikki Linnakangas <hlinnaka@iki.fi>
Date: 2018-10-29T17:11:57Z
Lists: pgsql-bugs
On Mon, Oct 29, 2018 at 4:51 PM Tom Lane <tgl@sss.pgh.pa.us> wrote: > >> "performsort of -1"? Seems a bit suspicious. > > > This just refers to the leader Tuplesortstate. It isn't suspicious. > > We follow the convention that worker -1 is the leader within > > tuplesort.c. > > Hmm. But the sort of "0" has already completed, according to the first > couple of log lines I quoted. Why is something still trying to access > it? Why is a worker trying to do anything at all with the leader's > Tuplesortstate? This is almost certainly because the parallel infrastructure generally doesn't guarantee that log output will be in order. Even if something bizarre took place with the temporary files, there is no way that the worker number in trace_sort would change within a worker. It's an immutable field within Tuplesortstate, initialized once. > > trace_sort is a developer option, so this seems fine to me. > > That's a poor excuse for ignoring the message style guidelines. > There are many reasons why even experts could get confused trying > to follow badly-written messages. I'll change the trace_sort messages to refer to "worker n" -- that should bring the trace_sort output in line with our style guidelines. -- Peter Geoghegan
Commits
-
Have BufFileSize() ereport() on FileSize() failure.
- 1a990b207b86 12.0 landed
- 95c45718126f 11.2 landed
-
Use 64 bit type for BufFileSize().
- fa2ceaca4358 11.2 landed
- aa5518304213 12.0 landed
-
Adjust trace_sort log messages.
- cb6f8a9a7243 12.0 landed
- 886319d71bd5 11.1 landed
-
Fix some sloppiness in the new BufFileSize() and BufFileAppend() functions.
- 445e31bdc749 11.0 cited