Community
Participate
Working Groups
Build Identifier: EclipseLink, version: Eclipse Persistence Services - 2.0.1.v20100213-r6600 When setting a field on an entity in a @PostPersist callback (or entity listener), the update is not detected and not written out during a subsequent flush() and merge(). Reproducible: Always Steps to Reproduce: See attached test case.
Created attachment 184279 [details] Test case
Created attachment 184280 [details] Test entity
Only an insert is issued, like this: INSERT INTO CALLBACKENTITY (ID, POSTPERSISTSTATE) VALUES (?, ?) bind => [1, null]
If you haven't done so, it is likely a good idea to go through the mailing lists or forums prior to posting these kinds of bugs. The reason: There is a good chance someone will be able to provide you with a reasonable workaround.
A workaround is to call detach() before merge(). But that shouldn't be necessary, right? That's what this bug is about.
Setting target and priority. See the following page for the meanings of these fields: http://wiki.eclipse.org/EclipseLink/Development/Bugs/Guidelines
The Eclipselink project has moved to Github: https://github.com/eclipse-ee4j/eclipselink