proto

package
v0.29.0 Latest Latest
Warning

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

Go to latest
Published: May 10, 2019 License: Apache-2.0 Imports: 15 Imported by: 0

Documentation

Overview

Package proto is a reverse proxy.

It translates gRPC into RESTful JSON APIs.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func RegisterSkaffoldServiceHandler added in v0.26.0

func RegisterSkaffoldServiceHandler(ctx context.Context, mux *runtime.ServeMux, conn *grpc.ClientConn) error

RegisterSkaffoldServiceHandler registers the http handlers for service SkaffoldService to "mux". The handlers forward requests to the grpc endpoint over "conn".

func RegisterSkaffoldServiceHandlerClient added in v0.26.0

func RegisterSkaffoldServiceHandlerClient(ctx context.Context, mux *runtime.ServeMux, client SkaffoldServiceClient) error

RegisterSkaffoldServiceHandlerClient registers the http handlers for service SkaffoldService to "mux". The handlers forward requests to the grpc endpoint over the given implementation of "SkaffoldServiceClient". Note: the gRPC framework executes interceptors within the gRPC handler. If the passed in "SkaffoldServiceClient" doesn't go through the normal gRPC flow (creating a gRPC client etc.) then it will be up to the passed in "SkaffoldServiceClient" to call the correct interceptors.

func RegisterSkaffoldServiceHandlerFromEndpoint added in v0.26.0

func RegisterSkaffoldServiceHandlerFromEndpoint(ctx context.Context, mux *runtime.ServeMux, endpoint string, opts []grpc.DialOption) (err error)

RegisterSkaffoldServiceHandlerFromEndpoint is same as RegisterSkaffoldServiceHandler but automatically dials to "endpoint" and closes the connection when "ctx" gets done.

func RegisterSkaffoldServiceServer

func RegisterSkaffoldServiceServer(s *grpc.Server, srv SkaffoldServiceServer)

Types

type BuildEvent

type BuildEvent struct {
	Artifact             string   `protobuf:"bytes,1,opt,name=artifact,proto3" json:"artifact,omitempty"`
	Status               string   `protobuf:"bytes,2,opt,name=status,proto3" json:"status,omitempty"`
	Err                  string   `protobuf:"bytes,3,opt,name=err,proto3" json:"err,omitempty"`
	XXX_NoUnkeyedLiteral struct{} `json:"-"`
	XXX_unrecognized     []byte   `json:"-"`
	XXX_sizecache        int32    `json:"-"`
}

func (*BuildEvent) Descriptor

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

func (*BuildEvent) GetArtifact

func (m *BuildEvent) GetArtifact() string

func (*BuildEvent) GetErr

func (m *BuildEvent) GetErr() string

func (*BuildEvent) GetStatus

func (m *BuildEvent) GetStatus() string

func (*BuildEvent) ProtoMessage

func (*BuildEvent) ProtoMessage()

func (*BuildEvent) Reset

func (m *BuildEvent) Reset()

func (*BuildEvent) String

func (m *BuildEvent) String() string

func (*BuildEvent) XXX_DiscardUnknown

func (m *BuildEvent) XXX_DiscardUnknown()

func (*BuildEvent) XXX_Marshal

func (m *BuildEvent) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*BuildEvent) XXX_Merge

func (m *BuildEvent) XXX_Merge(src proto.Message)

func (*BuildEvent) XXX_Size

func (m *BuildEvent) XXX_Size() int

func (*BuildEvent) XXX_Unmarshal

func (m *BuildEvent) XXX_Unmarshal(b []byte) error

type BuildState

type BuildState struct {
	Artifacts            map[string]string `` /* 159-byte string literal not displayed */
	XXX_NoUnkeyedLiteral struct{}          `json:"-"`
	XXX_unrecognized     []byte            `json:"-"`
	XXX_sizecache        int32             `json:"-"`
}

BuildState contains a map of all skaffold artifacts to their current build states

func (*BuildState) Descriptor

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

func (*BuildState) GetArtifacts

func (m *BuildState) GetArtifacts() map[string]string

func (*BuildState) ProtoMessage

func (*BuildState) ProtoMessage()

func (*BuildState) Reset

func (m *BuildState) Reset()

func (*BuildState) String

func (m *BuildState) String() string

func (*BuildState) XXX_DiscardUnknown

