actorv1

package
v0.15.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: 8 Imported by: 1 module, 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 (
	Restart_name = map[int32]string{
		0: "RESTART_UNSPECIFIED",
		1: "RESTART_PERMANENT",
		2: "RESTART_TRANSIENT",
		3: "RESTART_TEMPORARY",
	}
	Restart_value = map[string]int32{
		"RESTART_UNSPECIFIED": 0,
		"RESTART_PERMANENT":   1,
		"RESTART_TRANSIENT":   2,
		"RESTART_TEMPORARY":   3,
	}
)

Enum value maps for Restart.

View Source
var File_grpcproc_actor_v1_actor_proto protoreflect.FileDescriptor

Functions

This section is empty.

Types

type Child added in v0.2.0

type Child struct {

	// Empty for an anonymous child.
	Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"`
	// Unset unless the child runs.
	Pid *v1.PID `protobuf:"bytes,2,opt,name=pid,proto3" json:"pid,omitempty"`
	// A restart owes the child a start, which waits for a process to exit.
	Restarting bool    `protobuf:"varint,3,opt,name=restarting,proto3" json:"restarting,omitempty"`
	Restart    Restart `protobuf:"varint,4,opt,name=restart,proto3,enum=grpcproc.actor.v1.Restart" json:"restart,omitempty"`
	// How many times the supervisor has restarted it.
	Restarts uint32 `protobuf:"varint,5,opt,name=restarts,proto3" json:"restarts,omitempty"`
	// The child is a supervisor itself.
	Supervisor bool `protobuf:"varint,6,opt,name=supervisor,proto3" json:"supervisor,omitempty"`
	// contains filtered or unexported fields
}

func (*Child) Descriptor deprecated added in v0.2.0

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

Deprecated: Use Child.ProtoReflect.Descriptor instead.

func (*Child) GetName added in v0.2.0

func (x *Child) GetName() string

func (*Child) GetPid added in v0.2.0

func (x *Child) GetPid() *v1.PID

func (*Child) GetRestart added in v0.2.0

func (x *Child) GetRestart() Restart

func (*Child) GetRestarting added in v0.2.0

func (x *Child) GetRestarting() bool

func (*Child) GetRestarts added in v0.2.0

func (x *Child) GetRestarts() uint32

func (*Child) GetSupervisor added in v0.2.0

func (x *Child) GetSupervisor() bool

func (*Child) ProtoMessage added in v0.2.0

func (*Child) ProtoMessage()

func (*Child) ProtoReflect added in v0.2.0

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

func (*Child) Reset added in v0.2.0

func (x *Child) Reset()

func (*Child) String added in v0.2.0

func (x *Child) String() string

type Children added in v0.2.0

type Children struct {
	Children []*Child `protobuf:"bytes,1,rep,name=children,proto3" json:"children,omitempty"`
	// contains filtered or unexported fields
}

Children answers which_children: the supervisor's children, in the order it starts them.

func (*Children) Descriptor deprecated added in v0.2.0

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

Deprecated: Use Children.ProtoReflect.Descriptor instead.

func (*Children) GetChildren added in v0.2.0

func (x *Children) GetChildren() []*Child

func (*Children) ProtoMessage added in v0.2.0

func (*Children) ProtoMessage()

func (*Children) ProtoReflect added in v0.2.0

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

func (*Children) Reset added in v0.2.0

func (x *Children) Reset()

func (*Children) String added in v0.2.0

func (x *Children) String() string

type Control

type Control struct {

	// Types that are valid to be assigned to Op:
	//
	//	*Control_Start
	//	*Control_Stop
	//	*Control_WhichChildren
	//	*Control_StartFrom
	Op isControl_Op `protobuf_oneof:"op"`
	// contains filtered or unexported fields
}

Control asks a supervisor to start a child, to stop one, or which children it has.

func (*Control) Descriptor deprecated

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

Deprecated: Use Control.ProtoReflect.Descriptor instead.

func (*Control) GetOp

func (x *Control) GetOp() isControl_Op

func (*Control) GetStart

func (x *Control) GetStart() uint64

func (*Control) GetStartFrom added in v0.3.0

func (x *Control) GetStartFrom() *StartFrom

func (*Control) GetStop

func (x *Control) GetStop() *v1.PID

func (*Control) GetWhichChildren added in v0.2.0

func (x *Control) GetWhichChildren() *emptypb.Empty

func (*Control) ProtoMessage

