Skip to content

Commit

Permalink
Add InetAddress.getLocalHost().getCanonicalHostName() for MyRack.
Browse files Browse the repository at this point in the history
  • Loading branch information
horizonzy committed Feb 20, 2024
1 parent f5e4a98 commit dd3c288
Showing 1 changed file with 1 addition and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -80,6 +80,7 @@ public class TestRegionAwareEnsemblePlacementPolicy extends TestCase {
static void updateMyRack(String rack) throws Exception {
StaticDNSResolver.addNodeToRack(InetAddress.getLocalHost().getHostAddress(), rack);
StaticDNSResolver.addNodeToRack(InetAddress.getLocalHost().getHostName(), rack);
StaticDNSResolver.addNodeToRack(InetAddress.getLocalHost().getCanonicalHostName(), rack);
BookieSocketAddress bookieAddress = new BookieSocketAddress(
InetAddress.getLocalHost().getHostAddress(), 0);
StaticDNSResolver.addNodeToRack(bookieAddress.getSocketAddress().getHostName(), rack);
Expand Down

0 comments on commit dd3c288

Please sign in to comment.