Jump to content

Apache OJB

From Wikipedia, the free encyclopedia
This is an old revision of this page, as edited by RJFJR (talk | contribs) at 20:12, 27 August 2012 (Configuration: change bulleted list to comma-ed list). The present address (URL) is a permanent link to this revision, which may differ significantly from the current revision.
Apache ObJectRelationalBridge
Developer(s)Apache Software Foundation
Stable release
1.0.4 / December 31, 2005 (2005-12-31)
Written inJava
Operating systemCross-platform
TypeObject-relational mapping
LicenseApache License 2.0
Websitehttp://db.apache.org/ojb/

Apache ObJectRelationalBridge (OJB) is an Object/Relational mapping tool that allows transparent persistence for Java Objects against relational databases.

Apache OJB was released on April 6th, 2005.[1]

Features

  • OJB is open source (open source code).
  • Is also lightweight and easy to use, because to implement a persistence layer, one must simply configure two files (see section below)
  • Easy to integrate into an existing application because it does not generate code.
  • Allows the use of different patterns of persistence: owner (PersistenceBroker API), JDO and Object Data Management Group (ODMG).

Functionality

OJB uses an XML based Object/Relational mapping. The mapping resides in a dynamic MetaData layer, which can be manipulated at runtime through a simple Meta-Object-Protocol (MOP) to change the behaviour of the persistence kernel.

Configuration

At least two files are required to configure OJB: OJB.properties and repository.xml

Allocation

For mapping a 1-1 relationship, for example, you have two tables: person and account. In this case, a person has an account and vice versa.

References

See also