[RFE] Allow bulk-tagging of resources

Bug #1815933 reported by Michal Dulko on 2019-02-14
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
neutron
Wishlist
Miguel Lavalle

Bug Description

We have a use case to tag all Neutron resources created by Kuryr-Kubernetes, as Kubernetes clusters that Kuryr serves may come and go and it should be possible to easily identify all the leftovers for garbage collection purpose. As adding a tag is a distinct API call that should be done after initial POST, it's a bit painful, but in most cases manageable.

We, however, also use bulk port creation to create and keep some ports ready in what we call "port pools". In case of bulk creation we need 1+n calls to Neutron API to create and tag n ports. This is ridiculously inefficient.

Allowing bulk-tagging, either when doing bulk request itself, or by a distinct call that accepts list of ID's would be very useful for us.

Changed in neutron:
importance: Undecided → Wishlist
Miguel Lavalle (minsel) on 2019-02-15
tags: added: rfe-triaged
removed: rfe
Miguel Lavalle (minsel) wrote :

Per discussion during the drivers meeting, we think the best approach would be to tag the ports during creation. However, the OpenStack community guidelines for tagging (https://specs.openstack.org/openstack/api-wg/guidelines/tags.html) don't support that. We will start a conversation in the mailing list with the SIG API to propose supporting adding tags on creation

Miguel Lavalle (minsel) wrote :

This RFE has been discussed by Neutron drivers team and it has been approved. The suggested approach is to support tag association during POST and then leverage bulk creation of resources, like it is being done for ports

tags: added: rfe-approved
removed: rfe-triaged
Changed in neutron:
milestone: none → ussuri-1
status: New → Triaged
Changed in neutron:
milestone: ussuri-1 → none
Miguel Lavalle (minsel) on 2019-12-16
Changed in neutron:
assignee: nobody → Miguel Lavalle (minsel)
Miguel Lavalle (minsel) wrote :

This is how we are going to specify the tags to be attached to each port in the bulk POST request (as discussed in this ML thread: http://lists.openstack.org/pipermail/openstack-discuss/2019-February/003116.html):

 {'port':
    {'name': 'foo',
     'network_id': <network-id>,
     'tags': ['red', 'blue']
     }
  }

Changed in neutron:
milestone: none → ussuri-2

Reviewed: https://review.opendev.org/700754
Committed: https://git.openstack.org/cgit/openstack/neutron-lib/commit/?id=8673f033196771ef907314f823ca23ef9360134d
Submitter: Zuul
Branch: master

commit 8673f033196771ef907314f823ca23ef9360134d
Author: Miguel Lavalle <email address hidden>
Date: Sun Dec 29 18:48:48 2019 -0600

    Extension for tagging ports during bulk creation

    Define a shim API extension to support the tagging of ports during bulk
    creation.

    Change-Id: I69904a235121876a14dbb3e4cf1beac614dcd5e9
    Related-Bug: #1815933

Changed in neutron:
status: Triaged → In Progress

Reviewed: https://review.opendev.org/700755
Committed: https://git.openstack.org/cgit/openstack/neutron/commit/?id=e22a191f47fe0d1a05cd707a0ad6a1ca637f69d1
Submitter: Zuul
Branch: master

commit e22a191f47fe0d1a05cd707a0ad6a1ca637f69d1
Author: Miguel Lavalle <email address hidden>
Date: Sun Dec 29 19:48:14 2019 -0600

    Implement tagging during bulk port creation

    This change proposes a ML2 plugin extension to implement tagging during
    bulk port creation.

    Change-Id: Ic70f7d282db478c69016ab1c317c5cae786401ce
    Related-Bug: #1815933

Changed in neutron:
milestone: ussuri-2 → ussuri-3
To post a comment you must log in.
This report contains Public information  Edit
Everyone can see this information.

Other bug subscribers