dennishuo commented on code in PR #1026:
URL: https://github.com/apache/polaris/pull/1026#discussion_r2006737209
##########
spec/polaris-management-service.yml:
##########
@@ -850,9 +850,92 @@ components:
- $ref: "#/components/schemas/Catalog"
- type: object
properties:
- remoteUrl:
- type: string
- description: URL to the remote catalog API
+ connectionConfigInfo:
+ $ref: "#/components/schemas/ConnectionConfigInfo"
+
+ ConnectionConfigInfo:
+ type: object
+ description: A connection configuration representing a remote catalog
service
+ properties:
+ connectionType:
+ type: string
+ enum:
+ - ICEBERG_REST
+ description: The type of remote catalog service represented by this
connection
+ uri:
+ type: string
+ description: URI to the remote catalog service
+ required:
+ - connectionType
+ discriminator:
+ propertyName: connectionType
+ mapping:
+ ICEBERG_REST: "#/components/schemas/IcebergRestConnectionConfigInfo"
+
+ IcebergRestConnectionConfigInfo:
Review Comment:
Right, each other `connectionType` should have a corresponding type-specific
struct defined.
discriminator:
propertyName: connectionType
mapping:
ICEBERG_REST:
"#/components/schemas/IcebergRestConnectionConfigInfo"
HIVE: "#/components/schemas/HiveConnectionConfigInfo"
HiveConnectionConfigInfo:
..
If we remove the discriminator, the JSON on the wire is still *generally*
compatible, if we flatten the fields of all possible subtypes into the base
type. The internal autogenerated java classes will not be compatible, but can
be rewritten if we want that.
--
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]