You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@texera.apache.org by "Yicong-Huang (via GitHub)" <gi...@apache.org> on 2026/04/26 01:55:43 UTC

[PR] fix(amber): emit ExecutionStateUpdate after resume [texera]

Yicong-Huang opened a new pull request, #4515:
URL: https://github.com/apache/texera/pull/4515

   ### What changes were proposed in this PR?
   
   `ResumeHandler.resumeWorkflow` (`ResumeHandler.scala`) finished by sending `ExecutionStatsUpdate` and `RuntimeStatisticsPersist` to the client but never sent `ExecutionStateUpdate`. `PauseHandler.scala:88-90` emits the corresponding state event at the end of pause, so the asymmetry meant clients (and tests) had no event-driven signal for the resume → RUNNING transition.
   
   The aggregated state is already correct on the server side after the per-worker resume futures resolve (each `workerInterface.resumeWorker(...)` returns a `WorkerStateResponse` and `ResumeHandler` updates the internal `WorkerExecution` state with that result, so `cp.workflowExecution.getState` returns `RUNNING`). The fix is to broadcast it:
   
   ```diff
    sendToClient(ExecutionStatsUpdate(stats))
    sendToClient(RuntimeStatisticsPersist(stats))
   +sendToClient(ExecutionStateUpdate(cp.workflowExecution.getState))
   ```
   
   ### Any related issues, documentation, discussions?
   
   Closes #4514
   
   ### How was this PR tested?
   
   `sbt WorkflowExecutionService/compile` succeeds; `scalafmtCheckAll` clean. The two existing consumers of `ExecutionStateUpdate` (`ExecutionStatsService.scala:209` and `ExecutionConsoleService.scala:204`) already handle `WorkflowAggregatedState.Recognized`, so an additional `RUNNING` emit at resume time is a strictly additive event. No existing test asserts the absence of this event. Relying on CI for the full backend test run.
   
   ### Was this PR authored or co-authored using generative AI tooling?
   
   Generated-by: Claude Code (Opus 4.7)


-- 
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: notifications-unsubscribe@texera.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


Re: [PR] fix(amber): emit ExecutionStateUpdate after resume [texera]

Posted by "Yicong-Huang (via GitHub)" <gi...@apache.org>.
Yicong-Huang commented on PR #4515:
URL: https://github.com/apache/texera/pull/4515#issuecomment-4321081602

   Closing — the test motivation for this change can be solved without a new event broadcast: `Await.result(resumeWorkflow)` already blocks until all workers have transitioned to RUNNING (the resumeWorkflow Future completes inside ResumeHandler's `.map` block, after every worker future has resolved with its updated state). Adding a duplicate ExecutionStateUpdate(RUNNING) emit would only mean an extra round-trip on every resume, with no behavior change for existing consumers (web layer already sets RUNNING via `.onSuccess`).


-- 
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: notifications-unsubscribe@texera.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


Re: [PR] fix(amber): emit ExecutionStateUpdate after resume [texera]

Posted by "Yicong-Huang (via GitHub)" <gi...@apache.org>.
Yicong-Huang closed pull request #4515: fix(amber): emit ExecutionStateUpdate after resume
URL: https://github.com/apache/texera/pull/4515


-- 
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: notifications-unsubscribe@texera.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org