Example usage for com.amazonaws.services.dynamodbv2 AmazonDynamoDB setRegion

List of usage examples for com.amazonaws.services.dynamodbv2 AmazonDynamoDB setRegion

Introduction

In this page you can find the example usage for com.amazonaws.services.dynamodbv2 AmazonDynamoDB setRegion.

Prototype

@Deprecated
void setRegion(Region region);

Source Link

Document

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

Usage

From source file:uk.co.keithj.postcodelookup.infrastructure.repository.SpringDataDynamoDBConfigurator.java

License:Apache License

@Bean
public AmazonDynamoDB amazonDynamoDB() {
    AmazonDynamoDB amazonDynamoDB = new AmazonDynamoDBClient(amazonAWSCredentials());
    if (StringUtils.isNotEmpty(amazonDynamoDBEndpoint)) {
        amazonDynamoDB.setEndpoint(amazonDynamoDBEndpoint);
    }//from   w ww .  j a  v a 2s  . c o m
    amazonDynamoDB.setRegion(amazonRegion());
    return amazonDynamoDB;
}