The GitHub Actions job "Required Checks" on texera.git/backport/6280-include-coverimage-in-search-and-list-ap-v1.2 has failed. Run started by GitHub user Yicong-Huang (triggered by Yicong-Huang).
Head commit for run: 296ff6761b7903d2b328acf78169e8bb695c5661 / Martin Vu <[email protected]> fix(workflow): include coverImage in search and list API responses (#6280) ### What changes were proposed in this PR? Include workflow cover image data in the dashboard search response to prevent the frontend from needing additional requests to fetch cover images. This PR fixes the N+1 query issue where each workflow card was making a separate GET /workflow/{wid}/cover request to fetch its cover image. Before: · The frontend loads the workflow list (1 request) · Each card calls workflowCoverService.getCover() individually (N requests) · Total: 1 + N requests for N workflows <img width="1221" height="432" alt="Screenshot 2026-07-10 at 12 37 25 AM" src="https://github.com/user-attachments/assets/cf747ba8-5fd8-485c-8a26-52a27a476204" /> <img width="1221" height="622" alt="Screenshot 2026-07-10 at 12 37 41 AM" src="https://github.com/user-attachments/assets/43a9852f-b308-4729-8449-1cfc1d859769" /> After: · /dashboard/search and workflow responses now include the coverImage field in the response · Each card uses the bundled data directly · Total: 1 request <img width="1221" height="454" alt="Screenshot 2026-07-10 at 1 28 12 AM" src="https://github.com/user-attachments/assets/1b71a087-8b4e-4f26-b9c6-8960af2b1199" /> <img width="2442" height="1232" alt="image" src="https://github.com/user-attachments/assets/ee55371e-38dd-40ec-8af6-5199afef9651" /> <img width="2442" height="1232" alt="image" src="https://github.com/user-attachments/assets/17ef276c-f000-4180-815e-152f838b3353" /> Changes made: 1. Added coverImage field to DashboardWorkflow case class 2. Modified baseWorkflowSelect() to left join WORKFLOW_COVER_IMAGE and select max(WORKFLOW_COVER_IMAGE.IMAGE).as("cover_image") 3. Updated WorkflowSearchQueryBuilder to include coverImage in search results 4. Updated frontend DashboardEntry and DashboardWorkflow interfaces to include coverImage data and use it directly in card rendering 5. Replaced per-card getCover() calls with direct coverImage usage in card-item.component.ts ### Any related issues, documentation, discussions? Closes #5920 Follow-up to #5704 ### How was this PR tested? Manual Testing: · Verified coverImage field appears in search responses · Uploaded a test cover image via API and confirmed it appears in search response Automated Tests: · Added a test case to verify workflow cover images are included in search results. Tested with: sbt "project WorkflowExecutionService" "testOnly *WorkflowResourceSpec -- -z \"include workflow cover image in search results\"" ### Was this PR authored or co-authored using generative AI tooling? Co-authored with ChatGPT 5.5-mini (backported from commit ff82fd82fd7229b7ea27a683af41454eebd74985) Report URL: https://github.com/apache/texera/actions/runs/30512248283 With regards, GitHub Actions via GitBox
