| 1 | What Hibernate cascading mode is used as much as possible? This mode is specified per cardinality in the hibernate mapping. |
| 2 | |
| 3 | '''Option 1:''' save-update |
| 4 | * + no resources gets magically deleted |
| 5 | * - resources do remain |
| 6 | |
| 7 | |
| 8 | '''Option 2:''' all |
| 9 | * + related resources are always cleaned uyp |
| 10 | * - magic deletion which might not be desirable |
| 11 | |
| 12 | Chosen option 2 |
| 13 | I ran into the situation that I was inserting and deleting. The thing is that with option 1, Hibernate does not delete the related resources. Therefore I have chosen for option 2. Not thought that this can be differentiated per entity. |