Closed lisandrofernandez closed 4 years ago
@lisandrofernandez I checked it out, and it's a Hibernate bug. You need to open a Jira issue and attache a replicating test case.
It looks like the merge generates an extra copy of the transient entity which has an id of null
as if it was loaded from the DB.
I think @gbadner is the best person to tackle this issue.
@vladmihalcea I opened HHH-13815 to track the issue. I also opened a pull request with a replicated test case.
Great.
This test fails because an org.hibernate.TransientObjectException is thrown when calling post.getComments().isEmpty() with a merge operation.
A couple of things to mention: