Comment 16 for bug 1511574

Revision history for this message
John Davidge (john-davidge) wrote : Re: [RFE] Support cleanup of all resources associated with a given tenant with a single API call

Great discussion here, allow me to weigh in.

First, I should say that I am not particularly interested in (nor well equipped for) leading a cross-project spec for this. I am of the opinion that if we try to agree on syntax etc across all projects (and which projects would we include?) before getting started then nothing will get done for a very long time. This is a consistent pain point from the ops group so I'd prefer to fix it as soon as possible. That doesn't necessarily mean that I think we should do this work in a vacuum. We already have an established approach in the form of ospurge, and I think that we should leverage that in creating an API that operators will already be familiar with. When we have something that works we can use that in leading the proposal of a cross-project spec with already established conventions.

I'm not sure I see the benefit in not making this API-accessible from the beginning. If we build this feature then we should make it as easy to use as possible otherwise we're just creating another pain point for operators. If future cross-project work means that we have to make changes to the API then that's fine.

As for what that API would look like, I'd like to propose that we follow the conventions already established by ospurge. Many operators will already be familiar with the commands, and they are generic enough to work across projects in the future. Specifically, it would look like:

$ neutron purge <project_id>

This is based on the assumption that we will make this an admin-only API to begin with, but we could also allow users to purge their own projects with a simple:

$ neutron purge

We can also make use of ospurge's --dry-run syntax to return a list of the resources that would be deleted by a full purge.

Assaf - the work that you did last year [1] will be very helpful in providing a starting point for deletion orders etc. Thank you.

I think we have a good opportunity to remove a pain point for operators here. Should I write a spec before getting started or are we more or less agreed on a direction here for the first pass?

[1] - https://review.openstack.org/#/c/92600/5/neutron/services/identity/project_deleted.py