fhan688 commented on code in PR #20281:
URL: https://github.com/apache/hudi/pull/20281#discussion_r4247676532


##########
hudi-agent-gateway/skills/hudi-architect/validate_flink_design.py:
##########
@@ -651,8 +733,48 @@ def assess_design(
     else:
         assessment.add("FLINK_DESIGN_CONTRACT_INVALID", "identity.mode is 
required")
 
+    ordering_fields: list[str] = []
+    if mutable_contract:
+        ordering = _dict(contract.get("ordering"), "ordering", assessment)
+        _check_keys(ordering, {"fields", "mode"}, "ordering", assessment)
+        ordering_fields = _string_list(
+            ordering.get("fields"), "ordering.fields", assessment
+        )
+        if ordering.get("mode") != "event_time":
+            assessment.add(
+                "FLINK_MUTABLE_ORDERING_FIELD_REQUIRED",
+                "The first mutable path requires event_time ordering",
+            )
+        if len(ordering_fields) != 1:
+            assessment.add(
+                "FLINK_MUTABLE_ORDERING_FIELD_REQUIRED",
+                "Exactly one ordering field is required",
+            )
+        for field in ordering_fields:

Review Comment:
   Thanks for catching this. I’ve added `no_precombine` to the reserved 
ordering-field values and now block it with 
`FLINK_MUTABLE_ORDERING_FIELD_INVALID`. I also added Python and pinned Hudi 
1.2.0 fixture coverage.



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