Comment 16 for bug 1731834

Revision history for this message
OpenContrail Admin (ci-admin-f) wrote : A change has been merged

Reviewed: https://review.opencontrail.org/37449
Committed: http://github.com/Juniper/contrail-controller/commit/51f07ac6b602fd8276c636cdad4d5e31d508b4f9
Submitter: Zuul (<email address hidden>)
Branch: R4.1

commit 51f07ac6b602fd8276c636cdad4d5e31d508b4f9
Author: Ananth Suryanarayana <email address hidden>
Date: Sun Nov 12 22:23:30 2017 -0800

Swap XmppConnections correctly during XMPP Graceful Restart

During XMPP GR, Old and Newly formed XmppConnection objects are swapped in
order to retain some critical data structures as is. There are two issues here.

1. During the swap, all related members to the new session must also be swapped,
such as endpoints, proto_stats, disable_read_, etc. endpoint is also the key
inside XmppServer::connection_map_. Hence this map also needs to be updated,
when the endpoints are swapped. During this update, the map is protected using
a lock because multiple XmppState machine data structures can run and hence
update the map concurrently.

2. In the state machine, after connections are swapped, updated connection must
be used for further processing, such as to trigger keep-alive timer

o Add specific checks in GR tests to make sure that KeepAlive and HoldTImers are
always running in established session
o Run all GR tests with xmpp authentication enabled as well.
o Split GR test cases into separate tests so that they can be run in parallel
and also because each of them now gets a longer time to complete

3. Partly stablize GR tests by removing some of the outdated code in mock agent.
We should task_util::TaskFire() routines to safely access data structures
instead of using a separate work queue, conditional variable etc.

Change-Id: I5aab8b175c33870d8991058d79e4fe7dd5b72170
Closes-Bug: 1731834
Closes-Bug: 1732267