Search code examples
javahibernatehibernate-envers

How can I make entities locally revisioned in hibernate?


I've audited my entities with the @Audited annotation of hibernate. It has a simple mechanism, It creates a REVINFO table and also _AUD for each entity by default and make a foreign key in each _AUD table with relation of REVINFO table. But I want to make revisioning to local. It means that I want to move revision to each _AUD table and removing REVINFO table.

According to Hibernate envers page

"locally revisioned", that is revisions would be created for it independently. This wouldn't enable correct versioning of relations, but wouldn't also require the "REVINFO" table.

But I don't know how can I do that?


Solution

  • That's only a discussion on what might be considered as a feature to implement in the future. Currently not possible.