ibessonov commented on code in PR #6325: URL: https://github.com/apache/ignite-3/pull/6325#discussion_r2236168936
########## modules/runner/src/test/java/org/apache/ignite/internal/configuration/compatibility/framework/ConfigurationTreeComparator.java: ########## @@ -227,15 +254,73 @@ private static boolean rootsMatch(ConfigNode candidate, ConfigNode current) { return nameMatches && kindMatches; } - private static void validate(Node candidate, Node current, ComparisonContext context) { - compareNodes(candidate.node(), current.node(), context); + private static void validate(ConfigNode candidate, ConfigNode current, ComparisonContext context) { + validate(null, candidate, current, context); } - private static void validate(ConfigNode candidate, ConfigNode current, ComparisonContext context) { + private static void validate(@Nullable String instanceType, ConfigNode candidate, ConfigNode current, ComparisonContext context) { + if (!context.errors.isEmpty()) { + return; + } + context.enterInstance(instanceType); + try { + compareNodes(candidate, current, context); + } finally { + context.leaveInstance(); + } + } + + private static void validate(Node candidate, Node current, ComparisonContext context) { if (!context.errors.isEmpty()) { return; } - compareNodes(candidate, current, context); + + if (candidate.isPolymorphic() && current.isPolymorphic()) { + if (!Objects.equals(candidate.defaultPolymorphicInstanceId(), current.defaultPolymorphicInstanceId())) { + ConfigNode anyNode = candidate.nodes().values().iterator().next(); + String message = format( + "Default polymorphic instance id does not match. Expected: {} got {}", Review Comment: Is this a mistake? I don't think so, we may want to switch the default implementation of a failure handler, and it's supposed to be a valid change -- 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: notifications-unsubscr...@ignite.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org