Example usage for com.amazonaws AmazonWebServiceClient setRegion

List of usage examples for com.amazonaws AmazonWebServiceClient setRegion

Introduction

In this page you can find the example usage for com.amazonaws AmazonWebServiceClient setRegion.

Prototype

@Deprecated
public void setRegion(Region region) throws IllegalArgumentException 

Source Link

Document

An alternative to AmazonWebServiceClient#setEndpoint(String) , sets the regional endpoint for this client's service calls.

Usage

From source file:com.netflix.bluespar.amazon.security.AmazonClientProvider.java

License:Apache License

private GeneralAmazonClientInvocationHandler getInvocationHandler(AmazonWebServiceClient client, String region,
        AmazonCredentials amazonCredentials) {
    if (region != null && region.length() > 0) {
        client.setRegion(Region.getRegion(Regions.fromName(region)));
    }//www .  j ava2  s.  c o m

    return new GeneralAmazonClientInvocationHandler(client,
            String.format(edda, region, amazonCredentials.getEnvironment()),
            this.httpClient == null ? new DefaultHttpClient() : this.httpClient, objectMapper);
}

From source file:io.macgyver.plugin.cloud.aws.AWSServiceClientImpl.java

License:Apache License

void assignRegion(AmazonWebServiceClient c, Regions r) {
    c.setRegion(Region.getRegion(r));
}

From source file:io.macgyver.plugin.cloud.aws.AWSServiceClientImpl.java

License:Apache License

void assignRegion(AmazonWebServiceClient c, Region r) {
    c.setRegion(r);
}