kennknowles commented on a change in pull request #13861:
URL: https://github.com/apache/beam/pull/13861#discussion_r571311858



##########
File path: 
runners/core-java/src/main/java/org/apache/beam/runners/core/metrics/ExecutionStateSampler.java
##########
@@ -151,8 +150,10 @@ void addTracker(ExecutionStateTracker tracker) {
    *
    * <p>This method needs to be synchronized to prevent race condition with 
sampling thread
    */
-  synchronized void removeTracker(ExecutionStateTracker tracker) {
-    this.activeTrackers.remove(tracker);
+  void removeTracker(ExecutionStateTracker tracker) {
+    synchronized (this) {

Review comment:
       Update javadoc to match code, as needed. Or just remove commentary if 
not relevant.




----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
[email protected]


Reply via email to