groupsv1

package
v0.14.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Oct 17, 2026 License: MIT Imports: 6 Imported by: ? modules, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Index

Constants

This section is empty.

Variables

View Source
var File_grpcproc_groups_v1_groups_proto protoreflect.FileDescriptor

Functions

This section is empty.

Types

type Changed

type Changed struct {
	Group  string    `protobuf:"bytes,1,opt,name=group,proto3" json:"group,omitempty"`
	Joined []*v1.PID `protobuf:"bytes,2,rep,name=joined,proto3" json:"joined,omitempty"`
	Left   []*v1.PID `protobuf:"bytes,3,rep,name=left,proto3" json:"left,omitempty"`
	// contains filtered or unexported fields
}

Changed tells a watcher who joined and who left a group.

func (*Changed) Descriptor deprecated

func (*Changed) Descriptor() ([]byte, []int)

Deprecated: Use Changed.ProtoReflect.Descriptor instead.

func (*Changed) GetGroup

func (x *Changed) GetGroup() string

func (*Changed) GetJoined

func (x *Changed) GetJoined() []*v1.PID

func (*Changed) GetLeft

func (x *Changed) GetLeft() []*v1.PID

func (*Changed) ProtoMessage

func (*Changed) ProtoMessage()

func (*Changed) ProtoReflect

func (x *Changed) ProtoReflect() protoreflect.Message

func (*Changed) Reset

func (x *Changed) Reset()

func (*Changed) String

func (x *Changed) String() string

type Found

type Found struct {
	Scope *v1.PID `protobuf:"bytes,1,opt,name=scope,proto3" json:"scope,omitempty"`
	// contains filtered or unexported fields
}

Found is a relay telling its scope that the other node's scope answered its Hello, and that it watches that scope now.

func (*Found) Descriptor deprecated

func (*Found) Descriptor() ([]byte, []int)

Deprecated: Use Found.ProtoReflect.Descriptor instead.

func (*Found) GetScope

func (x *Found) GetScope() *v1.PID

func (*Found) ProtoMessage

func (*Found) ProtoMessage()

func (*Found) ProtoReflect

func (x *Found) ProtoReflect() protoreflect.Message

func (*Found) Reset

func (x *Found) Reset()

func (*Found) String

func (x *Found) String() string

type Group

type Group struct {
	Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"`
	// Members on every node.
	Members uint32 `protobuf:"varint,2,opt,name=members,proto3" json:"members,omitempty"`
	// Members on the scope's node.
	Local uint32 `protobuf:"varint,3,opt,name=local,proto3" json:"local,omitempty"`
	// Nodes with a member.
	Nodes uint32 `protobuf:"varint,4,opt,name=nodes,proto3" json:"nodes,omitempty"`
	// contains filtered or unexported fields
}

Group is a group as a scope knows it.

func (*Group) Descriptor deprecated

func (*Group) Descriptor() ([]byte, []int)

Deprecated: Use Group.ProtoReflect.Descriptor instead.

func (*Group) GetLocal

func (x *Group) GetLocal() uint32

func (*Group) GetMembers

func (x *Group) GetMembers() uint32

func (*Group) GetName

func (x *Group) GetName() string

func (*Group) GetNodes

func (x *Group) GetNodes() uint32

func (*Group) ProtoMessage

func (*Group) ProtoMessage()

func (*Group) ProtoReflect

func (x *Group) ProtoReflect() protoreflect.Message

func (*Group) Reset

func (x *Group) Reset()

func (*Group) String

func (x *Group) String() string

type Hello

type Hello struct {
	Scope *v1.PID `protobuf:"bytes,1,opt,name=scope,proto3" json:"scope,omitempty"`
	// contains filtered or unexported fields
}

Hello, as a call from a scope's relay to the scope of the same name on another node, asks for that scope's members; the answer is a Hello that names the scope answering. The scope called then sends its members to the caller's scope, which the call's Hello names.

func (*Hello) Descriptor deprecated

func (*Hello) Descriptor() ([]byte, []int)

Deprecated: Use Hello.ProtoReflect.Descriptor instead.

func (*Hello) GetScope

func (x *Hello) GetScope() *v1.PID

func (*Hello) ProtoMessage

func (*Hello) ProtoMessage()

func (*Hello) ProtoReflect

func (x *Hello) ProtoReflect() protoreflect.Message

func (*Hello) Reset

