Bump upstreams
[bgpcep.git] / bgp / rib-impl / src / main / java / org / opendaylight / protocol / bgp / rib / impl / config / AppPeer.java
index 948512ae2087835e756778c4f541208517fc04c0..48793b6b2d796e3848ffbebbd43ef79929b563f3 100644 (file)
@@ -17,7 +17,7 @@ import com.google.common.util.concurrent.ListenableFuture;
 import java.util.Objects;
 import org.checkerframework.checker.lock.qual.GuardedBy;
 import org.opendaylight.mdsal.common.api.LogicalDatastoreType;
-import org.opendaylight.mdsal.dom.api.DOMDataTreeChangeService;
+import org.opendaylight.mdsal.dom.api.DOMDataBroker.DataTreeChangeExtension;
 import org.opendaylight.mdsal.dom.api.DOMDataTreeIdentifier;
 import org.opendaylight.protocol.bgp.openconfig.spi.BGPTableTypeRegistryConsumer;
 import org.opendaylight.protocol.bgp.rib.impl.ApplicationPeer;
@@ -125,7 +125,7 @@ final class AppPeer extends PeerBean {
 
     private static final class BgpAppPeerSingletonService implements BGPPeerStateProvider {
         private final ApplicationPeer applicationPeer;
-        private final DOMDataTreeChangeService dataTreeChangeService;
+        private final DataTreeChangeExtension dataTreeChangeService;
         private final ApplicationRibId appRibId;
         @GuardedBy("this")
         private boolean isServiceInstantiated;
@@ -139,11 +139,13 @@ final class AppPeer extends PeerBean {
 
         synchronized void instantiateServiceInstance() {
             isServiceInstantiated = true;
-            final YangInstanceIdentifier yangIId = YangInstanceIdentifier.builder().node(APPRIB)
-                    .nodeWithKey(ApplicationRib.QNAME, APP_ID_QNAME, appRibId.getValue())
-                    .node(TABLES_NID).node(TABLES_NID).build();
             applicationPeer.instantiateServiceInstance(dataTreeChangeService,
-                    new DOMDataTreeIdentifier(LogicalDatastoreType.CONFIGURATION, yangIId));
+                DOMDataTreeIdentifier.of(LogicalDatastoreType.CONFIGURATION,  YangInstanceIdentifier.builder()
+                    .node(APPRIB)
+                    .nodeWithKey(ApplicationRib.QNAME, APP_ID_QNAME, appRibId.getValue())
+                    .node(TABLES_NID)
+                    .node(TABLES_NID)
+                    .build()));
         }
 
         synchronized ListenableFuture<?> closeServiceInstance() {