org.hibernate.PropertyValueException: not-null property exception when trying to persist an entity object with null value for each of the property marked with nullable = true

Description

When trying to persist an object of RelatedEntities with null value for entity2, hibernate throws following exception:

Similarly when trying to persist an object of RelatedEntities with null value for entity3, hibernate throws same exception for example.RelatedEntities.entity3:

Above piece of code works perfectly with hibernate version 4.3.8.Final

Environment

None

Assignee

Unassigned

Reporter

Amar Laddha

Fix versions

None

backPortable

None

Suitable for new contributors

None

Requires Release Note

None

Pull Request

None

backportDecision

None

Components

Affects versions

Priority

Major
Configure