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

   ### Task Summary
   Remove unused code from the Scala sources and tests of the Amber engine and 
web server, `workflow-core` and `workflow-operator`, without changing behavior:
   
   - Unused bindings: name the pattern, `catch` and callback bindings that 
nothing reads `_` in `ClusterListener`, `DeadLetterMonitorActor`, `Utils`, 
`SequentialRecordStorage`, the argument parsers of `ComputingUnitMaster` and 
`ComputingUnitWorker`, `WebsocketInput`, `WorkflowWebsocketResource`, 
`AiAssistantManager`, `ExecFactory`, `VirtualIdentityUtils`, `URLFetchUtil`, 
`HtmlVizOpDesc` and `DPThreadSpec`.
   - `S3StorageClient.uploadObject`: read each chunk with a plain `while` loop 
and upload the parts in a loop that adds each `CompletedPart` to the Java list 
the SDK takes, instead of an `Iterator` of `(partNumber, size)` tuples. Copy 
each part out of the reused buffer once instead of twice (`buffer.take` and 
then `RequestBody.fromBytes`).
   - `SQLSourceOpExec.fetchBatchByBoundary`: take the boundary from the type 
`match` as a `val` instead of overwriting a `var` that starts as `null`.
   - Test helpers: drop parameters and defaults that no caller uses 
(`budgetMs`'s default in `DPThreadSpec`, `avatar` in 
`ExternalAuthProvisionerSpec`, `dictionary`'s default in 
`DictionaryMatcherOpExecSpec`, `n`'s default in `HashJoinOpSpec` and 
`IntervalOpExecSpec`), and the thread references `PythonWorkerPool` never reads.
   - Test fixtures: drop `TestOperators.asterixDBSourceOpDesc`, which only its 
own `TestOperatorsSpec` case still builds, and `getCsvScanOpDesc`'s `multiLine` 
parameter, which it never read. Point 
`headerlessSmallMultiLineDataCsvScanOpDesc` and the "infer schema from 
headerless multi-line-data csv" case of `CSVScanSourceOpDescSpec` at 
`country_sales_headerless_small_multi_line.csv`, so the tests named for 
multi-line data read it, and check the scanned rows in that case.
   
   **Introduced by:**
   - Amber engine and web server: #945 (2021-01-05), #1101 (2021-05-03), #1387 
(2022-02-10), #1381 (2022-05-13), #1671 (2022-11-07), #1677 (2022-11-07), #2060 
(2023-07-14), #2529 (2024-03-29), and #2808 (2024-09-02).
   - `workflow-core`: #2271 (2024-01-18), #3183 (2024-12-31), and #4067 
(2025-11-25).
   - `workflow-operator`: #1013 (2021-02-11), #1866 (2023-03-23), and #3186 
(2024-12-31).
   - Tests: #1044 (2021-02-25), #1083 (2021-04-25), #1227 (2021-07-25), #2254 
(2023-12-13), #2302 (2024-02-05), #3425 (2025-05-26), #6077 (2026-07-03), #7055 
(2026-08-10), #7207 (2026-08-14), #7870 (2026-08-23), #9534 (2026-11-19), and 
#9518 (2026-11-21).
   
   **Usage removed by:**
   - AsterixDB fixture: #1118 (2021-05-11, `Disable dependent tests with 
AsterixDB`) commented out its only test use, which #3294 (2025-03-04) deleted; 
#6077 then added a case that builds the fixture alone.
   - Multi-line fixture: #3111 (2024-11-26, `Update amber to depend on sub 
projects`) pointed `headerlessSmallMultiLineDataCsvScanOpDesc` at the 
single-line `country_sales_headerless_small.csv`. The `CSVScanSourceOpDescSpec` 
case has read that single-line file since #1083 added it.
   - `awaitCond`'s default budget: #9534 (2026-11-19, `test(amber): share 
engine and service test fixtures`) routed its last callers through a helper 
that always passes a budget.
   - Everything else: unused since introduction.
   
   This is a cleanup: production behavior does not change, and the two CSV 
tests named for multi-line data read the multi-line file.
   
   ### Task Type
   - [x] Refactor / Cleanup
   


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

  • [I] Remove unused Scala bindin... aglinxinyuan (via GitHub) via notifications

Reply via email to