func (m *BuildState) XXX_DiscardUnknown()

func (*BuildState) XXX_Marshal

func (m *BuildState) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*BuildState) XXX_Merge

func (m *BuildState) XXX_Merge(src proto.Message)

func (*BuildState) XXX_Size

func (m *BuildState) XXX_Size() int

func (*BuildState) XXX_Unmarshal

func (m *BuildState) XXX_Unmarshal(b []byte) error

type DeployEvent

type DeployEvent struct {
	Status               string   `protobuf:"bytes,1,opt,name=status,proto3" json:"status,omitempty"`
	Err                  string   `protobuf:"bytes,2,opt,name=err,proto3" json:"err,omitempty"`
	XXX_NoUnkeyedLiteral struct{} `json:"-"`
	XXX_unrecognized     []byte   `json:"-"`
	XXX_sizecache        int32    `json:"-"`
}

func (*DeployEvent) Descriptor

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

func (*DeployEvent) GetErr

func (m *DeployEvent) GetErr() string

func (*DeployEvent) GetStatus

func (m *DeployEvent) GetStatus() string

func (*DeployEvent) ProtoMessage

func (*DeployEvent) ProtoMessage()

func (*DeployEvent) Reset

func (m *DeployEvent) Reset()

func (*DeployEvent) String

func (m *DeployEvent) String() string

func (*DeployEvent) XXX_DiscardUnknown

func (m *DeployEvent) XXX_DiscardUnknown()

func (*DeployEvent) XXX_Marshal

func (m *DeployEvent) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*DeployEvent) XXX_Merge

func (m *DeployEvent) XXX_Merge(src proto.Message)

func (*DeployEvent) XXX_Size

func (m *DeployEvent) XXX_Size() int

func (*DeployEvent) XXX_Unmarshal

func (m *DeployEvent) XXX_Unmarshal(b []byte) error

type DeployState

type DeployState struct {
	Status               string   `protobuf:"bytes,1,opt,name=status,proto3" json:"status,omitempty"`
	XXX_NoUnkeyedLiteral struct{} `json:"-"`
	XXX_unrecognized     []byte   `json:"-"`
	XXX_sizecache        int32    `json:"-"`
}

DeployState contains the status of the current deploy

func (*DeployState) Descriptor

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

func (*DeployState) GetStatus

func (m *DeployState) GetStatus() string

func (*DeployState) ProtoMessage

func (*DeployState) ProtoMessage()

func (*DeployState) Reset

func (m *DeployState) Reset()

func (*DeployState) String

func (m *DeployState) String() string

func (*DeployState) XXX_DiscardUnknown

func (m *DeployState) XXX_DiscardUnknown()

func (*DeployState) XXX_Marshal

func (m *DeployState) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*DeployState) XXX_Merge

func (m *DeployState) XXX_Merge(src proto.Message)

func (*DeployState) XXX_Size

func (m *DeployState) XXX_Size() int

func (*DeployState) XXX_Unmarshal

func (m *DeployState) XXX_Unmarshal(b []byte) error

type Event

type Event struct {
	// Types that are valid to be assigned to EventType:
	//	*Event_MetaEvent
	//	*Event_BuildEvent
	//	*Event_DeployEvent
	//	*Event_PortEvent
	EventType            isEvent_EventType `protobuf_oneof:"event_type"`
	XXX_NoUnkeyedLiteral struct{}          `json:"-"`
	XXX_unrecognized     []byte            `json:"-"`
	XXX_sizecache        int32             `json:"-"`
}

func (*Event) Descriptor

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

func (*Event) GetBuildEvent

func (m *Event) GetBuildEvent() *BuildEvent

func (*Event) GetDeployEvent

func (m *Event) GetDeployEvent() *DeployEvent

func (*Event) GetEventType

func (m *Event) GetEventType() isEvent_EventType

func (*Event) GetMetaEvent

func (m *Event) GetMetaEvent() *MetaEvent

func (*Event) GetPortEvent

func (m *Event) GetPortEvent() *PortEvent

func (*Event) ProtoMessage

func (*Event) ProtoMessage()

func (*Event) Reset

func (m *Event) Reset()

func (*Event) String

func (m *Event) String() string

func (*Event) XXX_DiscardUnknown

func (m *Event) XXX_DiscardUnknown()

func (*Event) XXX_Marshal

