redis_store

package
v0.3.0 Latest Latest
Warning

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

Go to latest
Published: Aug 11, 2020 License: Apache-2.0 Imports: 7 Imported by: 0

Documentation

Index

Constants

View Source
const RedisKeySep = "####"

Variables

This section is empty.

Functions

This section is empty.

Types

type RedisStore

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

func NewRedisStore

func NewRedisStore(cli *redis.Client, keyPrefix string) (*RedisStore, error)

// build new store from redis cli

func NewStore

func NewStore(address string, pass string, keyPrefix string) (*RedisStore, error)

build new store from redis's address

func (*RedisStore) Load

func (store *RedisStore) Load(name string, beginTime time.Time, endTime time.Time, lbs map[string]string,
) (cluster_counter.CounterValue, error)

load cluster's data for clients

func (*RedisStore) Store

func (store *RedisStore) Store(name string, beginTime time.Time, endTime time.Time, lbs map[string]string,
	value cluster_counter.CounterValue, force bool) error

store client's data within cluster

Jump to

Keyboard shortcuts

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