Github user lw-lin commented on the pull request: https://github.com/apache/spark/pull/12681#issuecomment-214601397 Actually this wouldn't cause any problem and wouldn't fail any test suits **_for now_**, because the read of `acquiredButNotUsed` is guaranteed to see most recent value due to the existing `synchronized(this) {consumers...}` block before the read of `acquiredButNotUsed`. It is kind of ["Piggybacking" on synchronization](http://www.javamex.com/tutorials/synchronization_piggyback.shtml) -- but let's not rely on this because it's vulnerable to future code changes? :-)
--- If your project is set up for it, you can reply to this email and have your reply appear on GitHub as well. If your project does not have this feature enabled and wishes so, or if the feature is enabled but not working, please contact infrastructure at infrastruct...@apache.org or file a JIRA ticket with INFRA. --- --------------------------------------------------------------------- To unsubscribe, e-mail: reviews-unsubscr...@spark.apache.org For additional commands, e-mail: reviews-h...@spark.apache.org