From 2c59edf33654e4d5d33ceee4f7c24dde46249666 Mon Sep 17 00:00:00 2001 From: Loshmitha Date: Fri, 24 Nov 2017 14:05:49 +0530 Subject: [PATCH] NETVIRT 1029:Route label mismatch for Subnet route For an update of network,BGP was deleting the old network,sleeping for 5 secs and adding a new network to QBGP.But if the same network update came in this 5 secs,it was creating issues.So removing 5 sec delay after checking with QBGP guys Change-Id: I9a4cb8f096b608e84e377eeb301d3bd52519b175 Signed-off-by: Loshmitha --- .../bgpmanager/BgpConfigurationManager.java | 15 +++++---------- 1 file changed, 5 insertions(+), 10 deletions(-) diff --git a/vpnservice/bgpmanager/bgpmanager-impl/src/main/java/org/opendaylight/netvirt/bgpmanager/BgpConfigurationManager.java b/vpnservice/bgpmanager/bgpmanager-impl/src/main/java/org/opendaylight/netvirt/bgpmanager/BgpConfigurationManager.java index d878989f12..d9666288cb 100755 --- a/vpnservice/bgpmanager/bgpmanager-impl/src/main/java/org/opendaylight/netvirt/bgpmanager/BgpConfigurationManager.java +++ b/vpnservice/bgpmanager/bgpmanager-impl/src/main/java/org/opendaylight/netvirt/bgpmanager/BgpConfigurationManager.java @@ -26,7 +26,6 @@ import java.util.List; import java.util.Map; import java.util.Objects; import java.util.Timer; -import java.util.TimerTask; import java.util.concurrent.Callable; import java.util.concurrent.ConcurrentHashMap; import java.util.concurrent.CountDownLatch; @@ -1166,16 +1165,12 @@ public class BgpConfigurationManager { oldval.getRd(), oldval.getPrefixLen(), oldval.getLabel(), oldval.getNexthop()); return; } - LOG.debug("received update networks config val {}", newval.getPrefixLen()); + LOG.debug("update networks old val RD: {}, Prefix: {}, Label: {}, NH: {} " + + "new val RD: {}, Prefix: {}, Label: {}, NH: {}", + oldval.getRd(), oldval.getPrefixLen(), oldval.getLabel(), oldval.getNexthop(), + newval.getRd(), newval.getPrefixLen(), newval.getLabel(), newval.getNexthop()); remove(iid, oldval); - timer.schedule(new TimerTask() { - @Override - public void run() { - if (newval != null) { - add(iid, newval); - } - } - }, Integer.getInteger("bgp.nexthop.update.delay.in.secs", 5) * 1000L); + add(iid, newval); } } -- 2.36.6