Comment 13 for bug 1613553

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

Reviewed: https://review.opencontrail.org/23513
Committed: http://github.org/Juniper/contrail-controller/commit/390bc9f56f86f13f7e7c54a0cfddfb276ac8f245
Submitter: Zuul
Branch: R3.1

commit 390bc9f56f86f13f7e7c54a0cfddfb276ac8f245
Author: Prabhjot Singh Sethi <email address hidden>
Date: Sat Aug 20 00:08:14 2016 +0530

Fix Vrouter Agent crash @ update flow handle

Issue:
------
Even though Hash id is part of the key for ksync flow
entry, we do allow change of hash id to -1 when other
ksync entry for the same flow ends up receiving same
flow handle to handle two entries with same key.
however if there was a pending response(Add/Change Ack)
from vrouter we will end up processing the ack as a
index allocation from value -1 to flow handle for
delete ksync entry. This can end up acquiring the
index from the active entry and cause invalid state
for ksync flow entry, resulting in crash.

Fix:
----
Save the last vrouter hash id (hash id used while
sending message to vrouter) and compare the ack/response
against this hash id to evaluate if response has a new
index allocation.

Closes-Bug: 1613553
Change-Id: I21a12fbd5684de871eabf5cd6dd1568c0a9d6c52
(cherry picked from commit 2a743d785986f7c276927b59749c1acb28534c70)