About PostPersist

1-5 of 5Refresh
Manual
124

JPA Lifecycle Events

MyEntityWithCallbacks { @PrePersist void onPrePersist() {} @PostPersist void onPostPersist ... (added to the EntityManager). @PostPersist - after storing a new entity in the database (during commit or ... MyListener { @PrePersist void onPrePersist(Object o) {} @PostPersist void onPostPersist(Object
JPA Doc
119

javax.persistence.PostPersist

javax.persistence Annotation PostPersist Target: Callback methods Is used to specify callback methods for the corresponding lifecycle event. This annotation may be applied to methods of an entity class, a mapped superclass, or a callback listener class. Since: JPA 1.0 Learn how to define and use
JPA Doc
57

JPA Annotations for Callback Methods

Reference (JavaDoc) of JPA 2 event callback and listener annotations, including @PrePersist(2), @PreRemove, @PreUpdate, @PostLoad, @PostPersist, @PostRemove and @PostUpdate.
Forum
3

JPA lifecycle events across processes

Hi, wondering if it's possible to listen for changes in one process from another process? ie: process A changes an entity process B listens for @PostPersist   thanks   This is not supported. You may be able to implement your own cross process event listeners based on the JPA event listeners
Forum
3

Auto Date for Creation and Update

to check @PostPersist and other callbacks as well. > it would be MUCH more simple