tunnel

package
v0.5.6-alpha.4 Latest Latest
Warning

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

Go to latest
Published: Apr 25, 2024 License: MPL-2.0 Imports: 8 Imported by: 2

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	LogLevel_name = map[int32]string{
		0: "DEBUG",
		1: "INFO",
		2: "DONE",
		3: "WARNING",
		4: "ERROR",
	}
	LogLevel_value = map[string]int32{
		"DEBUG":   0,
		"INFO":    1,
		"DONE":    2,
		"WARNING": 3,
		"ERROR":   4,
	}
)

Enum value maps for LogLevel.

View Source
var File_tunnel_proto protoreflect.FileDescriptor
View Source
var Tunnel_ServiceDesc = grpc.ServiceDesc{
	ServiceName: "tunnel.Tunnel",
	HandlerType: (*TunnelServer)(nil),
	Methods: []grpc.MethodDesc{
		{
			MethodName: "Ping",
			Handler:    _Tunnel_Ping_Handler,
		},
		{
			MethodName: "Log",
			Handler:    _Tunnel_Log_Handler,
		},
		{
			MethodName: "SendResult",
			Handler:    _Tunnel_SendResult_Handler,
		},
		{
			MethodName: "DockerCredentials",
			Handler:    _Tunnel_DockerCredentials_Handler,
		},
		{
			MethodName: "GitCredentials",
			Handler:    _Tunnel_GitCredentials_Handler,
		},
		{
			MethodName: "GitUser",
			Handler:    _Tunnel_GitUser_Handler,
		},
		{
			MethodName: "ForwardPort",
			Handler:    _Tunnel_ForwardPort_Handler,
		},
		{
			MethodName: "StopForwardPort",
			Handler:    _Tunnel_StopForwardPort_Handler,
		},
	},
	Streams: []grpc.StreamDesc{
		{
			StreamName:    "StreamGitClone",
			Handler:       _Tunnel_StreamGitClone_Handler,
			ServerStreams: true,
		},
		{
			StreamName:    "StreamWorkspace",
			Handler:       _Tunnel_StreamWorkspace_Handler,
			ServerStreams: true,
		},
		{
			StreamName:    "StreamMount",
			Handler:       _Tunnel_StreamMount_Handler,
			ServerStreams: true,
		},
	},
	Metadata: "tunnel.proto",
}

Tunnel_ServiceDesc is the grpc.ServiceDesc for Tunnel service. It's only intended for direct use with grpc.RegisterService, and not to be introspected or modified (even as a copy)

Functions

func RegisterTunnelServer

func RegisterTunnelServer(s grpc.ServiceRegistrar, srv TunnelServer)

Types

type Chunk

type Chunk struct {
	Content []byte `protobuf:"bytes,1,opt,name=Content,proto3" json:"Content,omitempty"`
	// contains filtered or unexported fields
}

func (*Chunk) Descriptor deprecated

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

Deprecated: Use Chunk.ProtoReflect.Descriptor instead.

func (*Chunk) GetContent

func (x *Chunk) GetContent() []byte

func (*Chunk) ProtoMessage

func (*Chunk) ProtoMessage()

func (*Chunk) ProtoReflect

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

func (*Chunk) Reset

func (x *Chunk) Reset()

func (*Chunk) String

func (x *Chunk) String() string

type Empty

type Empty struct {
	// contains filtered or unexported fields
}

func (*Empty) Descriptor deprecated

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

Deprecated: Use Empty.ProtoReflect.Descriptor instead.

func (*Empty) ProtoMessage

func (*Empty) ProtoMessage()

func (*Empty) ProtoReflect

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

func (*Empty) Reset

func (x *Empty) Reset()

func (*Empty) String

func (x *Empty) String() string

type ForwardPortRequest added in v0.1.0

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

func (*ForwardPortRequest) Descriptor deprecated added in v0.1.0

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

Deprecated: Use ForwardPortRequest.ProtoReflect.Descriptor instead.

func (*ForwardPortRequest) GetPort added in v0.1.0

func (x *ForwardPortRequest) GetPort() string

func (*ForwardPortRequest) ProtoMessage added in v0.1.0

func (*ForwardPortRequest) ProtoMessage()

func (*ForwardPortRequest) ProtoReflect added in v0.1.0

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

func (*ForwardPortRequest) Reset added in v0.1.0

func (x *ForwardPortRequest) Reset()

func (*ForwardPortRequest) String added in v0.1.0

func (x *ForwardPortRequest) String() string

type ForwardPortResponse added in v0.1.0

type ForwardPortResponse struct {
	// contains filtered or unexported fields
}

func (*ForwardPortResponse) Descriptor deprecated added in v0.1.0

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

Deprecated: Use ForwardPortResponse.ProtoReflect.Descriptor instead.

func (*ForwardPortResponse) ProtoMessage added in v0.1.0

func (*ForwardPortResponse) ProtoMessage()