func (x *Hello) Reset()

func (*Hello) String

func (x *Hello) String() string

type Join

type Join struct {
	Group string    `protobuf:"bytes,1,opt,name=group,proto3" json:"group,omitempty"`
	Pids  []*v1.PID `protobuf:"bytes,2,rep,name=pids,proto3" json:"pids,omitempty"`
	// contains filtered or unexported fields
}

Join, as a call to a scope, adds processes of the scope's node to a group.

func (*Join) Descriptor deprecated

func (*Join) Descriptor() ([]byte, []int)

Deprecated: Use Join.ProtoReflect.Descriptor instead.

func (*Join) GetGroup

func (x *Join) GetGroup() string

func (*Join) GetPids

func (x *Join) GetPids() []*v1.PID

func (*Join) ProtoMessage

func (*Join) ProtoMessage()

func (*Join) ProtoReflect

func (x *Join) ProtoReflect() protoreflect.Message

func (*Join) Reset

func (x *Join) Reset()

func (*Join) String

func (x *Join) String() string

type Leave

type Leave struct {
	Group string    `protobuf:"bytes,1,opt,name=group,proto3" json:"group,omitempty"`
	Pids  []*v1.PID `protobuf:"bytes,2,rep,name=pids,proto3" json:"pids,omitempty"`
	// contains filtered or unexported fields
}

Leave, as a call to a scope, removes processes of the scope's node from a group.

func (*Leave) Descriptor deprecated

func (*Leave) Descriptor() ([]byte, []int)

Deprecated: Use Leave.ProtoReflect.Descriptor instead.

func (*Leave) GetGroup

func (x *Leave) GetGroup() string

func (*Leave) GetPids

func (x *Leave) GetPids() []*v1.PID

func (*Leave) ProtoMessage

func (*Leave) ProtoMessage()

func (*Leave) ProtoReflect

func (x *Leave) ProtoReflect() protoreflect.Message

func (*Leave) Reset

func (x *Leave) Reset()

func (*Leave) String

func (x *Leave) String() string

type Listing

type Listing struct {
	// contains filtered or unexported fields
}

Listing is a scope's membership watch telling it that a new list of the members begins: what an earlier watch listed is listed again.

func (*Listing) Descriptor deprecated

func (*Listing) Descriptor() ([]byte, []int)

Deprecated: Use Listing.ProtoReflect.Descriptor instead.

func (*Listing) ProtoMessage

func (*Listing) ProtoMessage()

func (*Listing) ProtoReflect

func (x *Listing) ProtoReflect() protoreflect.Message

func (*Listing) Reset

func (x *Listing) Reset()

func (*Listing) String

func (x *Listing) String() string

type Lost

type Lost struct {

	// The scope that is gone; unset when Hello was not answered.
	Scope *v1.PID `protobuf:"bytes,1,opt,name=scope,proto3" json:"scope,omitempty"`
	// Why: noproc when that node runs no such scope, noconnection when it
	// cannot be reached, or the exit reason of the scope it watched.
	Reason string `protobuf:"bytes,2,opt,name=reason,proto3" json:"reason,omitempty"`
	// contains filtered or unexported fields
}

Lost is a relay telling its scope that the other node's scope did not answer, or that the scope it watched is gone, and that the relay ends.

func (*Lost) Descriptor deprecated

func (*Lost) Descriptor() ([]byte, []int)

Deprecated: Use Lost.ProtoReflect.Descriptor instead.

func (*Lost) GetReason

func (x *Lost) GetReason() string

func (*Lost) GetScope

func (x *Lost) GetScope() *v1.PID

func (*Lost) ProtoMessage

func (*Lost) ProtoMessage()

func (*Lost) ProtoReflect

func (x *Lost) ProtoReflect() protoreflect.Message

func (*Lost) Reset

func (x *Lost) Reset()

func (*Lost) String

func (x *Lost) String() string

type MemberEvent

type MemberEvent struct {
	Node     string `protobuf:"bytes,1,opt,name=node,proto3" json:"node,omitempty"`
	Up       bool   `protobuf:"varint,2,opt,name=up,proto3" json:"up,omitempty"`
	Selected bool   `protobuf:"varint,3,opt,name=selected,proto3" json:"selected,omitempty"`
	// Which incarnation Membership reported; 0 for whichever.
	Incarnation uint64 `protobuf:"varint,4,opt,name=incarnation,proto3" json:"incarnation,omitempty"`
	// contains filtered or unexported fields
}

