Bug 7091 : When Primary NAPT switch goes down, NAPT switch re-election is 92/48092/1
authorSatish Dutt <satishd@altencalsoftlabs.com>
Fri, 4 Nov 2016 15:20:39 +0000 (20:50 +0530)
committerSam Hague <shague@redhat.com>
Mon, 7 Nov 2016 22:53:58 +0000 (22:53 +0000)
commit38b5e7d0a0a921d7041906020ab9d7d68d96caa0
tree2719d8a08c209db1fd1df2e4b6a64f57fdc017fe
parentc2648d5c94e8148e8b1be333ec8a4fcfc7343596
Bug 7091 : When Primary NAPT switch goes down, NAPT switch re-election is
not happening.

The root cause of this issue was the change in the representation of the
ietf-interfaces:interfaces-state model.

Since NAT models depends upon the ietf-interfaces:interfaces-state model,
NAT HA functionality of re-electing the NAPT switch never got triggered
and the functionality got broken. As per the new representation of the
'ietf-interfaces:interfaces-state' model, 'oper-status' attribute value is
'unknown' if the corressponding DPN goes down.

update() of the NatInterfaceStateChangeListner is implemented to handle this change for
clearing or populating the 'dpn-vpninterfaces-list' in the NAT model
'odl-l3vpn:neutron-router-dpns' used by the NAT HA code.

Change-Id: I533c9c1c5d32ab5967cd21e7b0f203978b074703
Signed-off-by: Satish Dutt <satishd@altencalsoftlabs.com>
vpnservice/natservice/natservice-impl/src/main/java/org/opendaylight/netvirt/natservice/internal/NatInterfaceStateChangeListener.java
vpnservice/natservice/natservice-impl/src/main/java/org/opendaylight/netvirt/natservice/internal/NatUtil.java
vpnservice/vpnmanager/vpnmanager-impl/src/main/java/org/opendaylight/netvirt/vpnmanager/InterfaceStateChangeListener.java