Package io.inversion.dynamodb
Class DynamoDb
java.lang.Object
io.inversion.Db<DynamoDb>
io.inversion.dynamodb.DynamoDb
-
Field Summary
FieldsModifier and TypeFieldDescriptionprotected Stringprotected Stringprotected Stringprotected Stringprotected final intprotected StringUse to config which row is used to build the column/attribute model (otherwise first row of scan will be used)protected com.amazonaws.services.dynamodbv2.AmazonDynamoDBstatic final Stringstatic final Stringstatic final Stringstatic final StringFields inherited from class io.inversion.Db
bootstrap, collections, dryRun, endpointPath, excludeColumns, includeColumns, includeTables, log, name, reservedParams, type -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprotected voidaddTableIndex(String type, String indexName, List<com.amazonaws.services.dynamodbv2.model.KeySchemaElement> keySchemaList, io.inversion.Collection table, boolean unique) protected io.inversion.CollectionbuildCollection(String tableName) static com.amazonaws.services.dynamodbv2.AmazonDynamoDBbuildDynamoClient(String prefix) static com.amazonaws.services.dynamodbv2.AmazonDynamoDBbuildDynamoClient(String awsRegion, String awsAccessKey, String awsSecretKey, String awsEndpoint) voidconfigDb()voidvoidio.inversion.Resultsstatic io.inversion.IndexfindIndexByName(io.inversion.Collection coll, String name) com.amazonaws.services.dynamodbv2.AmazonDynamoDBcom.amazonaws.services.dynamodbv2.document.TablegetDynamoTable(io.inversion.Collection table) com.amazonaws.services.dynamodbv2.document.TablegetDynamoTable(String tableName) protected static StringtoString()withAwsAccessKey(String awsAccessKey) withAwsEndpoint(String awsEndpoint) withAwsRegion(String awsRegion) withAwsSecretKey(String awsSecretKey) withBlueprintRow(String blueprintRow) Methods inherited from class io.inversion.Db
beautifyCollectionName, beautifyName, buildCollections, buildRelationships, castDbOutput, castJsonInput, castJsonInput, configApi, doPatch, doShutdown, doShutdown, doStartup, filterOutJsonProperty, getCollectionByTableName, getCollections, getEndpointPath, getHref, getKey, getName, getProperty, getType, isBootstrap, isDryRun, isRunning, isType, makeRelationshipName, mapTo, mapToColumnNames, mapToJsonNames, patch, removeCollection, select, shutdown, shutdown, startup, upsert, withBootstrap, withCollection, withCollections, withDryRun, withEndpointPath, withExcludeColumns, withIncludeColumns, withIncludeTable, withIncludeTables, withName, withType
-
Field Details
-
PRIMARY_INDEX_NAME
- See Also:
-
PRIMARY_INDEX_TYPE
- See Also:
-
LOCAL_SECONDARY_INDEX_TYPE
- See Also:
-
GLOBAL_SECONDARY_INDEX_TYPE
- See Also:
-
batchMax
protected final int batchMax- See Also:
-
awsAccessKey
-
awsSecretKey
-
awsRegion
-
awsEndpoint
-
blueprintRow
Use to config which row is used to build the column/attribute model (otherwise first row of scan will be used)FORMAT: collection name | primaryKey | sortKey (optional)
-
dynamoClient
protected transient com.amazonaws.services.dynamodbv2.AmazonDynamoDB dynamoClient
-
-
Constructor Details
-
DynamoDb
public DynamoDb() -
DynamoDb
-
-
Method Details
-
findIndexByName
-
getTypeStringFromObject
-
buildDynamoClient
-
buildDynamoClient
-
doSelect
public io.inversion.Results doSelect(io.inversion.Collection table, List<io.inversion.rql.Term> columnMappedTerms) throws io.inversion.ApiException - Specified by:
doSelectin classio.inversion.Db<DynamoDb>- Throws:
io.inversion.ApiException
-
doUpsert
public List<String> doUpsert(io.inversion.Collection table, List<Map<String, Object>> rows) throws io.inversion.ApiException- Specified by:
doUpsertin classio.inversion.Db<DynamoDb>- Throws:
io.inversion.ApiException
-
delete
public void delete(io.inversion.Collection table, List<Map<String, Object>> indexValues) throws io.inversion.ApiException- Specified by:
deletein classio.inversion.Db<DynamoDb>- Throws:
io.inversion.ApiException
-
deleteRow
public void deleteRow(io.inversion.Collection table, Map<String, Object> row) throws io.inversion.ApiException- Throws:
io.inversion.ApiException
-
configDb
public void configDb() throws io.inversion.ApiException- Overrides:
configDbin classio.inversion.Db<DynamoDb>- Throws:
io.inversion.ApiException
-
buildCollection
-
addTableIndex
-
getDynamoTable
public com.amazonaws.services.dynamodbv2.document.Table getDynamoTable(io.inversion.Collection table) -
getDynamoTable
-
withBlueprintRow
-
withAwsRegion
-
withAwsAccessKey
-
withAwsSecretKey
-
withAwsEndpoint
-
toString
-
getDynamoClient
public com.amazonaws.services.dynamodbv2.AmazonDynamoDB getDynamoClient()
-