This is an automated email from the ASF dual-hosted git repository.
mchades pushed a commit to branch branch-1.3
in repository https://gitbox.apache.org/repos/asf/gravitino.git
The following commit(s) were added to refs/heads/branch-1.3 by this push:
new ab07a0a978 [Cherry-pick to branch-1.3] [#11985] fix(openapi): restore
the ExternalType variant to DataType (#11991) (#12907)
ab07a0a978 is described below
commit ab07a0a9781942419b2c6fcf9ae47393b12eba38
Author: mchades <[email protected]>
AuthorDate: Fri Sep 4 15:15:53 2026 +0800
[Cherry-pick to branch-1.3] [#11985] fix(openapi): restore the ExternalType
variant to DataType (#11991) (#12907)
### What changes were proposed in this pull request?
Backport #11991 to `branch-1.3`:
- add `ExternalType` to `DataType.oneOf`;
- move `ExternalType` under `components.schemas`.
### Why are the changes needed?
`branch-1.3` can return external column types, but its OpenAPI schema
omits
`ExternalType` from the `DataType` union and declares it outside
`components.schemas`. Generated clients therefore cannot model this
valid response.
Backport of #11991.
### Does this PR introduce _any_ user-facing change?
The OpenAPI contract now describes a response the server could already
return.
There is no server behavior change.
### How was this patch tested?
- `./gradlew :docs:build`
- `git diff --check`
---
docs/open-api/datatype.yaml | 35 ++++++++++++++++++-----------------
1 file changed, 18 insertions(+), 17 deletions(-)
diff --git a/docs/open-api/datatype.yaml b/docs/open-api/datatype.yaml
index d5ad0cc2b5..986188e41a 100644
--- a/docs/open-api/datatype.yaml
+++ b/docs/open-api/datatype.yaml
@@ -27,6 +27,7 @@ components:
- $ref: "#/components/schemas/MapType"
- $ref: "#/components/schemas/UnionType"
- $ref: "#/components/schemas/UnparsedType"
+ - $ref: "#/components/schemas/ExternalType"
PrimitiveType:
type: string
@@ -201,20 +202,20 @@ components:
]
}
- ExternalType:
- type: object
- required:
- - type
- - catalogString
- properties:
- type:
- type: string
- enum:
- - "external"
- catalogString:
- type: string
- description: The string representation of this type in the catalog
- example: {
- "type": "external",
- "externalType": "user-defined"
- }
\ No newline at end of file
+ ExternalType:
+ type: object
+ required:
+ - type
+ - catalogString
+ properties:
+ type:
+ type: string
+ enum:
+ - "external"
+ catalogString:
+ type: string
+ description: The string representation of this type in the catalog
+ example: {
+ "type": "external",
+ "externalType": "user-defined"
+ }