cgpoh commented on code in PR #1022:
URL: https://github.com/apache/polaris/pull/1022#discussion_r1960725225
##########
service/common/src/main/java/org/apache/polaris/service/config/Serializers.java:
##########
@@ -73,8 +73,18 @@ public CreateCatalogRequest deserialize(JsonParser p,
DeserializationContext ctx
throws IOException, JacksonException {
TreeNode treeNode = p.readValueAsTree();
if (treeNode.isObject() && ((ObjectNode) treeNode).has("catalog")) {
+ ObjectNode catalogTreeNode = (ObjectNode) treeNode;
+ JsonNode catalogNode = catalogTreeNode.get("catalog");
+ if (catalogNode.has("storageConfigInfo")) {
+ ObjectNode storageConfigNode = (ObjectNode)
catalogNode.get("storageConfigInfo");
+ if (storageConfigNode.has("storageType")) {
+ String storageType = storageConfigNode.get("storageType").asText();
+ //ensure the storage type is always serialized as upper case text
+ storageConfigNode.put("storageType", storageType.toUpperCase());
Review Comment:
In places like Turkey "i".toUpperCase() results in `Ì ` instead of `I`,
should we use `storageType.toUpperCase(Locale.ROOT)`?
--
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]