func (*Control) ProtoMessage()

func (*Control) ProtoReflect

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

func (*Control) Reset

func (x *Control) Reset()

func (*Control) String

func (x *Control) String() string

type Control_Start

type Control_Start struct {
	// A child spec its caller registered in the actor package under this
	// id. A spec holds Go functions, so only a supervisor on the caller's
	// node can start it. Answered with Started.
	Start uint64 `protobuf:"varint,1,opt,name=start,proto3,oneof"`
}

type Control_StartFrom added in v0.3.0

type Control_StartFrom struct {
	// A child one of the supervisor's factories builds, from any node.
	// Answered with Started.
	StartFrom *StartFrom `protobuf:"bytes,4,opt,name=start_from,json=startFrom,proto3,oneof"`
}

type Control_Stop

type Control_Stop struct {
	// A running child to stop and forget.
	Stop *v1.PID `protobuf:"bytes,2,opt,name=stop,proto3,oneof"`
}

type Control_WhichChildren added in v0.2.0

type Control_WhichChildren struct {
	// Answered with Children.
	WhichChildren *emptypb.Empty `protobuf:"bytes,3,opt,name=which_children,json=whichChildren,proto3,oneof"`
}

type Restart added in v0.2.0

type Restart int32
const (
	Restart_RESTART_UNSPECIFIED Restart = 0
	Restart_RESTART_PERMANENT   Restart = 1
	Restart_RESTART_TRANSIENT   Restart = 2
	Restart_RESTART_TEMPORARY   Restart = 3
)

func (Restart) Descriptor added in v0.2.0

func (Restart) Descriptor() protoreflect.EnumDescriptor

func (Restart) Enum added in v0.2.0

func (x Restart) Enum() *Restart

func (Restart) EnumDescriptor deprecated added in v0.2.0

func (Restart) EnumDescriptor() ([]byte, []int)

Deprecated: Use Restart.Descriptor instead.

func (Restart) Number added in v0.2.0

func (x Restart) Number() protoreflect.EnumNumber

func (Restart) String added in v0.2.0

func (x Restart) String() string

func (Restart) Type added in v0.2.0

func (Restart) Type() protoreflect.EnumType

type StartFrom added in v0.3.0

type StartFrom struct {
	Factory string     `protobuf:"bytes,1,opt,name=factory,proto3" json:"factory,omitempty"`
	Arg     *anypb.Any `protobuf:"bytes,2,opt,name=arg,proto3" json:"arg,omitempty"`
	// contains filtered or unexported fields
}

StartFrom names a factory of the supervisor's Spec, and the argument it builds a child spec from.

func (*StartFrom) Descriptor deprecated added in v0.3.0

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

Deprecated: Use StartFrom.ProtoReflect.Descriptor instead.

func (*StartFrom) GetArg added in v0.3.0

func (x *StartFrom) GetArg() *anypb.Any

func (*StartFrom) GetFactory added in v0.3.0

func (x *StartFrom) GetFactory() string

func (*StartFrom) ProtoMessage added in v0.3.0

func (*StartFrom) ProtoMessage()

func (*StartFrom) ProtoReflect added in v0.3.0

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

func (*StartFrom) Reset added in v0.3.0

func (x *StartFrom) Reset()

func (*StartFrom) String added in v0.3.0

func (x *StartFrom) String() string

type Started added in v0.2.0

type Started struct {
	Pid *v1.PID `protobuf:"bytes,1,opt,name=pid,proto3" json:"pid,omitempty"`
	// A child of the spec's name was running already: pid is that child's,
	// and the spec was not started.
	Already bool `protobuf:"varint,2,opt,name=already,proto3" json:"already,omitempty"`
	// contains filtered or unexported fields
}

Started answers a start with the child's PID.

func (*Started) Descriptor deprecated added in v0.2.0

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

Deprecated: Use Started.ProtoReflect.Descriptor instead.

func (*Started) GetAlready added in v0.2.0

func (x *Started) GetAlready() bool

func (*Started) GetPid added in v0.2.0

func (x *Started) GetPid() *v1.PID

func (*Started) ProtoMessage added in v0.2.0

func (*Started) ProtoMessage()

func (*Started) ProtoReflect added in v0.2.0

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

func (*Started) Reset added in v0.2.0

func (x *Started) Reset()

func (*Started) String added in v0.2.0

func (x *Started) String() string

Jump to

Keyboard shortcuts

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