hjtran opened a new pull request, #38136:
URL: https://github.com/apache/beam/pull/38136

   ## Summary
   
   - Initialize `consuming_received_data` to `True` at the start of 
`process_bundle`, so runners polling `ProcessBundleProgress` can distinguish 
"still setting up / actively processing" from "idle and caught up with all 
received data."
   - Previously both setup and idle reported `False`, making them 
indistinguishable.
   - After setup completes, the flag is set to `False` before entering the data 
processing loop.
   
   ## Motivation
   
   After sending a `ProcessBundleRequest` and data, a runner polling progress 
sees `consuming_received_data=False` in two cases: the worker hasn't started 
processing yet (still in setup), or it has finished processing everything sent. 
This change makes `False` unambiguously mean "caught up."
   
   ## Test plan
   
   - [x] `bundle_processor_test.py` — 20 tests passed
   - [x] `sdk_worker_test.py` — 12 tests passed
   
   ---
   *Generated by Claude in a [Cork](https://github.com/schrodinger/cork) 
session*
   - Session: `lax-dry-ivy_APR092009`
   - Host: `corkbuilder`
   - Cork: `v1.1.1`


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

To unsubscribe, e-mail: [email protected]

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

Reply via email to