impl

package
v0.1.4 Latest Latest
Warning

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

Go to latest
Published: Mar 14, 2023 License: Apache-2.0 Imports: 37 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var File_internal_tool_ssh_impl_ssh_proto protoreflect.FileDescriptor

Functions

func DefaultRegistry

func DefaultRegistry(ctx context.Context) (*status.Registry, error)

DefaultRegistry returns the default registry in $XDG_DATA_HOME/serviceweaver/ssh_registry, or ~/.local/share/serviceweaver/ssh_registry if XDG_DATA_HOME is not set.

func RunBabysitter

func RunBabysitter(ctx context.Context) error

RunBabysitter creates and runs an envelope.Envelope and a metrics collector for a weavelet deployed with SSH.

func RunManager

func RunManager(ctx context.Context, dep *protos.Deployment, locations []string,
	logDir string) (func() error, error)

RunManager creates and runs a new manager.

Types

type AppVersionState added in v0.1.2

type AppVersionState struct {
	App            string                           `protobuf:"bytes,1,opt,name=app,proto3" json:"app,omitempty"`
	DeploymentId   string                           `protobuf:"bytes,2,opt,name=deployment_id,json=deploymentId,proto3" json:"deployment_id,omitempty"`
	SubmissionTime *timestamppb.Timestamp           `protobuf:"bytes,3,opt,name=submission_time,json=submissionTime,proto3" json:"submission_time,omitempty"`
	Groups         map[string]*ColocationGroupState `` // per group information
	/* 153-byte string literal not displayed */
	Listeners []*protos.Listener `protobuf:"bytes,5,rep,name=listeners,proto3" json:"listeners,omitempty"` // per listener information
	// contains filtered or unexported fields
}

AppVersionState contains state managed for an application version by the babysitter.

func (*AppVersionState) Descriptor deprecated added in v0.1.2

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

Deprecated: Use AppVersionState.ProtoReflect.Descriptor instead.

func (*AppVersionState) GetApp added in v0.1.2

func (x *AppVersionState) GetApp() string

func (*AppVersionState) GetDeploymentId added in v0.1.2

func (x *AppVersionState) GetDeploymentId() string

func (*AppVersionState) GetGroups added in v0.1.2

func (x *AppVersionState) GetGroups() map[string]*ColocationGroupState

func (*AppVersionState) GetListeners added in v0.1.2

func (x *AppVersionState) GetListeners() []*protos.Listener

func (*AppVersionState) GetSubmissionTime added in v0.1.2

func (x *AppVersionState) GetSubmissionTime() *timestamppb.Timestamp

func (*AppVersionState) ProtoMessage added in v0.1.2

func (*AppVersionState) ProtoMessage()

func (*AppVersionState) ProtoReflect added in v0.1.2

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

func (*AppVersionState) Reset added in v0.1.2

func (x *AppVersionState) Reset()

func (*AppVersionState) String added in v0.1.2

func (x *AppVersionState) String() string

type BabysitterInfo

type BabysitterInfo struct {
	Deployment  *protos.Deployment      `protobuf:"bytes,1,opt,name=deployment,proto3" json:"deployment,omitempty"`
	Group       *protos.ColocationGroup `protobuf:"bytes,2,opt,name=group,proto3" json:"group,omitempty"`
	ReplicaId   int32                   `protobuf:"varint,3,opt,name=replica_id,json=replicaId,proto3" json:"replica_id,omitempty"`
	ManagerAddr string                  `protobuf:"bytes,4,opt,name=manager_addr,json=managerAddr,proto3" json:"manager_addr,omitempty"`
	LogDir      string                  `protobuf:"bytes,5,opt,name=logDir,proto3" json:"logDir,omitempty"`
	// contains filtered or unexported fields
}

BabysitterInfo contains app deployment information that is needed by a babysitter started using SSH to manage a colocation group.

func (*BabysitterInfo) Descriptor deprecated

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

Deprecated: Use BabysitterInfo.ProtoReflect.Descriptor instead.

func (*BabysitterInfo) GetDeployment

func (x *BabysitterInfo) GetDeployment() *protos.Deployment

func (*BabysitterInfo) GetGroup

func (x *BabysitterInfo) GetGroup() *protos.ColocationGroup

func (*BabysitterInfo) GetLogDir

