Bartekszost opened a new pull request, #17846: URL: https://github.com/apache/iceberg/pull/17846
## Summary * Add a configurable `rest-scan-planning.poll-num-retries` catalog property that controls the maximum number of poll attempts when waiting for async scan planning results in `RESTTableScan` (default remains 10) * This complements the existing `rest-scan-planning.poll-timeout-ms` property from #15863: the timeout bounds the total wait time, while this property bounds the number of poll retries. Together they let deployments that support **longer-running server-side scan plans** raise both limits so large plans are not cut off prematurely by a fixed retry count * Replace the previously hardcoded `MAX_RETRIES` constant in `RESTTableScan` with the configured value, and validate that the configured value is non-negative * Include the configured retry limit in the `RemotePlanTimeoutException` message so the failure is easier to diagnose ## Test plan * `asyncPlanningRespectsConfigurablePollRetries`: sets a low `poll-num-retries` against a server that never completes and verifies the poll loop stops after exactly the configured number of retries * `asyncPlanningSucceedsWithCustomRetries`: sets an explicit `poll-num-retries` and verifies async planning completes successfully * `asyncPlanningRejectsInvalidRetries`: verifies negative `poll-num-retries` values are rejected with `IllegalArgumentException` --- **AI Disclosure** - Model: Cursor Auto - Platform/Tool: Cursor - Human Oversight: partially reviewed - Prompt Summary: Make the REST scan planning poll retry count configurable via a catalog property, mirroring the existing configurable poll timeout, and add unit tests. -- 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] --------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected]