MemberEvent is a scope's membership watch telling it of a node that is up, and whether Select takes it, or of one that left the cluster.

func (*MemberEvent) Descriptor deprecated

func (*MemberEvent) Descriptor() ([]byte, []int)

Deprecated: Use MemberEvent.ProtoReflect.Descriptor instead.

func (*MemberEvent) GetIncarnation

func (x *MemberEvent) GetIncarnation() uint64

func (*MemberEvent) GetNode

func (x *MemberEvent) GetNode() string

func (*MemberEvent) GetSelected

func (x *MemberEvent) GetSelected() bool

func (*MemberEvent) GetUp

func (x *MemberEvent) GetUp() bool

func (*MemberEvent) ProtoMessage

func (*MemberEvent) ProtoMessage()

func (*MemberEvent) ProtoReflect

func (x *MemberEvent) ProtoReflect() protoreflect.Message

func (*MemberEvent) Reset

func (x *MemberEvent) Reset()

func (*MemberEvent) String

func (x *MemberEvent) String() string

type Members

type Members struct {
	Group string   `protobuf:"bytes,1,opt,name=group,proto3" json:"group,omitempty"`
	Ids   []uint64 `protobuf:"varint,2,rep,packed,name=ids,proto3" json:"ids,omitempty"`
	// contains filtered or unexported fields
}

Members are processes of the sender's node in a group, by id: their incarnation is the sender's.

func (*Members) Descriptor deprecated

func (*Members) Descriptor() ([]byte, []int)

Deprecated: Use Members.ProtoReflect.Descriptor instead.

func (*Members) GetGroup

func (x *Members) GetGroup() string

func (*Members) GetIds

func (x *Members) GetIds() []uint64

func (*Members) ProtoMessage

func (*Members) ProtoMessage()

func (*Members) ProtoReflect

func (x *Members) ProtoReflect() protoreflect.Message

func (*Members) Reset

func (x *Members) Reset()

func (*Members) String

func (x *Members) String() string

type Peer

type Peer struct {
	Node string `protobuf:"bytes,1,opt,name=node,proto3" json:"node,omitempty"`
	// syncing: asked, its members not yet known; synced: its members are
	// known; absent: it runs no such scope; unreachable: lost, and asked
	// again later.
	State string `protobuf:"bytes,2,opt,name=state,proto3" json:"state,omitempty"`
	// Its scope, once it synced.
	Scope *v1.PID `protobuf:"bytes,3,opt,name=scope,proto3" json:"scope,omitempty"`
	// Its members, in every group.
	Members uint32 `protobuf:"varint,4,opt,name=members,proto3" json:"members,omitempty"`
	// contains filtered or unexported fields
}

Peer is another node's scope, as this one knows it.

func (*Peer) Descriptor deprecated

func (*Peer) Descriptor() ([]byte, []int)

Deprecated: Use Peer.ProtoReflect.Descriptor instead.

func (*Peer) GetMembers

func (x *Peer) GetMembers() uint32

func (*Peer) GetNode

func (x *Peer) GetNode() string

func (*Peer) GetScope

func (x *Peer) GetScope() *v1.PID

func (*Peer) GetState

func (x *Peer) GetState() string

func (*Peer) ProtoMessage

func (*Peer) ProtoMessage()

func (*Peer) ProtoReflect

func (x *Peer) ProtoReflect() protoreflect.Message

func (*Peer) Reset

func (x *Peer) Reset()

func (*Peer) String

func (x *Peer) String() string

type Query

type Query struct {

	// One group's members; unset, the groups.
	Group string `protobuf:"bytes,1,opt,name=group,proto3" json:"group,omitempty"`
	// Only the groups whose names start with this.
	Prefix string `protobuf:"bytes,2,opt,name=prefix,proto3" json:"prefix,omitempty"`
	// At most this many groups, or members of the group, ordered; 0 is 1000.
	Limit uint32 `protobuf:"varint,3,opt,name=limit,proto3" json:"limit,omitempty"`
	// contains filtered or unexported fields
}

Query, asked of a scope (grpcproc.WithQuery), is answered with a Report: its groups, or with a group the members of it.

func (*Query) Descriptor deprecated

func (*Query) Descriptor() ([]byte, []int)

Deprecated: Use Query.ProtoReflect.Descriptor instead.

