Determine the optimal locking order for NQE APIs in Cronet |
|||||
Issue descriptionCronetUrlRequestContext.java currently uses nested locks: First it acquires mNetworkQualityLock followed by mLock, and later it releases both locks at the same time. It is not clear why the NQE APIs need nested locks. A faster approach is to first acquire mLock, check if a valid adapter is present, release mLock. Next, acquire and release the mNetworkQualityLock. This nested lock pattern was first added in https://codereview.chromium.org/2283243002/diff/120001/components/cronet/android/java/src/org/chromium/net/impl/CronetUrlRequestContext.java. So, CC'ing clm@ who might have more insights.
,
Oct 21 2016
mLock was removed from NQE APIs in https://codereview.chromium.org/2439833002/. Marking as WontFix.
,
Oct 21 2016
,
Feb 13 2017
,
Feb 14 2017
|
|||||
►
Sign in to add a comment |
|||||
Comment 1 by clm@google.com
, Oct 18 2016