func (m *Event) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*Event) XXX_Merge

func (m *Event) XXX_Merge(src proto.Message)

func (*Event) XXX_OneofWrappers

func (*Event) XXX_OneofWrappers() []interface{}

XXX_OneofWrappers is for the internal use of the proto package.

func (*Event) XXX_Size

func (m *Event) XXX_Size() int

func (*Event) XXX_Unmarshal

func (m *Event) XXX_Unmarshal(b []byte) error

type Event_BuildEvent

type Event_BuildEvent struct {
	BuildEvent *BuildEvent `protobuf:"bytes,2,opt,name=buildEvent,proto3,oneof"`
}

type Event_DeployEvent

type Event_DeployEvent struct {
	DeployEvent *DeployEvent `protobuf:"bytes,3,opt,name=deployEvent,proto3,oneof"`
}

type Event_MetaEvent

type Event_MetaEvent struct {
	MetaEvent *MetaEvent `protobuf:"bytes,1,opt,name=metaEvent,proto3,oneof"`
}

type Event_PortEvent

type Event_PortEvent struct {
	PortEvent *PortEvent `protobuf:"bytes,4,opt,name=portEvent,proto3,oneof"`
}

type LogEntry

type LogEntry struct {
	Timestamp            *timestamp.Timestamp `protobuf:"bytes,1,opt,name=timestamp,proto3" json:"timestamp,omitempty"`
	Event                *Event               `protobuf:"bytes,2,opt,name=event,proto3" json:"event,omitempty"`
	Entry                string               `protobuf:"bytes,3,opt,name=entry,proto3" json:"entry,omitempty"`
	XXX_NoUnkeyedLiteral struct{}             `json:"-"`
	XXX_unrecognized     []byte               `json:"-"`
	XXX_sizecache        int32                `json:"-"`
}

func (*LogEntry) Descriptor

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

func (*LogEntry) GetEntry

func (m *LogEntry) GetEntry() string

func (*LogEntry) GetEvent

func (m *LogEntry) GetEvent() *Event

func (*LogEntry) GetTimestamp

func (m *LogEntry) GetTimestamp() *timestamp.Timestamp

func (*LogEntry) ProtoMessage

func (*LogEntry) ProtoMessage()

func (*LogEntry) Reset

func (m *LogEntry) Reset()

func (*LogEntry) String

func (m *LogEntry) String() string

func (*LogEntry) XXX_DiscardUnknown

func (m *LogEntry) XXX_DiscardUnknown()

func (*LogEntry) XXX_Marshal

func (m *LogEntry) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*LogEntry) XXX_Merge

func (m *LogEntry) XXX_Merge(src proto.Message)

func (*LogEntry) XXX_Size

func (m *LogEntry) XXX_Size() int

func (*LogEntry) XXX_Unmarshal

func (m *LogEntry) XXX_Unmarshal(b []byte) error

type MetaEvent

type MetaEvent struct {
	Entry                string   `protobuf:"bytes,1,opt,name=entry,proto3" json:"entry,omitempty"`
	XXX_NoUnkeyedLiteral struct{} `json:"-"`
	XXX_unrecognized     []byte   `json:"-"`
	XXX_sizecache        int32    `json:"-"`
}

func (*MetaEvent) Descriptor

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

func (*MetaEvent) GetEntry

func (m *MetaEvent) GetEntry() string

func (*MetaEvent) ProtoMessage

func (*MetaEvent) ProtoMessage()

func (*MetaEvent) Reset

func (m *MetaEvent) Reset()

func (*MetaEvent) String

func (m *MetaEvent) String() string

func (*MetaEvent) XXX_DiscardUnknown

func (m *MetaEvent) XXX_DiscardUnknown()

func (*MetaEvent) XXX_Marshal

func (m *MetaEvent) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*MetaEvent) XXX_Merge

func (m *MetaEvent) XXX_Merge(src proto.Message)

func (*MetaEvent) XXX_Size

func (m *MetaEvent) XXX_Size() int

func (*MetaEvent) XXX_Unmarshal

func (m *MetaEvent) XXX_Unmarshal(b []byte) error

type PortEvent

