Bug 7170: ARP thread is sleeping 2s 23/48723/9
authorOlga Schukin <olga.schukin@hpe.com>
Sun, 27 Nov 2016 10:01:35 +0000 (12:01 +0200)
committerSam Hague <shague@redhat.com>
Fri, 2 Dec 2016 21:22:53 +0000 (21:22 +0000)
commit34e218c9fb274709f7a8d1b4974606e506a69567
tree104382845e404387ec1a6cfadd91225d59fba999
parent2e146e0ae956734773a926c9f16812008899400d
Bug 7170: ARP thread is sleeping 2s

ARP thread is sleeping 2s each time MAC migration occurs

1. Koby: every time a MAC migration occurs (i.e. ArpNotificationHandler
notices a MAC change), instead of removing the entry & sleeping for 2s,
it will remove the entry & add that "VPNInstance+IP" to a "dirty IPs"
hashmap with timestamp. Now, each time ArpNotificationHandler is about
to learn a new IP, it will compare against that "dirty IPs" hashmap
and will ignore the learn in case 2s hasn't passed yet.
This will make sure the notification thread is not blocked.

2. Learn from GARP and ARP Responses only.

Change-Id: Ic3d6f58bd1a8ff5b9e29abd9280c3954fd7c7fb3
Signed-off-by: Olga Schukin <olga.schukin@hpe.com>
vpnservice/vpnmanager/vpnmanager-impl/src/main/java/org/opendaylight/netvirt/vpnmanager/ArpNotificationHandler.java
vpnservice/vpnmanager/vpnmanager-impl/src/main/resources/org/opendaylight/blueprint/vpnmanager.xml
vpnservice/vpnmanager/vpnmanager-impl/src/main/yang/vpnmanager-config.yang [new file with mode: 0644]