v1

package
v0.8.0 Latest Latest
Warning

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

Go to latest
Published: Sep 28, 2025 License: Apache-2.0 Imports: 11 Imported by: 0

Documentation

Overview

Code generated by protoc-gen-go-ttrpc. DO NOT EDIT. source: shim.proto

Index

Constants

This section is empty.

Variables

View Source
var (
	ContainerPhase_name = map[int32]string{
		0: "SCALED_DOWN",
		1: "RUNNING",
		2: "STOPPING",
	}
	ContainerPhase_value = map[string]int32{
		"SCALED_DOWN": 0,
		"RUNNING":     1,
		"STOPPING":    2,
	}
)

Enum value maps for ContainerPhase.

Functions

func RegisterShimService

func RegisterShimService(srv *ttrpc.Server, svc ShimService)

func WriteAddress added in v0.6.0

func WriteAddress(path, address string) error

WriteAddress writes a address file atomically

Types

type ContainerMetrics added in v0.6.0

type ContainerMetrics struct {
	Name                   string                 `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"`
	PodName                string                 `protobuf:"bytes,2,opt,name=pod_name,json=podName,proto3" json:"pod_name,omitempty"`
	PodNamespace           string                 `protobuf:"bytes,3,opt,name=pod_namespace,json=podNamespace,proto3" json:"pod_namespace,omitempty"`
	LastCheckpoint         *timestamppb.Timestamp `protobuf:"bytes,4,opt,name=lastCheckpoint,proto3" json:"lastCheckpoint,omitempty"`
	LastRestore            *timestamppb.Timestamp `protobuf:"bytes,5,opt,name=lastRestore,proto3" json:"lastRestore,omitempty"`
	LastCheckpointDuration *durationpb.Duration   `protobuf:"bytes,6,opt,name=lastCheckpointDuration,proto3" json:"lastCheckpointDuration,omitempty"`
	LastRestoreDuration    *durationpb.Duration   `protobuf:"bytes,7,opt,name=lastRestoreDuration,proto3" json:"lastRestoreDuration,omitempty"`
	Running                bool                   `protobuf:"varint,8,opt,name=running,proto3" json:"running,omitempty"`
	// contains filtered or unexported fields
}

func (*ContainerMetrics) Descriptor deprecated added in v0.6.0

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

Deprecated: Use ContainerMetrics.ProtoReflect.Descriptor instead.

func (*ContainerMetrics) GetLastCheckpoint added in v0.6.0

func (x *ContainerMetrics) GetLastCheckpoint() *timestamppb.Timestamp

func (*ContainerMetrics) GetLastCheckpointDuration added in v0.6.0

func (x *ContainerMetrics) GetLastCheckpointDuration() *durationpb.Duration

func (*ContainerMetrics) GetLastRestore added in v0.6.0

func (x *ContainerMetrics) GetLastRestore() *timestamppb.Timestamp

func (*ContainerMetrics) GetLastRestoreDuration added in v0.6.0

func (x *ContainerMetrics) GetLastRestoreDuration() *durationpb.Duration

func (*ContainerMetrics) GetName added in v0.6.0

func (x *ContainerMetrics) GetName() string

func (*ContainerMetrics) GetPodName added in v0.6.0

func (x *ContainerMetrics) GetPodName() string

func (*ContainerMetrics) GetPodNamespace added in v0.6.0

func (x *ContainerMetrics) GetPodNamespace() string

func (*ContainerMetrics) GetRunning added in v0.6.0

func (x *ContainerMetrics) GetRunning() bool

func (*ContainerMetrics) ProtoMessage added in v0.6.0

func (*ContainerMetrics) ProtoMessage()

func (*ContainerMetrics) ProtoReflect added in v0.6.0

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

func (*ContainerMetrics) Reset added in v0.6.0

func (x *ContainerMetrics) Reset()

func (*ContainerMetrics) String added in v0.6.0

func (x *ContainerMetrics) String() string

type ContainerPhase

type ContainerPhase int32
const (
	ContainerPhase_SCALED_DOWN ContainerPhase = 0
	ContainerPhase_RUNNING     ContainerPhase = 1
	ContainerPhase_STOPPING    ContainerPhase = 2
)

func (ContainerPhase) Descriptor

func (ContainerPhase) Enum

func (x ContainerPhase) Enum() *ContainerPhase

func (ContainerPhase) EnumDescriptor deprecated

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

Deprecated: Use ContainerPhase.Descriptor instead.

func (ContainerPhase) Number

func (ContainerPhase) String

func (x ContainerPhase) String() string

func (ContainerPhase) Type

type ContainerRequest

type ContainerRequest struct {
	Id string `protobuf:"bytes,1,opt,name=id,proto3" json:"id,omitempty"`
	// contains filtered or unexported fields
}

func (*ContainerRequest) Descriptor deprecated

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

Deprecated: Use ContainerRequest.ProtoReflect.Descriptor instead.

func (*ContainerRequest) GetId

func (x *ContainerRequest) GetId() string

func (*ContainerRequest) ProtoMessage

func (*ContainerRequest) ProtoMessage()

func (*ContainerRequest) ProtoReflect

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

func (*ContainerRequest) Reset

func (x *ContainerRequest) Reset()

func (*ContainerRequest) String

func (x *ContainerRequest) String() string

