List of usage examples for com.amazonaws.services.dynamodbv2 AmazonDynamoDBClient AmazonDynamoDBClient
AmazonDynamoDBClient(AwsSyncClientParams clientParams, boolean endpointDiscoveryEnabled)
From source file:org.apache.nifi.processors.aws.dynamodb.AbstractDynamoDBProcessor.java
License:Apache License
/** * Create client using credentials provider. This is the preferred way for creating clients *//*ww w . j a va2 s . c o m*/ @Override protected AmazonDynamoDBClient createClient(final ProcessContext context, final AWSCredentialsProvider credentialsProvider, final ClientConfiguration config) { getLogger().debug("Creating client with credentials provider"); final AmazonDynamoDBClient client = new AmazonDynamoDBClient(credentialsProvider, config); return client; }
From source file:org.apache.nifi.processors.aws.dynamodb.AbstractDynamoDBProcessor.java
License:Apache License
/** * Create client using AWSCredentials//www. j a va2s .co m * * @deprecated use {@link #createClient(ProcessContext, AWSCredentialsProvider, ClientConfiguration)} instead */ @Override protected AmazonDynamoDBClient createClient(final ProcessContext context, final AWSCredentials credentials, final ClientConfiguration config) { getLogger().debug("Creating client with aws credentials"); final AmazonDynamoDBClient client = new AmazonDynamoDBClient(credentials, config); return client; }
From source file:org.finra.herd.dao.credstash.JCredStashWrapper.java
License:Apache License
/** * Constructor for the JCredStashWrapper * * @param region the aws region location of the KMS Client * @param tableName name of the credentials table * @param clientConfiguration the AWS client configuration *//*from w ww . j a v a2 s .c o m*/ public JCredStashWrapper(String region, String tableName, ClientConfiguration clientConfiguration) { AWSCredentialsProvider provider = new DefaultAWSCredentialsProviderChain(); AmazonDynamoDBClient ddb = new AmazonDynamoDBClient(provider, clientConfiguration) .withRegion(Regions.fromName(region)); AWSKMSClient kms = new AWSKMSClient(provider, clientConfiguration).withRegion(Regions.fromName(region)); credstash = new JCredStash(tableName, ddb, kms, new CredStashBouncyCastleCrypto()); }