3.5. Transactional vs. non-transactional

As well as being transient or persistent, a JDO instance may be transactional or non-transactional.

A transactional instance is one whose persistent and transactional field values will be cached by the JDO implementation when the instance is first involved with a transaction. Upon commit() the cached field values will be discarded, but on rollback() the cached values will be restored into those fields.

Recall that the persistence descriptor can be used to declare a persistence modifier for each field, identifying that field as persistent, transactional, or none. Persistent fields are synchronized with the data store and are managed transactionally. Transactional fields are not synchronized to the data ...

Get Java™ Data Objects now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.