Skip to content

Commit

Permalink
fix check style
Browse files Browse the repository at this point in the history
  • Loading branch information
hangc0276 committed Aug 23, 2023
1 parent 8c7a4d2 commit 2cb5cf6
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -209,8 +209,8 @@ public Integer getSample() {
BookieNode bn = null;
if (!ignoreLocalNodeInPlacementPolicy) {
try {
String hostname = useHostnameResolveLocalNodePlacementPolicy ?
InetAddress.getLocalHost().getCanonicalHostName() : InetAddress.getLocalHost().getHostAddress();
String hostname = useHostnameResolveLocalNodePlacementPolicy
? InetAddress.getLocalHost().getCanonicalHostName() : InetAddress.getLocalHost().getHostAddress();
bn = createDummyLocalBookieNode(hostname);
} catch (IOException e) {
LOG.error("Failed to get local host address : ", e);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -1714,8 +1714,8 @@ public void testNewEnsemblePickLocalRackBookiesInternal(boolean useHostnameResol
StaticDNSResolver.addNodeToRack(addr4.getHostName(), "/default-region/r2");
StaticDNSResolver.addNodeToRack(addr5.getHostName(), "/default-region/r3");

String hostname = useHostnameResolveLocalNodePlacementPolicy ?
InetAddress.getLocalHost().getCanonicalHostName() : InetAddress.getLocalHost().getHostAddress();
String hostname = useHostnameResolveLocalNodePlacementPolicy
? InetAddress.getLocalHost().getCanonicalHostName() : InetAddress.getLocalHost().getHostAddress();
StaticDNSResolver.addNodeToRack(hostname, "/default-region/r1");
if (useHostnameResolveLocalNodePlacementPolicy) {
conf.setUseHostnameResolveLocalNodePlacementPolicy(useHostnameResolveLocalNodePlacementPolicy);
Expand Down

0 comments on commit 2cb5cf6

Please sign in to comment.