java.lang.ClassCastException: java.util.ArrayList cannot be cast to org.hibernate.collection.spi.PersistentCollection

Hibernate JIRA | Jethro Bakker | 5 years ago
tip
Click on the to mark the solution that helps you, Samebug will learn from it.
As a community member, you’ll be rewarded for you help.

    Root Cause Analysis

    1. java.lang.ClassCastException

      java.util.ArrayList cannot be cast to org.hibernate.collection.spi.PersistentCollection

      at org.hibernate.envers.entities.mapper.relation.AbstractCollectionMapper.mapModifiedFlagsToMapFromEntity()
    2. A Hibernate O/RM Module
      AddWorkUnit.<init>
      1. org.hibernate.envers.entities.mapper.relation.AbstractCollectionMapper.mapModifiedFlagsToMapFromEntity(AbstractCollectionMapper.java:142)
      2. org.hibernate.envers.entities.mapper.MultiPropertyMapper.map(MultiPropertyMapper.java:89)
      3. org.hibernate.envers.synchronization.work.AddWorkUnit.<init>(AddWorkUnit.java:49)
      3 frames