rahil-c commented on code in PR #9695:
URL: https://github.com/apache/iceberg/pull/9695#discussion_r1733326978
##########
open-api/rest-catalog-open-api.yaml:
##########
@@ -541,6 +541,216 @@ paths:
5XX:
$ref: '#/components/responses/ServerErrorResponse'
+ /v1/{prefix}/namespaces/{namespace}/tables/{table}/plan:
+ parameters:
+ - $ref: '#/components/parameters/prefix'
+ - $ref: '#/components/parameters/namespace'
+ - $ref: '#/components/parameters/table'
+ post:
+ tags:
+ - Catalog API
+ summary: Returns either a list of `PlanTask`, a list of `FileScanTask`.
If planning is not complete returns a `plan-id`.
+ description:
+ Prepares either a list of `PlanTask` that can be used to distribute
table scan planning, or a list of `FileScanTask`, based on a set of table scan
criteria
+ such as selected columns, filters, snapshot range, case sensitivity,
etc.
+ In the event that the plan tasks or file scan tasks are not ready to
be served, the service will return a `plan-id`,
Review Comment:
To me I think the idea of returning a partial amount of plan tasks with an
id makes this protocol a little more complicated for two reasons.
1. To me I thought the goal was to make sure that planning is fully done
before returning any planTasks such that you get good gurantees that work can
be distributed evenly (as you can see how many file scan tasks are generated on
service side and allocate appropriate amount of file scan tasks per plan task)
2. I feel that just returning plan tasks file scan tasks without an id, is
the best signal to indicate that planning is done. Returning the `plan-id` by
itself signals that planning is not finished and that a person can either poll
using this id for their tasks with `GetTasksStatus` , or go and cancel the plan
entirely with this id in `CancelPlan`
--
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]