mirror of
https://github.com/gofiber/storage.git
synced 2025-12-24 05:08:39 +08:00
Bumps the aws-modules group with 3 updates in the /dynamodb directory: [github.com/aws/aws-sdk-go-v2](https://github.com/aws/aws-sdk-go-v2), [github.com/aws/aws-sdk-go-v2/config](https://github.com/aws/aws-sdk-go-v2) and [github.com/aws/aws-sdk-go-v2/feature/dynamodb/attributevalue](https://github.com/aws/aws-sdk-go-v2). Bumps the aws-modules group with 3 updates in the /s3 directory: [github.com/aws/aws-sdk-go-v2](https://github.com/aws/aws-sdk-go-v2), [github.com/aws/aws-sdk-go-v2/config](https://github.com/aws/aws-sdk-go-v2) and [github.com/aws/aws-sdk-go-v2/feature/s3/manager](https://github.com/aws/aws-sdk-go-v2). Updates `github.com/aws/aws-sdk-go-v2` from 1.40.0 to 1.40.1 - [Release notes](https://github.com/aws/aws-sdk-go-v2/releases) - [Changelog](https://github.com/aws/aws-sdk-go-v2/blob/main/changelog-template.json) - [Commits](https://github.com/aws/aws-sdk-go-v2/compare/v1.40.0...v1.40.1) Updates `github.com/aws/aws-sdk-go-v2/config` from 1.32.2 to 1.32.3 - [Release notes](https://github.com/aws/aws-sdk-go-v2/releases) - [Changelog](https://github.com/aws/aws-sdk-go-v2/blob/main/changelog-template.json) - [Commits](https://github.com/aws/aws-sdk-go-v2/compare/v1.32.2...v1.32.3) Updates `github.com/aws/aws-sdk-go-v2/credentials` from 1.19.2 to 1.19.3 - [Release notes](https://github.com/aws/aws-sdk-go-v2/releases) - [Changelog](https://github.com/aws/aws-sdk-go-v2/blob/main/changelog-template.json) - [Commits](https://github.com/aws/aws-sdk-go-v2/compare/service/m2/v1.19.2...service/pi/v1.19.3) Updates `github.com/aws/aws-sdk-go-v2/feature/dynamodb/attributevalue` from 1.20.26 to 1.20.27 - [Release notes](https://github.com/aws/aws-sdk-go-v2/releases) - [Changelog](https://github.com/aws/aws-sdk-go-v2/blob/main/changelog-template.json) - [Commits](https://github.com/aws/aws-sdk-go-v2/compare/feature/dynamodb/attributevalue/v1.20.26...feature/dynamodb/attributevalue/v1.20.27) Updates `github.com/aws/aws-sdk-go-v2/service/dynamodb` from 1.53.2 to 1.53.3 - [Release notes](https://github.com/aws/aws-sdk-go-v2/releases) - [Changelog](https://github.com/aws/aws-sdk-go-v2/blob/main/changelog-template.json) - [Commits](https://github.com/aws/aws-sdk-go-v2/compare/service/s3/v1.53.2...service/ecs/v1.53.3) Updates `github.com/aws/aws-sdk-go-v2/feature/ec2/imds` from 1.18.14 to 1.18.15 - [Release notes](https://github.com/aws/aws-sdk-go-v2/releases) - [Changelog](https://github.com/aws/aws-sdk-go-v2/blob/main/changelog-template.json) - [Commits](https://github.com/aws/aws-sdk-go-v2/compare/config/v1.18.14...config/v1.18.15) Updates `github.com/aws/aws-sdk-go-v2/internal/configsources` from 1.4.14 to 1.4.15 - [Release notes](https://github.com/aws/aws-sdk-go-v2/releases) - [Changelog](https://github.com/aws/aws-sdk-go-v2/blob/main/changelog-template.json) - [Commits](https://github.com/aws/aws-sdk-go-v2/compare/internal/v4a/v1.4.14...internal/v4a/v1.4.15) Updates `github.com/aws/aws-sdk-go-v2/internal/endpoints/v2` from 2.7.14 to 2.7.15 - [Release notes](https://github.com/aws/aws-sdk-go-v2/releases) - [Changelog](https://github.com/aws/aws-sdk-go-v2/blob/main/changelog-template.json) - [Commits](https://github.com/aws/aws-sdk-go-v2/compare/internal/endpoints/v2.7.14...internal/endpoints/v2.7.15) Updates `github.com/aws/aws-sdk-go-v2/service/dynamodbstreams` from 1.32.6 to 1.32.7 - [Release notes](https://github.com/aws/aws-sdk-go-v2/releases) - [Changelog](https://github.com/aws/aws-sdk-go-v2/blob/main/changelog-template.json) - [Commits](https://github.com/aws/aws-sdk-go-v2/compare/v1.32.6...v1.32.7) Updates `github.com/aws/aws-sdk-go-v2/service/internal/accept-encoding` from 1.13.3 to 1.13.4 - [Release notes](https://github.com/aws/aws-sdk-go-v2/releases) - [Changelog](https://github.com/aws/aws-sdk-go-v2/blob/main/changelog-template.json) - [Commits](https://github.com/aws/aws-sdk-go-v2/compare/service/m2/v1.13.3...service/mq/v1.13.4) Updates `github.com/aws/aws-sdk-go-v2/service/internal/endpoint-discovery` from 1.11.14 to 1.11.15 - [Release notes](https://github.com/aws/aws-sdk-go-v2/releases) - [Changelog](https://github.com/aws/aws-sdk-go-v2/blob/main/changelog-template.json) - [Commits](https://github.com/aws/aws-sdk-go-v2/compare/service/sso/v1.11.14...service/waf/v1.11.15) Updates `github.com/aws/aws-sdk-go-v2/service/internal/presigned-url` from 1.13.14 to 1.13.15 - [Release notes](https://github.com/aws/aws-sdk-go-v2/releases) - [Changelog](https://github.com/aws/aws-sdk-go-v2/blob/main/changelog-template.json) - [Commits](https://github.com/aws/aws-sdk-go-v2/compare/service/mq/v1.13.14...service/mq/v1.13.15) Updates `github.com/aws/aws-sdk-go-v2/service/signin` from 1.0.2 to 1.0.3 - [Release notes](https://github.com/aws/aws-sdk-go-v2/releases) - [Changelog](https://github.com/aws/aws-sdk-go-v2/blob/main/changelog-template.json) - [Commits](https://github.com/aws/aws-sdk-go-v2/compare/service/m2/v1.0.2...service/m2/v1.0.3) Updates `github.com/aws/aws-sdk-go-v2/service/sso` from 1.30.5 to 1.30.6 - [Release notes](https://github.com/aws/aws-sdk-go-v2/releases) - [Changelog](https://github.com/aws/aws-sdk-go-v2/blob/main/changelog-template.json) - [Commits](https://github.com/aws/aws-sdk-go-v2/compare/v1.30.5...service/s3/v1.30.6) Updates `github.com/aws/aws-sdk-go-v2/service/ssooidc` from 1.35.10 to 1.35.11 - [Release notes](https://github.com/aws/aws-sdk-go-v2/releases) - [Changelog](https://github.com/aws/aws-sdk-go-v2/blob/main/changelog-template.json) - [Commits](https://github.com/aws/aws-sdk-go-v2/compare/service/pi/v1.35.10...service/pi/v1.35.11) Updates `github.com/aws/aws-sdk-go-v2/service/sts` from 1.41.2 to 1.41.3 - [Release notes](https://github.com/aws/aws-sdk-go-v2/releases) - [Changelog](https://github.com/aws/aws-sdk-go-v2/blob/main/changelog-template.json) - [Commits](https://github.com/aws/aws-sdk-go-v2/compare/service/ivs/v1.41.2...service/kms/v1.41.3) Updates `github.com/aws/smithy-go` from 1.23.2 to 1.24.0 - [Release notes](https://github.com/aws/smithy-go/releases) - [Changelog](https://github.com/aws/smithy-go/blob/main/CHANGELOG.md) - [Commits](https://github.com/aws/smithy-go/compare/v1.23.2...v1.24.0) Updates `github.com/aws/aws-sdk-go-v2` from 1.40.0 to 1.40.1 - [Release notes](https://github.com/aws/aws-sdk-go-v2/releases) - [Changelog](https://github.com/aws/aws-sdk-go-v2/blob/main/changelog-template.json) - [Commits](https://github.com/aws/aws-sdk-go-v2/compare/v1.40.0...v1.40.1) Updates `github.com/aws/aws-sdk-go-v2/config` from 1.32.2 to 1.32.3 - [Release notes](https://github.com/aws/aws-sdk-go-v2/releases) - [Changelog](https://github.com/aws/aws-sdk-go-v2/blob/main/changelog-template.json) - [Commits](https://github.com/aws/aws-sdk-go-v2/compare/v1.32.2...v1.32.3) Updates `github.com/aws/aws-sdk-go-v2/credentials` from 1.19.2 to 1.19.3 - [Release notes](https://github.com/aws/aws-sdk-go-v2/releases) - [Changelog](https://github.com/aws/aws-sdk-go-v2/blob/main/changelog-template.json) - [Commits](https://github.com/aws/aws-sdk-go-v2/compare/service/m2/v1.19.2...service/pi/v1.19.3) Updates `github.com/aws/aws-sdk-go-v2/feature/ec2/imds` from 1.18.14 to 1.18.15 - [Release notes](https://github.com/aws/aws-sdk-go-v2/releases) - [Changelog](https://github.com/aws/aws-sdk-go-v2/blob/main/changelog-template.json) - [Commits](https://github.com/aws/aws-sdk-go-v2/compare/config/v1.18.14...config/v1.18.15) Updates `github.com/aws/aws-sdk-go-v2/internal/configsources` from 1.4.14 to 1.4.15 - [Release notes](https://github.com/aws/aws-sdk-go-v2/releases) - [Changelog](https://github.com/aws/aws-sdk-go-v2/blob/main/changelog-template.json) - [Commits](https://github.com/aws/aws-sdk-go-v2/compare/internal/v4a/v1.4.14...internal/v4a/v1.4.15) Updates `github.com/aws/aws-sdk-go-v2/internal/endpoints/v2` from 2.7.14 to 2.7.15 - [Release notes](https://github.com/aws/aws-sdk-go-v2/releases) - [Changelog](https://github.com/aws/aws-sdk-go-v2/blob/main/changelog-template.json) - [Commits](https://github.com/aws/aws-sdk-go-v2/compare/internal/endpoints/v2.7.14...internal/endpoints/v2.7.15) Updates `github.com/aws/aws-sdk-go-v2/service/internal/accept-encoding` from 1.13.3 to 1.13.4 - [Release notes](https://github.com/aws/aws-sdk-go-v2/releases) - [Changelog](https://github.com/aws/aws-sdk-go-v2/blob/main/changelog-template.json) - [Commits](https://github.com/aws/aws-sdk-go-v2/compare/service/m2/v1.13.3...service/mq/v1.13.4) Updates `github.com/aws/aws-sdk-go-v2/service/internal/presigned-url` from 1.13.14 to 1.13.15 - [Release notes](https://github.com/aws/aws-sdk-go-v2/releases) - [Changelog](https://github.com/aws/aws-sdk-go-v2/blob/main/changelog-template.json) - [Commits](https://github.com/aws/aws-sdk-go-v2/compare/service/mq/v1.13.14...service/mq/v1.13.15) Updates `github.com/aws/aws-sdk-go-v2/service/signin` from 1.0.2 to 1.0.3 - [Release notes](https://github.com/aws/aws-sdk-go-v2/releases) - [Changelog](https://github.com/aws/aws-sdk-go-v2/blob/main/changelog-template.json) - [Commits](https://github.com/aws/aws-sdk-go-v2/compare/service/m2/v1.0.2...service/m2/v1.0.3) Updates `github.com/aws/aws-sdk-go-v2/service/sso` from 1.30.5 to 1.30.6 - [Release notes](https://github.com/aws/aws-sdk-go-v2/releases) - [Changelog](https://github.com/aws/aws-sdk-go-v2/blob/main/changelog-template.json) - [Commits](https://github.com/aws/aws-sdk-go-v2/compare/v1.30.5...service/s3/v1.30.6) Updates `github.com/aws/aws-sdk-go-v2/service/ssooidc` from 1.35.10 to 1.35.11 - [Release notes](https://github.com/aws/aws-sdk-go-v2/releases) - [Changelog](https://github.com/aws/aws-sdk-go-v2/blob/main/changelog-template.json) - [Commits](https://github.com/aws/aws-sdk-go-v2/compare/service/pi/v1.35.10...service/pi/v1.35.11) Updates `github.com/aws/aws-sdk-go-v2/service/sts` from 1.41.2 to 1.41.3 - [Release notes](https://github.com/aws/aws-sdk-go-v2/releases) - [Changelog](https://github.com/aws/aws-sdk-go-v2/blob/main/changelog-template.json) - [Commits](https://github.com/aws/aws-sdk-go-v2/compare/service/ivs/v1.41.2...service/kms/v1.41.3) Updates `github.com/aws/smithy-go` from 1.23.2 to 1.24.0 - [Release notes](https://github.com/aws/smithy-go/releases) - [Changelog](https://github.com/aws/smithy-go/blob/main/CHANGELOG.md) - [Commits](https://github.com/aws/smithy-go/compare/v1.23.2...v1.24.0) Updates `github.com/aws/aws-sdk-go-v2/feature/s3/manager` from 1.20.12 to 1.20.13 - [Release notes](https://github.com/aws/aws-sdk-go-v2/releases) - [Changelog](https://github.com/aws/aws-sdk-go-v2/blob/main/changelog-template.json) - [Commits](https://github.com/aws/aws-sdk-go-v2/compare/service/sns/v1.20.12...service/emr/v1.20.13) Updates `github.com/aws/aws-sdk-go-v2/service/s3` from 1.92.1 to 1.93.0 - [Release notes](https://github.com/aws/aws-sdk-go-v2/releases) - [Changelog](https://github.com/aws/aws-sdk-go-v2/blob/main/changelog-template.json) - [Commits](https://github.com/aws/aws-sdk-go-v2/compare/service/s3/v1.92.1...service/s3/v1.93.0) Updates `github.com/aws/aws-sdk-go-v2/aws/protocol/eventstream` from 1.7.3 to 1.7.4 - [Release notes](https://github.com/aws/aws-sdk-go-v2/releases) - [Changelog](https://github.com/aws/aws-sdk-go-v2/blob/main/changelog-template.json) - [Commits](https://github.com/aws/aws-sdk-go-v2/compare/service/m2/v1.7.3...service/m2/v1.7.4) Updates `github.com/aws/aws-sdk-go-v2/internal/v4a` from 1.4.14 to 1.4.15 - [Release notes](https://github.com/aws/aws-sdk-go-v2/releases) - [Changelog](https://github.com/aws/aws-sdk-go-v2/blob/main/changelog-template.json) - [Commits](https://github.com/aws/aws-sdk-go-v2/compare/internal/v4a/v1.4.14...internal/v4a/v1.4.15) Updates `github.com/aws/aws-sdk-go-v2/service/internal/checksum` from 1.9.5 to 1.9.6 - [Release notes](https://github.com/aws/aws-sdk-go-v2/releases) - [Changelog](https://github.com/aws/aws-sdk-go-v2/blob/main/changelog-template.json) - [Commits](https://github.com/aws/aws-sdk-go-v2/compare/service/m2/v1.9.5...service/dsql/v1.9.6) Updates `github.com/aws/aws-sdk-go-v2/service/internal/s3shared` from 1.19.14 to 1.19.15 - [Release notes](https://github.com/aws/aws-sdk-go-v2/releases) - [Changelog](https://github.com/aws/aws-sdk-go-v2/blob/main/changelog-template.json) - [Commits](https://github.com/aws/aws-sdk-go-v2/compare/service/sqs/v1.19.14...service/sqs/v1.19.15) --- updated-dependencies: - dependency-name: github.com/aws/aws-sdk-go-v2 dependency-version: 1.40.1 dependency-type: direct:production update-type: version-update:semver-patch dependency-group: aws-modules - dependency-name: github.com/aws/aws-sdk-go-v2/config dependency-version: 1.32.3 dependency-type: direct:production update-type: version-update:semver-patch dependency-group: aws-modules - dependency-name: github.com/aws/aws-sdk-go-v2/credentials dependency-version: 1.19.3 dependency-type: direct:production update-type: version-update:semver-patch dependency-group: aws-modules - dependency-name: github.com/aws/aws-sdk-go-v2/feature/dynamodb/attributevalue dependency-version: 1.20.27 dependency-type: direct:production update-type: version-update:semver-patch dependency-group: aws-modules - dependency-name: github.com/aws/aws-sdk-go-v2/service/dynamodb dependency-version: 1.53.3 dependency-type: direct:production update-type: version-update:semver-patch dependency-group: aws-modules - dependency-name: github.com/aws/aws-sdk-go-v2/feature/ec2/imds dependency-version: 1.18.15 dependency-type: indirect update-type: version-update:semver-patch dependency-group: aws-modules - dependency-name: github.com/aws/aws-sdk-go-v2/internal/configsources dependency-version: 1.4.15 dependency-type: indirect update-type: version-update:semver-patch dependency-group: aws-modules - dependency-name: github.com/aws/aws-sdk-go-v2/internal/endpoints/v2 dependency-version: 2.7.15 dependency-type: indirect update-type: version-update:semver-patch dependency-group: aws-modules - dependency-name: github.com/aws/aws-sdk-go-v2/service/dynamodbstreams dependency-version: 1.32.7 dependency-type: indirect update-type: version-update:semver-patch dependency-group: aws-modules - dependency-name: github.com/aws/aws-sdk-go-v2/service/internal/accept-encoding dependency-version: 1.13.4 dependency-type: indirect update-type: version-update:semver-patch dependency-group: aws-modules - dependency-name: github.com/aws/aws-sdk-go-v2/service/internal/endpoint-discovery dependency-version: 1.11.15 dependency-type: indirect update-type: version-update:semver-patch dependency-group: aws-modules - dependency-name: github.com/aws/aws-sdk-go-v2/service/internal/presigned-url dependency-version: 1.13.15 dependency-type: indirect update-type: version-update:semver-patch dependency-group: aws-modules - dependency-name: github.com/aws/aws-sdk-go-v2/service/signin dependency-version: 1.0.3 dependency-type: indirect update-type: version-update:semver-patch dependency-group: aws-modules - dependency-name: github.com/aws/aws-sdk-go-v2/service/sso dependency-version: 1.30.6 dependency-type: indirect update-type: version-update:semver-patch dependency-group: aws-modules - dependency-name: github.com/aws/aws-sdk-go-v2/service/ssooidc dependency-version: 1.35.11 dependency-type: indirect update-type: version-update:semver-patch dependency-group: aws-modules - dependency-name: github.com/aws/aws-sdk-go-v2/service/sts dependency-version: 1.41.3 dependency-type: indirect update-type: version-update:semver-patch dependency-group: aws-modules - dependency-name: github.com/aws/smithy-go dependency-version: 1.24.0 dependency-type: indirect update-type: version-update:semver-minor dependency-group: aws-modules - dependency-name: github.com/aws/aws-sdk-go-v2 dependency-version: 1.40.1 dependency-type: direct:production update-type: version-update:semver-patch dependency-group: aws-modules - dependency-name: github.com/aws/aws-sdk-go-v2/config dependency-version: 1.32.3 dependency-type: direct:production update-type: version-update:semver-patch dependency-group: aws-modules - dependency-name: github.com/aws/aws-sdk-go-v2/credentials dependency-version: 1.19.3 dependency-type: direct:production update-type: version-update:semver-patch dependency-group: aws-modules - dependency-name: github.com/aws/aws-sdk-go-v2/feature/ec2/imds dependency-version: 1.18.15 dependency-type: indirect update-type: version-update:semver-patch dependency-group: aws-modules - dependency-name: github.com/aws/aws-sdk-go-v2/internal/configsources dependency-version: 1.4.15 dependency-type: indirect update-type: version-update:semver-patch dependency-group: aws-modules - dependency-name: github.com/aws/aws-sdk-go-v2/internal/endpoints/v2 dependency-version: 2.7.15 dependency-type: indirect update-type: version-update:semver-patch dependency-group: aws-modules - dependency-name: github.com/aws/aws-sdk-go-v2/service/internal/accept-encoding dependency-version: 1.13.4 dependency-type: indirect update-type: version-update:semver-patch dependency-group: aws-modules - dependency-name: github.com/aws/aws-sdk-go-v2/service/internal/presigned-url dependency-version: 1.13.15 dependency-type: indirect update-type: version-update:semver-patch dependency-group: aws-modules - dependency-name: github.com/aws/aws-sdk-go-v2/service/signin dependency-version: 1.0.3 dependency-type: indirect update-type: version-update:semver-patch dependency-group: aws-modules - dependency-name: github.com/aws/aws-sdk-go-v2/service/sso dependency-version: 1.30.6 dependency-type: indirect update-type: version-update:semver-patch dependency-group: aws-modules - dependency-name: github.com/aws/aws-sdk-go-v2/service/ssooidc dependency-version: 1.35.11 dependency-type: indirect update-type: version-update:semver-patch dependency-group: aws-modules - dependency-name: github.com/aws/aws-sdk-go-v2/service/sts dependency-version: 1.41.3 dependency-type: indirect update-type: version-update:semver-patch dependency-group: aws-modules - dependency-name: github.com/aws/smithy-go dependency-version: 1.24.0 dependency-type: direct:production update-type: version-update:semver-minor dependency-group: aws-modules - dependency-name: github.com/aws/aws-sdk-go-v2/feature/s3/manager dependency-version: 1.20.13 dependency-type: direct:production update-type: version-update:semver-patch dependency-group: aws-modules - dependency-name: github.com/aws/aws-sdk-go-v2/service/s3 dependency-version: 1.93.0 dependency-type: direct:production update-type: version-update:semver-minor dependency-group: aws-modules - dependency-name: github.com/aws/aws-sdk-go-v2/aws/protocol/eventstream dependency-version: 1.7.4 dependency-type: indirect update-type: version-update:semver-patch dependency-group: aws-modules - dependency-name: github.com/aws/aws-sdk-go-v2/internal/v4a dependency-version: 1.4.15 dependency-type: indirect update-type: version-update:semver-patch dependency-group: aws-modules - dependency-name: github.com/aws/aws-sdk-go-v2/service/internal/checksum dependency-version: 1.9.6 dependency-type: indirect update-type: version-update:semver-patch dependency-group: aws-modules - dependency-name: github.com/aws/aws-sdk-go-v2/service/internal/s3shared dependency-version: 1.19.15 dependency-type: indirect update-type: version-update:semver-patch dependency-group: aws-modules ... Signed-off-by: dependabot[bot] <support@github.com>
id, title
| id | title |
|---|---|
| dynamodb | DynamoDB |
A DynamoDB storage driver using aws/aws-sdk-go-v2.
Note: If config fields of credentials not given, credentials are using from the environment variables, ~/.aws/credentials, or EC2 instance role. If config fields of credentials given, credentials are using from config. Look at: specifying credentials
Table of Contents
Signatures
func New(config Config) Storage
func (s *Storage) Get(key string) ([]byte, error)
func (s *Storage) GetWithContext(ctx context.Context, key string) ([]byte, error)
func (s *Storage) Set(key string, val []byte, exp time.Duration) error
func (s *Storage) SetWithContext(ctx context.Context, key string, val []byte, exp time.Duration) error
func (s *Storage) Delete(key string) error
func (s *Storage) DeleteWithContext(ctx context.Context, key string) error
func (s *Storage) Reset() error
func (s *Storage) ResetWithContext(ctx context.Context) error
func (s *Storage) Close() error
func (s *Storage) Conn() *awsdynamodb.Client
Installation
DynamoDB is tested on the 2 last Go versions with support for modules. So make sure to initialize one first if you didn't do that yet:
go mod init github.com/<user>/<repo>
And then install the dynamodb implementation:
go get github.com/gofiber/storage/dynamodb/v2
Examples
Import the storage package.
import "github.com/gofiber/storage/dynamodb/v2"
You can use the following possibilities to create a storage:
// Initialize dynamodb
store := dynamodb.New(dynamodb.Config{
})
Config
type Config struct {
// Region of the DynamoDB service you want to use.
// Valid values: https://docs.aws.amazon.com/general/latest/gr/rande.html#ddb_region.
// E.g. "us-west-2".
// Optional (read from shared config file or environment variable if not set).
// Environment variable: "AWS_REGION".
Region string
// Name of the DynamoDB table.
// Optional ("fiber_storage" by default).
Table string
// CustomEndpoint allows you to set a custom DynamoDB service endpoint.
// This is especially useful if you're running a "DynamoDB local" Docker container for local testing.
// Typical value for the Docker container: "http://localhost:8000".
// See https://hub.docker.com/r/amazon/dynamodb-local/.
// Optional ("" by default)
Endpoint string
// Credentials overrides AWS access key and AWS secret access key. Not recommended.
//
// Optional. Default is Credentials{}
Credentials Credentials
// The maximum number of times requests that encounter retryable failures should be attempted.
//
// Optional. Default is 3
MaxAttempts int
// Reset clears any existing keys in existing Bucket
//
// Optional. Default is false
Reset bool
// ReadCapacityUnits of the table.
// Only required when the table doesn't exist yet and is created by gokv.
// Optional (5 by default, which is the same default value as when creating a table in the web console)
// 25 RCUs are included in the free tier (across all tables).
// For example calculations, see https://github.com/awsdocs/amazon-dynamodb-developer-guide/blob/c420420a59040c5b3dd44a6e59f7c9e55fc922ef/doc_source/HowItWorks.ProvisionedThroughput.
// For limits, see https://github.com/awsdocs/amazon-dynamodb-developer-guide/blob/c420420a59040c5b3dd44a6e59f7c9e55fc922ef/doc_source/Limits.md#capacity-units-and-provisioned-throughput.md#provisioned-throughput.
ReadCapacityUnits int64
// ReadCapacityUnits of the table.
// Only required when the table doesn't exist yet and is created by gokv.
// Optional (5 by default, which is the same default value as when creating a table in the web console)
// 25 RCUs are included in the free tier (across all tables).
// For example calculations, see https://github.com/awsdocs/amazon-dynamodb-developer-guide/blob/c420420a59040c5b3dd44a6e59f7c9e55fc922ef/doc_source/HowItWorks.ProvisionedThroughput.
// For limits, see https://github.com/awsdocs/amazon-dynamodb-developer-guide/blob/c420420a59040c5b3dd44a6e59f7c9e55fc922ef/doc_source/Limits.md#capacity-units-and-provisioned-throughput.md#provisioned-throughput.
WriteCapacityUnits int64
// If the table doesn't exist yet, gokv creates it.
// If WaitForTableCreation is true, gokv will block until the table is created, with a timeout of 15 seconds.
// If the table still doesn't exist after 15 seconds, an error is returned.
// If WaitForTableCreation is false, gokv returns the client immediately.
// In the latter case you need to make sure that you don't read from or write to the table before it's created,
// because otherwise you will get ResourceNotFoundException errors.
// Optional (true by default).
WaitForTableCreation *bool
}
type Credentials struct {
AccessKey string
SecretAccessKey string
}
Default Config
var ConfigDefault = Config{
Table: "fiber_storage",
Credentials: Credentials{},
MaxAttempts: 3,
Reset: false,
ReadCapacityUnits: 5,
WriteCapacityUnits: 5,
WaitForTableCreation: aws.Bool(true),
}