backconnectd

package
v0.0.0-...-cd40d76 Latest Latest
Warning

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

Go to latest
Published: May 23, 2023 License: MIT Imports: 9 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	EventType_name = map[int32]string{
		0: "ADD",
		1: "DELETE",
	}
	EventType_value = map[string]int32{
		"ADD":    0,
		"DELETE": 1,
	}
)

Enum value maps for EventType.

View Source
var Backconnectd_ServiceDesc = grpc.ServiceDesc{
	ServiceName: "grpc.Backconnectd",
	HandlerType: (*BackconnectdServer)(nil),
	Methods: []grpc.MethodDesc{
		{
			MethodName: "KillSession",
			Handler:    _Backconnectd_KillSession_Handler,
		},
	},
	Streams: []grpc.StreamDesc{
		{
			StreamName:    "ConnectSession",
			Handler:       _Backconnectd_ConnectSession_Handler,
			ServerStreams: true,
			ClientStreams: true,
		},
		{
			StreamName:    "Subscribe",
			Handler:       _Backconnectd_Subscribe_Handler,
			ServerStreams: true,
		},
	},
	Metadata: "service.proto",
}

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

View Source
var File_service_proto protoreflect.FileDescriptor

Functions

func RegisterBackconnectdServer

func RegisterBackconnectdServer(s grpc.ServiceRegistrar, srv BackconnectdServer)

Types

type BackconnectdClient

type BackconnectdClient interface {
	KillSession(ctx context.Context, in *SessionKillRequest, opts ...grpc.CallOption) (*Response, error)
	ConnectSession(ctx context.Context, opts ...grpc.CallOption) (Backconnectd_ConnectSessionClient, error)
	Subscribe(ctx context.Context, in *SubscribeRequest, opts ...grpc.CallOption) (Backconnectd_SubscribeClient, error)
}

BackconnectdClient is the client API for Backconnectd 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.

type BackconnectdServer

type BackconnectdServer interface {
	KillSession(context.Context, *SessionKillRequest) (*Response, error)
	ConnectSession(Backconnectd_ConnectSessionServer) error
	Subscribe(*SubscribeRequest, Backconnectd_SubscribeServer) error
	// contains filtered or unexported methods
}

BackconnectdServer is the server API for Backconnectd service. All implementations must embed UnimplementedBackconnectdServer for forward compatibility

type Backconnectd_ConnectSessionClient

type Backconnectd_ConnectSessionClient interface {
	Send(*RawData) error
	Recv() (*RawData, error)
	grpc.ClientStream
}

type Backconnectd_ConnectSessionServer

type Backconnectd_ConnectSessionServer interface {
	Send(*RawData) error
	Recv() (*RawData, error)
	grpc.ServerStream
}

type Backconnectd_SubscribeClient

type Backconnectd_SubscribeClient interface {
	Recv() (*SessionEvent, error)
	grpc.ClientStream
}

type Backconnectd_SubscribeServer

type Backconnectd_SubscribeServer interface {
	Send(*SessionEvent) error
	grpc.ServerStream
}

type EventType

type EventType int32
const (
	EventType_ADD    EventType = 0
	EventType_DELETE EventType = 1
)

func (EventType) Descriptor

func (EventType) Descriptor() protoreflect.EnumDescriptor

func (EventType) Enum

func (x EventType) Enum() *EventType

func (EventType) EnumDescriptor deprecated

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

Deprecated: Use EventType.Descriptor instead.

func (EventType) Number

func (x EventType) Number() protoreflect.EnumNumber

func (EventType) String

func (x EventType) String() string

func (EventType) Type

type RawData

type RawData struct {

	// Types that are assignable to Message:
	//	*RawData_Data
	//	*RawData_Id
	Message isRawData_Message `protobuf_oneof:"message"`
	// contains filtered or unexported fields
}

func (*RawData) Descriptor deprecated

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

Deprecated: Use RawData.ProtoReflect.Descriptor instead.

func (*RawData) GetData

func (x *RawData) GetData() []byte

func (*RawData) GetId

func (x *RawData) GetId() string

func (*RawData) GetMessage

func (m *RawData) GetMessage() isRawData_Message

func (*RawData) ProtoMessage

func (*RawData) ProtoMessage()

func (*RawData) ProtoReflect

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

func (*RawData) Reset

func (x *RawData) Reset()

func (*RawData) String

func (x *RawData) String() string

type RawData_Data

type RawData_Data struct {
	Data []byte `protobuf:"bytes,1,opt,name=data,proto3,oneof"`
}

type RawData_Id

type RawData_Id struct {
	Id string `protobuf:"bytes,2,opt,name=id,proto3,oneof"`
}

type Response

type Response struct {
	Ok bool `protobuf:"varint,1,opt,name=ok,proto3" json:"ok,omitempty"`
	// contains filtered or unexported fields
}

