eric-maynard commented on code in PR #1840:
URL: https://github.com/apache/polaris/pull/1840#discussion_r2143259166


##########
polaris-core/src/main/java/org/apache/polaris/core/secrets/UserSecretReference.java:
##########
@@ -88,8 +88,7 @@ public UserSecretReference(
    */
   @JsonIgnore
   public String getUserSecretManagerTypeFromUrn() {
-    // TODO: Add better/standardized parsing and validation of URN syntax
-    return urn.split(":")[2];
+    return UserSecretReferenceUrnHelper.getSecretManagerType(urn);

Review Comment:
   I'm wondering why we need `UserSecretReferenceUrnHelper` rather than just 
using `UserSecretReference`. Right now it seems like the responsibility of 
parsing a URN has been shifted to `UserSecretReferenceUrnHelper`, but it's only 
ever done in the context of a `UserSecretReferece` right? So why not keep the 
code in `UserSecretReference`?



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