Welcome to PL-J, a Java Stored Procedure Server for PostgreSQL RDBMS!
PL-J aims to provide a modular and flexible solution for your RDBMS logic, supporting triggers and user defined functions written in java.
PL-J runs on PostgreSQL version 8.0 and 7.4, with some work, the architecture is portable to other relational databases.
PL-J is built from reusable/replacable components. We have our implementations and the default deployment descriptor, but you can write yours if you want.
There is a need for a configuration api on the C side for channel implementation specific settings (how to communicate or even connect to the java side).
The java side channel is responsible for sending and receiving messages from the RDBMS.
The typemapper is a component that maps raw data into java objects. You may use it for custom datatypes too, so you don`t have to worry about SQLData in your stored procedures.
The following components are implemented:
The PostgreSQL call handler is the entry point of a stored procedure or function from the PostgreSQL ORDBMS. It contains the main logic of how messages are handled in a PostgreSQL system.
The FE/BE channel is built from the PostgreSQL groups frontend/backend protocol. It contains a modified version of libpq.
The default (and now the only) implementation of the C side configuration api. It uses a table called 'sqlj.plj_config' to read configuration settings.
Maps PostgreSQL raw data into java objects.
This component is very important if you want to add custom datatypes, or use non standard types such as inet.
The executor tho execute java UDFs and triggers.
The default executor is java of course. This component depends on more services. With the default classloader implementation, the executor will load and store classes in an RDBMS table.