Using the following entity configuration:
Hibernate will insert *child* as the discriminator value on the ORM side; however, the fully qualified class name of the audited entity will be used in the envers audit tables.
In Hibernate 4.3.11.Final, this wasn't observed and the actual configured discriminator value was used instead. This also introduces a column width problem as column width is configured based on the expected configured values, which are often far shorter than the fully qualified name; causing insertion failures on the Envers side.
The main reason for this regression is that ORM5 didn't provide support for discriminator-value attributes on joined-subclass HBM mapping elements.
The provided PR will introduce this change, allowing the discriminator values to be properly set on the persisters for the audit entities and therefore properly set at the table level to address this regression.
Fixed in master.
Fixed in 5.1 branch as well.