Skip to content

Commit

Permalink
Enable DNS node discovery by default (#2182)
Browse files Browse the repository at this point in the history
Enable DNS node discovery by default
carterkozak authored Mar 3, 2024
1 parent 2b0f302 commit a24052c
Showing 2 changed files with 6 additions and 7 deletions.
5 changes: 5 additions & 0 deletions changelog/@unreleased/pr-2182.v2.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
type: feature
feature:
description: Enable DNS node discovery by default
links:
- https://github.com/palantir/dialogue/pull/2182
Original file line number Diff line number Diff line change
@@ -127,12 +127,6 @@ public Channel getNonReloadingChannel(String channelName, ClientConfiguration in
params.runtime().clients());
}

// allow enabling dns node discovery by setting an environment variable
// note that this can still be disabled explicitly via the factory, but having a global flag
// that overrides the default value allows for enabling this behavior without explicit code
// changes
private static final String ENABLE_DNS_NODE_DISCOVERY_ENV_VAR = "DIALOGUE_ENABLE_EXPERIMENTAL_DNS_NODE_DISCOVERY";

@Value.Immutable
interface ReloadingParams extends AugmentClientConfig {

@@ -172,7 +166,7 @@ default Duration dnsRefreshInterval() {

@Value.Default
default boolean dnsNodeDiscovery() {
return "true".equalsIgnoreCase(System.getenv(ENABLE_DNS_NODE_DISCOVERY_ENV_VAR));
return true;
}

Optional<ExecutorService> blockingExecutor();

0 comments on commit a24052c

Please sign in to comment.