func (*Query) GetGroup

func (x *Query) GetGroup() string

func (*Query) GetLimit

func (x *Query) GetLimit() uint32

func (*Query) GetPrefix

func (x *Query) GetPrefix() string

func (*Query) ProtoMessage

func (*Query) ProtoMessage()

func (*Query) ProtoReflect

func (x *Query) ProtoReflect() protoreflect.Message

func (*Query) Reset

func (x *Query) Reset()

func (*Query) String

func (x *Query) String() string

type Report

type Report struct {
	Scope string `protobuf:"bytes,1,opt,name=scope,proto3" json:"scope,omitempty"`
	// The groups with members, by name, when no group was asked.
	Groups []*Group `protobuf:"bytes,2,rep,name=groups,proto3" json:"groups,omitempty"`
	// The group's members, when one was asked, ordered.
	Members []*v1.PID `protobuf:"bytes,3,rep,name=members,proto3" json:"members,omitempty"`
	// How many groups, or members, were left out past the limit.
	Omitted uint32 `protobuf:"varint,4,opt,name=omitted,proto3" json:"omitted,omitempty"`
	// The other nodes the scope knows, by name.
	Peers []*Peer `protobuf:"bytes,5,rep,name=peers,proto3" json:"peers,omitempty"`
	// contains filtered or unexported fields
}

Report answers Query.

func (*Report) Descriptor deprecated

func (*Report) Descriptor() ([]byte, []int)

Deprecated: Use Report.ProtoReflect.Descriptor instead.

func (*Report) GetGroups

func (x *Report) GetGroups() []*Group

func (*Report) GetMembers

func (x *Report) GetMembers() []*v1.PID

func (*Report) GetOmitted

func (x *Report) GetOmitted() uint32

func (*Report) GetPeers

func (x *Report) GetPeers() []*Peer

func (*Report) GetScope

func (x *Report) GetScope() string

func (*Report) ProtoMessage

func (*Report) ProtoMessage()

func (*Report) ProtoReflect

func (x *Report) ProtoReflect() protoreflect.Message

func (*Report) Reset

func (x *Report) Reset()

func (*Report) String

func (x *Report) String() string

type Retry

type Retry struct {
	Node string `protobuf:"bytes,1,opt,name=node,proto3" json:"node,omitempty"`
	// Which of the node's waits it ends: a later one is not ended early.
	Seq uint64 `protobuf:"varint,2,opt,name=seq,proto3" json:"seq,omitempty"`
	// contains filtered or unexported fields
}

Retry is a scope's note to itself: to ask an unreachable node again, or, with no node, to watch the membership again.

func (*Retry) Descriptor deprecated

func (*Retry) Descriptor() ([]byte, []int)

Deprecated: Use Retry.ProtoReflect.Descriptor instead.

func (*Retry) GetNode

func (x *Retry) GetNode() string

func (*Retry) GetSeq

func (x *Retry) GetSeq() uint64

func (*Retry) ProtoMessage

func (*Retry) ProtoMessage()

func (*Retry) ProtoReflect

func (x *Retry) ProtoReflect() protoreflect.Message

func (*Retry) Reset

func (x *Retry) Reset()

func (*Retry) String

func (x *Retry) String() string

type Sync

type Sync struct {

	// The scope whose members these are.
	Scope  *v1.PID    `protobuf:"bytes,1,opt,name=scope,proto3" json:"scope,omitempty"`
	Groups []*Members `protobuf:"bytes,2,rep,name=groups,proto3" json:"groups,omitempty"`
	First  bool       `protobuf:"varint,3,opt,name=first,proto3" json:"first,omitempty"`
	More   bool       `protobuf:"varint,4,opt,name=more,proto3" json:"more,omitempty"`
	// contains filtered or unexported fields
}

Sync, from one scope to another of the same name, lists the sender's local members, which replace those the receiver kept for the sender's node. A long list comes in several, the first with first set and the last with more unset.

func (*Sync) Descriptor deprecated

func (*Sync) Descriptor() ([]byte, []int)

Deprecated: Use Sync.ProtoReflect.Descriptor instead.

func (*Sync) GetFirst

func (x *Sync) GetFirst() bool

func (*Sync) GetGroups

func (x *Sync) GetGroups() []*Members

func (*Sync) GetMore

func (x *Sync) GetMore() bool

func (*Sync) GetScope

