Обсуждение: Pl/Java broken since Postgresql 8.3-rc1

Поиск
Список
Период
Сортировка

Pl/Java broken since Postgresql 8.3-rc1

От
Jan Ischebeck
Дата:
Hi,
I'm following the 8.3 beta releases for some time now, mostly using the
Win32 with Installer package.
8.3beta3 and 4 have worked perfectly with the provided pljava ddl, just
with 8.3-rc1 it doesn't work anymore.
i.e. 
1. automatic installation of Pl/Java via Installer fails.
2. manual Installation via 
CREATE FUNCTION java_call_handler() RETURNS language_handler   AS 'pljava', 'java_call_handler'   LANGUAGE c;
raises the following error:

ERROR:  could not load library
"C:/Programme/PostgreSQL/8.3-rc1/lib/pljava.dll": unknown error 127
Tested on two different WinXP machines with JDK 1.6.

Regards,

Jan Ischebeck




Re: Pl/Java broken since Postgresql 8.3-rc1

От
Kris Jurka
Дата:

On Thu, 10 Jan 2008, Jan Ischebeck wrote:

> 8.3beta3 and 4 have worked perfectly with the provided pljava ddl, just
> with 8.3-rc1 it doesn't work anymore.
>

8.3RC1 changed the function definition for SetUserId, so it pljava needs 
some changes and a rebuild.  Will fix.

Kris Jurka


Re: Pl/Java broken since Postgresql 8.3-rc1

От
Kris Jurka
Дата:

On Thu, 10 Jan 2008, Kris Jurka wrote:

> On Thu, 10 Jan 2008, Jan Ischebeck wrote:
>
>> 8.3beta3 and 4 have worked perfectly with the provided pljava ddl, just
>> with 8.3-rc1 it doesn't work anymore.
>> 
>
> 8.3RC1 changed the function definition for SetUserId, so pljava needs 
> some changes and a rebuild.  Will fix.
>

Turns out it's not just 83RC1, but all of the security releases, which 
will require different pljava packages for the patch versions before/after 
the security changes.  I've committed a fix to CVS for this, and I guess 
I'll try to respin those this weekend and try to convince the windows 
installer folks to include them in the next point release.

For the moment you can pull the pljava.dll from here and it should work 
for you.

http://www.ejurka.com/pgsql/pljava/83rc1/

Kris Jurka


Re: Pl/Java broken since Postgresql 8.3-rc1

От
Tom Lane
Дата:
Kris Jurka <books@ejurka.com> writes:
> Turns out it's not just 83RC1, but all of the security releases, which 
> will require different pljava packages for the patch versions before/after 
> the security changes.

Just out of curiosity, what was pljava doing calling SetUserId?
If I'd known about that I'd have thought harder about removing the
function; but it's not clear to me why a PL should be doing that.
        regards, tom lane


Re: Pl/Java broken since Postgresql 8.3-rc1

От
Kris Jurka
Дата:

On Thu, 10 Jan 2008, Tom Lane wrote:

> Just out of curiosity, what was pljava doing calling SetUserId?
> If I'd known about that I'd have thought harder about removing the
> function; but it's not clear to me why a PL should be doing that.
>

pljava wants to run code as the session user when inside a security 
definer function.  The sqlj spec has an install_jar function which 
installs a library of java code and has an optional deployment descriptor 
which can create functions against the library and tables for it to use. 
The install_jar function is security definer to be able to register the 
jar file in various sqlj tables that the calling user may not be able to 
write to, but it wants to create the tables and function specified in the 
deployement descriptor with the ownership of the user calling install_jar, 
not the person who initially installed pljava.

Kris Jurka



Re: Pl/Java broken since Postgresql 8.3-rc1

От
"Dave Page"
Дата:
On 11/01/2008, Kris Jurka <books@ejurka.com> wrote:
> Turns out it's not just 83RC1, but all of the security releases, which
> will require different pljava packages for the patch versions before/after
> the security changes.  I've committed a fix to CVS for this, and I guess
> I'll try to respin those this weekend and try to convince the windows
> installer folks to include them in the next point release.

Thanks Kris - I've pulled the 8.3 dll to the win32 build VM, if you
can provide 8.2 as well that'd be great.

Regards, Dave