Skip to content

Commit

Permalink
Add missing init for DynamoDB client in Worker (#51)
Browse files Browse the repository at this point in the history
When the dynamoDBEndpoint configuration property was added, not all paths that
should have made use of it were updated.  Both paths now use the config value to
set up the DynamoDB client.
  • Loading branch information
chris-chambers authored and pfifer committed Feb 27, 2017
1 parent 9113ae2 commit 4ed375b
Showing 1 changed file with 5 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -1064,6 +1064,11 @@ public Worker build() {
dynamoDBClient.setRegion(region);
LOG.debug("The region of Amazon DynamoDB client has been set to " + config.getRegionName());
}
// If a dynamoDB endpoint was explicitly specified, use it to set the DynamoDB endpoint.
if (config.getDynamoDBEndpoint() != null) {
dynamoDBClient.setEndpoint(config.getDynamoDBEndpoint());
LOG.debug("The endpoint of Amazon DynamoDB client has been set to " + config.getDynamoDBEndpoint());
}
// If a kinesis endpoint was explicitly specified, use it to set the region of kinesis.
if (config.getKinesisEndpoint() != null) {
kinesisClient.setEndpoint(config.getKinesisEndpoint());
Expand Down

0 comments on commit 4ed375b

Please sign in to comment.