aglinxinyuan opened a new issue, #5711:
URL: https://github.com/apache/texera/issues/5711

   ### Feature Summary
   
   Several amber e2e specs repeat the same boilerplate: build a workflow, start 
it, await `COMPLETED` (handling `FatalError`), then resolve each terminal 
operator's external RESULT document via iceberg and read its tuples. Each spec 
carries its own copy of this run-and-read block, so the pattern drifts between 
specs and every new e2e spec re-implements it.
   
   ### Proposed Solution or Design
   
   Add two reusable, loop/state-agnostic helpers to `TestUtils`:
   
   - `readMaterializedResults(executionId, operatorIds, extract)` — resolve and 
open each operator's external RESULT document, applying `extract` to the opened 
`VirtualDocument[Tuple]` (operators with no materialized output are omitted).
   - `runWorkflowAndReadResults(system, workflow, operatorIds, extract, 
completionTimeout)` — run a workflow to `COMPLETED` (surfacing a `FatalError` 
as the awaited exception), then read the requested operators' results via 
`readMaterializedResults`.
   
   Refactor `DataProcessingSpec.executeWorkflow` to call the shared harness 
instead of its inline copy. The helpers only use existing core APIs 
(`DocumentFactory`, `VirtualDocument[Tuple]`, `AmberClient`, 
`ExecutionStateUpdate`, `FatalError`), so other e2e specs (and upcoming ones) 
can adopt them too.
   
   ### Affected Area
   
   - Workflow Engine (Amber)


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