self._extend_port_dict_profile(context, port)
return port
- def delete_port(self, context, id):
+ def delete_port(self, context, id, l3_port_check=True):
"""
Delete a port.
:param id: UUID representing the port to delete
:returns: deleted port object
"""
+ # if needed, check to see if this is a port owned by
+ # and l3-router. If so, we should prevent deletion.
+ if l3_port_check:
+ self.prevent_l3_port_deletion(context, id)
+ self.disassociate_floatingips(context, id)
self._send_delete_port_request(context, id)
return super(N1kvNeutronPluginV2, self).delete_port(context, id)