You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@pulsar.apache.org by "lhotari (via GitHub)" <gi...@apache.org> on 2023/05/10 12:24:01 UTC

[GitHub] [pulsar] lhotari commented on issue #20290: Flaky-test: ConnectionPoolTest.testSetProxyToTargetBrokerAddress

lhotari commented on issue #20290:
URL: https://github.com/apache/pulsar/issues/20290#issuecomment-1542115730

   the test has a problem:
   https://github.com/apache/pulsar/blob/e2863391e7f6f9b6c5060f0f78378493f8df37f3/pulsar-broker/src/test/java/org/apache/pulsar/client/impl/ConnectionPoolTest.java#L186-L192
   
   `new InetSocketAddress("localhost", brokerPort)` and `new InetSocketAddress("127.0.0.1", brokerPort)` will collide and that's why test fails in certain case. 
   
   I guess that one way to fix this would be to use different loopback address. 
   [IPv4 network standards reserve the entire address block 127.0.0.0/8 (more than 16 million addresses) for loopback purposes](https://en.wikipedia.org/wiki/Localhost#Name_resolution).
   For example `127.0.0.101` and `127.0.0.102` could be used.
   


-- 
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: commits-unsubscribe@pulsar.apache.org

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