com.amazonaws.services.dynamodbv2.model.DeleteTableResult Java Examples
The following examples show how to use
com.amazonaws.services.dynamodbv2.model.DeleteTableResult.
You can vote up the ones you like or vote down the ones you don't like,
and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example #1
Source File: DynamoDSETranslatorJSONBlob.java From dynamo-cassandra-proxy with Apache License 2.0 | 6 votes |
@Override public DynamoDBResponse deleteTable(DeleteTableRequest deleteTableRequest) { logger.info("deleting JSON table"); String keyspace = keyspaceName; String table = deleteTableRequest.getTableName(); String statement = String.format("DROP TABLE %s.\"%s\";\n", keyspace, table); ResultSet result = session().execute(statement); if (result.wasApplied()) { logger.info("deleted table " + table); cassandraManager.refreshSchema(); TableDescription newTableDesc = this.getTableDescription(table, null,null); DeleteTableResult createResult = (new DeleteTableResult()).withTableDescription(newTableDesc); return new DynamoDBResponse(createResult, 200); } return null; }
Example #2
Source File: DynamoDbDelegate.java From dynamodb-janusgraph-storage-backend with Apache License 2.0 | 5 votes |
public DeleteTableResult deleteTable(final DeleteTableRequest request) throws BackendException { controlPlaneRateLimiter.acquire(); final Timer.Context apiTimerContext = getTimerContext(DELETE_TABLE, request.getTableName()); DeleteTableResult result; try { result = client.deleteTable(request); } catch (Exception e) { throw processDynamoDbApiException(e, DELETE_TABLE, request.getTableName()); } finally { apiTimerContext.stop(); } return result; }
Example #3
Source File: AwsNoSqlConnectorTest.java From cloudbreak with Apache License 2.0 | 5 votes |
@Test public void deleteNoSqlTable() { TableDescription tableDescription = new TableDescription().withTableArn(ARN).withTableStatus(DELETING_STATUS); DeleteTableResult deleteResult = new DeleteTableResult().withTableDescription(tableDescription); when(dynamoDb.deleteTable(argThat((ArgumentMatcher<String>) argument -> true))).thenReturn(deleteResult); NoSqlTableDeleteResponse result = underTest.deleteNoSqlTable(new NoSqlTableDeleteRequest()); assertEquals(ARN, result.getId()); assertEquals(DELETING_STATUS, result.getTableStatus()); assertEquals(ResponseStatus.OK, result.getStatus()); }
Example #4
Source File: ITAbstractDynamoDBTest.java From localization_nifi with Apache License 2.0 | 4 votes |
@AfterClass public static void afterClass() { DeleteTableResult result = amazonDynamoDBClient.deleteTable(stringHashStringRangeTableName); result = amazonDynamoDBClient.deleteTable(numberHashNumberRangeTableName); result = amazonDynamoDBClient.deleteTable(numberHashOnlyTableName); }
Example #5
Source File: PostgresDynamoDB.java From podyn with Apache License 2.0 | 4 votes |
@Override public DeleteTableResult deleteTable(DeleteTableRequest deleteTableRequest) { throw new UnsupportedOperationException(); }
Example #6
Source File: PostgresDynamoDB.java From podyn with Apache License 2.0 | 4 votes |
@Override public DeleteTableResult deleteTable(String tableName) { throw new UnsupportedOperationException(); }
Example #7
Source File: DynamoDbDelegate.java From dynamodb-janusgraph-storage-backend with Apache License 2.0 | 4 votes |
DeleteTableResult deleteTable(final String tableName) throws BackendException { return deleteTable(new DeleteTableRequest().withTableName(tableName)); }
Example #8
Source File: ITAbstractDynamoDBTest.java From nifi with Apache License 2.0 | 4 votes |
@AfterClass public static void afterClass() { DeleteTableResult result = amazonDynamoDBClient.deleteTable(stringHashStringRangeTableName); result = amazonDynamoDBClient.deleteTable(numberHashNumberRangeTableName); result = amazonDynamoDBClient.deleteTable(numberHashOnlyTableName); }
Example #9
Source File: TransactionManagerDynamoDBFacade.java From dynamodb-transactions with Apache License 2.0 | 4 votes |
@Override public DeleteTableResult deleteTable(DeleteTableRequest arg0) throws AmazonServiceException, AmazonClientException { throw new UnsupportedOperationException("Use the underlying client instance instead"); }
Example #10
Source File: TransactionManagerDynamoDBFacade.java From dynamodb-transactions with Apache License 2.0 | 4 votes |
@Override public DeleteTableResult deleteTable(String tableName) throws AmazonServiceException, AmazonClientException { throw new UnsupportedOperationException("Use the underlying client instance instead"); }
Example #11
Source File: ThreadLocalDynamoDBFacade.java From dynamodb-transactions with Apache License 2.0 | 4 votes |
@Override public DeleteTableResult deleteTable(DeleteTableRequest request) throws AmazonServiceException, AmazonClientException { return getBackend().deleteTable(request); }
Example #12
Source File: ThreadLocalDynamoDBFacade.java From dynamodb-transactions with Apache License 2.0 | 4 votes |
@Override public DeleteTableResult deleteTable(String tableName) throws AmazonServiceException, AmazonClientException { return getBackend().deleteTable(tableName); }
Example #13
Source File: TransactionDynamoDBFacade.java From dynamodb-transactions with Apache License 2.0 | 4 votes |
@Override public DeleteTableResult deleteTable(DeleteTableRequest arg0) throws AmazonServiceException, AmazonClientException { throw new UnsupportedOperationException("Use the underlying client instance instead"); }
Example #14
Source File: TransactionDynamoDBFacade.java From dynamodb-transactions with Apache License 2.0 | 4 votes |
@Override public DeleteTableResult deleteTable(String tableName) throws AmazonServiceException, AmazonClientException { throw new UnsupportedOperationException("Use the underlying client instance instead"); }
Example #15
Source File: AmazonDynamoDBStubTest.java From aws-java-sdk-stubs with Apache License 2.0 | 3 votes |
@Test public void test_deleteTable() throws Exception { createTable(); DeleteTableResult deleteResult = dynamoDb.deleteTable(TEST_TABLE_NAME); String tableName = deleteResult.getTableDescription().getTableName(); assertThat(tableName, equalTo(TEST_TABLE_NAME)); ListTablesResult listResult = listTables(); assertThat(listResult.getTableNames().size(), equalTo(0)); }