diqiu50 commented on code in PR #12010:
URL: https://github.com/apache/gravitino/pull/12010#discussion_r3579765856


##########
core/src/main/java/org/apache/gravitino/connector/capability/Capability.java:
##########
@@ -73,6 +74,22 @@ default CapabilityResult caseSensitiveOnName(Scope scope) {
     return DEFAULT.caseSensitiveOnName(scope);
   }
 
+  /**
+   * Normalizes the given name to the catalog's canonical form before it is 
used to call the
+   * underlying catalog operation and persisted as the Gravitino entity name. 
This is invoked
+   * instead of the simple lowercase folding implied by {@link 
#caseSensitiveOnName(Scope)} whenever
+   * a catalog needs custom folding logic (for example, a catalog whose native 
folding direction is
+   * uppercase, or one that supports a case-sensitive quoted form alongside a 
case-insensitive
+   * unquoted form).
+   *
+   * @param scope The scope of the capability.
+   * @param name The name to normalize.
+   * @return The normalized, canonical name.
+   */
+  default String normalizeName(Scope scope, String name) {
+    return caseSensitiveOnName(scope).supported() ? name : 
name.toLowerCase(Locale.ROOT);

Review Comment:
   fixed



-- 
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]

Reply via email to