vkcpiped

package
v1.3.0 Latest Latest
Warning

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

Go to latest
Published: Sep 22, 2025 License: MIT Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type VKOptions

type VKOptions struct {
	WriteClient *redis.Client
	ReadClient  *redis.Client
	Addr        string
	Password    string
	DB          int
	PoolSize    int

	PipeSize      int
	FlushInterval time.Duration
	Workers       int
	QueueCapacity int

	EnqueueTimeout     time.Duration
	WaitAckTimeout     time.Duration
	ExecTimeout        time.Duration
	DirectWriteTimeout time.Duration

	Prefix string

	ResetUseFlushDB bool
	ResetScanCount  int
}

type VKStorage

type VKStorage struct {
	// contains filtered or unexported fields
}

VKStorage implements fiber.Storage

func NewVKStorage

func NewVKStorage(opts VKOptions) (*VKStorage, error)

func NewVKStorageFromClient

func NewVKStorageFromClient(c *redis.Client, tweak func(*VKOptions)) (*VKStorage, error)

func (*VKStorage) Close

func (s *VKStorage) Close() error

func (*VKStorage) Delete

func (s *VKStorage) Delete(key string) error

func (*VKStorage) DeleteWithContext

func (s *VKStorage) DeleteWithContext(ctx context.Context, key string) error

func (*VKStorage) Get

func (s *VKStorage) Get(key string) ([]byte, error)

func (*VKStorage) GetWithContext

func (s *VKStorage) GetWithContext(ctx context.Context, key string) ([]byte, error)

func (*VKStorage) Reset

func (s *VKStorage) Reset() error

func (*VKStorage) ResetWithContext

func (s *VKStorage) ResetWithContext(ctx context.Context) error

func (*VKStorage) Set

func (s *VKStorage) Set(key string, val []byte, exp time.Duration) error

func (*VKStorage) SetWithContext

func (s *VKStorage) SetWithContext(ctx context.Context, key string, val []byte, exp time.Duration) error

Jump to

Keyboard shortcuts

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