| I just started working on this, but whatever happened before was not deterministic. The model you posted has two different collections that aren't compatible with each other, thus it's not possible to join a collection with that name on BaseEntity. The collections are different because essentially they use a different collection table for each collection in the subtype. In Hibernate 5.2.13 and before, Hibernate just joins one of the two tables in a non deterministic manner which might lead to unexpected results. Adding the following mapping to both OneToMany attributes will resolve the issue by using just a single collection table
@JoinTable(name = "entity_attributes", joinColumns = @JoinColumn(name = "entity_id"), foreignKey = @ForeignKey(ConstraintMode.NO_CONSTRAINT))
|