From 1d652d0d85dd6bb78c62ea07b0d544e58b80666b Mon Sep 17 00:00:00 2001 From: Adam Jordens Date: Fri, 11 Sep 2020 12:09:26 -0700 Subject: [PATCH] feat(proxy): Slight tightening of the `ProxyConfig` contact. (#1339) s/Object/String, we can revisit should we need to store more than simple Strings. --- .../com/netflix/spinnaker/gate/api/extension/ProxyConfig.java | 2 +- .../main/kotlin/com/netflix/spinnaker/gate/controllers/Proxy.kt | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/gate-api/src/main/java/com/netflix/spinnaker/gate/api/extension/ProxyConfig.java b/gate-api/src/main/java/com/netflix/spinnaker/gate/api/extension/ProxyConfig.java index 607eab1489..08e21310bd 100644 --- a/gate-api/src/main/java/com/netflix/spinnaker/gate/api/extension/ProxyConfig.java +++ b/gate-api/src/main/java/com/netflix/spinnaker/gate/api/extension/ProxyConfig.java @@ -45,5 +45,5 @@ public class ProxyConfig { private Long writeTimeoutMs = 30_000L; /** Additional attributes for this proxy. */ - private Map additionalAttributes = new HashMap<>(); + private Map additionalAttributes = new HashMap<>(); } diff --git a/gate-proxy/src/main/kotlin/com/netflix/spinnaker/gate/controllers/Proxy.kt b/gate-proxy/src/main/kotlin/com/netflix/spinnaker/gate/controllers/Proxy.kt index 6f71c2c1cf..58fb8e4daf 100644 --- a/gate-proxy/src/main/kotlin/com/netflix/spinnaker/gate/controllers/Proxy.kt +++ b/gate-proxy/src/main/kotlin/com/netflix/spinnaker/gate/controllers/Proxy.kt @@ -35,7 +35,7 @@ internal class Proxy(val config: ProxyConfig) { */ fun init(okHttpClientProvider: OkHttpClientProvider) : Proxy { val okHttpClient = okHttpClientProvider.getClient(DefaultServiceEndpoint( - "proxy__${config.id}", config.uri, config.additionalAttributes, false + "proxy__${config.id}", config.uri, config.additionalAttributes as Map, false )) this.okHttpClient = okHttpClient