type PortEvent struct {
	LocalPort            int32    `protobuf:"varint,1,opt,name=localPort,proto3" json:"localPort,omitempty"`
	RemotePort           int32    `protobuf:"varint,2,opt,name=remotePort,proto3" json:"remotePort,omitempty"`
	PodName              string   `protobuf:"bytes,3,opt,name=podName,proto3" json:"podName,omitempty"`
	ContainerName        string   `protobuf:"bytes,4,opt,name=containerName,proto3" json:"containerName,omitempty"`
	Namespace            string   `protobuf:"bytes,5,opt,name=namespace,proto3" json:"namespace,omitempty"`
	PortName             string   `protobuf:"bytes,6,opt,name=portName,proto3" json:"portName,omitempty"`
	XXX_NoUnkeyedLiteral struct{} `json:"-"`
	XXX_unrecognized     []byte   `json:"-"`
	XXX_sizecache        int32    `json:"-"`
}

func (*PortEvent) Descriptor

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

func (*PortEvent) GetContainerName

func (m *PortEvent) GetContainerName() string

func (*PortEvent) GetLocalPort

func (m *PortEvent) GetLocalPort() int32

func (*PortEvent) GetNamespace

func (m *PortEvent) GetNamespace() string

func (*PortEvent) GetPodName

func (m *PortEvent) GetPodName() string

func (*PortEvent) GetPortName added in v0.26.0

func (m *PortEvent) GetPortName() string

func (*PortEvent) GetRemotePort

func (m *PortEvent) GetRemotePort() int32

func (*PortEvent) ProtoMessage

func (*PortEvent) ProtoMessage()

func (*PortEvent) Reset

func (m *PortEvent) Reset()

func (*PortEvent) String

func (m *PortEvent) String() string

func (*PortEvent) XXX_DiscardUnknown

func (m *PortEvent) XXX_DiscardUnknown()

func (*PortEvent) XXX_Marshal

func (m *PortEvent) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*PortEvent) XXX_Merge

func (m *PortEvent) XXX_Merge(src proto.Message)

func (*PortEvent) XXX_Size

func (m *PortEvent) XXX_Size() int

func (*PortEvent) XXX_Unmarshal

func (m *PortEvent) XXX_Unmarshal(b []byte) error

type Request

type Request struct {
	Name                 string   `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"`
	XXX_NoUnkeyedLiteral struct{} `json:"-"`
	XXX_unrecognized     []byte   `json:"-"`
	XXX_sizecache        int32    `json:"-"`
}

func (*Request) Descriptor

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

func (*Request) GetName

func (m *Request) GetName() string

func (*Request) ProtoMessage

func (*Request) ProtoMessage()

func (*Request) Reset

func (m *Request) Reset()

func (*Request) String

func (m *Request) String() string

func (*Request) XXX_DiscardUnknown

func (m *Request) XXX_DiscardUnknown()

func (*Request) XXX_Marshal

func (m *Request) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*Request) XXX_Merge

func (m *Request) XXX_Merge(src proto.Message)

func (*Request) XXX_Size

func (m *Request) XXX_Size() int

func (*Request) XXX_Unmarshal

func (m *Request) XXX_Unmarshal(b []byte) error

type Response

type Response struct {
	Msg                  string   `protobuf:"bytes,1,opt,name=msg,proto3" json:"msg,omitempty"`
	XXX_NoUnkeyedLiteral struct{} `json:"-"`
	XXX_unrecognized     []byte   `json:"-"`
	XXX_sizecache        int32    `json:"-"`
}

func (*Response) Descriptor

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

func (*Response) GetMsg

func (m *Response) GetMsg() string

func (*Response) ProtoMessage

func (*Response) ProtoMessage()

func (*Response) Reset

func (m *Response) Reset()

func (*Response) String

func (m *Response) String() string

func (*Response) XXX_DiscardUnknown

func (m *Response) XXX_DiscardUnknown()

func (*Response) XXX_Marshal

func (m *Response) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*Response) XXX_Merge

func (m *Response) XXX_Merge(src proto.Message)

func (*Response) XXX_Size

func (m *Response) XXX_Size() int

func (*Response) XXX_Unmarshal

func (m *Response) XXX_Unmarshal(b []byte) error

type SkaffoldServiceClient

type SkaffoldServiceClient interface {
	GetState(ctx context.Context, in *empty.Empty, opts ...grpc.CallOption) (*State, error)
	EventLog(ctx context.Context, opts ...grpc.CallOption) (SkaffoldService_EventLogClient, error)
	Handle(ctx context.Context, in *Event, opts ...grpc.CallOption) (*empty.Empty, error)
}

