membership

package
v0.3.3 Latest Latest
Warning

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

Go to latest
Published: Aug 31, 2023 License: Apache-2.0 Imports: 30 Imported by: 0

Documentation

Overview

Package membership contains the webmesh membership service.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Options added in v0.3.0

type Options struct {
	Raft      raft.Raft
	Plugins   plugins.Manager
	RBAC      rbac.Evaluator
	WireGuard wireguard.Interface
}

Options are the options for the Membership service.

type Server

type Server struct {
	v1.UnimplementedMembershipServer
	// contains filtered or unexported fields
}

Server is the webmesh Membership service.

func NewServer

func NewServer(ctx context.Context, opts Options) *Server

NewServer returns a new Server.

func (*Server) Apply

func (s *Server) Apply(ctx context.Context, log *v1.RaftLogEntry) (*v1.RaftApplyResponse, error)

func (*Server) GetRaftConfiguration

func (s *Server) GetRaftConfiguration(ctx context.Context, _ *v1.RaftConfigurationRequest) (*v1.RaftConfigurationResponse, error)

func (*Server) Join

func (s *Server) Join(ctx context.Context, req *v1.JoinRequest) (*v1.JoinResponse, error)

func (*Server) Leave

func (s *Server) Leave(ctx context.Context, req *v1.LeaveRequest) (*v1.LeaveResponse, error)

func (*Server) SubscribePeers added in v0.3.0

func (s *Server) SubscribePeers(req *v1.SubscribePeersRequest, stream v1.Membership_SubscribePeersServer) error

func (*Server) Update

func (s *Server) Update(ctx context.Context, req *v1.UpdateRequest) (*v1.UpdateResponse, error)

Jump to

Keyboard shortcuts

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