The GitHub Actions job "Required Checks" on texera.git/main has failed. Run started by GitHub user github-merge-queue[bot] (triggered by github-merge-queue[bot]).
Head commit for run: 0aea3df361dff4d4406be9f47d36747233ff9e1d / Meng Wang <[email protected]> feat(result-service): add a service that reads results (#9356) ### What changes were proposed in this PR? Adds `result-service`, a Dropwizard service that reads execution results without a computing unit. It stands in front of Lakekeeper the way `file-service` stands in front of LakeFS. This PR is the module and its CI legs, so nothing calls it yet: its image, Helm chart, gateway route and local-dev entry follow in a second PR, and #8996 moves the frontend over. **Before**: a result page is read through the computing unit, so a result cannot be read once its unit is gone. ```mermaid flowchart TB browser(["Browser"]) gateway["Gateway"] cu["Computing unit<br/>engine + Iceberg client"] lakekeeper["Lakekeeper<br/>Iceberg catalog"] postgres[("Postgres")] s3[("S3 storage")] browser -->|"read a result page"| gateway gateway -->|"websocket"| cu cu -->|"table location"| lakekeeper cu -->|"Parquet files"| s3 lakekeeper -->|"metadata"| postgres ``` **After** (with the deployment PR and #8996): pages are read through result-service, which needs no unit. The unit still writes results and, while an execution runs, tells the browser which pages changed. Red marks what is new. ```mermaid flowchart TB browser(["Browser"]) gateway["Gateway"] rs["result-service<br/>access check<br/>Iceberg client"] cu["Computing unit<br/>engine"] lakekeeper["Lakekeeper<br/>Iceberg catalog"] postgres[("Postgres")] s3[("S3 storage")] browser -->|"read a result page"| gateway gateway -->|"HTTP"| rs gateway -.->|"websocket: which pages changed"| cu rs -->|"table location"| lakekeeper rs -->|"Parquet files"| s3 cu -.->|"writes results"| s3 lakekeeper -->|"metadata"| postgres classDef added stroke:#cf222e,stroke-width:2px class rs added ``` | Endpoint | Returns | |---|---| | `GET /api/results/workflows/{wid}/latest-execution` | The caller's own latest finished execution | | `GET /api/results/executions/{eid}` | Each result of an execution: operator, port, output mode and row count, from the database alone | | `GET /api/results/executions/{eid}/operators/{operatorId}/pages` | One page, with the existing column offset, limit and search; `port` defaults to 0, and a visualization's content is sent whole | | `GET /api/results/executions/{eid}/operators/{operatorId}/statistics` | Per-column statistics; `port` defaults to 0 | Two choices go beyond the issue. A read needs the caller to have started the execution, or to have access to the computing unit it ran on, the boundary these results sit behind today. Access to the workflow is not enough, public or granted, since a run reads datasets with the access of the user who started it. And `pageSize` is capped at 1000, because a page is read into memory in a service everyone shares. `TerminalWorkflowExecutionStatus` moves from computing-unit-managing-service to WorkflowCore, so both services read one definition of an ended execution. Three follow-ups promised on #9219 ride along: `getResultUriByLogicalPortId` skips rows with no URI, and two Scaladoc comments are corrected. About 2,900 of the added lines are `result-service/LICENSE-binary` and `NOTICE-binary`, which the other platform services carry too and CI checks against the dist. The code to review is mostly `ResultResource.scala` and its spec. ### Any related issues, documentation, discussions? Part of #8995, which the deployment PR will close. Part of #5363. ### How was this PR tested? - `ResultResourceSpec` sends requests through the production Jersey and JWT stack against an embedded database and real Iceberg tables in a local Hadoop catalog, the way WorkflowCore's storage specs do. It covers the read rule on every endpoint, paging, column search, rows appended between reads and each error code. - 44 deliberate defects, such as a removed access check or an off-by-one page, each turned a test red. - Before the review changes, which left table reading alone, ran the packaged service against local Lakekeeper and RustFS on tables seeded through `DocumentFactory`: every endpoint, a result in a per-user warehouse, and rows appended while it stayed up. - `smoke-boot.sh` passes on the dist, `check_binary_deps.py` passes for its 311 jars, and `NOTICE-binary` is the generator's output. - `Auth/test`, `WorkflowCore/test`, `ResultService/test` and `ComputingUnitManagingService/test` pass, amber still compiles, and `scalafmtCheck` and `scalafix --check` pass for those modules. ### Was this PR authored or co-authored using generative AI tooling? Generated-by: Claude Code (claude-opus-5-5) Report URL: https://github.com/apache/texera/actions/runs/44456128160 With regards, GitHub Actions via GitBox