func (x *BabysitterInfo) GetLogDir() string

func (*BabysitterInfo) GetManagerAddr

func (x *BabysitterInfo) GetManagerAddr() string

func (*BabysitterInfo) GetReplicaId

func (x *BabysitterInfo) GetReplicaId() int32

func (*BabysitterInfo) ProtoMessage

func (*BabysitterInfo) ProtoMessage()

func (*BabysitterInfo) ProtoReflect

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

func (*BabysitterInfo) Reset

func (x *BabysitterInfo) Reset()

func (*BabysitterInfo) String

func (x *BabysitterInfo) String() string

type BabysitterMetrics

type BabysitterMetrics struct {
	GroupName string                   `protobuf:"bytes,1,opt,name=group_name,json=groupName,proto3" json:"group_name,omitempty"`
	ReplicaId int32                    `protobuf:"varint,2,opt,name=replica_id,json=replicaId,proto3" json:"replica_id,omitempty"`
	Metrics   []*protos.MetricSnapshot `protobuf:"bytes,3,rep,name=metrics,proto3" json:"metrics,omitempty"`
	// contains filtered or unexported fields
}

BabysitterMetrics is a snapshot of a deployment's metrics as collected by a babysitter for a given colocation group.

func (*BabysitterMetrics) Descriptor deprecated

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

Deprecated: Use BabysitterMetrics.ProtoReflect.Descriptor instead.

func (*BabysitterMetrics) GetGroupName

func (x *BabysitterMetrics) GetGroupName() string

func (*BabysitterMetrics) GetMetrics

func (x *BabysitterMetrics) GetMetrics() []*protos.MetricSnapshot

func (*BabysitterMetrics) GetReplicaId

func (x *BabysitterMetrics) GetReplicaId() int32

func (*BabysitterMetrics) ProtoMessage

func (*BabysitterMetrics) ProtoMessage()

func (*BabysitterMetrics) ProtoReflect

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

func (*BabysitterMetrics) Reset

func (x *BabysitterMetrics) Reset()

func (*BabysitterMetrics) String

func (x *BabysitterMetrics) String() string

type ColocationGroupState added in v0.1.2

type ColocationGroupState struct {
	Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"` // Name of the colocation group.
	// The set of components that a colocation group in a given deployment
	// should be running, along with their routing status (whether a component is
	// routed).
	Components map[string]bool `` /* 162-byte string literal not displayed */
	// The list of replica addresses for the colocation group.
	Replicas []string `protobuf:"bytes,3,rep,name=replicas,proto3" json:"replicas,omitempty"`
	// It contains the list of replica pids for the colocation group.
	ReplicaPids []int64 `protobuf:"varint,4,rep,packed,name=replica_pids,json=replicaPids,proto3" json:"replica_pids,omitempty"`
	// It contains the list of assignments for the routed components that are
	// running in a colocation group.
	Assignments map[string]*protos.Assignment `` /* 163-byte string literal not displayed */
	// contains filtered or unexported fields
}

func (*ColocationGroupState) Descriptor deprecated added in v0.1.2

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

Deprecated: Use ColocationGroupState.ProtoReflect.Descriptor instead.

func (*ColocationGroupState) GetAssignments added in v0.1.2

func (x *ColocationGroupState) GetAssignments() map[string]*protos.Assignment

func (*ColocationGroupState) GetComponents added in v0.1.2

func (x *ColocationGroupState) GetComponents() map[string]bool

func (*ColocationGroupState) GetName added in v0.1.2

func (x *ColocationGroupState) GetName() string

func (*ColocationGroupState) GetReplicaPids added in v0.1.2

func (x *ColocationGroupState) GetReplicaPids() []int64

func (*ColocationGroupState) GetReplicas added in v0.1.2

func (x *ColocationGroupState) GetReplicas() []string

func (*ColocationGroupState) ProtoMessage added in v0.1.2

func (*ColocationGroupState) ProtoMessage()

func (*ColocationGroupState) ProtoReflect added in v0.1.2

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

func (*ColocationGroupState) Reset added in v0.1.2

func (x *ColocationGroupState) Reset()

func (*ColocationGroupState) String added in v0.1.2

func (x *ColocationGroupState) String() string

Jump to

Keyboard shortcuts

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