X-Git-Url: https://osm.etsi.org/gitweb/?p=osm%2Fvim-emu.git;a=blobdiff_plain;f=src%2Femuvim%2Fapi%2Fopenstack%2Fresources%2Fport_chain.py;h=7dcd834239061821d9ca9eb5aaec01d7a016e34d;hp=7c0a2b004a9fe514974f4d911f3ec02e51fadedc;hb=ce776393dccaf31ad47f21b06dcf0a2ba56b4874;hpb=64d1436431fbf61e21bd4cc40ad015e32dbac560 diff --git a/src/emuvim/api/openstack/resources/port_chain.py b/src/emuvim/api/openstack/resources/port_chain.py index 7c0a2b0..7dcd834 100644 --- a/src/emuvim/api/openstack/resources/port_chain.py +++ b/src/emuvim/api/openstack/resources/port_chain.py @@ -76,15 +76,12 @@ class PortChain(object): if port_pair.egress.name in server.port_names or port_pair.egress.id in server.port_names: server_egress = server - # TODO: Not sure, if this should throw an error if not server_ingress: - logging.warn("Neutron SFC: ingress port %s not connected." % str( - port_pair.ingress.name)) - continue + raise RuntimeError("Neutron SFC: ingress port %s not connected to any server." % + port_pair.ingress.name) if not server_egress: - logging.warn("Neutron SFC: egress port %s not connected." % str( - port_pair.egress.name)) - continue + raise RuntimeError("Neutron SFC: egress port %s not connected to any server." % + port_pair.egress.name) compute.dc.net.setChain( server_ingress.name, server_egress.name,