cache

package
v0.0.12 Latest Latest
Warning

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

Go to latest
Published: Nov 17, 2024 License: MIT Imports: 3 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func GetFromCache

func GetFromCache(ctx context.Context, cacheInstanceName string, key string, val any) error

GetFromCache - get simple type value from the cache by key

func GetHashmapFromCache

func GetHashmapFromCache(ctx context.Context, cacheInstanceName string, key string, val any) error

GetHashmapFromCache - get map/struct/array value from the cache by key

func HGetFromCache

func HGetFromCache(ctx context.Context, cacheInstanceName string, key string, field string, val any) error

func HSetIntoCache

func HSetIntoCache(ctx context.Context, cacheInstanceName string, key string, expiration time.Duration, val ...any) error

HSetIntoCache - set struct value into the cache by key

func Release

func Release() error

Release - release the cache connection

func SetHashmapIntoCache

func SetHashmapIntoCache(ctx context.Context, cacheInstanceName string, key string, val any, expiration time.Duration) error

SetHashmapIntoCache - set map/struct/array value into cache by key

func SetIntoCache

func SetIntoCache(ctx context.Context, cacheInstanceName string, key string, val any, expiration time.Duration) error

SetIntoCache - set simple type value into cache by key

Types

This section is empty.

Jump to

Keyboard shortcuts

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