pg.ddx.io  pgsql-hackers@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Tom Lane <tgl@sss.pgh.pa.us>
To: Andy Fan <zhihui.fan1213@gmail.com>
Cc: Robert Haas <robertmhaas@gmail.com>
Cc: Amit Langote <amitlangote09@gmail.com>
Cc: Justin Pryzby <pryzby@telsasoft.com>
Cc: pgsql-hackers@postgresql.org <pgsql-hackers@postgresql.org>
Subject: Re: FailedAssertion("pd_idx == pinfo->nparts", File: "execPartition.c", Line: 1689)
Date: Thu, 06 Aug 2020 10:42:10 -0400
Message-ID: <2626504.1596724930@sss.pgh.pa.us> (raw)
In-Reply-To: <CAKU4AWo0wDDabURj9FQoJU6p6yczy8fk48gSvTTdq1kYPAcWoQ@mail.gmail.com>
References: <20200802181131.GA27754@telsasoft.com>
	<CA+TgmoawZkbuvP5BDBNNVp18F4tuwaZtqKUFxtH61QX7CiAV=Q@mail.gmail.com>
	<20200803161133.GA21372@telsasoft.com>
	<CA+HiwqETTgTh5SG9bcAdYRahEeTgpPHy+Xi=b93icoTX7j2EFg@mail.gmail.com>
	<2528807.1596648630@sss.pgh.pa.us>
	<CA+TgmoYMqqqHaOpfMYs8R6VJekykfRABCD=o4ovN2eUz-efYMA@mail.gmail.com>
	<2550497.1596651719@sss.pgh.pa.us>
	<CAKU4AWpEMxre9zDs-Odx7PnYd7tW3MiAyYBaP=9QrjuD7ps=MQ@mail.gmail.com>
	<2598266.1596686548@sss.pgh.pa.us>
	<CAKU4AWo0wDDabURj9FQoJU6p6yczy8fk48gSvTTdq1kYPAcWoQ@mail.gmail.com>

Andy Fan <zhihui.fan1213@gmail.com> writes:
> On Thu, Aug 6, 2020 at 12:02 PM Tom Lane <tgl@sss.pgh.pa.us> wrote:
>> See my straw-man proposal downthread.

> Thanks for your explanation, I checked it again and it looks a very clean
> method.  The attached is a draft patch based on my understanding.  Hope
> I didn't  misunderstand you..

Ah, I was going to play arond with that today, but you beat me to it ;-)

A few thoughts after a quick look at the patch:

* I had envisioned that there's a custom GUC controlling the lock ID
used; this would allow blocking different sessions at different points,
if we ever need that.  Also, I'd make the GUC start out as zero which
means "do nothing", so that merely loading the module has no immediate
effect.

* Don't really see the point of the before-planning lock.

* Rather than exposing internal declarations from lockfuncs.c, you
could just write calls to pg_advisory_lock_int8 etc. using
DirectFunctionCall1.

* We need some better name than "test_module".  I had vaguely thought
about "delay_execution", but am surely open to better ideas.

			regards, tom lane





view thread (31+ messages)  latest in thread

Message-ID: <2626504.1596724930@sss.pgh.pa.us>
Permalink:  ../2626504.1596724930@sss.pgh.pa.us/
Also on:    postgresql.org/message-id/2626504.1596724930@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-hackers@postgresql.org
  Cc: tgl@sss.pgh.pa.us, zhihui.fan1213@gmail.com, robertmhaas@gmail.com, amitlangote09@gmail.com, pryzby@telsasoft.com
  Subject: Re: FailedAssertion("pd_idx == pinfo->nparts", File: "execPartition.c", Line: 1689)
  In-Reply-To: <2626504.1596724930@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