Documentation ¶
Index ¶
- Variables
- type KVState
- func (*KVState) Descriptor() ([]byte, []int)
- func (s *KVState) Encode() [][]byte
- func (m *KVState) GetRecords() map[string]*KVStateRecord
- func (m *KVState) Marshal() (dAtA []byte, err error)
- func (m *KVState) MarshalTo(dAtA []byte) (int, error)
- func (m *KVState) MarshalToSizedBuffer(dAtA []byte) (int, error)
- func (s *KVState) Merge(other mesh.GossipData) (complete mesh.GossipData)
- func (*KVState) ProtoMessage()
- func (m *KVState) Reset()
- func (m *KVState) Size() (n int)
- func (this *KVState) String() string
- func (m *KVState) Unmarshal(dAtA []byte) error
- func (m *KVState) XXX_DiscardUnknown()
- func (m *KVState) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *KVState) XXX_Merge(src proto.Message)
- func (m *KVState) XXX_Size() int
- func (m *KVState) XXX_Unmarshal(b []byte) error
- type KVStateRecord
- func (*KVStateRecord) Descriptor() ([]byte, []int)
- func (m *KVStateRecord) GetData() []byte
- func (m *KVStateRecord) GetTombstone() bool
- func (m *KVStateRecord) GetVersion() uint64
- func (m *KVStateRecord) Marshal() (dAtA []byte, err error)
- func (m *KVStateRecord) MarshalTo(dAtA []byte) (int, error)
- func (m *KVStateRecord) MarshalToSizedBuffer(dAtA []byte) (int, error)
- func (*KVStateRecord) ProtoMessage()
- func (m *KVStateRecord) Reset()
- func (m *KVStateRecord) Size() (n int)
- func (this *KVStateRecord) String() string
- func (m *KVStateRecord) Unmarshal(dAtA []byte) error
- func (m *KVStateRecord) XXX_DiscardUnknown()
- func (m *KVStateRecord) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *KVStateRecord) XXX_Merge(src proto.Message)
- func (m *KVStateRecord) XXX_Size() int
- func (m *KVStateRecord) XXX_Unmarshal(b []byte) error
- type MeshGossiper
Constants ¶
This section is empty.
Variables ¶
Functions ¶
This section is empty.
Types ¶
type KVState ¶
type KVState struct { Records map[string]*KVStateRecord `` /* 155-byte string literal not displayed */ XXX_NoUnkeyedLiteral struct{} `json:"-"` XXX_sizecache int32 `json:"-"` }
func DecodeKVState ¶
func (*KVState) Descriptor ¶
func (*KVState) Encode ¶
Encode serializes our complete state to a slice of byte-slices. In this simple example, we use a single gob-encoded buffer: see https://golang.org/pkg/encoding/gob/
func (*KVState) GetRecords ¶
func (m *KVState) GetRecords() map[string]*KVStateRecord
func (*KVState) MarshalToSizedBuffer ¶ added in v1.19.0
func (*KVState) Merge ¶
func (s *KVState) Merge(other mesh.GossipData) (complete mesh.GossipData)
Merge merges the other GossipData into this one, and returns our resulting, complete state.
func (*KVState) ProtoMessage ¶
func (*KVState) ProtoMessage()
func (*KVState) XXX_DiscardUnknown ¶ added in v1.19.0
func (m *KVState) XXX_DiscardUnknown()
func (*KVState) XXX_Marshal ¶ added in v1.19.0
func (*KVState) XXX_Unmarshal ¶ added in v1.19.0
type KVStateRecord ¶
type KVStateRecord struct { Data []byte `protobuf:"bytes,1,opt,name=data,proto3" json:"data,omitempty"` Tombstone bool `protobuf:"varint,2,opt,name=tombstone,proto3" json:"tombstone,omitempty"` Version uint64 `protobuf:"varint,3,opt,name=version,proto3" json:"version,omitempty"` XXX_NoUnkeyedLiteral struct{} `json:"-"` XXX_sizecache int32 `json:"-"` }
func (*KVStateRecord) Descriptor ¶
func (*KVStateRecord) Descriptor() ([]byte, []int)
func (*KVStateRecord) GetData ¶ added in v1.19.0
func (m *KVStateRecord) GetData() []byte
func (*KVStateRecord) GetTombstone ¶ added in v1.19.0
func (m *KVStateRecord) GetTombstone() bool
func (*KVStateRecord) GetVersion ¶ added in v1.19.0
func (m *KVStateRecord) GetVersion() uint64
func (*KVStateRecord) Marshal ¶
func (m *KVStateRecord) Marshal() (dAtA []byte, err error)
func (*KVStateRecord) MarshalToSizedBuffer ¶ added in v1.19.0
func (m *KVStateRecord) MarshalToSizedBuffer(dAtA []byte) (int, error)
func (*KVStateRecord) ProtoMessage ¶
func (*KVStateRecord) ProtoMessage()
func (*KVStateRecord) Reset ¶
func (m *KVStateRecord) Reset()
func (*KVStateRecord) Size ¶
func (m *KVStateRecord) Size() (n int)
func (*KVStateRecord) String ¶
func (this *KVStateRecord) String() string
func (*KVStateRecord) Unmarshal ¶
func (m *KVStateRecord) Unmarshal(dAtA []byte) error
func (*KVStateRecord) XXX_DiscardUnknown ¶ added in v1.19.0
func (m *KVStateRecord) XXX_DiscardUnknown()
func (*KVStateRecord) XXX_Marshal ¶ added in v1.19.0
func (m *KVStateRecord) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
func (*KVStateRecord) XXX_Merge ¶ added in v1.19.0
func (m *KVStateRecord) XXX_Merge(src proto.Message)
func (*KVStateRecord) XXX_Size ¶ added in v1.19.0
func (m *KVStateRecord) XXX_Size() int
func (*KVStateRecord) XXX_Unmarshal ¶ added in v1.19.0
func (m *KVStateRecord) XXX_Unmarshal(b []byte) error
type MeshGossiper ¶
type MeshGossiper struct {
// contains filtered or unexported fields
}
func NewMeshGossiper ¶
func NewMeshGossiper(listen string, channelName string, nodeName string, password []byte, seeds gossip.SeedProvider) (*MeshGossiper, error)
func (*MeshGossiper) Snapshot ¶
func (g *MeshGossiper) Snapshot() *gossip.GossipStateSnapshot
func (*MeshGossiper) Start ¶
func (g *MeshGossiper) Start() error
func (*MeshGossiper) UpdateValues ¶
func (g *MeshGossiper) UpdateValues(removeKeys []string, putEntries map[string]string) error
Click to show internal directories.
Click to hide internal directories.