[RFE] Add should_bind_property to NetworkInterface

Bug #1662446 reported by Vasyl Saienko
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Ironic
Won't Fix
Wishlist
Vasyl Saienko

Bug Description

We have a places where we rely on node.network_interface name field to do some things like check port information or add binding:host_id.

https://github.com/openstack/ironic/blob/b9a792af9f90dcaa33896a82a4183ad403155591/ironic/common/neutron.py#L198

This approach won't work with out of tree network drivers. We should have an @abstractproperty instead.

Tags: rfe
Changed in ironic:
assignee: nobody → Vasyl Saienko (vsaienko)
status: New → In Progress
Vladyslav Drok (vdrok)
summary: - [RFE] Add should_bing_property to NetworkInterface
+ [RFE] Add should_bind_property to NetworkInterface
Dmitry Tantsur (divius)
Changed in ironic:
importance: Undecided → Wishlist
tags: added: rfe
Revision history for this message
Ruby Loo (rloo) wrote :

We discussed this in the ironic meeting today [1].

It doesn't need a spec.

Dmitry sez no @abstractproperty because it isn't backward compatible.

Jim suggested a method (I think, you might want to read the log), but either a property or method is fine.

I'm fine with either; depends on the use case since you only had a link to one example of 'bad' code. However, whatever you decide, I'd like a better description of it, what it will default to be in the/a base class, what its value is (I know, it is a flag, but let's just be explicit and say Boolean blah blah). Basically, similar to the docstring associated with this new thing.

[1] starting at 17:47:47, http://eavesdrop.openstack.org/meetings/ironic/2017/ironic.2017-02-13-17.00.log.html

Revision history for this message
Sam Betts (sambetts) wrote :

I personally think that we shouldn't be doing anything different with the host_id based on the driver, we should be interacting with Neutron in the same way for all Neutron based drivers. I think the solution to this problem is to create the neutron ml2 driver for auto binding statically configured (flat) baremetal switch ports.

Revision history for this message
Vasyl Saienko (vsaienko) wrote :

@Sam: yeah it is the best option as for me too, Neutron team don't want to keep the code in Neutron tree [0], I agree with them.

Might be it is time to think about networking-baremetal or networking-ironic repo?

[0] https://review.openstack.org/#/c/339129/

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Change abandoned on ironic (master)

Change abandoned by Vasyl Saienko (<email address hidden>) on branch: master
Review: https://review.openstack.org/429893
Reason: https://review.openstack.org/#/c/448073

Revision history for this message
Vasyl Saienko (vsaienko) wrote :

we have networking-baremetal repo now, it will be fixed there https://review.openstack.org/#/c/448073

Changed in ironic:
status: In Progress → Won't Fix
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.