|
I flushed entitymanager twice (using autoflush) in one transaction.
First flush ended in ModWorkUnit with 3 modified attribute flags set to true
Second flush ended in ModWorkUnit wih 1 modified attribute flag set to true.
Merge of these two ModWorkUnits ended in ModWorkUnit with corrent entity, but only with 1 modified attribute flag set to true.
I suppose this is because this method:
public AuditWorkUnit merge(ModWorkUnit second) {
return second;
}
I thing mod flags should be set again by comparing second ModWorkUnit with state of entity before first ModWorkUnit.
|