- for (Subnets sub : tZone.getSubnets()) {
- if (sub.getDeviceVteps() != null && !sub.getDeviceVteps().isEmpty()) {
- for (DeviceVteps hwVtepDS : sub.getDeviceVteps()) {
- logger.trace("hwtepDS exists {}", hwVtepDS);
- //do i need to check node-id?
- //for mlag case and non-m-lag case, isnt it enough to just check ipaddress?
- if (hwVtepDS.getIpAddress().equals(hwTep.getHwIp()))
- continue;//dont delete tunnels with self
- //TOR-TOR
- logger.trace("deleting tor-tor {} and {}", hwTep, hwVtepDS);
- deleteTrunksTORTOR(dataBroker, idManagerService, hwTep.getTopo_id(), hwTep.getNode_id(),
- hwTep.getHwIp(), hwVtepDS.getTopologyId(), hwVtepDS.getNodeId(),
- hwVtepDS.getIpAddress(), tZone.getTunnelType(),
- t, futures);
+ for (Subnets sub : originalTZone.getSubnets()) {
+ if (sub.getDeviceVteps() != null && !sub.getDeviceVteps().isEmpty()) {
+ for (DeviceVteps hwVtepDS : sub.getDeviceVteps()) {
+ logger.trace("hwtepDS exists {}", hwVtepDS);
+ //do i need to check node-id?
+ //for mlag case and non-m-lag case, isnt it enough to just check ipaddress?
+ if (hwVtepDS.getIpAddress().equals(hwTep.getHwIp()))
+ continue;//dont delete tunnels with self
+ //TOR-TOR
+ logger.trace("deleting tor-tor {} and {}", hwTep, hwVtepDS);
+ deleteTrunksTORTOR(dataBroker, idManagerService, hwTep.getTopo_id(), hwTep.getNode_id(),
+ hwTep.getHwIp(), hwVtepDS.getTopologyId(), hwVtepDS.getNodeId(),
+ hwVtepDS.getIpAddress(), originalTZone.getTunnelType(),
+ t, futures);