Please use the google group to ask questions - thanks.

by Lyubo 04 Mar 10:39
@PrePersist, @PostPersist, @PostLoad,...

lifesycle management via annotations would be handy

04 Mar 21:29
by Rob

Quite right. At the moment you have to use the Ebean specific BeanPersistController.

However, the BeanPersistController does do more ... takes into account partial objects (loaded properties), gives you access to the transaction and server that is processing the persist request etc, allows you to override the insert/update/delete behaviour.

Also note that often @PostPersist is NOT what you want as that fires even when a transaction rolls back - in this case you'd want to use a BeanPersistListener instead.

So yes, we need to add support for the annotations... but be careful because sometimes you might need to use a BeanPersistController or BeanPersistListener instead.

Cheers, Rob.

05 Mar 22:27
by Rob

Create a New Topic

Title:
Body:
 
Introduction User Guide (pdf) Install/Configure Public JavaDoc Whitepapers
General Database Specific Byte Code Deployment Annotations Features
Top Bugs Top Enhancements
woResponse