jerryshao commented on code in PR #14667:
URL: https://github.com/apache/gravitino/pull/14667#discussion_r4490295958
##########
docs/open-api/partitions.yaml:
##########
@@ -130,7 +144,13 @@ paths:
$ref: "./openapi.yaml#/components/responses/DropResponse"
"400":
$ref: "./openapi.yaml#/components/responses/BadRequestErrorResponse"
- "5xx":
+ "403":
+ $ref: "./openapi.yaml#/components/responses/ForbiddenErrorResponse"
+ "406":
+ $ref:
"./openapi.yaml#/components/responses/NotAcceptableErrorResponse"
+ "501":
Review Comment:
The 501 is only documented on `DELETE` (purge). But
`Table.supportPartitions()` throws `UnsupportedOperationException("Table does
not support partition operations.")` by default, and
`PartitionExceptionHandler` maps it to HTTP 501, so list, get and add on a
table without partition support also return 501. Could we add a 501 response to
those operations as well, or generalize
`PartitionPurgeUnsupportedErrorResponse` to also cover "the table does not
support partition operations"?
##########
docs/open-api/filesets.yaml:
##########
@@ -35,7 +35,9 @@ paths:
$ref: "./openapi.yaml#/components/responses/EntityListResponse"
"400":
$ref: "./openapi.yaml#/components/responses/BadRequestErrorResponse"
- "5xx":
+ "403":
Review Comment:
The description says shared 403/406 responses are added, and
`VersioningFilter` applies to every endpoint, but no fileset operation gets the
`406` response while the partition and topic operations do. Could we add
`NotAcceptableErrorResponse` to the fileset operations too, or mention in the
description why they are left out?
--
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]