Rebalance checkConnected() 23/323/4
authorRobert Varga <nite@hq.sk>
Sun, 14 Feb 2016 01:10:18 +0000 (02:10 +0100)
committerGerrit Code Review <gerrit@fd.io>
Fri, 19 Feb 2016 21:02:59 +0000 (21:02 +0000)
commite1cfcbcda62a94caffc3cf2a40f3440d3752f9d9
treed70e953694948b12afd0e22a302407b64d7fb5a2
parent9b7057fe36d00adc136b4f41c699041c1591635d
Rebalance checkConnected()

AtomicBoolean forces the enclosed boolean to be cache-aligned,
needlessly hitting a cacheline. Since we only flip state only once,
when the connection is severed, we can turn this into a volatile
boolean.

Doing that is costing us a synchronized close(), but that is perfectly
acceptable, as that is called only once.

Change-Id: I76fda3d3f65a5f800e7d3970b0b8fe99fb3e8b6d
Signed-off-by: Robert Varga <nite@hq.sk>
vpp-japi/japi/org/openvpp/vppjapi/vppConn.java