Re: parallel mode and parallel contexts - Mailing list pgsql-hackers

From Robert Haas
Subject Re: parallel mode and parallel contexts
Date
Msg-id CA+TgmoZmkwkDJo85KpPLaL1h4mcQtX_muj2OrXryQr_8SAb0eQ@mail.gmail.com
Whole thread Raw
In response to Re: parallel mode and parallel contexts  (Jim Nasby <Jim.Nasby@BlueTreble.com>)
List pgsql-hackers
On Wed, Jan 7, 2015 at 3:54 PM, Jim Nasby <Jim.Nasby@bluetreble.com> wrote:
> Agreed, I was more concerned with calls to nextval(), which don't seem to be
> prevented in parallel mode?

It looks prevented:
   /*    * Forbid this during parallel operation because, to make it work,    * the cooperating backends would need to
sharethe backend-local cached    * sequence information.  Currently, we don't support that.    */
PreventCommandIfParallelMode("nextval()");

> I was more thinking about all the add-on pl's like pl/ruby. But yeah, I
> don't see that there's much we can do if they're not using SPI.

Actually, there is: it's forbidden at the layer of heap_insert(),
heap_update(), heap_delete().  It's hard to imagine anyone trying to
modify the database as a lower level than that.

-- 
Robert Haas
EnterpriseDB: http://www.enterprisedb.com
The Enterprise PostgreSQL Company



pgsql-hackers by date:

Previous
From: Dean Rasheed
Date:
Subject: Re: INSERT ... ON CONFLICT UPDATE and RLS
Next
From: Robert Haas
Date:
Subject: Re: parallel mode and parallel contexts