func (*ForwardPortResponse) ProtoReflect added in v0.1.0

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

func (*ForwardPortResponse) Reset added in v0.1.0

func (x *ForwardPortResponse) Reset()

func (*ForwardPortResponse) String added in v0.1.0

func (x *ForwardPortResponse) String() string

type LogLevel

type LogLevel int32
const (
	LogLevel_DEBUG   LogLevel = 0
	LogLevel_INFO    LogLevel = 1
	LogLevel_DONE    LogLevel = 2
	LogLevel_WARNING LogLevel = 3
	LogLevel_ERROR   LogLevel = 4
)

func (LogLevel) Descriptor

func (LogLevel) Descriptor() protoreflect.EnumDescriptor

func (LogLevel) Enum

func (x LogLevel) Enum() *LogLevel

func (LogLevel) EnumDescriptor deprecated

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

Deprecated: Use LogLevel.Descriptor instead.

func (LogLevel) Number

func (x LogLevel) Number() protoreflect.EnumNumber

func (LogLevel) String

func (x LogLevel) String() string

func (LogLevel) Type

type LogMessage

type LogMessage struct {
	LogLevel LogLevel `protobuf:"varint,1,opt,name=logLevel,proto3,enum=tunnel.LogLevel" json:"logLevel,omitempty"`
	Message  string   `protobuf:"bytes,2,opt,name=message,proto3" json:"message,omitempty"`
	// contains filtered or unexported fields
}

func (*LogMessage) Descriptor deprecated

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

Deprecated: Use LogMessage.ProtoReflect.Descriptor instead.

func (*LogMessage) GetLogLevel

func (x *LogMessage) GetLogLevel() LogLevel

func (*LogMessage) GetMessage

func (x *LogMessage) GetMessage() string

func (*LogMessage) ProtoMessage

func (*LogMessage) ProtoMessage()

func (*LogMessage) ProtoReflect

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

func (*LogMessage) Reset

func (x *LogMessage) Reset()

func (*LogMessage) String

func (x *LogMessage) String() string

type Message

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

func (*Message) Descriptor deprecated

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

Deprecated: Use Message.ProtoReflect.Descriptor instead.

func (*Message) GetMessage

func (x *Message) GetMessage() string

func (*Message) ProtoMessage

func (*Message) ProtoMessage()

func (*Message) ProtoReflect

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

func (*Message) Reset

func (x *Message) Reset()

func (*Message) String

func (x *Message) String() string

type StopForwardPortRequest added in v0.1.0

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

func (*StopForwardPortRequest) Descriptor deprecated added in v0.1.0

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

Deprecated: Use StopForwardPortRequest.ProtoReflect.Descriptor instead.

func (*StopForwardPortRequest) GetPort added in v0.1.0

func (x *StopForwardPortRequest) GetPort() string

func (*StopForwardPortRequest) ProtoMessage added in v0.1.0

func (*StopForwardPortRequest) ProtoMessage()

func (*StopForwardPortRequest) ProtoReflect added in v0.1.0

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

func (*StopForwardPortRequest) Reset added in v0.1.0

func (x *StopForwardPortRequest) Reset()

func (*StopForwardPortRequest) String added in v0.1.0

func (x *StopForwardPortRequest) String() string

type StopForwardPortResponse added in v0.1.0

type StopForwardPortResponse struct {
	// contains filtered or unexported fields
}

func (*StopForwardPortResponse) Descriptor deprecated added in v0.1.0

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

Deprecated: Use StopForwardPortResponse.ProtoReflect.Descriptor instead.

func (*StopForwardPortResponse) ProtoMessage added in v0.1.0

func (*StopForwardPortResponse) ProtoMessage()

func (*StopForwardPortResponse) ProtoReflect added in v0.1.0

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

func (*StopForwardPortResponse) Reset added in v0.1.0

func (x *StopForwardPortResponse) Reset()

func (*StopForwardPortResponse) String added in v0.1.0

func (x *StopForwardPortResponse) String() string

type StreamMountRequest added in v0.4.0

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

func (*StreamMountRequest) Descriptor deprecated added in v0.4.0

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

Deprecated: Use StreamMountRequest.ProtoReflect.Descriptor instead.

func (*StreamMountRequest) GetMount added in v0.4.0

func (x *StreamMountRequest) GetMount() string

func (*StreamMountRequest) ProtoMessage added in v0.4.0

func (*StreamMountRequest) ProtoMessage()

func (*StreamMountRequest) ProtoReflect added in v0.4.0

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

func (*StreamMountRequest) Reset added in v0.4.0

func (x *StreamMountRequest) Reset()

func (*StreamMountRequest) String added in v0.4.0

func (x *StreamMountRequest) String() string

type TunnelClient

