From: | Robert Haas <robertmhaas(at)gmail(dot)com> |
---|---|
To: | Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> |
Cc: | Amit Langote <amitlangote09(at)gmail(dot)com>, Justin Pryzby <pryzby(at)telsasoft(dot)com>, "pgsql-hackers(at)postgresql(dot)org" <pgsql-hackers(at)postgresql(dot)org> |
Subject: | Re: FailedAssertion("pd_idx == pinfo->nparts", File: "execPartition.c", Line: 1689) |
Date: | 2020-08-05 20:20:48 |
Message-ID: | CA+TgmoZRdk-gsuWi2JB9gxoNVO_qiuHu9bYL7vSZ9MfRfYUhgA@mail.gmail.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
On Wed, Aug 5, 2020 at 4:19 PM Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> wrote:
> After thinking about it for a little bit, I'm envisioning a test module
> that can be loaded into a session, and then it gets into the planner_hook,
> and what it does is after each planner execution, take and release an
> advisory lock with some selectable ID. Then we can construct
> isolationtester specs that do something like
>
> session 1 session 2
>
> LOAD test-module;
> SET custom_guc_for_lock_id = n;
> prepare test tables;
>
> SELECT pg_advisory_lock(n);
>
> SELECT victim-query-here;
> ... after planning, query blocks on lock
>
> perform DDL changes;
> SELECT pg_advisory_unlock(n);
>
> ... query executes with now-stale plan
Very sneaky!
--
Robert Haas
EnterpriseDB: http://www.enterprisedb.com
The Enterprise PostgreSQL Company
From | Date | Subject | |
---|---|---|---|
Next Message | Peter Geoghegan | 2020-08-05 20:36:40 | Re: new heapcheck contrib module |
Previous Message | Tom Lane | 2020-08-05 20:19:08 | Re: FailedAssertion("pd_idx == pinfo->nparts", File: "execPartition.c", Line: 1689) |