- In eclipse
- find pom.xml
- click on the pom.xml tab to see the actual xml code
- Add the JBoss Repository according to: https://community.jboss.org/wiki/MavenGettingStarted-Developers
- Go to the Dependencies tab on the pom.xml
- click Add...
- Start writing "envers" in "Enter groupId..." field
- "org.hibernate hibernate-envers" should appear in the results, instead of the latest version, enter your hibernate version, or "${org.hibernate.version}" to copy it dynamically.
- save pom.xml
You now have envers configured, just add @Audited above the classes/properties you want to audit.
No comments:
Post a Comment