XML Datastores

DataNucleus supports persisting objects to XML datastores (using the datanucleus-xml plugin). It makes use of JAXB. Support for XML is in its very early stages and will be enhanced 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 DataNucleus Forum.

Datastore Connection

DataNucleus supports the following mode of operation, file-based

The following persistence properties will connect to a local file on your local machine

datanucleus.ConnectionURL=xml:file:test.xml
datanucleus.ConnectionUserName=
datanucleus.ConnectionPassword=


Known Limitations

The following are known limitations of the current implementation

  • Datastore identity is not supported
  • Optimistic checking of versions is not supported
  • 1-1 relationships are supported but the PK of the related object needs to be a String field (JAXB limitation)
  • 1-N relationships are supported
  • Persistent properties are not supported, only persistent fields
  • Identity generators that operate using the datastore are not supported