func (*Response) Descriptor deprecated

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

Deprecated: Use Response.ProtoReflect.Descriptor instead.

func (*Response) GetOk

func (x *Response) GetOk() bool

func (*Response) ProtoMessage

func (*Response) ProtoMessage()

func (*Response) ProtoReflect

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

func (*Response) Reset

func (x *Response) Reset()

func (*Response) String

func (x *Response) String() string

type SessionConnectRequest

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

func (*SessionConnectRequest) Descriptor deprecated

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

Deprecated: Use SessionConnectRequest.ProtoReflect.Descriptor instead.

func (*SessionConnectRequest) GetCtrlid

func (x *SessionConnectRequest) GetCtrlid() string

func (*SessionConnectRequest) GetId

func (x *SessionConnectRequest) GetId() string

func (*SessionConnectRequest) ProtoMessage

func (*SessionConnectRequest) ProtoMessage()

func (*SessionConnectRequest) ProtoReflect

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

func (*SessionConnectRequest) Reset

func (x *SessionConnectRequest) Reset()

func (*SessionConnectRequest) String

func (x *SessionConnectRequest) String() string

type SessionEvent

type SessionEvent struct {
	Type    EventType    `protobuf:"varint,1,opt,name=type,proto3,enum=grpc.EventType" json:"type,omitempty"`
	Session *SessionInfo `protobuf:"bytes,2,opt,name=session,proto3" json:"session,omitempty"`
	// contains filtered or unexported fields
}

func (*SessionEvent) Descriptor deprecated

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

Deprecated: Use SessionEvent.ProtoReflect.Descriptor instead.

func (*SessionEvent) GetSession

func (x *SessionEvent) GetSession() *SessionInfo

func (*SessionEvent) GetType

func (x *SessionEvent) GetType() EventType

func (*SessionEvent) ProtoMessage

func (*SessionEvent) ProtoMessage()

func (*SessionEvent) ProtoReflect

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

func (*SessionEvent) Reset

func (x *SessionEvent) Reset()

func (*SessionEvent) String

func (x *SessionEvent) String() string

type SessionInfo

type SessionInfo struct {
	Id            string               `protobuf:"bytes,1,opt,name=id,proto3" json:"id,omitempty"`
	InitTime      *timestamp.Timestamp `protobuf:"bytes,2,opt,name=init_time,json=initTime,proto3" json:"init_time,omitempty"`
	RemoteAddress string               `protobuf:"bytes,3,opt,name=remote_address,json=remoteAddress,proto3" json:"remote_address,omitempty"`
	// contains filtered or unexported fields
}

func (*SessionInfo) Descriptor deprecated

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

Deprecated: Use SessionInfo.ProtoReflect.Descriptor instead.

func (*SessionInfo) GetId

func (x *SessionInfo) GetId() string

func (*SessionInfo) GetInitTime

func (x *SessionInfo) GetInitTime() *timestamp.Timestamp

func (*SessionInfo) GetRemoteAddress

func (x *SessionInfo) GetRemoteAddress() string

func (*SessionInfo) ProtoMessage

func (*SessionInfo) ProtoMessage()

func (*SessionInfo) ProtoReflect

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

func (*SessionInfo) Reset

func (x *SessionInfo) Reset()

func (*SessionInfo) String

func (x *SessionInfo) String() string

type SessionKillRequest

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

func (*SessionKillRequest) Descriptor deprecated

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

Deprecated: Use SessionKillRequest.ProtoReflect.Descriptor instead.

func (*SessionKillRequest) GetId

func (x *SessionKillRequest) GetId() string

func (*SessionKillRequest) ProtoMessage

func (*SessionKillRequest) ProtoMessage()

func (*SessionKillRequest) ProtoReflect

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

func (*SessionKillRequest) Reset

func (x *SessionKillRequest) Reset()

func (*SessionKillRequest) String

func (x *SessionKillRequest) String() string

type SubscribeRequest

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

func (*SubscribeRequest) Descriptor deprecated

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

Deprecated: Use SubscribeRequest.ProtoReflect.Descriptor instead.

func (*SubscribeRequest) ProtoMessage

func (*SubscribeRequest) ProtoMessage()

func (*SubscribeRequest) ProtoReflect

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

func (*SubscribeRequest) Reset

func (x *SubscribeRequest) Reset()

func (*SubscribeRequest) String

func (x *SubscribeRequest) String() string

type UnimplementedBackconnectdServer

type UnimplementedBackconnectdServer struct {
}

UnimplementedBackconnectdServer must be embedded to have forward compatible implementations.

func (UnimplementedBackconnectdServer) ConnectSession

func (UnimplementedBackconnectdServer) KillSession

func (UnimplementedBackconnectdServer) Subscribe

type UnsafeBackconnectdServer

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

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

Jump to

Keyboard shortcuts

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