xiaozcy commented on code in PR #7674:
URL: https://github.com/apache/gravitino/pull/7674#discussion_r2209376972
##########
core/src/main/java/org/apache/gravitino/catalog/ModelNormalizeDispatcher.java:
##########
@@ -125,6 +126,18 @@ public void linkModelVersion(
dispatcher.linkModelVersion(normalizeCaseSensitive(ident), uri, aliases,
comment, properties);
}
+ @Override
+ public String getModelVersionUri(NameIdentifier ident, int version, String
uriName)
+ throws NoSuchModelVersionException, NoSuchModelVersionURINameException {
+ return dispatcher.getModelVersionUri(normalizeCaseSensitive(ident),
version, uriName);
+ }
+
+ @Override
+ public String getModelVersionUri(NameIdentifier ident, String alias, String
uriName)
+ throws NoSuchModelVersionException, NoSuchModelVersionURINameException {
+ return dispatcher.getModelVersionUri(normalizeCaseSensitive(ident), alias,
uriName);
+ }
+
Review Comment:
There are several disadvantages to do it in the client side:
1. Audits cannot be conducted, but we may need to analyze the access
frequency of different URIs based on the audits.
2. It may require two client calls to achieve this, because we support set
the `default-uri-name` at the model level, clients may need to call both
`getModelVersion` and `getModel` at once.
3. The same logic needs to be implemented in clients of different languages,
which leads to repetitive work.
So I still think it's better to do it in the server side, like what we did
for fileset.
--
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]