Re: Parallel safety tagging of extension functions

From: Robert Haas <robertmhaas(at)gmail(dot)com>
To: Andreas Karlsson <andreas(at)proxel(dot)se>
Cc: PostgreSQL-development <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: Parallel safety tagging of extension functions
Date: 2016-05-25 00:36:42
Message-ID: CA+TgmoagALGBY0YqzwHR5rqUFirTjcbTJu9ggSrJPiQjjCQ26w@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On Sat, May 21, 2016 at 1:01 PM, Andreas Karlsson <andreas(at)proxel(dot)se> wrote:
> Another question which I thought of is what we should do with functions like
> pg_file_write() in adminpack.
>
> While it is perfectly fine to modify files from the parallel workers, a user
> could get race conditions if he tries to modify the same file multiple
> times. Is this a kind of problem the PARALLEL tagging should try to prevent,
> or is that something we should leave to the user?

I think there's little value in marking such things parallel-safe,
even though by some definition they may be. Parallelizing queries
involving pg_file_write() is not really a useful thing to do. What we
really want to do is nail the functions that people might be likely to
use as scan quals, plus any generally useful aggregates.

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

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Robert Haas 2016-05-25 00:41:07 Re: Parallel safety tagging of extension functions
Previous Message Robert Haas 2016-05-25 00:34:10 Re: Parallel safety tagging of extension functions