Re: Shared memory - Mailing list pgsql-hackers

From Thomas Hallgren
Subject Re: Shared memory
Date
Msg-id 44296E24.5010602@tada.se
Whole thread Raw
In response to Re: Shared memory  (Tom Lane <tgl@sss.pgh.pa.us>)
Responses Re: Shared memory
List pgsql-hackers
Tom Lane wrote:
> Thomas Hallgren <thomas@tada.se> writes:
>   
>> This FENCED/NOT FENCED terminology would be a good way to
>> differentiate between the two approaches. Any chance of that syntax
>> making it into the PostgreSQL grammar, should the need arise?
>>     
>
> Of what value would it be to have it in the grammar?  The behavior would
> be entirely internal to any particular PL in any case.
>
>   
Not necessarily but perhaps the term FENCED is incorrect for the concept 
that I have in mind.

All languages that are implemented using a VM could benefit from the 
same remote UDF protocol. Java, C#, perhaps even Perl or Ruby. The flag 
that I'd like to have would control 'in-process' versus 'remote'.

I'm not too keen on the term FENCED, since it, in the PL/Java case will 
lead to poorer isolation. Multiple threads running in the same JVM will 
be able to share data and a JVM crash will affect all connected sessions.

Then again, perhaps it's a bad idea to have this in the function 
declaration in the first place. A custom GUC parameter might be a better 
choice. It will not be possible to have some functions use the 
in-process approach and others to execute remotely but I doubt that will 
matter that much.

I'm still eager to hear what it is in the current PL/Java that you 
consider fundamental unresolvable problems.

Regards,
Thomas Hallgren



pgsql-hackers by date:

Previous
From: Tom Lane
Date:
Subject: Re: Why are default encoding conversions
Next
From: Simon Riggs
Date:
Subject: Re: Shared memory