use of com.netflix.spinnaker.kork.plugins.update.internal.PluginOkHttpClientProvider in project kork by spinnaker.
the class Front50PluginsConfiguration method pluginsOkHttpClient.
@Bean
public static PluginOkHttpClientProvider pluginsOkHttpClient(Environment environment) {
OkHttpClientConfigurationProperties okHttpClientProperties = Binder.get(environment).bind("ok-http-client", Bindable.of(OkHttpClientConfigurationProperties.class)).orElse(new OkHttpClientConfigurationProperties());
OkHttpClient okHttpClient = new OkHttp3ClientConfiguration(okHttpClientProperties).create().retryOnConnectionFailure(okHttpClientProperties.isRetryOnConnectionFailure()).build();
return new PluginOkHttpClientProvider(okHttpClient);
}
Aggregations