Fixup Augmentable and Identifiable methods changing
[bgpcep.git] / bgp / rib-impl / src / main / java / org / opendaylight / protocol / bgp / rib / impl / config / BgpPeer.java
index a7358453f7c95afc011fe70cb6cee00d6e42ede5..e9df6da34d0d370d76feaecf7f52ab332efbdc90 100644 (file)
@@ -216,7 +216,7 @@ public final class BgpPeer implements PeerBean, BGPPeerStateConsumer {
     }
 
     private final class BgpPeerSingletonService implements BGPPeerStateConsumer {
-        private boolean activeConnection;
+        private final boolean activeConnection;
         private final BGPDispatcher dispatcher;
         private final InetSocketAddress inetAddress;
         private final int retryTimer;
@@ -236,7 +236,7 @@ public final class BgpPeer implements PeerBean, BGPPeerStateConsumer {
             String peerGroupName = null;
             final Config neighborConfig = neighbor.getConfig();
             if (neighborConfig != null) {
-                final NeighborPeerGroupConfig pgConfig = neighborConfig.getAugmentation(NeighborPeerGroupConfig.class);
+                final NeighborPeerGroupConfig pgConfig = neighborConfig.augmentation(NeighborPeerGroupConfig.class);
                 if (pgConfig != null) {
                     peerGroupName = StringUtils.substringBetween(pgConfig.getPeerGroup(), "=\"", "\"");
                     peerGroup = peerGroupLoader.getPeerGroup(bgpIid, peerGroupName);
@@ -268,8 +268,8 @@ public final class BgpPeer implements PeerBean, BGPPeerStateConsumer {
                 neighborLocalAs = globalAs;
             }
 
-            this.bgpPeer = new BGPPeer(this.neighborAddress, peerGroupName, rib, role, clusterId, neighborLocalAs,
-                    BgpPeer.this.rpcRegistry, afiSafisAdvertized, Collections.emptySet());
+            this.bgpPeer = new BGPPeer(tableTypeRegistry, this.neighborAddress, peerGroupName, rib, role, clusterId,
+                    neighborLocalAs, BgpPeer.this.rpcRegistry, afiSafisAdvertized, Collections.emptySet());
             this.prefs = new BGPSessionPreferences(neighborLocalAs, hold, rib.getBgpIdentifier(),
                     neighborRemoteAs, bgpParameters, getPassword(keyMapping));
             this.activeConnection = OpenConfigMappingUtil.isActive(neighbor, peerGroup);