package
1.19.0
Repository: https://github.com/cortexproject/cortex.git
Documentation: pkg.go.dev

# Packages

No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author

# Functions

DoBatch request against a set of keys in the ring, handling replication and failures.
GetCodec returns the codec used to encode and decode data being put by ring.
GetInstanceAddr returns the address to use to register the instance in the ring.
GetInstancePort returns the port to use to register the instance in the ring.
No description provided by the author
No description provided by the author
HasReplicationSetChanged returns false if two replications sets are the same (with possibly different timestamps), true if they differ in any way (number of instances, instance states, tokens, zones, ...).
HasReplicationSetChangedWithoutState returns false if two replications sets are the same (with possibly different timestamps and instance states), true if they differ in any other way (number of instances, tokens, zones, ...).
No description provided by the author
No description provided by the author
No description provided by the author
MakeBuffersForGet returns buffers to use with Ring.Get().
MergeTokens takes in input multiple lists of tokens and returns a single list containing all tokens merged and sorted.
MergeTokensByZone is like MergeTokens but does it for each input zone.
New creates a new Ring.
No description provided by the author
NewBasicLifecycler makes a new BasicLifecycler.
No description provided by the author
No description provided by the author
NewDesc returns an empty ring.Desc.
No description provided by the author
No description provided by the author
NewLifecycler creates new Lifecycler.
No description provided by the author
No description provided by the author
NewNoopFlushTransferer makes a new NoopFlushTransferer.
NewOp constructs new Operation with given "healthy" states for operation, and optional function to extend replica set.
No description provided by the author
No description provided by the author
No description provided by the author
ProtoDescFactory makes new Descs.
WaitInstanceState waits until the input instanceID is registered within the ring matching the provided state.
WaitRingStability monitors the ring topology for the provided operation and waits until it keeps stable for at least minStability.
WaitRingTokensStability waits for the Ring to be unchanged at least for minStability time period, excluding transitioning between allowed states (e.g.

# Constants

No description provided by the author
Rings have different set of instances, or their information don't match.
Both rings contain same exact instances.
Both rings contain the same instances with the same data except states and timestamps (may differ).
GetBufferSize is the suggested size of buffers passed to Ring.Get().
GetZoneSize is the suggested size of zone map passed to Ring.Get().
No description provided by the author
No description provided by the author
This state is only used by gossiping code to distribute information about instances that have been removed from the ring.
No description provided by the author
No description provided by the author

# Variables

ErrEmptyRing is the error returned when trying to get an element when nothing has been added to hash.
ErrInconsistentTokensInfo is the error returned if, due to an internal bug, the mapping between a token and its own instance is missing or unknown.
ErrInstanceNotFound is the error returned when trying to get information for an instance not registered within the ring.
No description provided by the author
No description provided by the author
ErrTooManyUnhealthyInstances is the error returned when there are too many failed instances for a specific operation.
No description provided by the author
No description provided by the author
Read operation that extends the replica set if an instance is not ACTIVE, PENDING, LEAVING, JOINING OR READONLY.
Reporting is a special value for inquiring about health.
Write operation that also extends replica set, if instance state is not ACTIVE.
WriteNoExtend is like Write, but with no replicaset extension.

# Structs

AutoForgetDelegate automatically remove an instance from the ring if the last heartbeat is older than a configured period.
BasicLifecycler is a basic ring lifecycler which allows to hook custom logic at different stages of the lifecycle.
No description provided by the author
No description provided by the author
Config for a Ring.
No description provided by the author
No description provided by the author
No description provided by the author
Lifecycler is responsible for managing the lifecycle of entries in the ring.
LifecyclerConfig is the config to build a Lifecycler.
No description provided by the author
No description provided by the author
NoopFlushTransferer is a FlushTransferer which does nothing and can be used in cases we don't need one.
No description provided by the author
ReplicationSet describes the instances to talk to for a given key, and how many errors to tolerate.
Ring holds the information about the members of the consistent hash ring.
No description provided by the author
No description provided by the author

# Interfaces

No description provided by the author
FlushTransferer controls the shutdown of an instance in the ring.
ReadRing represents the read interface to the ring.
No description provided by the author
No description provided by the author

# Type aliases

ByAddr is a sortable list of InstanceDesc.
No description provided by the author
No description provided by the author
Operation describes which instances can be included in the replica set, based on their state.
Tokens is a simple list of tokens.
TokensHeap is an heap data structure used to merge multiple lists of sorted tokens into a single one.