Bug 5558 - Closing session after a large RIB is sent kills BGPCEP 41/37141/5
authorMilos Fabian <milfabia@cisco.com>
Tue, 5 Apr 2016 06:21:45 +0000 (08:21 +0200)
committerRobert Varga <nite@hq.sk>
Wed, 13 Apr 2016 08:47:13 +0000 (08:47 +0000)
commit54e12560f5b823a24da39c4f9cbe274fb88f30ca
tree79533e7bfc3f3a12dc8af128070afe0aec869c59
parentd407438261e74b43d0b49f710b4dce89eccee58f
Bug 5558 - Closing session after a large RIB is sent kills BGPCEP

Fixed peer session recovery, in a case of failed transaction chain.
The AdjRibInWriter need working chain when cleaning, also it needs
to be started with fresh transaction chain when session goes up again.
Hence recreate AdjRibInWriter with a new tx chain, when the current
failed.

Fixed duplicated session avoidance. The peer's session should not be
removed from registry if it was not created during this negotiation process.
Otherwise, the active peer's sesion can be removed from registry, which can
later lead to the duplicated session establishment.

Signed-off-by: Milos Fabian <milfabia@cisco.com>
Change-Id: I46ef33d49a11db8465a719af5ba4e1716da14602
bgp/rib-impl/src/main/java/org/opendaylight/protocol/bgp/rib/impl/AbstractBGPSessionNegotiator.java
bgp/rib-impl/src/main/java/org/opendaylight/protocol/bgp/rib/impl/BGPPeer.java