rahil-c commented on code in PR #9695:
URL: https://github.com/apache/iceberg/pull/9695#discussion_r1687273787
##########
open-api/rest-catalog-open-api.yaml:
##########
@@ -3647,6 +3786,173 @@ components:
type: integer
description: "List of equality field IDs"
+ PreplanTableRequest:
+ type: object
+ required:
+ - table-scan-context
+ properties:
+ table-scan-context:
+ $ref: '#/components/schemas/TableScanContext'
+
+ PlanTableRequest:
+ type: object
+ required:
+ - table-scan-context
+ properties:
+ table-scan-context:
+ $ref: '#/components/schemas/TableScanContext'
+ plan-task:
+ $ref: '#/components/schemas/PlanTask'
+ stats-fields:
+ description:
+ A list of fields that the client requests the server to send
statistics
+ in each `FileScanTask` returned in the response
+ type: array
+ items:
+ $ref: '#/components/schemas/FieldName'
+
+ TableScanContext:
+ anyOf:
Review Comment:
@jackye1995 @amogh-jahagirdar @rdblue I think i agree that it should
probably just be `oneOf` as thats more clear for a spec reader to know its
either a `SnapshotScanContext` or a `IncrementalSnapshotScanContext`.
However from the link that amogh shared
https://swagger.io/docs/specification/data-models/inheritance-and-
polymorphism/ the doc states that a spec writer can use either `oneOf` or
`anyOf`, when using `discriminator`.
>Polymorphism
In your API, you can have request and responses that can be described by
several alternative schemas. In OpenAPI 3.0, to describe such a model, you can
use the oneOf or anyOf keywords
>In our example, the discriminator points to the objectType property that
contains the data type name. The discriminator is used with anyOf or oneOf
keywords only. It is important that all the models mentioned below anyOf or
oneOf contain the property that the discriminator specifies. This means, for
example, that in our code above, both simpleObject and complexObject must have
the objectType property
For now though will change this to be `oneOf`.
--
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]