Keep track of datetime an entity was last modified with Ebean in Play

October 31st, 2017 | #ebean #playframework #java #sql

TIL that Ebean helps you to keep track of the datetime an entity was last modified. I wanted to implement a column last_modified_at, when a colleague showed me this commit. You simply can add a timestamp property to a model with the annotation @WhenModified. Ebean will set the timestamp to the datetime when the entitiy was last modified.

Read more

© 2018 Tonny Garić | With from Nijmegen, The Netherlands