ynput/ayon-backend

Events: Allow cascade delete

Closed this issue · 1 comments

Story

Currently it is tricky to delete events if they have children events. Constrain for depends_on column does not have ON DELETE CASCADE set.

After a year of experience with the event stream, pros of having a fast and simple way of deleting event including children outweigh most of the concerns. Manual check for children always can be performed in the case this behavior is undesired.

Proposed solution

Add ON DELETE CASCADE to events.depends_on foreign key constraint

No longer needed