I wonder if change [1] (to be expanded) can come to the rescue after all. We could associate the network id to the segment tables, and leverage a foreign key constraint with delete on cascade that will wipe the segments automatically on network deletion. This is basically what is commented in [2].
That said, I really think that we're over-engineering a solution to a problem that hardly occurs in practice.
I wonder if change [1] (to be expanded) can come to the rescue after all. We could associate the network id to the segment tables, and leverage a foreign key constraint with delete on cascade that will wipe the segments automatically on network deletion. This is basically what is commented in [2].
That said, I really think that we're over-engineering a solution to a problem that hardly occurs in practice.
[1] https:/ /review. openstack. org/#/c/ 255614/ /github. com/openstack/ neutron/ blob/af89d74d29 61db6a045723751 50ad908c9e72e78 /neutron/ plugins/ ml2/managers. py#L105
[2] https:/