Java Code Examples for com.amazonaws.services.cloudwatch.AmazonCloudWatchClientBuilder#withRegion()
The following examples show how to use
com.amazonaws.services.cloudwatch.AmazonCloudWatchClientBuilder#withRegion() .
You can vote up the ones you like or vote down the ones you don't like,
and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example 1
Source File: CloudwatchReporterFactory.java From bender with Apache License 2.0 | 5 votes |
@Override public void setConf(AbstractConfig config) { this.config = (CloudwatchReporterConfig) config; AmazonCloudWatchClientBuilder clientBuilder = AmazonCloudWatchClientBuilder.standard(); if (this.config.getRegion() != null) { clientBuilder.withRegion(this.config.getRegion()); } this.client = clientBuilder.build(); }
Example 2
Source File: BasicKinesisProvider.java From beam with Apache License 2.0 | 5 votes |
@Override public AmazonCloudWatch getCloudWatchClient() { AmazonCloudWatchClientBuilder clientBuilder = AmazonCloudWatchClientBuilder.standard().withCredentials(getCredentialsProvider()); if (serviceEndpoint == null) { clientBuilder.withRegion(region); } else { clientBuilder.withEndpointConfiguration( new AwsClientBuilder.EndpointConfiguration(serviceEndpoint, region.getName())); } return clientBuilder.build(); }
Example 3
Source File: BasicSnsProvider.java From beam with Apache License 2.0 | 5 votes |
@Override public AmazonCloudWatch getCloudWatchClient() { AmazonCloudWatchClientBuilder clientBuilder = AmazonCloudWatchClientBuilder.standard().withCredentials(getCredentialsProvider()); if (serviceEndpoint == null) { clientBuilder.withRegion(region); } else { clientBuilder.withEndpointConfiguration( new AwsClientBuilder.EndpointConfiguration(serviceEndpoint, region.getName())); } return clientBuilder.build(); }
Example 4
Source File: BasicDynamoDBProvider.java From beam with Apache License 2.0 | 5 votes |
@Override public AmazonCloudWatch getCloudWatchClient() { AmazonCloudWatchClientBuilder clientBuilder = AmazonCloudWatchClientBuilder.standard().withCredentials(getCredentialsProvider()); if (serviceEndpoint == null) { clientBuilder.withRegion(region); } else { clientBuilder.withEndpointConfiguration( new AwsClientBuilder.EndpointConfiguration(serviceEndpoint, region.getName())); } return clientBuilder.build(); }