diff options
author | Henning Baldersheim <balder@yahoo-inc.com> | 2020-02-11 09:58:51 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2020-02-11 09:58:51 +0100 |
commit | faa3a4a5d4d512be13fc2de2d4c1e5a7cdf5ad35 (patch) | |
tree | 032683afce3b8787f40b2a605601c4b7cb39f85f | |
parent | db62ee69565b564c6a28cba4008ab3416e9846db (diff) | |
parent | 4cdb4b0f3be0627353247517bbfc48dcd206401c (diff) |
Merge pull request #12144 from vespa-engine/hmusum/cleanup-6
Config cleanup 6
-rw-r--r-- | config/src/main/java/com/yahoo/vespa/config/protocol/JRTClientConfigRequestV3.java | 24 |
1 files changed, 10 insertions, 14 deletions
diff --git a/config/src/main/java/com/yahoo/vespa/config/protocol/JRTClientConfigRequestV3.java b/config/src/main/java/com/yahoo/vespa/config/protocol/JRTClientConfigRequestV3.java index b3ca7355023..12e5968ab83 100644 --- a/config/src/main/java/com/yahoo/vespa/config/protocol/JRTClientConfigRequestV3.java +++ b/config/src/main/java/com/yahoo/vespa/config/protocol/JRTClientConfigRequestV3.java @@ -109,22 +109,19 @@ public class JRTClientConfigRequestV3 implements JRTClientConfigRequest { Trace trace, CompressionType compressionType, Optional<VespaVersion> vespaVersion) { - String hostname = ConfigUtils.getCanonicalHostName(); - ConfigKey<T> key = sub.getKey(); ConfigSubscription.ConfigState<T> configState = sub.getConfigState(); - T i = configState.getConfig(); - return createWithParams(key, - sub.getDefContent(), - hostname, - i != null ? i.getConfigMd5() : "", - configState.getGeneration() != null ? configState.getGeneration() : 0L, - sub.timingValues().getSubscribeTimeout(), - trace, - compressionType, - vespaVersion); + T config = configState.getConfig(); + return createWithParams(sub.getKey(), + sub.getDefContent(), + ConfigUtils.getCanonicalHostName(), + config != null ? config.getConfigMd5() : "", + configState.getGeneration(), + sub.timingValues().getSubscribeTimeout(), + trace, + compressionType, + vespaVersion); } - public static JRTClientConfigRequest createFromRaw(RawConfig config, long serverTimeout, Trace trace, @@ -142,7 +139,6 @@ public class JRTClientConfigRequestV3 implements JRTClientConfigRequest { vespaVersion); } - public static JRTClientConfigRequest createWithParams(ConfigKey<?> reqKey, DefContent defContent, String hostname, |