Hi,
funny, by chance I was looking this morning for the same issue, just 15 hours after you posted here.
Anyway, for eclipselink I found this:
https://stackoverflow.com/questions/22141391/tracking-changes-using-history-policy-in-eclipse-link
https://stackoverflow.com/questions/25032275/eclipselink-history-of-related-objects
https://wiki.eclipse.org/EclipseLink/UserGuide/JPA/Advanced_JPA_Development/Customizers
https://wiki.eclipse.org/EclipseLink/Examples/JPA/History
This is a nice approach and might help in certain situations. In my case it's not enough, I'd like to do something like git in the database, so I actually need to be able to do branching and work on different 'current' versions in parallel. But the above might help as an example how to implement such stuff.
Regards,
Andreas