I have also noticed that cascade=ALL is not behaving the same as cascade={PERSIST, MERGE, REMOVE, REFRESH, DETACH}.
We have a many-to-many relationship via an intermediate object and when using CascadeType.ALL I was getting an exception saying that a deleted object would be re-saved by a cascade, but when using cascade={PERSIST, MERGE, REMOVE, REFRESH, DETACH} I would not receive this exception. Now after reading this bug I understand that it's because CascadeType.ALL was re-persisting the child objects but specifying each specific CascadeType was not.
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira
I have also noticed that cascade=ALL is not behaving the same as cascade={PERSIST, MERGE, REMOVE, REFRESH, DETACH}.
We have a many-to-many relationship via an intermediate object and when using CascadeType.ALL I was getting an exception saying that a deleted object would be re-saved by a cascade, but when using cascade={PERSIST, MERGE, REMOVE, REFRESH, DETACH} I would not receive this exception. Now after reading this bug I understand that it's because CascadeType.ALL was re-persisting the child objects but specifying each specific CascadeType was not.