type TunnelClient interface {
	Ping(ctx context.Context, in *Empty, opts ...grpc.CallOption) (*Empty, error)
	Log(ctx context.Context, in *LogMessage, opts ...grpc.CallOption) (*Empty, error)
	SendResult(ctx context.Context, in *Message, opts ...grpc.CallOption) (*Empty, error)
	DockerCredentials(ctx context.Context, in *Message, opts ...grpc.CallOption) (*Message, error)
	GitCredentials(ctx context.Context, in *Message, opts ...grpc.CallOption) (*Message, error)
	GitUser(ctx context.Context, in *Empty, opts ...grpc.CallOption) (*Message, error)
	ForwardPort(ctx context.Context, in *ForwardPortRequest, opts ...grpc.CallOption) (*ForwardPortResponse, error)
	StopForwardPort(ctx context.Context, in *StopForwardPortRequest, opts ...grpc.CallOption) (*StopForwardPortResponse, error)
	StreamGitClone(ctx context.Context, in *Empty, opts ...grpc.CallOption) (Tunnel_StreamGitCloneClient, error)
	StreamWorkspace(ctx context.Context, in *Empty, opts ...grpc.CallOption) (Tunnel_StreamWorkspaceClient, error)
	StreamMount(ctx context.Context, in *StreamMountRequest, opts ...grpc.CallOption) (Tunnel_StreamMountClient, error)
}

TunnelClient is the client API for Tunnel service.

For semantics around ctx use and closing/ending streaming RPCs, please refer to https://pkg.go.dev/google.golang.org/grpc/?tab=doc#ClientConn.NewStream.

func NewTunnelClient

func NewTunnelClient(cc grpc.ClientConnInterface) TunnelClient

type TunnelServer

type TunnelServer interface {
	Ping(context.Context, *Empty) (*Empty, error)
	Log(context.Context, *LogMessage) (*Empty, error)
	SendResult(context.Context, *Message) (*Empty, error)
	DockerCredentials(context.Context, *Message) (*Message, error)
	GitCredentials(context.Context, *Message) (*Message, error)
	GitUser(context.Context, *Empty) (*Message, error)
	ForwardPort(context.Context, *ForwardPortRequest) (*ForwardPortResponse, error)
	StopForwardPort(context.Context, *StopForwardPortRequest) (*StopForwardPortResponse, error)
	StreamGitClone(*Empty, Tunnel_StreamGitCloneServer) error
	StreamWorkspace(*Empty, Tunnel_StreamWorkspaceServer) error
	StreamMount(*StreamMountRequest, Tunnel_StreamMountServer) error
	// contains filtered or unexported methods
}

TunnelServer is the server API for Tunnel service. All implementations must embed UnimplementedTunnelServer for forward compatibility

type Tunnel_StreamGitCloneClient added in v0.4.0

type Tunnel_StreamGitCloneClient interface {
	Recv() (*Chunk, error)
	grpc.ClientStream
}

type Tunnel_StreamGitCloneServer added in v0.4.0

type Tunnel_StreamGitCloneServer interface {
	Send(*Chunk) error
	grpc.ServerStream
}

type Tunnel_StreamMountClient added in v0.4.0

type Tunnel_StreamMountClient interface {
	Recv() (*Chunk, error)
	grpc.ClientStream
}

type Tunnel_StreamMountServer added in v0.4.0

type Tunnel_StreamMountServer interface {
	Send(*Chunk) error
	grpc.ServerStream
}

type Tunnel_StreamWorkspaceClient added in v0.4.0

type Tunnel_StreamWorkspaceClient interface {
	Recv() (*Chunk, error)
	grpc.ClientStream
}

type Tunnel_StreamWorkspaceServer added in v0.4.0

type Tunnel_StreamWorkspaceServer interface {
	Send(*Chunk) error
	grpc.ServerStream
}

type UnimplementedTunnelServer

type UnimplementedTunnelServer struct {
}

UnimplementedTunnelServer must be embedded to have forward compatible implementations.

func (UnimplementedTunnelServer) DockerCredentials

func (UnimplementedTunnelServer) DockerCredentials(context.Context, *Message) (*Message, error)

func (UnimplementedTunnelServer) ForwardPort added in v0.1.0

func (UnimplementedTunnelServer) GitCredentials

func (UnimplementedTunnelServer) GitUser

func (UnimplementedTunnelServer) Log

func (UnimplementedTunnelServer) Ping

func (UnimplementedTunnelServer) SendResult

func (UnimplementedTunnelServer) StopForwardPort added in v0.1.0

func (UnimplementedTunnelServer) StreamGitClone added in v0.4.0

func (UnimplementedTunnelServer) StreamMount added in v0.4.0

func (UnimplementedTunnelServer) StreamWorkspace added in v0.4.0

type UnsafeTunnelServer

type UnsafeTunnelServer interface {
	// contains filtered or unexported methods
}

UnsafeTunnelServer may be embedded to opt out of forward compatibility for this service. Use of this interface is not recommended, as added methods to TunnelServer will result in compilation errors.

Jump to

Keyboard shortcuts

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