aloknnikhil commented on a change in pull request #9985:
URL: https://github.com/apache/kafka/pull/9985#discussion_r566378930



##########
File path: raft/src/main/java/org/apache/kafka/raft/RaftConfig.java
##########
@@ -102,31 +120,23 @@ public boolean equals(Object obj) {
                 return false;
             }
 
-            final AddressSpec that = (AddressSpec) obj;
-            return that.address().equals(address());
+            final InetAddressSpec that = (InetAddressSpec) obj;
+            return that.address.equals(address);
         }
     }
 
-    public static class InetAddressSpec extends AddressSpec {
-        private final InetSocketAddress address;
-
-        public InetAddressSpec(InetSocketAddress address) {
-            if (address.equals(UNROUTABLE_ADDRESS)) {
-                throw new IllegalArgumentException("Address not routable");
-            }
-            this.address = address;
+    public static class UnknownAddressSpec implements AddressSpec {
+        private UnknownAddressSpec() {

Review comment:
       Yea, that's true actually. Should work fine for the map equals test case 
containing an instance of the UnknownAddressSpec. Removed




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

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


Reply via email to