X-Git-Url: https://git.opendaylight.org/gerrit/gitweb?a=blobdiff_plain;f=opendaylight%2Fmd-sal%2Ftopology-manager%2Fsrc%2Fmain%2Fjava%2Forg%2Fopendaylight%2Fmd%2Fcontroller%2Ftopology%2Fmanager%2FFlowCapableTopologyExporter.java;h=542e972deb2d7585348876219b5f82dab6ceca14;hb=478ce1fa1dc30974b7cf23fd5258f1af5366d547;hp=f4685d2bd918b7a3aa0653e6ed809e010662abc9;hpb=bba161ea7fb714c9d21abac4c13a0ae2975810e8;p=controller.git
diff --git a/opendaylight/md-sal/topology-manager/src/main/java/org/opendaylight/md/controller/topology/manager/FlowCapableTopologyExporter.java b/opendaylight/md-sal/topology-manager/src/main/java/org/opendaylight/md/controller/topology/manager/FlowCapableTopologyExporter.java
index f4685d2bd9..542e972deb 100644
--- a/opendaylight/md-sal/topology-manager/src/main/java/org/opendaylight/md/controller/topology/manager/FlowCapableTopologyExporter.java
+++ b/opendaylight/md-sal/topology-manager/src/main/java/org/opendaylight/md/controller/topology/manager/FlowCapableTopologyExporter.java
@@ -193,8 +193,7 @@ class FlowCapableTopologyExporter implements //
}
for (Link link : topologyData.getLink()) {
if (id.equals(link.getSource().getSourceNode()) || id.equals(link.getDestination().getDestNode())) {
- InstanceIdentifier path = InstanceIdentifier.builder(topologyPath)
- .child(Link.class, link.getKey()).build();
+ InstanceIdentifier path = topologyPath.child(Link.class, link.getKey());
transaction.removeOperationalData(path);
}
}
@@ -208,8 +207,7 @@ class FlowCapableTopologyExporter implements //
}
for (Link link : topologyData.getLink()) {
if (id.equals(link.getSource().getSourceTp()) || id.equals(link.getDestination().getDestTp())) {
- InstanceIdentifier path = InstanceIdentifier.builder(topologyPath)
- .child(Link.class, link.getKey()).build();
+ InstanceIdentifier path = topologyPath.child(Link.class, link.getKey());
transaction.removeOperationalData(path);
}
}
@@ -233,20 +231,20 @@ class FlowCapableTopologyExporter implements //
.child(Topology.class, topology).child(Link.class, link.getKey()).build();
return linkInstanceId;
}
-
+
/**
* @param txId transaction identificator
* @param future transaction result
*/
private static void listenOnTransactionState(final Object txId, Future> future) {
Futures.addCallback(JdkFutureAdapters.listenInPoolThread(future),new FutureCallback>() {
-
+
@Override
public void onFailure(Throwable t) {
LOG.error("Topology export failed for Tx:{}", txId, t);
-
+
}
-
+
@Override
public void onSuccess(RpcResult result) {
if(!result.isSuccessful()) {