Not generating extra-route config fault alarm 05/81305/2
authoreswanit <swati.udhavrao.niture@ericsson.com>
Fri, 29 Mar 2019 03:36:26 +0000 (09:06 +0530)
committerStephen Kitt <skitt@redhat.com>
Tue, 2 Apr 2019 07:42:27 +0000 (07:42 +0000)
Number of nexthops are not calculated properly
(were being calculated x-1 always) because of
wrong initial value resulting in alarm not getting
generated for the check when number of RDs are
less than number of nexthops.

Change-Id: Ie6875c95c42ab285fde765bae50b8f0e62a604a4
Signed-off-by: eswanit <swati.udhavrao.niture@ericsson.com>
neutronvpn/impl/src/main/java/org/opendaylight/netvirt/neutronvpn/NeutronvpnManager.java

index a6896eaf8630d3f5550b492f003ed9468b263bed..be51f48945fbe310d5bfcdca04c5b64068a83514 100644 (file)
@@ -2140,7 +2140,7 @@ public class NeutronvpnManager implements NeutronvpnService, AutoCloseable, Even
             String nextHop = route.getNexthop().stringValue();
             List<String> nextHopList = new ArrayList<>();
             nextHopList.add(nextHop);
-            int nbNextHops = 0;
+            int nbNextHops = 1;
             for (Routes routeTmp : routeList) {
                 String routeDest = routeTmp.getDestination().stringValue();
                 if (!destination.equals(routeDest)) {