Re: IMMUTABLE and PARALLEL SAFE function markings
От | Vik Fearing |
---|---|
Тема | Re: IMMUTABLE and PARALLEL SAFE function markings |
Дата | |
Msg-id | 028a3895-2713-ad20-ef03-d192bc245f98@2ndquadrant.com обсуждение исходный текст |
Ответ на | Re: IMMUTABLE and PARALLEL SAFE function markings (Tom Lane <tgl@sss.pgh.pa.us>) |
Ответы |
Re: IMMUTABLE and PARALLEL SAFE function markings
|
Список | pgsql-hackers |
On 27/11/2018 01:40, Tom Lane wrote: > Vik Fearing <vik.fearing@2ndquadrant.com> writes: >> On 27/11/2018 01:13, Stephen Frost wrote: >>> Parallel safe functions should be marked as such. Immutable functions >>> should be marked as such. We should not assume that one implies the >>> other, nor should we operate as if they do. > >> Yes we should! Unless you can produce a case where an immutable >> function is not parallel safe. > > As far as that goes, I agree with the idea of adding an oprsanity test > that shows any built-in functions that are immutable but not parallel > safe, on the grounds Stephen mentioned: it's probably a mistake, and > if it isn't, we can add that function to the expected output. > > I'm way less inclined to buy into the idea that it MUST be wrong, though. > Immutability is a promise about result stability and lack of side effects, > but it is not a promise about implementation details. There could be an > implementation reason not to run something in a parallel worker. Off the > top of my head, a possible example is "it's written in plfoo which hasn't > yet been made to work correctly in parallel workers". Now, see, that is an actual argument for making a difference. The other arguments in this thread were not, so say I. -- Vik Fearing +33 6 46 75 15 36 http://2ndQuadrant.fr PostgreSQL : Expertise, Formation et Support
В списке pgsql-hackers по дате отправления: