This is a request for an update to the hibernate migration page so save others the trouble I experienced.
The upgrade was from 3.0.5 to 3.2.3.
There seems to have been a change in how the DefaultDeleteEventListener bahaves. Until upgrading, I only implemented the method
Code:
public void onDelete(DeleteEvent event) throws HibernateException
and as expected, this method got called when an entity is deleted. On upgrading to 3.2.3, this method was not getting called. The fix was to override
Code:
public void onDelete(DeleteEvent event, Set transientEntities) throws HibernateException
I haven't investigated what has changed. If anybody can shed some light that would be great.
There was nothing obvious on the migration web page that indicates something has changed.
This is an important change because if override this method to do soft deletes for instance, this will cease to work and it's hard to find.