cache

package
v0.7.1 Latest Latest
Warning

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

Go to latest
Published: Dec 15, 2022 License: Apache-2.0 Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func GetFromBigCache

func GetFromBigCache(ids []int64, out interface{}, keyMaker func(int64) string) ([]int64, error)

GetFromBigCache inputs:

ids should be unique ids
out should be a pointer to a slice contains your custom type pointer, which will receive the outputs
keyMaker should be a func will format the key of ids

outputs:

[]int64 is the missing ids, need fetch from your distributed cache or database
error return error(if it has)

func MustInit

func MustInit()

func SetBigCache

func SetBigCache(id int64, v interface{}, keyMaker func(int64) string) error

func UserKeyMaker

func UserKeyMaker(id int64) string

Types

This section is empty.

Jump to

Keyboard shortcuts

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