I just noticed in my mapping code that I forgot to set the inverse relation on a one-to-many composition.
parent -* child
Since this is composition I would never want my children to exist without a parent. But now I have a whole bunch of dangling child records in the db.
Wouldn’t it make sense to have this as a not-null constraint (code and db) by default?