Documentation ¶
Overview ¶
Package db is a DB helper interface for AWS DynamoDB
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type DynamoDBHelper ¶
type DynamoDBHelper struct { Region string // contains filtered or unexported fields }
DynamoDBHelper is a DB helper structure
func GetInstance ¶
func GetInstance(region string) *DynamoDBHelper
GetInstance returns an instance of DbHelper region is blank or aws-region such as ap-northeast-2 In case of blank, use AWS_DEFAULT_REGION as region
func (*DynamoDBHelper) GetItem ¶
func (d *DynamoDBHelper) GetItem(tblName, propName, propVal, targetName string) *dynamodb.ScanOutput
GetItem returns queried result following inputs For table named "tblName" in DynamoDB, Scan target value following propName is propVal
----------------------------- | propName | targetName | ----------------------------- | propVal | targetVal | | ... | ... | -----------------------------
func (*DynamoDBHelper) ListTables ¶
func (d *DynamoDBHelper) ListTables()
ListTables lists table names
func (*DynamoDBHelper) UnmarshalMap ¶
func (d *DynamoDBHelper) UnmarshalMap(in map[string]*dynamodb.AttributeValue, out interface{})
UnmarshalMap makes output data from DynamoDB output
Click to show internal directories.
Click to hide internal directories.