coredb

package
v1.0.12 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Aug 12, 2023 License: MIT Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type DB

type DB struct {
	Client *dynamodb.DynamoDB
}

func NewDb

func NewDb() (*DB, error)

CreateDynamoDBClient creates a new DynamoDB client and session

func (DB) CacheData

func (c DB) CacheData(table_name string, partition_key string, sort_key string, attributes interface{}, ttl int64) error

func (DB) DeleteRecord

func (c DB) DeleteRecord(table_name string, partition_key string, sort_key *string) error

func (DB) MutateDatabase

func (c DB) MutateDatabase(table_name string, partition_key string, sort_key string, attributes interface{}) error

func (DB) QueryDatabase

func (c DB) QueryDatabase(table_name string, partition_key string, sort_key *string) (*dynamodb.GetItemOutput, error)

func (DB) QueryDatabasePartition

func (c DB) QueryDatabasePartition(table_name string, partition_key string) (*dynamodb.QueryOutput, error)

func (DB) UpdateRecord

func (c DB) UpdateRecord(table_name string, partition_key string, sort_key string, attributes interface{}) error

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL