boyuanzz commented on a change in pull request #15062:
URL: https://github.com/apache/beam/pull/15062#discussion_r656665867



##########
File path: 
sdks/java/harness/src/main/java/org/apache/beam/fn/harness/control/ProcessBundleHandler.java
##########
@@ -665,6 +667,11 @@ void release(String bundleDescriptorId, BundleProcessor 
bundleProcessor) {
       }
     }
 
+    /** Discard an active {@link BundleProcessor} instead of being re-used. */
+    void discard(BundleProcessor bundleProcessor) {
+      activeBundleProcessors.remove(bundleProcessor.getInstructionId());

Review comment:
       Do we want to do `bundleProcessor.setInstructionId(null);` before 
discarding it to avoid the same race condition as `reset`?




-- 
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