type ContainerStatus

type ContainerStatus struct {
	Id            string                 `protobuf:"bytes,1,opt,name=id,proto3" json:"id,omitempty"`
	Name          string                 `protobuf:"bytes,2,opt,name=name,proto3" json:"name,omitempty"`
	PodName       string                 `protobuf:"bytes,3,opt,name=pod_name,json=podName,proto3" json:"pod_name,omitempty"`
	PodNamespace  string                 `protobuf:"bytes,4,opt,name=pod_namespace,json=podNamespace,proto3" json:"pod_namespace,omitempty"`
	Phase         ContainerPhase         `protobuf:"varint,5,opt,name=phase,proto3,enum=zeropod.shim.v1.ContainerPhase" json:"phase,omitempty"`
	EventTime     *timestamppb.Timestamp `protobuf:"bytes,6,opt,name=event_time,json=eventTime,proto3" json:"event_time,omitempty"`
	EventDuration *durationpb.Duration   `protobuf:"bytes,7,opt,name=event_duration,json=eventDuration,proto3" json:"event_duration,omitempty"`
	// contains filtered or unexported fields
}

func (*ContainerStatus) Descriptor deprecated

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

Deprecated: Use ContainerStatus.ProtoReflect.Descriptor instead.

func (*ContainerStatus) GetEventDuration added in v0.7.0

func (x *ContainerStatus) GetEventDuration() *durationpb.Duration

func (*ContainerStatus) GetEventTime added in v0.7.0

func (x *ContainerStatus) GetEventTime() *timestamppb.Timestamp

func (*ContainerStatus) GetId

func (x *ContainerStatus) GetId() string

func (*ContainerStatus) GetName

func (x *ContainerStatus) GetName() string

func (*ContainerStatus) GetPhase

func (x *ContainerStatus) GetPhase() ContainerPhase

func (*ContainerStatus) GetPodName

func (x *ContainerStatus) GetPodName() string

func (*ContainerStatus) GetPodNamespace

func (x *ContainerStatus) GetPodNamespace() string

func (*ContainerStatus) ProtoMessage

func (*ContainerStatus) ProtoMessage()

func (*ContainerStatus) ProtoReflect

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

func (*ContainerStatus) Reset

func (x *ContainerStatus) Reset()

func (*ContainerStatus) String

func (x *ContainerStatus) String() string

type MetricsRequest

type MetricsRequest struct {
	Empty *emptypb.Empty `protobuf:"bytes,1,opt,name=empty,proto3" json:"empty,omitempty"`
	// contains filtered or unexported fields
}

func (*MetricsRequest) Descriptor deprecated

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

Deprecated: Use MetricsRequest.ProtoReflect.Descriptor instead.

func (*MetricsRequest) GetEmpty

func (x *MetricsRequest) GetEmpty() *emptypb.Empty

func (*MetricsRequest) ProtoMessage

func (*MetricsRequest) ProtoMessage()

func (*MetricsRequest) ProtoReflect

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

func (*MetricsRequest) Reset

func (x *MetricsRequest) Reset()

func (*MetricsRequest) String

func (x *MetricsRequest) String() string

type MetricsResponse

type MetricsResponse struct {
	Metrics []*ContainerMetrics `protobuf:"bytes,1,rep,name=metrics,proto3" json:"metrics,omitempty"`
	// contains filtered or unexported fields
}

func (*MetricsResponse) Descriptor deprecated

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

Deprecated: Use MetricsResponse.ProtoReflect.Descriptor instead.

func (*MetricsResponse) GetMetrics

func (x *MetricsResponse) GetMetrics() []*ContainerMetrics

func (*MetricsResponse) ProtoMessage

func (*MetricsResponse) ProtoMessage()

func (*MetricsResponse) ProtoReflect

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

func (*MetricsResponse) Reset

func (x *MetricsResponse) Reset()

func (*MetricsResponse) String

func (x *MetricsResponse) String() string

type ShimClient

func NewShimClient

func NewShimClient(client *ttrpc.Client) ShimClient

type Shim_SubscribeStatusClient

type Shim_SubscribeStatusClient interface {
	Recv() (*ContainerStatus, error)
	ttrpc.ClientStream
}

type Shim_SubscribeStatusServer

type Shim_SubscribeStatusServer interface {
	Send(*ContainerStatus) error
	ttrpc.StreamServer
}

type SubscribeStatusRequest

type SubscribeStatusRequest struct {
	Empty *emptypb.Empty `protobuf:"bytes,1,opt,name=empty,proto3" json:"empty,omitempty"`
	// contains filtered or unexported fields
}

func (*SubscribeStatusRequest) Descriptor deprecated

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

Deprecated: Use SubscribeStatusRequest.ProtoReflect.Descriptor instead.

func (*SubscribeStatusRequest) GetEmpty

func (x *SubscribeStatusRequest) GetEmpty() *emptypb.Empty

func (*SubscribeStatusRequest) ProtoMessage

func (*SubscribeStatusRequest) ProtoMessage()

func (*SubscribeStatusRequest) ProtoReflect

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

func (*SubscribeStatusRequest) Reset

func (x *SubscribeStatusRequest) Reset()

func (*SubscribeStatusRequest) String

func (x *SubscribeStatusRequest) String() string

Jump to

Keyboard shortcuts

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