func (x *Sync) GetScope() *v1.PID

func (*Sync) ProtoMessage

func (*Sync) ProtoMessage()

func (*Sync) ProtoReflect

func (x *Sync) ProtoReflect() protoreflect.Message

func (*Sync) Reset

func (x *Sync) Reset()

func (*Sync) String

func (x *Sync) String() string

type Unwatch

type Unwatch struct {
	Group string `protobuf:"bytes,1,opt,name=group,proto3" json:"group,omitempty"`
	Id    uint64 `protobuf:"varint,2,opt,name=id,proto3" json:"id,omitempty"`
	// contains filtered or unexported fields
}

Unwatch, sent to a scope, ends the sender's watch of a group with that id; one it does not hold is ignored.

func (*Unwatch) Descriptor deprecated

func (*Unwatch) Descriptor() ([]byte, []int)

Deprecated: Use Unwatch.ProtoReflect.Descriptor instead.

func (*Unwatch) GetGroup

func (x *Unwatch) GetGroup() string

func (*Unwatch) GetId

func (x *Unwatch) GetId() uint64

func (*Unwatch) ProtoMessage

func (*Unwatch) ProtoMessage()

func (*Unwatch) ProtoReflect

func (x *Unwatch) ProtoReflect() protoreflect.Message

func (*Unwatch) Reset

func (x *Unwatch) Reset()

func (*Unwatch) String

func (x *Unwatch) String() string

type Update

type Update struct {
	Joined []*Members `protobuf:"bytes,1,rep,name=joined,proto3" json:"joined,omitempty"`
	Left   []*Members `protobuf:"bytes,2,rep,name=left,proto3" json:"left,omitempty"`
	// contains filtered or unexported fields
}

Update, from one scope to the others after its Sync, says which of its node's processes joined groups, and which left them. A long one comes in several.

func (*Update) Descriptor deprecated

func (*Update) Descriptor() ([]byte, []int)

Deprecated: Use Update.ProtoReflect.Descriptor instead.

func (*Update) GetJoined

func (x *Update) GetJoined() []*Members

func (*Update) GetLeft

func (x *Update) GetLeft() []*Members

func (*Update) ProtoMessage

func (*Update) ProtoMessage()

func (*Update) ProtoReflect

func (x *Update) ProtoReflect() protoreflect.Message

func (*Update) Reset

func (x *Update) Reset()

func (*Update) String

func (x *Update) String() string

type Watch

type Watch struct {
	Group string `protobuf:"bytes,1,opt,name=group,proto3" json:"group,omitempty"`
	// Unique among the caller's watches.
	Id uint64 `protobuf:"varint,2,opt,name=id,proto3" json:"id,omitempty"`
	// contains filtered or unexported fields
}

Watch, as a call to a scope from a process of its node, has it send the caller a Changed for every change to the group, until the caller sends Unwatch with the same id or exits. It is answered with Watching. A process that holds several watches of a group gets one Changed per change.

func (*Watch) Descriptor deprecated

func (*Watch) Descriptor() ([]byte, []int)

Deprecated: Use Watch.ProtoReflect.Descriptor instead.

func (*Watch) GetGroup

func (x *Watch) GetGroup() string

func (*Watch) GetId

func (x *Watch) GetId() uint64

func (*Watch) ProtoMessage

func (*Watch) ProtoMessage()

func (*Watch) ProtoReflect

func (x *Watch) ProtoReflect() protoreflect.Message

func (*Watch) Reset

func (x *Watch) Reset()

func (*Watch) String

func (x *Watch) String() string

type Watching

type Watching struct {

	// The group's members when the watch began, every node's, ordered.
	Members []*v1.PID `protobuf:"bytes,1,rep,name=members,proto3" json:"members,omitempty"`
	// contains filtered or unexported fields
}

Watching answers Watch.

func (*Watching) Descriptor deprecated

func (*Watching) Descriptor() ([]byte, []int)

Deprecated: Use Watching.ProtoReflect.Descriptor instead.

func (*Watching) GetMembers

func (x *Watching) GetMembers() []*v1.PID

func (*Watching) ProtoMessage

func (*Watching) ProtoMessage()

func (*Watching) ProtoReflect

func (x *Watching) ProtoReflect() protoreflect.Message

func (*Watching) Reset

func (x *Watching) Reset()

func (*Watching) String

func (x *Watching) String() string

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL