Skip to content

may you add default replicas ? #156

@ZBIGBEAR

Description

@ZBIGBEAR

1.add default replicas
groupcache/consistenthash.go: line 34.
replicas must has a default value. if replicas <=0, then it will do nothing when call func (m *Map) Add(keys ...string)

and i suggest the default replicas value is 23

2.add sync.Mutex. when call Add and Get,we can lock the kes and hashMap

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions