mchades commented on code in PR #12833:
URL: https://github.com/apache/gravitino/pull/12833#discussion_r4121830591


##########
core/src/main/java/org/apache/gravitino/catalog/ManagedSemanticModelOperations.java:
##########
@@ -131,15 +141,106 @@ public SemanticModel createSemanticModel(
   public SemanticModel alterSemanticModel(NameIdentifier ident, 
SemanticModelChange... changes)
       throws NoSuchSemanticModelException, SemanticModelAlreadyExistsException,
           IllegalSemanticModelException {
-    // TODO: Implement in the Semantic Model list/alter/drop capability.
-    throw new UnsupportedOperationException(
-        "alterSemanticModel: list/alter/drop capability is not implemented");
+    boolean validateForWrite = requiresWriteValidation(changes);
+
+    try {
+      return store.update(

Review Comment:
   Yes. A version is a complete Semantic Model snapshot, not definition-only 
history. The version row includes the name, comment, definition, properties, 
and audit info, and the storage contract intentionally appends a snapshot for 
every successful alter while advancing the current and last versions.
   
   Even `removeProperty("absent")` goes through the alter path and updates the 
audit metadata. Retention therefore applies to complete model snapshots rather 
than only definition changes. Owner, tag, and policy changes remain in their 
separate governance stores and do not create Semantic Model versions.
   
   `updateSemanticModel` already documents this as creating a complete new 
snapshot, so no change is needed in this PR.



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