Search Postgresql Archives

Re: stored function (possible to access file system or call java program)?

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Mon, Oct 3, 2011 at 4:53 PM, John R Pierce <pierce@xxxxxxxxxxxx> wrote:
> On 10/03/11 2:18 PM, Merlin Moncure wrote:
>>
>> hm -- care to comment in more detail?
>
>
> I've had to custom build it for each platform I've deployed it on, and it
> then has dependencies on the exact JDK version and location.   It currently
> doesn't work with JDK 6, only 1.5.    It also requires custom lines be added
> to postgresql.conf and environment variables defined by the postgres service
> startup script.

I don't remember if I did anything special to get this running (I
downloaded the stock .so from pgfoundry), but this is working fine for
me:
merlin@mmoncure-ubuntu:~$ ldd /home/merlin/pljava/pljava.so
        linux-gate.so.1 =>  (0x002b2000)
        libjvm.so => /usr/lib/libjvm.so (0x00cfc000)
        libc.so.6 => /lib/libc.so.6 (0x007db000)
        libm.so.6 => /lib/libm.so.6 (0x0075f000)
        libdl.so.2 => /lib/libdl.so.2 (0x001b2000)
        libpthread.so.0 => /lib/libpthread.so.0 (0x0049a000)

merlin@mmoncure-ubuntu:~$ ldd /usr/lib/libjvm.so
        linux-gate.so.1 =>  (0x0029c000)
        libm.so.6 => /lib/libm.so.6 (0x0033b000)
        libdl.so.2 => /lib/libdl.so.2 (0x00110000)
        libpthread.so.0 => /lib/libpthread.so.0 (0x00114000)
        libc.so.6 => /lib/libc.so.6 (0x0012e000)

merlin@mmoncure-ubuntu:~$ ls -l /usr/lib/libjvm.so
lrwxrwxrwx 1 root root 57 2011-08-12 17:13 /usr/lib/libjvm.so ->
/usr/lib/jvm/java-6-openjdk/jre/lib/i386/server/libjvm.so

also postgres startup script etc is normal -- just the custom .conf
entries, etc.  basically, everything was smooth as silk.  it looks
like a real bear to compile though if anything goes wrong, I'll admit.

> My first attempt to get it working with 64bit CentOS 6, Sun JDK 1.5.0_22,
> and PG 9.0.5 failed, although I need to start over and make sure I didn't
> mess up a step.

that's (sun) probably the issue.  everything's easier on linux i guess.

> The idea of dragging a whole JVM into the process context of the postgres
> server also bothers me, but I must say, that once you DO get it working, the
> developers in another division of $job were able to move some code over from
> Oracle pljava to Postgres pljava without any modifications at all.

yeah -- understood, but especially with the new stuff coming down the
pike for java 7 there are definitely advantages for java shops in
going in this direction...I wouldn't go so far as to say 'integration
nightmare' -- maybe 'situationally dependent difficulties' :-).

merlin

-- 
Sent via pgsql-general mailing list (pgsql-general@xxxxxxxxxxxxxx)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-general



[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Postgresql Jobs]     [Postgresql Admin]     [Postgresql Performance]     [Linux Clusters]     [PHP Home]     [PHP on Windows]     [Kernel Newbies]     [PHP Classes]     [PHP Books]     [PHP Databases]     [Postgresql & PHP]     [Yosemite]
  Powered by Linux