It would be desirable to configure envers in that way, that the audit tables only contain historic revisions, excluding the current revision. With this, the main table would contain the current revision and the audit table would contain all revisions before the current revision.
So, where is the revision number and revision timestamp related to the current revision stored or are these values no longer relevant in your proposal?
The main reason for this feature request is the fact, that we're using liquibase in our project to manage database migration. Since we're dealing with lot's of master data (with the requirement to audit all of them) wich is inserted into database via liquibase, we would be forced to insert the audit data beside the revision meta data by hand. The requested feature would free us from this, since the first historic revision would be inserted into the audit log before the first update event.
Are you assuming your liquibase scripts would only ever INSERT rows and never have a need to UPDATE or DELETE audited entity rows? |