Crate memberlist_proto

Crate memberlist_proto 

Source
Expand description

Types used by the memberlist crate.

Re-exports§

pub use bytes;
pub use checksum::*;crc32 or xxhash32 or xxhash64 or xxhash3 or murmur3
pub use compression::*;zstd or lz4 or brotli or snappy
pub use encryption::*;encryption

Modules§

checksumcrc32 or xxhash32 or xxhash64 or xxhash3 or murmur3
Checksum related types.
compressionzstd or lz4 or brotli or snappy
Compression related types.
either
The enum Either with variants Left and Right is a general purpose sum type with two cases.
encryptionencryption
Encryption related types.
utils
Utils for protobuf-like encoding/decoding

Macros§

smallvec_wrapper
Wraps a SmallVec with a newtype.

Structs§

Ack
Ack response is sent for a ping
AckRef
The reference to an Ack message
AddrParseError
An error which can be returned when parsing an IP network address.
Alive
Alive message
AliveRef
The reference type of Alive.
CIDRsPolicy
Classless Inter-Domain Routing (CIDR) policy.
ChecksumHintcrc32 or xxhash32 or xxhash64 or xxhash3 or murmur3
The hint of how checksum is encoded to the buffer.
CompressHintzstd or lz4 or brotli or snappy
The hint of how the payload is compressed in the buffer.
Dead
Dead message
EncryptionHintencryption
The hint of how encrypted payload.
ErrorResponse
Error response from the remote peer
ErrorResponseRef
Reference type of error response from the remote peer
IndirectPing
IndirectPing is sent to a target to check if it is alive
Ipv4AddrRange
An Iterator over a range of IPv4 addresses.
Ipv4Net
An IPv4 network address.
Ipv4Subnets
An Iterator that generates IPv4 network addresses.
Ipv6AddrRange
An Iterator over a range of IPv6 addresses.
Ipv6Net
An IPv6 network address.
Ipv6Subnets
An Iterator that generates IPv6 network addresses.
Label
General approach is to prefix all packets and streams with the same structure:
LargeMeta
Invalid meta error.
LargeVec
A big vec which can inline 16 elements on stack.
MediumVec
A medium vec which can inline 8 elements on stack.
MessagesDecoder
A zero-copy decoder for Messages.
MessagesDecoderIter
An iterator to yield the messages.
Meta
The metadata of a node in the cluster.
MetricLabelsmetrics
A vector of Labels.
Nack
Nack response is sent for an indirect ping when the pinger doesn’t hear from the ping-ee within the configured timeout. This lets the original node know that the indirect ping attempt happened but didn’t succeed.
Nodestd or alloc
Node is consist of id and address, which can be used as a identifier in a distributed system.
NodeIdstd or alloc
A unique string identifying a server for all time. The maximum length of an id is 512 bytes.
NodeState
Represents a node in the cluster
NodeStateRef
The reference type for NodeState.
OneOrMore
A tiny vec which can inline 1 element on stack.
ParseDomainError(std or alloc) and hostaddr
The provided input could not be parsed because it is not a syntactically-valid DNS Domain.
Payload
A payload can be sent over the transport.
Ping
Ping is sent to a target to check if it is alive
PrefixLenError
An error which can be returned when the prefix length is invalid.
ProtoDecoder
A protocol decoder.
ProtoEncoder
The encoder of messages
ProtoHint
The hint for ProtoEncoder to encode the messages.
PushNodeState
Push node state is the state push to the remote server.
PushNodeStateRef
Push node state is the state push to the remote server.
PushPull
Push pull message.
PushPullRef
The reference type of Push pull message.
RepeatedDecoder
An iterator with can yields the reference type of D
RepeatedDecoderIter
An iterator over the RepeatedDecoder in the collection.
SmallVec
A small vec which can inline 4 elements on stack.
Suspect
Suspect message
TinyVec
A tiny vec which can inline 2 elements on stack.
TriVec
A vec which can inline 3 elements on stack.
TupleEncoder
The encoder for a tuple of two data types.
XLargeVec
A xlarge vec which can inline 32 elements on stack.
XXLargeVec
A xxlarge vec which can inline 64 elements on stack.
XXXLargeVec
A xxxlarge vec which can inline 128 elements on stack.

Enums§

DecodeError
A message decoding error.
DelegateVersion
Delegate version
EncodeError
A data encoding error
IpAddrRange
An Iterator over a range of IP addresses, either IPv4 or IPv6.
IpNet
An IP network address, either IPv4 or IPv6.
IpSubnets
An Iterator that generates IP network addresses, either IPv4 or IPv6.
LabelError
Label error.
MaybeResolvedAddress
MaybeResolvedAddress is used to represent an address that may or may not be resolved.
Message
Request to be sent to the Raft node.
MessageRef
The reference type of the Message enum.
MessageType
ParseHostAddrError(std or alloc) and hostaddr
An error which can be returned when parsing a HostAddr.
ParseLabelError
Parse label error.
ParseNodeIdErrorstd or alloc
Errors that can occur when transforming an NodeId.
ProtoDecoderError
An error that can occur during encoding.
ProtoEncoderError
The errors may occur during encoding.
ProtocolVersion
Protocol version
State
State for the memberlist
WireType
A wire type used in Protobuf-like encoding/decoding.

Traits§

CheapClonestd or alloc
Things that are fast to clone in the context of an application.
Data
The memberlist data can be transmitted through the network.
DataRef
The reference type of the data.
IpAdd
Provides a saturating_add() method for Ipv4Addr and Ipv6Addr.
IpBitAnd
Provides a bitand() method for Ipv4Addr and Ipv6Addr.
IpBitOr
Provides a bitor() method for Ipv4Addr and Ipv6Addr.
IpSub
Provides a saturating_sub() method for Ipv4Addr and Ipv6Addr.
ProtoReader
The reader used in the memberlist proto
ProtoWriter
The writer used in the memberlist proto

Functions§

ip_mask_to_prefix
Converts a IpAddr network mask into a prefix.
ipv4_mask_to_prefix
Converts a Ipv4Addr network mask into a prefix.
ipv6_mask_to_prefix
Converts a Ipv6Addr network mask into a prefix.

Type Aliases§

Domain(std or alloc) and hostaddr
Domain type alias
DomainBuffer(std or alloc) and hostaddr
Domain type alias
HostAddr(std or alloc) and hostaddr
Host address type alias
HostAddrBuffer(std or alloc) and hostaddr
Host address type alias