JPOX
JPOX
 Project  |  Ver 1.1  |  Ver 1.2  |  JDO  |  JPA  |  Guides  |  Tools
1.2 | Persistence | JDO ORM | JPA ORM | Runtime | JDO Runtime | JPA Runtime | Extensions | Developer
JPOX Runtime
RDBMS Datastores
DB4O Datastore
DB4O Datastores

JPOX supports persisting objects to DB4O datastores (using the jpox-db4o plugin). Support for DB4O is maturing and will be enhanced further in future releases. If you wish to help out in this effort either by contributing or by sponsoring particular functionality please contact us via the JPOX Forum.

Datastore Connection

JPOX supports 2 modes of operation of db4o - file-based, and client-server based. In order to do so and to fit in with the JDO/JPA APIs we have defined the following means of connection.

The following JDO connection properties will connect to a local file-based DB4O running on your local machine

javax.jdo.option.ConnectionDriverName=
javax.jdo.option.ConnectionURL=db4o:file:{my_db4o_file}
javax.jdo.option.ConnectionUserName=
javax.jdo.option.ConnectionPassword=

In JPOX 1.2.0-beta-1 the "file:" was not required. In JPOX 1.2.0-beta-2 and 1.2.0-beta-4 the "file:" was needed, BUT the filename should be absolute. In later JPOX releases the "file:" is needed and the filename can be absolute OR relative.

The following JDO connection properties will connect as a client to a DB4O server

javax.jdo.option.ConnectionDriverName=
javax.jdo.option.ConnectionURL=db4o:{db4o_host}:{db4o_port}
javax.jdo.option.ConnectionUserName=
javax.jdo.option.ConnectionPassword=

DB4O doesn't itself use such URLs so it was necessary to define this JPOX-specific way of addressing DB4O.