Skip to content

World's most powerful open data catalog for building a high-performance, geo-distributed and federated metadata lake.

[#15300] docs(open-api): Document HTTP 403, 406, and 501 responses in tables.yaml (#15301)

Qi Yu9cdf8c56345a
diff --git a/docs/open-api/tables.yaml b/docs/open-api/tables.yaml
index 801edef5db..453c5a0724 100644
--- a/docs/open-api/tables.yaml
+++ b/docs/open-api/tables.yaml
@@ -35,7 +35,13 @@ paths:
$ref: "./openapi.yaml#/components/responses/EntityListResponse"
"400":
$ref: "./openapi.yaml#/components/responses/BadRequestErrorResponse"
- "5xx":
+ "403":
+ $ref: "./openapi.yaml#/components/responses/ForbiddenErrorResponse"
+ "406":
+ $ref: "./openapi.yaml#/components/responses/NotAcceptableErrorResponse"
+ "501":
+ $ref: "#/components/responses/TableUnsupportedOperationErrorResponse"
+ "5XX":
$ref: "./openapi.yaml#/components/responses/ServerErrorResponse"
post:
@@ -62,6 +68,10 @@ paths:
responses:
"200":
$ref: "#/components/responses/TableResponse"
+ "403":
+ $ref: "./openapi.yaml#/components/responses/ForbiddenErrorResponse"
+ "406":
+ $ref: "./openapi.yaml#/components/responses/NotAcceptableErrorResponse"
"409":
description: Conflict - The target table already exists
content:
@@ -71,7 +81,9 @@ paths:
examples:
TableAlreadyExistsErrorResponse:
$ref: "#/components/examples/TableAlreadyExistsException"
- "5xx":
+ "501":
+ $ref: "#/components/responses/TableUnsupportedOperationErrorResponse"
+ "5XX":
$ref: "./openapi.yaml#/components/responses/ServerErrorResponse"
@@ -91,10 +103,14 @@ paths:
responses:
"200":
$ref: "#/components/responses/TableResponse"
+ "403":
+ $ref: "./openapi.yaml#/components/responses/ForbiddenErrorResponse"
"404":
- description: Not Found - The target table does not exist
+ description: >-
+ Not Found - The table or its parent resource does not exist. When authorization
+ is enabled, a missing metalake returns 403 instead.
content:
- application/vnd.gravitino.v1+json:
+ application/json:
schema:
$ref: "./openapi.yaml#/components/schemas/ErrorModel"
examples:
@@ -106,7 +122,11 @@ paths:
$ref: "./schemas.yaml#/components/examples/NoSuchSchemaException"
NoSuchTableException:
$ref: "#/components/examples/NoSuchTableException"
- "5xx":
+ "406":
+ $ref: "./openapi.yaml#/components/responses/NotAcceptableErrorResponse"
+ "501":
+ $ref: "#/components/responses/TableUnsupportedOperationErrorResponse"
+ "5XX":
$ref: "./openapi.yaml#/components/responses/ServerErrorResponse"
put:
@@ -125,10 +145,14 @@ paths:
$ref: "#/components/responses/TableResponse"
"400":
$ref: "./openapi.yaml#/components/responses/BadRequestErrorResponse"
+ "403":
+ $ref: "./openapi.yaml#/components/responses/ForbiddenErrorResponse"
"404":
- description: Not Found - The target table does not exist
+ description: >-
+ Not Found - The table or its parent resource does not exist. When authorization
+ is enabled, a missing metalake returns 403 instead.
content:
- application/vnd.gravitino.v1+json:
+ application/json:
schema:
$ref: "./openapi.yaml#/components/schemas/ErrorModel"
examples:
@@ -140,6 +164,8 @@ paths:
$ref: "./schemas.yaml#/components/examples/NoSuchSchemaException"
NoSuchTableException:
$ref: "#/components/examples/NoSuchTableException"
+ "406":
+ $ref: "./openapi.yaml#/components/responses/NotAcceptableErrorResponse"
"409":
description: Conflict - The target table already exists
content:
@@ -149,7 +175,9 @@ paths:
examples:
TableAlreadyExistsErrorResponse:
$ref: "#/components/examples/TableAlreadyExistsException"
- "5xx":
+ "501":
+ $ref: "#/components/responses/TableUnsupportedOperationErrorResponse"
+ "5XX":
$ref: "./openapi.yaml#/components/responses/ServerErrorResponse"
delete:
@@ -164,7 +192,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":
+ $ref: "#/components/responses/TableUnsupportedOperationErrorResponse"
+ "5XX":
$ref: "./openapi.yaml#/components/responses/ServerErrorResponse"
@@ -823,6 +857,17 @@ components:
responses:
+ TableUnsupportedOperationErrorResponse:
+ description: Not Implemented - The catalog does not support table operations or the requested table operation
+ content:
+ application/json:
+ schema:
+ $ref: "./openapi.yaml#/components/schemas/ErrorModel"
+ example:
+ code: 1006
+ type: UnsupportedOperationException
+ message: Catalog does not support table operations
+
TableResponse:
description: Returns include the table object
content: