Documentation ¶
Index ¶
- Constants
- func BatchGet(keys []interface{}) map[interface{}]interface{}
- func Close()
- func Decr(key interface{}, count int64) int64
- func Del(key interface{})
- func Get(key interface{}) (interface{}, bool)
- func GetCurrentGlData() map[string]interface{}
- func Incr(key interface{}, count int64) int64
- func IncrCost(key interface{}, cost time.Duration) int64
- func IncrCostKey(key string, cost time.Duration) int64
- func IncrCountKey(key string, val int64) int64
- func IncrFailKey(key string, val int64) int64
- func Init()
- func Set(key interface{}, val interface{})
- func SetLogger(l Logger)
- type ConcurrentMap
- type Logger
- type Shard
Constants ¶
View Source
const ( ClientIp = "glClientIp" Tag = "glTag" LogId = "glLogId" )
Variables ¶
This section is empty.
Functions ¶
func GetCurrentGlData ¶ added in v1.6.6
func GetCurrentGlData() map[string]interface{}
func IncrCountKey ¶ added in v1.6.6
func IncrFailKey ¶ added in v1.6.6
Types ¶
type ConcurrentMap ¶
type ConcurrentMap struct {
// contains filtered or unexported fields
}
func NewShard ¶
func NewShard(shardCount int) *ConcurrentMap
func (*ConcurrentMap) Get ¶
func (m *ConcurrentMap) Get(key string) (interface{}, bool)
func (*ConcurrentMap) GetShard ¶
func (m *ConcurrentMap) GetShard(key string) *Shard
func (*ConcurrentMap) Remove ¶
func (m *ConcurrentMap) Remove(key string)
func (*ConcurrentMap) Set ¶
func (m *ConcurrentMap) Set(key string, value interface{})
Click to show internal directories.
Click to hide internal directories.