SkaffoldServiceClient is the client API for SkaffoldService service.

For semantics around ctx use and closing/ending streaming RPCs, please refer to https://godoc.org/google.golang.org/grpc#ClientConn.NewStream.

func NewSkaffoldServiceClient

func NewSkaffoldServiceClient(cc *grpc.ClientConn) SkaffoldServiceClient

type SkaffoldServiceServer

type SkaffoldServiceServer interface {
	GetState(context.Context, *empty.Empty) (*State, error)
	EventLog(SkaffoldService_EventLogServer) error
	Handle(context.Context, *Event) (*empty.Empty, error)
}

SkaffoldServiceServer is the server API for SkaffoldService service.

type SkaffoldService_EventLogClient

type SkaffoldService_EventLogClient interface {
	Send(*LogEntry) error
	Recv() (*LogEntry, error)
	grpc.ClientStream
}

type SkaffoldService_EventLogServer

type SkaffoldService_EventLogServer interface {
	Send(*LogEntry) error
	Recv() (*LogEntry, error)
	grpc.ServerStream
}

type State

type State struct {
	BuildState           *BuildState           `protobuf:"bytes,1,opt,name=buildState,proto3" json:"buildState,omitempty"`
	DeployState          *DeployState          `protobuf:"bytes,2,opt,name=deployState,proto3" json:"deployState,omitempty"`
	ForwardedPorts       map[string]*PortEvent `` /* 169-byte string literal not displayed */
	XXX_NoUnkeyedLiteral struct{}              `json:"-"`
	XXX_unrecognized     []byte                `json:"-"`
	XXX_sizecache        int32                 `json:"-"`
}

func (*State) Descriptor

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

func (*State) GetBuildState

func (m *State) GetBuildState() *BuildState

func (*State) GetDeployState

func (m *State) GetDeployState() *DeployState

func (*State) GetForwardedPorts

func (m *State) GetForwardedPorts() map[string]*PortEvent

func (*State) ProtoMessage

func (*State) ProtoMessage()

func (*State) Reset

func (m *State) Reset()

func (*State) String

func (m *State) String() string

func (*State) XXX_DiscardUnknown

func (m *State) XXX_DiscardUnknown()

func (*State) XXX_Marshal

func (m *State) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*State) XXX_Merge

func (m *State) XXX_Merge(src proto.Message)

func (*State) XXX_Size

func (m *State) XXX_Size() int

func (*State) XXX_Unmarshal

func (m *State) XXX_Unmarshal(b []byte) error

type StateResponse

type StateResponse struct {
	State                *State   `protobuf:"bytes,1,opt,name=state,proto3" json:"state,omitempty"`
	XXX_NoUnkeyedLiteral struct{} `json:"-"`
	XXX_unrecognized     []byte   `json:"-"`
	XXX_sizecache        int32    `json:"-"`
}

func (*StateResponse) Descriptor

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

func (*StateResponse) GetState

func (m *StateResponse) GetState() *State

func (*StateResponse) ProtoMessage

func (*StateResponse) ProtoMessage()

func (*StateResponse) Reset

func (m *StateResponse) Reset()

func (*StateResponse) String

func (m *StateResponse) String() string

func (*StateResponse) XXX_DiscardUnknown

func (m *StateResponse) XXX_DiscardUnknown()

func (*StateResponse) XXX_Marshal

func (m *StateResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*StateResponse) XXX_Merge

func (m *StateResponse) XXX_Merge(src proto.Message)

func (*StateResponse) XXX_Size

func (m *StateResponse) XXX_Size() int

func (*StateResponse) XXX_Unmarshal

func (m *StateResponse) XXX_Unmarshal(b []byte) error

type UnimplementedSkaffoldServiceServer added in v0.26.0

type UnimplementedSkaffoldServiceServer struct {
}

UnimplementedSkaffoldServiceServer can be embedded to have forward compatible implementations.

func (*UnimplementedSkaffoldServiceServer) EventLog added in v0.26.0

func (*UnimplementedSkaffoldServiceServer) GetState added in v0.26.0

func (*UnimplementedSkaffoldServiceServer) Handle added in v0.26.0

Jump to

Keyboard shortcuts

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