Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func WithLock ¶
WithLock will ensure that a lock is refreshed after ever call to the DynamoDB service. The returned options modifier function can be used in a Query or Scan execution
func WithMapFn ¶
func WithMapFn(mapFn func(map[string]types.AttributeValue) (interface{}, error)) func(options *Options)
WithMapFn returns an options modifier function that sets an unmarshalling method of a Scan or Query execution
func WithUnmarshalToItemMapFn ¶ added in v0.0.2
WithUnmarshalToItemMapFn returns an options modifier function that sets an attributevalue unmarshalling . The returned options modifier function can be used in a Query or Scan execution
Types ¶
type DynamodbClient ¶
type Executor ¶
type Executor struct {
// contains filtered or unexported fields
}
Executor can execute DynamoDB query and scan executions while abstracting pagination and unmarshalling complexity
func New ¶ added in v0.0.2
func New(client DynamodbClient) *Executor
New creates a new DynamoDB query/scan executor. The executor will execute on the DynamodbClient given as client parameter.
type Options ¶
type Options struct { // MapFn is used to map all returned elements in the executor MapFn func(map[string]types.AttributeValue) (interface{}, error) // Lock if not nil Lock is refreshed after every call // Note there are no guarantees that retrieved data is still locked by the lock Lock Lock }