class DynamoDBStatusChecker implements StatusChecker {

    @Override
    public void check() throws StatusCheckException {
        DynamoDBClientAndCredentials clientAndCreds = null;
        try {
            // Get DynamoDB client and temp credentials (if required)
            DynamoDBClientFetcher dynamoDBClientFetcher = getDynamoDBClientFetcher();
            clientAndCreds = dynamoDBClientFetcher.getDynamoDBClient(null, keyStore);
            AmazonDynamoDB amazonDynamoDB = clientAndCreds.getAmazonDynamoDB();

            // Get list of tables and verify our table appears
            boolean tableFound = amazonDynamoDB.listTables().getTableNames().stream()
                    .anyMatch(fetchedTableName -> fetchedTableName.equals(tableName));

            if (!tableFound) {
                throw new StatusCheckException(HttpStatus.SC_OK, "Table named " + tableName + " wasn't found in DynamoDB");
            }
        } catch (StatusCheckException ex) {
            throw ex;
        } catch (Throwable ex) {
            throw new StatusCheckException(ex);
        } finally {
            // Close resources
            if (clientAndCreds != null) {
                try {
                    if (clientAndCreds.getAmazonDynamoDB() != null) {
                        clientAndCreds.getAmazonDynamoDB().shutdown();
                    }
                    if (clientAndCreds.getAwsCredentialsProvider() != null) {
                        clientAndCreds.getAwsCredentialsProvider().close();
                    }
                } catch (IOException ignored) {

                }
            }
        }
    }

    public  DynamoDBStatusChecker(String tableName, PrivateKeyStore keyStore);

}