BUG-5280: fix race proxy creation and reconnect 05/49705/2
authorRobert Varga <rovarga@cisco.com>
Wed, 21 Dec 2016 15:11:09 +0000 (16:11 +0100)
committerRobert Varga <rovarga@cisco.com>
Wed, 21 Dec 2016 15:19:23 +0000 (16:19 +0100)
ProxyHistory map insertions have to happen-before or
happen-after the reconnect attempt. This is mostly take care
of by client's inversible lock, except for the race window
when the connection lookup succeeds and the history map
is updated.

Resolve this by introducing a StampedLock, which is used
to establish order of these operations, covering the entire
createHistoryProxy() method.

Change-Id: Ibdee739c94f3a48bef3f7fb19cd2f041c0061fe2
Signed-off-by: Robert Varga <rovarga@cisco.com>

No differences found