Documentation ¶
Overview ¶
Copyright 2019 Gravitational, Inc.
Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.
Index ¶
- Variables
- func IsAbortedError(err error) bool
- func IsCompletedError(err error) bool
- func IsFailedPreconditionError(err error) bool
- func IsRPCError(err error) bool
- func KeyFromProto(key *OperationKey) ops.SiteOperationKey
- func RegisterAgentServer(s *grpc.Server, srv AgentServer)
- func WrapServiceError(err error) error
- type AbortRequest
- func (*AbortRequest) Descriptor() ([]byte, []int)
- func (*AbortRequest) ProtoMessage()
- func (m *AbortRequest) Reset()
- func (m *AbortRequest) String() string
- func (m *AbortRequest) XXX_DiscardUnknown()
- func (m *AbortRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *AbortRequest) XXX_Merge(src proto.Message)
- func (m *AbortRequest) XXX_Size() int
- func (m *AbortRequest) XXX_Unmarshal(b []byte) error
- type AgentClient
- type AgentServer
- type Agent_ExecuteClient
- type Agent_ExecuteServer
- type ClientConfig
- type CompleteRequest
- func (*CompleteRequest) Descriptor() ([]byte, []int)
- func (m *CompleteRequest) GetKey() *OperationKey
- func (*CompleteRequest) ProtoMessage()
- func (m *CompleteRequest) Reset()
- func (m *CompleteRequest) String() string
- func (m *CompleteRequest) XXX_DiscardUnknown()
- func (m *CompleteRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *CompleteRequest) XXX_Merge(src proto.Message)
- func (m *CompleteRequest) XXX_Size() int
- func (m *CompleteRequest) XXX_Unmarshal(b []byte) error
- type DebugReportRequest
- func (*DebugReportRequest) Descriptor() ([]byte, []int)
- func (m *DebugReportRequest) GetPath() string
- func (*DebugReportRequest) ProtoMessage()
- func (m *DebugReportRequest) Reset()
- func (m *DebugReportRequest) String() string
- func (m *DebugReportRequest) XXX_DiscardUnknown()
- func (m *DebugReportRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *DebugReportRequest) XXX_Merge(src proto.Message)
- func (m *DebugReportRequest) XXX_Size() int
- func (m *DebugReportRequest) XXX_Unmarshal(b []byte) error
- type Error
- func (*Error) Descriptor() ([]byte, []int)
- func (m *Error) GetMessage() string
- func (*Error) ProtoMessage()
- func (m *Error) Reset()
- func (m *Error) String() string
- func (m *Error) XXX_DiscardUnknown()
- func (m *Error) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *Error) XXX_Merge(src proto.Message)
- func (m *Error) XXX_Size() int
- func (m *Error) XXX_Unmarshal(b []byte) error
- type ExecuteRequest
- func (*ExecuteRequest) Descriptor() ([]byte, []int)
- func (m *ExecuteRequest) GetPhase() *Phase
- func (r *ExecuteRequest) HasResume() bool
- func (r *ExecuteRequest) HasSpecificPhase() bool
- func (*ExecuteRequest) ProtoMessage()
- func (m *ExecuteRequest) Reset()
- func (m *ExecuteRequest) String() string
- func (m *ExecuteRequest) XXX_DiscardUnknown()
- func (m *ExecuteRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *ExecuteRequest) XXX_Merge(src proto.Message)
- func (m *ExecuteRequest) XXX_Size() int
- func (m *ExecuteRequest) XXX_Unmarshal(b []byte) error
- type OperationKey
- func (*OperationKey) Descriptor() ([]byte, []int)
- func (m *OperationKey) GetAccountID() string
- func (m *OperationKey) GetClusterName() string
- func (m *OperationKey) GetID() string
- func (*OperationKey) ProtoMessage()
- func (m *OperationKey) Reset()
- func (m *OperationKey) String() string
- func (m *OperationKey) XXX_DiscardUnknown()
- func (m *OperationKey) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *OperationKey) XXX_Merge(src proto.Message)
- func (m *OperationKey) XXX_Size() int
- func (m *OperationKey) XXX_Unmarshal(b []byte) error
- type Phase
- func (*Phase) Descriptor() ([]byte, []int)
- func (m *Phase) GetForce() bool
- func (m *Phase) GetID() string
- func (m *Phase) GetKey() *OperationKey
- func (m *Phase) GetRollback() bool
- func (r *Phase) IsResume() bool
- func (*Phase) ProtoMessage()
- func (m *Phase) Reset()
- func (m *Phase) String() string
- func (m *Phase) XXX_DiscardUnknown()
- func (m *Phase) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *Phase) XXX_Merge(src proto.Message)
- func (m *Phase) XXX_Size() int
- func (m *Phase) XXX_Unmarshal(b []byte) error
- type ProgressResponse
- func (*ProgressResponse) Descriptor() ([]byte, []int)
- func (m *ProgressResponse) GetError() *Error
- func (m *ProgressResponse) GetMessage() string
- func (m *ProgressResponse) GetStatus() ProgressResponse_Status
- func (r *ProgressResponse) IsAborted() bool
- func (r *ProgressResponse) IsCompleted() bool
- func (*ProgressResponse) ProtoMessage()
- func (m *ProgressResponse) Reset()
- func (m *ProgressResponse) String() string
- func (m *ProgressResponse) XXX_DiscardUnknown()
- func (m *ProgressResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *ProgressResponse) XXX_Merge(src proto.Message)
- func (m *ProgressResponse) XXX_Size() int
- func (m *ProgressResponse) XXX_Unmarshal(b []byte) error
- type ProgressResponse_Status
- type SetStateRequest
- func (*SetStateRequest) Descriptor() ([]byte, []int)
- func (m *SetStateRequest) GetPhase() *Phase
- func (m *SetStateRequest) GetState() string
- func (r *SetStateRequest) OperationID() string
- func (r *SetStateRequest) OperationKey() ops.SiteOperationKey
- func (*SetStateRequest) ProtoMessage()
- func (m *SetStateRequest) Reset()
- func (m *SetStateRequest) String() string
- func (m *SetStateRequest) XXX_DiscardUnknown()
- func (m *SetStateRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *SetStateRequest) XXX_Merge(src proto.Message)
- func (m *SetStateRequest) XXX_Size() int
- func (m *SetStateRequest) XXX_Unmarshal(b []byte) error
- type ShutdownRequest
- func (*ShutdownRequest) Descriptor() ([]byte, []int)
- func (m *ShutdownRequest) GetCompleted() bool
- func (m *ShutdownRequest) GetExitCode() int32
- func (*ShutdownRequest) ProtoMessage()
- func (m *ShutdownRequest) Reset()
- func (m *ShutdownRequest) String() string
- func (m *ShutdownRequest) XXX_DiscardUnknown()
- func (m *ShutdownRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *ShutdownRequest) XXX_Merge(src proto.Message)
- func (m *ShutdownRequest) XXX_Size() int
- func (m *ShutdownRequest) XXX_Unmarshal(b []byte) error
- type UnimplementedAgentServer
- func (*UnimplementedAgentServer) Abort(ctx context.Context, req *AbortRequest) (*types.Empty, error)
- func (*UnimplementedAgentServer) Complete(ctx context.Context, req *CompleteRequest) (*types.Empty, error)
- func (*UnimplementedAgentServer) Execute(req *ExecuteRequest, srv Agent_ExecuteServer) error
- func (*UnimplementedAgentServer) GenerateDebugReport(ctx context.Context, req *DebugReportRequest) (*types.Empty, error)
- func (*UnimplementedAgentServer) SetState(ctx context.Context, req *SetStateRequest) (*types.Empty, error)
- func (*UnimplementedAgentServer) Shutdown(ctx context.Context, req *ShutdownRequest) (*types.Empty, error)
Constants ¶
This section is empty.
Variables ¶
var AbortEvent = &ProgressResponse{ Status: StatusAborted, }
AbortEvent is a progress response that indicates an aborted operation
var CompleteEvent = &ProgressResponse{ Status: StatusCompleted, }
CompleteEvent is a progress response that indicates a successfully completed operation
var Empty = &types.Empty{}
Empty defines the empty RPC message
var ErrAborted = utils.NewExitCodeErrorWithMessage(defaults.AbortedOperationExitCode, "operation aborted")
ErrAborted defines the aborted operation error
var ErrCompleted = utils.NewExitCodeErrorWithMessage(defaults.CompletedOperationExitCode, "operation completed")
ErrCompleted defines the completed operation error. This is not an error in the usual sense - rather, it indicates that the operation has been completed and that the agent should shut down and not restart
var ProgressResponse_Status_name = map[int32]string{
0: "UNKNOWN",
1: "COMPLETED",
2: "COMPLETED_PENDING",
3: "ABORTED",
}
var ProgressResponse_Status_value = map[string]int32{
"UNKNOWN": 0,
"COMPLETED": 1,
"COMPLETED_PENDING": 2,
"ABORTED": 3,
}
Functions ¶
func IsAbortedError ¶
IsAbortedError returns true if the specified error identifies the aborted operation
func IsCompletedError ¶
IsCompletedError returns true if the specified error identifies the completed operation
func IsFailedPreconditionError ¶
IsFailedPreconditionError returns true if the specified error indicates a failed precondition RPC error
func IsRPCError ¶
IsRPCError returns true if the specified error is a gRPC error
func KeyFromProto ¶
func KeyFromProto(key *OperationKey) ops.SiteOperationKey
KeyFromProto converts the specified operation key to internal format
func RegisterAgentServer ¶
func RegisterAgentServer(s *grpc.Server, srv AgentServer)
func WrapServiceError ¶
WrapServiceError returns an error from service optionally translating it to a more appropriate representation if required
Types ¶
type AbortRequest ¶
type AbortRequest struct { XXX_NoUnkeyedLiteral struct{} `json:"-"` XXX_unrecognized []byte `json:"-"` XXX_sizecache int32 `json:"-"` }
AbortRequest describes a request to abort the operation and clean up
func (*AbortRequest) Descriptor ¶
func (*AbortRequest) Descriptor() ([]byte, []int)
func (*AbortRequest) ProtoMessage ¶
func (*AbortRequest) ProtoMessage()
func (*AbortRequest) Reset ¶
func (m *AbortRequest) Reset()
func (*AbortRequest) String ¶
func (m *AbortRequest) String() string
func (*AbortRequest) XXX_DiscardUnknown ¶
func (m *AbortRequest) XXX_DiscardUnknown()
func (*AbortRequest) XXX_Marshal ¶
func (m *AbortRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
func (*AbortRequest) XXX_Merge ¶
func (m *AbortRequest) XXX_Merge(src proto.Message)
func (*AbortRequest) XXX_Size ¶
func (m *AbortRequest) XXX_Size() int
func (*AbortRequest) XXX_Unmarshal ¶
func (m *AbortRequest) XXX_Unmarshal(b []byte) error
type AgentClient ¶
type AgentClient interface { // Execute runs the operation specified with request. // If the client drops disconnects in the middle of the operation, // it can reconnect later and continue receiving progress updates // until the operation has completed Execute(ctx context.Context, in *ExecuteRequest, opts ...grpc.CallOption) (Agent_ExecuteClient, error) // Complete marks the operation as completed Complete(ctx context.Context, in *CompleteRequest, opts ...grpc.CallOption) (*types.Empty, error) // SetState sets the specified phase state without executing it SetState(ctx context.Context, in *SetStateRequest, opts ...grpc.CallOption) (*types.Empty, error) // Abort requests that the installer service aborts Abort(ctx context.Context, in *AbortRequest, opts ...grpc.CallOption) (*types.Empty, error) // Shutdown requests that the installer service shuts down gracefully Shutdown(ctx context.Context, in *ShutdownRequest, opts ...grpc.CallOption) (*types.Empty, error) // GenerateDebugReport requests the installer to generate a debug report GenerateDebugReport(ctx context.Context, in *DebugReportRequest, opts ...grpc.CallOption) (*types.Empty, error) }
AgentClient is the client API for Agent service.
For semantics around ctx use and closing/ending streaming RPCs, please refer to https://godoc.org/google.golang.org/grpc#ClientConn.NewStream.
func NewAgentClient ¶
func NewAgentClient(cc *grpc.ClientConn) AgentClient
func NewClient ¶
func NewClient(ctx context.Context, config ClientConfig) (AgentClient, error)
NewClient returns a new client using the specified socket file path
type AgentServer ¶
type AgentServer interface { // Execute runs the operation specified with request. // If the client drops disconnects in the middle of the operation, // it can reconnect later and continue receiving progress updates // until the operation has completed Execute(*ExecuteRequest, Agent_ExecuteServer) error // Complete marks the operation as completed Complete(context.Context, *CompleteRequest) (*types.Empty, error) // SetState sets the specified phase state without executing it SetState(context.Context, *SetStateRequest) (*types.Empty, error) // Abort requests that the installer service aborts Abort(context.Context, *AbortRequest) (*types.Empty, error) // Shutdown requests that the installer service shuts down gracefully Shutdown(context.Context, *ShutdownRequest) (*types.Empty, error) // GenerateDebugReport requests the installer to generate a debug report GenerateDebugReport(context.Context, *DebugReportRequest) (*types.Empty, error) }
AgentServer is the server API for Agent service.
type Agent_ExecuteClient ¶
type Agent_ExecuteClient interface { Recv() (*ProgressResponse, error) grpc.ClientStream }
type Agent_ExecuteServer ¶
type Agent_ExecuteServer interface { Send(*ProgressResponse) error grpc.ServerStream }
type ClientConfig ¶
type ClientConfig struct { // FieldLogger specifies the logger log.FieldLogger // SocketPath specifies the path to the service's socket file SocketPath string // ShouldReconnectService determines if the service should be reconnected. // If this returns an error, the internal dialer will cancel all attempts to reconnect ShouldReconnectService func() error // DialOptions specifies additional gRPC dial options DialOptions []grpc.DialOption }
ClientConfig describes client configuration
type CompleteRequest ¶
type CompleteRequest struct { // Key identifies the operation Key *OperationKey `protobuf:"bytes,1,opt,name=key,proto3" json:"key,omitempty"` XXX_NoUnkeyedLiteral struct{} `json:"-"` XXX_unrecognized []byte `json:"-"` XXX_sizecache int32 `json:"-"` }
CompleteRequest describes a request to manually complete the operation
func (*CompleteRequest) Descriptor ¶
func (*CompleteRequest) Descriptor() ([]byte, []int)
func (*CompleteRequest) GetKey ¶
func (m *CompleteRequest) GetKey() *OperationKey
func (*CompleteRequest) ProtoMessage ¶
func (*CompleteRequest) ProtoMessage()
func (*CompleteRequest) Reset ¶
func (m *CompleteRequest) Reset()
func (*CompleteRequest) String ¶
func (m *CompleteRequest) String() string
func (*CompleteRequest) XXX_DiscardUnknown ¶
func (m *CompleteRequest) XXX_DiscardUnknown()
func (*CompleteRequest) XXX_Marshal ¶
func (m *CompleteRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
func (*CompleteRequest) XXX_Merge ¶
func (m *CompleteRequest) XXX_Merge(src proto.Message)
func (*CompleteRequest) XXX_Size ¶
func (m *CompleteRequest) XXX_Size() int
func (*CompleteRequest) XXX_Unmarshal ¶
func (m *CompleteRequest) XXX_Unmarshal(b []byte) error
type DebugReportRequest ¶
type DebugReportRequest struct { // Path specifies the path to the report file Path string `protobuf:"bytes,1,opt,name=path,proto3" json:"path,omitempty"` XXX_NoUnkeyedLiteral struct{} `json:"-"` XXX_unrecognized []byte `json:"-"` XXX_sizecache int32 `json:"-"` }
DebugReportRequest describes a request to generate debug report
func (*DebugReportRequest) Descriptor ¶
func (*DebugReportRequest) Descriptor() ([]byte, []int)
func (*DebugReportRequest) GetPath ¶
func (m *DebugReportRequest) GetPath() string
func (*DebugReportRequest) ProtoMessage ¶
func (*DebugReportRequest) ProtoMessage()
func (*DebugReportRequest) Reset ¶
func (m *DebugReportRequest) Reset()
func (*DebugReportRequest) String ¶
func (m *DebugReportRequest) String() string
func (*DebugReportRequest) XXX_DiscardUnknown ¶
func (m *DebugReportRequest) XXX_DiscardUnknown()
func (*DebugReportRequest) XXX_Marshal ¶
func (m *DebugReportRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
func (*DebugReportRequest) XXX_Merge ¶
func (m *DebugReportRequest) XXX_Merge(src proto.Message)
func (*DebugReportRequest) XXX_Size ¶
func (m *DebugReportRequest) XXX_Size() int
func (*DebugReportRequest) XXX_Unmarshal ¶
func (m *DebugReportRequest) XXX_Unmarshal(b []byte) error
type Error ¶
type Error struct { // Message specifies the error message Message string `protobuf:"bytes,1,opt,name=message,proto3" json:"message,omitempty"` XXX_NoUnkeyedLiteral struct{} `json:"-"` XXX_unrecognized []byte `json:"-"` XXX_sizecache int32 `json:"-"` }
Error represents an error in the operation
func (*Error) Descriptor ¶
func (*Error) GetMessage ¶
func (*Error) ProtoMessage ¶
func (*Error) ProtoMessage()
func (*Error) XXX_DiscardUnknown ¶
func (m *Error) XXX_DiscardUnknown()
func (*Error) XXX_Marshal ¶
func (*Error) XXX_Unmarshal ¶
type ExecuteRequest ¶
type ExecuteRequest struct { // Phase optionally specifies the configuration for executing or rolling // back a specific phase. // If unspecified, the operation is executed from the beginning Phase *Phase `protobuf:"bytes,1,opt,name=phase,proto3" json:"phase,omitempty"` XXX_NoUnkeyedLiteral struct{} `json:"-"` XXX_unrecognized []byte `json:"-"` XXX_sizecache int32 `json:"-"` }
ExecuteRequest describes a request to execute install operation
func (*ExecuteRequest) Descriptor ¶
func (*ExecuteRequest) Descriptor() ([]byte, []int)
func (*ExecuteRequest) GetPhase ¶
func (m *ExecuteRequest) GetPhase() *Phase
func (*ExecuteRequest) HasResume ¶
func (r *ExecuteRequest) HasResume() bool
HasResume determines if this is a request to resume an operation
func (*ExecuteRequest) HasSpecificPhase ¶
func (r *ExecuteRequest) HasSpecificPhase() bool
HasSpecificPhase determines if this request is for a specific phase (other than root)
func (*ExecuteRequest) ProtoMessage ¶
func (*ExecuteRequest) ProtoMessage()
func (*ExecuteRequest) Reset ¶
func (m *ExecuteRequest) Reset()
func (*ExecuteRequest) String ¶
func (m *ExecuteRequest) String() string
func (*ExecuteRequest) XXX_DiscardUnknown ¶
func (m *ExecuteRequest) XXX_DiscardUnknown()
func (*ExecuteRequest) XXX_Marshal ¶
func (m *ExecuteRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
func (*ExecuteRequest) XXX_Merge ¶
func (m *ExecuteRequest) XXX_Merge(src proto.Message)
func (*ExecuteRequest) XXX_Size ¶
func (m *ExecuteRequest) XXX_Size() int
func (*ExecuteRequest) XXX_Unmarshal ¶
func (m *ExecuteRequest) XXX_Unmarshal(b []byte) error
type OperationKey ¶
type OperationKey struct { // AccountID refers to the account this operation belongs to AccountID string `protobuf:"bytes,1,opt,name=account_id,json=accountId,proto3" json:"account_id,omitempty"` // ClusterName identifies the cluster for the operation ClusterName string `protobuf:"bytes,2,opt,name=cluster_name,json=clusterName,proto3" json:"cluster_name,omitempty"` // ID specifies the operation ID ID string `protobuf:"bytes,3,opt,name=id,proto3" json:"id,omitempty"` XXX_NoUnkeyedLiteral struct{} `json:"-"` XXX_unrecognized []byte `json:"-"` XXX_sizecache int32 `json:"-"` }
OperationKey describes a cluster operation
func KeyToProto ¶
func KeyToProto(key ops.SiteOperationKey) *OperationKey
KeyToProto converts the specified operation key to proto format
func (*OperationKey) Descriptor ¶
func (*OperationKey) Descriptor() ([]byte, []int)
func (*OperationKey) GetAccountID ¶
func (m *OperationKey) GetAccountID() string
func (*OperationKey) GetClusterName ¶
func (m *OperationKey) GetClusterName() string
func (*OperationKey) GetID ¶
func (m *OperationKey) GetID() string
func (*OperationKey) ProtoMessage ¶
func (*OperationKey) ProtoMessage()
func (*OperationKey) Reset ¶
func (m *OperationKey) Reset()
func (*OperationKey) String ¶
func (m *OperationKey) String() string
func (*OperationKey) XXX_DiscardUnknown ¶
func (m *OperationKey) XXX_DiscardUnknown()
func (*OperationKey) XXX_Marshal ¶
func (m *OperationKey) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
func (*OperationKey) XXX_Merge ¶
func (m *OperationKey) XXX_Merge(src proto.Message)
func (*OperationKey) XXX_Size ¶
func (m *OperationKey) XXX_Size() int
func (*OperationKey) XXX_Unmarshal ¶
func (m *OperationKey) XXX_Unmarshal(b []byte) error
type Phase ¶
type Phase struct { // ID specifies the phase ID ID string `protobuf:"bytes,1,opt,name=id,proto3" json:"id,omitempty"` // Key identifies the operation Key *OperationKey `protobuf:"bytes,2,opt,name=key,proto3" json:"key,omitempty"` // Rollback specifies whether this is a rollback Rollback bool `protobuf:"varint,3,opt,name=rollback,proto3" json:"rollback,omitempty"` // Force specifies whether the phase execution/rollback should be rerun // regardless of phase state Force bool `protobuf:"varint,4,opt,name=force,proto3" json:"force,omitempty"` XXX_NoUnkeyedLiteral struct{} `json:"-"` XXX_unrecognized []byte `json:"-"` XXX_sizecache int32 `json:"-"` }
Phase represents an operation plan phase
func (*Phase) Descriptor ¶
func (*Phase) GetKey ¶
func (m *Phase) GetKey() *OperationKey
func (*Phase) GetRollback ¶
func (*Phase) ProtoMessage ¶
func (*Phase) ProtoMessage()
func (*Phase) XXX_DiscardUnknown ¶
func (m *Phase) XXX_DiscardUnknown()
func (*Phase) XXX_Marshal ¶
func (*Phase) XXX_Unmarshal ¶
type ProgressResponse ¶
type ProgressResponse struct { // Message specifies the progress message Message string `protobuf:"bytes,1,opt,name=message,proto3" json:"message,omitempty"` // Status describes the status of this response Status ProgressResponse_Status `protobuf:"varint,2,opt,name=status,proto3,enum=installer.ProgressResponse_Status" json:"status,omitempty"` // Error specifies the error for this progress step Error *Error `protobuf:"bytes,3,opt,name=error,proto3" json:"error,omitempty"` XXX_NoUnkeyedLiteral struct{} `json:"-"` XXX_unrecognized []byte `json:"-"` XXX_sizecache int32 `json:"-"` }
ProgressResponse describes a single progress step
func (*ProgressResponse) Descriptor ¶
func (*ProgressResponse) Descriptor() ([]byte, []int)
func (*ProgressResponse) GetError ¶
func (m *ProgressResponse) GetError() *Error
func (*ProgressResponse) GetMessage ¶
func (m *ProgressResponse) GetMessage() string
func (*ProgressResponse) GetStatus ¶
func (m *ProgressResponse) GetStatus() ProgressResponse_Status
func (*ProgressResponse) IsAborted ¶
func (r *ProgressResponse) IsAborted() bool
IsAborted returns true if this progress response indicates an aborted operation
func (*ProgressResponse) IsCompleted ¶
func (r *ProgressResponse) IsCompleted() bool
IsCompleted returns true if this progress response indicates a completed operation
func (*ProgressResponse) ProtoMessage ¶
func (*ProgressResponse) ProtoMessage()
func (*ProgressResponse) Reset ¶
func (m *ProgressResponse) Reset()
func (*ProgressResponse) String ¶
func (m *ProgressResponse) String() string
func (*ProgressResponse) XXX_DiscardUnknown ¶
func (m *ProgressResponse) XXX_DiscardUnknown()
func (*ProgressResponse) XXX_Marshal ¶
func (m *ProgressResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
func (*ProgressResponse) XXX_Merge ¶
func (m *ProgressResponse) XXX_Merge(src proto.Message)
func (*ProgressResponse) XXX_Size ¶
func (m *ProgressResponse) XXX_Size() int
func (*ProgressResponse) XXX_Unmarshal ¶
func (m *ProgressResponse) XXX_Unmarshal(b []byte) error
type ProgressResponse_Status ¶
type ProgressResponse_Status int32
Status defines the status of this progress message. If the status is one of (StatusCompleted, StatusCompletedPending, StatusAborted), this response is the last response sent
const ( // StatusUnknown indicates the unknown progress StatusUnknown ProgressResponse_Status = 0 // StatusCompleted status indicates that the operation has successfully completed. // This status is terminal - no more progress messages will follow StatusCompleted ProgressResponse_Status = 1 // StatusCompletedPending status indicates that the operation has successfully completed // but the installer process will continue running to enable post-install tasks. // This status is terminal - no more progress messages will follow StatusCompletedPending ProgressResponse_Status = 2 // StatusAborted status indicates that the operation has been aborted. // This status is terminal - no more progress messages will follow StatusAborted ProgressResponse_Status = 3 )
func (ProgressResponse_Status) EnumDescriptor ¶
func (ProgressResponse_Status) EnumDescriptor() ([]byte, []int)
func (ProgressResponse_Status) String ¶
func (r ProgressResponse_Status) String() string
String formats this status as text
type SetStateRequest ¶
type SetStateRequest struct { // Phase describes the phase to set the state for Phase *Phase `protobuf:"bytes,1,opt,name=phase,proto3" json:"phase,omitempty"` // State is the new phase state State string `protobuf:"bytes,2,opt,name=state,proto3" json:"state,omitempty"` XXX_NoUnkeyedLiteral struct{} `json:"-"` XXX_unrecognized []byte `json:"-"` XXX_sizecache int32 `json:"-"` }
SetStateRequest describes a request to explicitly set phase state
func (*SetStateRequest) Descriptor ¶
func (*SetStateRequest) Descriptor() ([]byte, []int)
func (*SetStateRequest) GetPhase ¶
func (m *SetStateRequest) GetPhase() *Phase
func (*SetStateRequest) GetState ¶
func (m *SetStateRequest) GetState() string
func (*SetStateRequest) OperationID ¶
func (r *SetStateRequest) OperationID() string
OperationID returns operation ID from request.
func (*SetStateRequest) OperationKey ¶
func (r *SetStateRequest) OperationKey() ops.SiteOperationKey
OperationKey returns operation key from request.
func (*SetStateRequest) ProtoMessage ¶
func (*SetStateRequest) ProtoMessage()
func (*SetStateRequest) Reset ¶
func (m *SetStateRequest) Reset()
func (*SetStateRequest) String ¶
func (m *SetStateRequest) String() string
func (*SetStateRequest) XXX_DiscardUnknown ¶
func (m *SetStateRequest) XXX_DiscardUnknown()
func (*SetStateRequest) XXX_Marshal ¶
func (m *SetStateRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
func (*SetStateRequest) XXX_Merge ¶
func (m *SetStateRequest) XXX_Merge(src proto.Message)
func (*SetStateRequest) XXX_Size ¶
func (m *SetStateRequest) XXX_Size() int
func (*SetStateRequest) XXX_Unmarshal ¶
func (m *SetStateRequest) XXX_Unmarshal(b []byte) error
type ShutdownRequest ¶
type ShutdownRequest struct { // Completed indicates that the operation has been successfully completed Completed bool `protobuf:"varint,1,opt,name=completed,proto3" json:"completed,omitempty"` // ExitCode optionally specifies the exit code for the service. // 0 value is considered success ExitCode int32 `protobuf:"varint,2,opt,name=exitCode,proto3" json:"exitCode,omitempty"` XXX_NoUnkeyedLiteral struct{} `json:"-"` XXX_unrecognized []byte `json:"-"` XXX_sizecache int32 `json:"-"` }
ShutdownRequest describes a request to shut down the server
func (*ShutdownRequest) Descriptor ¶
func (*ShutdownRequest) Descriptor() ([]byte, []int)
func (*ShutdownRequest) GetCompleted ¶
func (m *ShutdownRequest) GetCompleted() bool
func (*ShutdownRequest) GetExitCode ¶
func (m *ShutdownRequest) GetExitCode() int32
func (*ShutdownRequest) ProtoMessage ¶
func (*ShutdownRequest) ProtoMessage()
func (*ShutdownRequest) Reset ¶
func (m *ShutdownRequest) Reset()
func (*ShutdownRequest) String ¶
func (m *ShutdownRequest) String() string
func (*ShutdownRequest) XXX_DiscardUnknown ¶
func (m *ShutdownRequest) XXX_DiscardUnknown()
func (*ShutdownRequest) XXX_Marshal ¶
func (m *ShutdownRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
func (*ShutdownRequest) XXX_Merge ¶
func (m *ShutdownRequest) XXX_Merge(src proto.Message)
func (*ShutdownRequest) XXX_Size ¶
func (m *ShutdownRequest) XXX_Size() int
func (*ShutdownRequest) XXX_Unmarshal ¶
func (m *ShutdownRequest) XXX_Unmarshal(b []byte) error
type UnimplementedAgentServer ¶
type UnimplementedAgentServer struct { }
UnimplementedAgentServer can be embedded to have forward compatible implementations.
func (*UnimplementedAgentServer) Abort ¶
func (*UnimplementedAgentServer) Abort(ctx context.Context, req *AbortRequest) (*types.Empty, error)
func (*UnimplementedAgentServer) Complete ¶
func (*UnimplementedAgentServer) Complete(ctx context.Context, req *CompleteRequest) (*types.Empty, error)
func (*UnimplementedAgentServer) Execute ¶
func (*UnimplementedAgentServer) Execute(req *ExecuteRequest, srv Agent_ExecuteServer) error
func (*UnimplementedAgentServer) GenerateDebugReport ¶
func (*UnimplementedAgentServer) GenerateDebugReport(ctx context.Context, req *DebugReportRequest) (*types.Empty, error)
func (*UnimplementedAgentServer) SetState ¶
func (*UnimplementedAgentServer) SetState(ctx context.Context, req *SetStateRequest) (*types.Empty, error)
func (*UnimplementedAgentServer) Shutdown ¶
func (*UnimplementedAgentServer) Shutdown(ctx context.Context, req *ShutdownRequest) (*types.Empty, error)