Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type AllocatorImpl ¶
type AllocatorImpl struct {
// contains filtered or unexported fields
}
AllocatorImpl is used to allocate ID.
func NewAllocatorImpl ¶
func NewAllocatorImpl(client *clientv3.Client, rootPath string, member string) *AllocatorImpl
NewAllocatorImpl creates a new IDAllocator.
func (*AllocatorImpl) Alloc ¶
func (alloc *AllocatorImpl) Alloc() (uint64, error)
Alloc returns a new id.
Click to show internal directories.
Click to hide internal directories.