All notes

Why domain bookings must not simply be deleted

In a production model, delete is rarely the right correction. Usually you need a reversing entry.

In many applications, delete is the fastest way to fix a mistake. In a batch or material flow that is dangerous: a booking has already changed quantities, times, and downstream state.

The better operation is a reversing entry. It keeps history, makes the correction visible, and keeps reports honest. Soft-delete alone is not enough once the domain effect has occurred.

It looks like more work. It avoids the larger kind: overnight gaps between silo, recipe, and log that nobody can explain.

For technical decision-makers: model irreversibility where the domain requires it — not where the ORM offers a cascade.