Documentation
¶
Overview ¶
Package dynamokv provides a kv.BinaryStore implementation that persists to a DynamoDB table.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func CreateTable ¶
func CreateTable( ctx context.Context, client *dynamodb.Client, table string, decorators ...func(*dynamodb.CreateTableInput) []func(*dynamodb.Options), ) error
CreateTable creates a DynamoDB table for use with BinaryStore.
Types ¶
type BinaryStore ¶ added in v0.8.0
type BinaryStore struct {
// Client is the DynamoDB client to use.
Client *dynamodb.Client
// Table is the table name used for storage of journal records.
Table string
// DecorateGetItem is an optional function that is called before each
// DynamoDB "GetItem" request.
//
// It may modify the API input in-place. It returns options that will be
// applied to the request.
DecorateGetItem func(*dynamodb.GetItemInput) []func(*dynamodb.Options)
// DecorateQuery is an optional function that is called before each DynamoDB
// "Query" request.
//
// It may modify the API input in-place. It returns options that will be
// applied to the request.
DecorateQuery func(*dynamodb.QueryInput) []func(*dynamodb.Options)
// DecoratePutItem is an optional function that is called before each
// DynamoDB "PutItem" request.
//
// It may modify the API input in-place. It returns options that will be
// applied to the request.
DecoratePutItem func(*dynamodb.PutItemInput) []func(*dynamodb.Options)
// DecorateDeleteItem is an optional function that is called before each
// DynamoDB "DeleteItem" request.
//
// It may modify the API input in-place. It returns options that will be
// applied to the request.
DecorateDeleteItem func(*dynamodb.DeleteItemInput) []func(*dynamodb.Options)
}
BinaryStore is an implementation of kv.BinaryStore that persists to a DynamoDB table.
func (*BinaryStore) Open ¶ added in v0.8.0
func (s *BinaryStore) Open(_ context.Context, name string) (kv.BinaryKeyspace, error)
Open returns the keyspace with the given name.
Click to show internal directories.
Click to hide internal directories.