def _delete_nxos_db(self, vlan_id, device_id, host_id, vni, is_provider_vlan): """Delete the nexus database entry. Called during delete precommit port event. """ try: rows = nxos_db.get_nexusvm_bindings(vlan_id, device_id) for row in rows: nxos_db.remove_nexusport_binding(row.port_id, row.vlan_id, row.vni, row.switch_ip, row.instance_id, row.is_provider_vlan) except excep.NexusPortBindingNotFound: return
def _remove_binding_from_db(self, npb): """Removes a port binding from the Nexus database.""" return nexus_db_v2.remove_nexusport_binding( npb.port, npb.vlan, npb.vni, npb.switch, npb.instance, npb.is_provider_vlan)