I really have the same problem !
we have m : n relationship with between USER and GROUP, as also 1 : n between GROUP and PERMISSION.
If we update Group or Permissions, it throws an assertionfailure for collection USER.groups.
Code:
org.hibernate.AssertionFailure: collection [com.qualitype.lims.server.core.ejb.entity.user.UserEntity.groups] was not processed by flush()
at org.hibernate.engine.CollectionEntry.postFlush(CollectionEntry.java:205)
at org.hibernate.event.def.AbstractFlushingEventListener.postFlush(AbstractFlushingEventListener.java:333)
These error occures really only in following constellation: ManyToMany + @Version-Column + Flush-Event.
Seems really like a hibernate-bug.[/code]