diff --git a/plugins/cloud/aws/src/main/java/org/elasticsearch/cloud/aws/AwsEc2Service.java b/plugins/cloud/aws/src/main/java/org/elasticsearch/cloud/aws/AwsEc2Service.java index 989ecc64b61..33910c36022 100644 --- a/plugins/cloud/aws/src/main/java/org/elasticsearch/cloud/aws/AwsEc2Service.java +++ b/plugins/cloud/aws/src/main/java/org/elasticsearch/cloud/aws/AwsEc2Service.java @@ -68,14 +68,14 @@ public class AwsEc2Service extends AbstractLifecycleComponent { throw new ElasticSearchIllegalArgumentException("No s3 secret_key defined for s3 gateway"); } - String proxyHost = settings.get("network.proxyHost"); + String proxyHost = componentSettings.get("proxy_host"); if (proxyHost != null) { - String portString = settings.get("network.proxyPort","80"); + String portString = componentSettings.get("proxy_port", "80"); Integer proxyPort; try { - proxyPort = Integer.parseInt(portString,10); + proxyPort = Integer.parseInt(portString, 10); } catch (NumberFormatException ex) { - throw new ElasticSearchIllegalArgumentException("The configured proxy port value [" + portString + "] is invalid",ex); + throw new ElasticSearchIllegalArgumentException("The configured proxy port value [" + portString + "] is invalid", ex); } clientConfiguration.withProxyHost(proxyHost).setProxyPort(proxyPort); } diff --git a/plugins/cloud/aws/src/main/java/org/elasticsearch/cloud/aws/AwsS3Service.java b/plugins/cloud/aws/src/main/java/org/elasticsearch/cloud/aws/AwsS3Service.java index 28539e1be7d..766ddaf661f 100644 --- a/plugins/cloud/aws/src/main/java/org/elasticsearch/cloud/aws/AwsS3Service.java +++ b/plugins/cloud/aws/src/main/java/org/elasticsearch/cloud/aws/AwsS3Service.java @@ -68,14 +68,14 @@ public class AwsS3Service extends AbstractLifecycleComponent { throw new ElasticSearchIllegalArgumentException("No s3 secret_key defined for s3 gateway"); } - String proxyHost = settings.get("network.proxyHost"); + String proxyHost = componentSettings.get("proxy_host"); if (proxyHost != null) { - String portString = settings.get("network.proxyPort","80"); + String portString = componentSettings.get("proxy_port", "80"); Integer proxyPort; try { - proxyPort = Integer.parseInt(portString,10); + proxyPort = Integer.parseInt(portString, 10); } catch (NumberFormatException ex) { - throw new ElasticSearchIllegalArgumentException("The configured proxy port value [" + portString + "] is invalid",ex); + throw new ElasticSearchIllegalArgumentException("The configured proxy port value [" + portString + "] is invalid", ex); } clientConfiguration.withProxyHost(proxyHost).setProxyPort(proxyPort); }