The Envers project makes it simple to version entities. The only thing required is annotating them with @Versioned. Storing historical data (versions) is completely transparent to the developer. He/she may interact with the entities as always.
Not
... [More] only basic properties of an entity can be versioned, but also relations, making it possible to view parts of the database as they were at a given revision (each revision has an associated timestamp, one revision = one transaction, in which versioned data has changed).
Moreover, Envers provides a straightforward interface for retrieving historical data, a criteria-like query interface, and the possibility to store additional information alongside each revision.
Envers works with Hibernate and Hibernate Entity Manager. [Less]