WencongLiu commented on code in PR #20236:
URL: https://github.com/apache/flink/pull/20236#discussion_r931891522


##########
flink-runtime/src/main/java/org/apache/flink/runtime/rest/RestServerEndpoint.java:
##########
@@ -677,9 +674,15 @@ public int compare(
             if (urlComparisonResult != 0) {
                 return urlComparisonResult;
             } else {
-                return API_VERSION_ORDER.compare(
-                        Collections.min(o1.f0.getSupportedAPIVersions()),
-                        Collections.min(o2.f0.getSupportedAPIVersions()));
+                Collection<? extends RestAPIVersion> o1APIVersions =
+                        o1.f0.getSupportedAPIVersions();
+                RestAPIVersion o1Version =
+                        Collections.min(o1APIVersions, 
o1APIVersions.iterator().next());

Review Comment:
   Done. I've add related notes in `RuntimeRestAPIVersion` and 
`SqlGatewayRestAPIVersion`.



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