canal

package
v0.0.0-...-c9f961e Latest Latest
Warning

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

Go to latest
Published: Oct 16, 2022 License: Apache-2.0 Imports: 26 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var Canal_ServiceDesc = grpc.ServiceDesc{
	ServiceName: "api.canal.Canal",
	HandlerType: (*CanalServer)(nil),
	Methods: []grpc.MethodDesc{
		{
			MethodName: "InfocPost",
			Handler:    _Canal_InfocPost_Handler,
		},
		{
			MethodName: "InfocCurrent",
			Handler:    _Canal_InfocCurrent_Handler,
		},
		{
			MethodName: "Errors",
			Handler:    _Canal_Errors_Handler,
		},
		{
			MethodName: "CheckMaster",
			Handler:    _Canal_CheckMaster_Handler,
		},
		{
			MethodName: "SyncPos",
			Handler:    _Canal_SyncPos_Handler,
		},
	},
	Streams:  []grpc.StreamDesc{},
	Metadata: "api/canal/canal.proto",
}

Canal_ServiceDesc is the grpc.ServiceDesc for Canal 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_api_canal_canal_proto protoreflect.FileDescriptor

Functions

func ErrNoMasterInfoConfig

func ErrNoMasterInfoConfig(format string, a ...interface{}) error

func IsErrNoMasterInfoConfig

func IsErrNoMasterInfoConfig(err error) bool

func RegisterCanalHTTPServer

func RegisterCanalHTTPServer(s *http.Server, srv CanalHTTPServer)

func RegisterCanalServer

func RegisterCanalServer(s grpc.ServiceRegistrar, srv CanalServer)

Types

type CanalClient

type CanalClient interface {
	InfocPost(ctx context.Context, in *InfocPostRequest, opts ...grpc.CallOption) (*InfocPostReply, error)
	InfocCurrent(ctx context.Context, in *InfocCurrentRequest, opts ...grpc.CallOption) (*InfocCurrentReply, error)
	Errors(ctx context.Context, in *ErrorsRequest, opts ...grpc.CallOption) (*ErrorsReply, error)
	CheckMaster(ctx context.Context, in *CheckMasterRequest, opts ...grpc.CallOption) (*CheckMasterReply, error)
	SyncPos(ctx context.Context, in *SyncPosRequest, opts ...grpc.CallOption) (*SyncPosReply, error)
}

CanalClient is the client API for Canal 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 NewCanalClient

func NewCanalClient(cc grpc.ClientConnInterface) CanalClient

type CanalHTTPClient

type CanalHTTPClient interface {
	CheckMaster(ctx context.Context, req *CheckMasterRequest, opts ...http.CallOption) (rsp *CheckMasterReply, err error)
	Errors(ctx context.Context, req *ErrorsRequest, opts ...http.CallOption) (rsp *ErrorsReply, err error)
	InfocCurrent(ctx context.Context, req *InfocCurrentRequest, opts ...http.CallOption) (rsp *InfocCurrentReply, err error)
	InfocPost(ctx context.Context, req *InfocPostRequest, opts ...http.CallOption) (rsp *InfocPostReply, err error)
	SyncPos(ctx context.Context, req *SyncPosRequest, opts ...http.CallOption) (rsp *SyncPosReply, err error)
}

func NewCanalHTTPClient

func NewCanalHTTPClient(client *http.Client) CanalHTTPClient

type CanalHTTPClientImpl

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

func (*CanalHTTPClientImpl) CheckMaster

func (*CanalHTTPClientImpl) Errors

func (*CanalHTTPClientImpl) InfocCurrent

func (*CanalHTTPClientImpl) InfocPost

func (*CanalHTTPClientImpl) SyncPos

type CanalServer

type CanalServer interface {
	InfocPost(context.Context, *InfocPostRequest) (*InfocPostReply, error)
	InfocCurrent(context.Context, *InfocCurrentRequest) (*InfocCurrentReply, error)
	Errors(context.Context, *ErrorsRequest) (*ErrorsReply, error)
	CheckMaster(context.Context, *CheckMasterRequest) (*CheckMasterReply, error)
	SyncPos(context.Context, *SyncPosRequest) (*SyncPosReply, error)
	// contains filtered or unexported methods
}

CanalServer is the server API for Canal service. All implementations must embed UnimplementedCanalServer for forward compatibility

type CheckMasterReply

type CheckMasterReply struct {
	Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"`
	Pos  int64  `protobuf:"varint,2,opt,name=pos,proto3" json:"pos,omitempty"`
	// contains filtered or unexported fields
}

func (*CheckMasterReply) Descriptor deprecated

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

Deprecated: Use CheckMasterReply.ProtoReflect.Descriptor instead.

func (*CheckMasterReply) GetName

func (x *CheckMasterReply) GetName() string

func (*CheckMasterReply) GetPos

func (x *CheckMasterReply) GetPos() int64

func (*CheckMasterReply) ProtoMessage

func (*CheckMasterReply) ProtoMessage()

func (*CheckMasterReply) ProtoReflect

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

func (*CheckMasterReply) Reset

func (x *CheckMasterReply) Reset()

func (*CheckMasterReply) String

func (x *CheckMasterReply) String() string

func (*CheckMasterReply) Validate

func (m *CheckMasterReply) Validate() error

Validate checks the field values on CheckMasterReply with the rules defined in the proto definition for this message. If any rules are violated, an error is returned.

type CheckMasterReplyValidationError

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

CheckMasterReplyValidationError is the validation error returned by CheckMasterReply.Validate if the designated constraints aren't met.

func (CheckMasterReplyValidationError) Cause

Cause function returns cause value.

func (CheckMasterReplyValidationError) Error

Error satisfies the builtin error interface

func (CheckMasterReplyValidationError) ErrorName

ErrorName returns error name.

func (CheckMasterReplyValidationError) Field

Field function returns field value.

func (CheckMasterReplyValidationError) Key

Key function returns key value.

func (CheckMasterReplyValidationError) Reason

Reason function returns reason value.

type CheckMasterRequest

type CheckMasterRequest struct {
	Addr     string `protobuf:"bytes,1,opt,name=addr,proto3" json:"addr,omitempty"`
	User     string `protobuf:"bytes,2,opt,name=user,proto3" json:"user,omitempty"`
	Password string `protobuf:"bytes,3,opt,name=password,proto3" json:"password,omitempty"`
	// contains filtered or unexported fields
}

func (*CheckMasterRequest) Descriptor deprecated

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

Deprecated: Use CheckMasterRequest.ProtoReflect.Descriptor instead.

func (*CheckMasterRequest) GetAddr

func (x *CheckMasterRequest) GetAddr() string

func (*CheckMasterRequest) GetPassword

func (x *CheckMasterRequest) GetPassword() string

func (*CheckMasterRequest) GetUser

func (x *CheckMasterRequest) GetUser() string

func (*CheckMasterRequest) ProtoMessage

func (*CheckMasterRequest) ProtoMessage()

func (*CheckMasterRequest) ProtoReflect

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

func (*CheckMasterRequest) Reset

func (x *CheckMasterRequest) Reset()

func (*CheckMasterRequest) String

func (x *CheckMasterRequest) String() string

func (*CheckMasterRequest) Validate

func (m *CheckMasterRequest) Validate() error

Validate checks the field values on CheckMasterRequest with the rules defined in the proto definition for this message. If any rules are violated, an error is returned.

type CheckMasterRequestValidationError

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

CheckMasterRequestValidationError is the validation error returned by CheckMasterRequest.Validate if the designated constraints aren't met.

func (CheckMasterRequestValidationError) Cause

Cause function returns cause value.

func (CheckMasterRequestValidationError) Error

Error satisfies the builtin error interface

func (CheckMasterRequestValidationError) ErrorName

ErrorName returns error name.

func (CheckMasterRequestValidationError) Field

Field function returns field value.

func (CheckMasterRequestValidationError) Key

Key function returns key value.

func (CheckMasterRequestValidationError) Reason

Reason function returns reason value.

type ErrorsReply

type ErrorsReply struct {
	Error         string            `protobuf:"bytes,1,opt,name=error,proto3" json:"error,omitempty"`
	InstanceError map[string]string `` /* 167-byte string literal not displayed */
	// contains filtered or unexported fields
}

func (*ErrorsReply) Descriptor deprecated

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

Deprecated: Use ErrorsReply.ProtoReflect.Descriptor instead.

func (*ErrorsReply) GetError

func (x *ErrorsReply) GetError() string

func (*ErrorsReply) GetInstanceError

func (x *ErrorsReply) GetInstanceError() map[string]string

func (*ErrorsReply) ProtoMessage

func (*ErrorsReply) ProtoMessage()

func (*ErrorsReply) ProtoReflect

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

func (*ErrorsReply) Reset

func (x *ErrorsReply) Reset()

func (*ErrorsReply) String

func (x *ErrorsReply) String() string

func (*ErrorsReply) Validate

func (m *ErrorsReply) Validate() error

Validate checks the field values on ErrorsReply with the rules defined in the proto definition for this message. If any rules are violated, an error is returned.

type ErrorsReplyValidationError

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

ErrorsReplyValidationError is the validation error returned by ErrorsReply.Validate if the designated constraints aren't met.

func (ErrorsReplyValidationError) Cause

Cause function returns cause value.

func (ErrorsReplyValidationError) Error

Error satisfies the builtin error interface

func (ErrorsReplyValidationError) ErrorName

func (e ErrorsReplyValidationError) ErrorName() string

ErrorName returns error name.

func (ErrorsReplyValidationError) Field

Field function returns field value.

func (ErrorsReplyValidationError) Key

Key function returns key value.

func (ErrorsReplyValidationError) Reason

Reason function returns reason value.

type ErrorsRequest

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

func (*ErrorsRequest) Descriptor deprecated

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

Deprecated: Use ErrorsRequest.ProtoReflect.Descriptor instead.

func (*ErrorsRequest) ProtoMessage

func (*ErrorsRequest) ProtoMessage()

func (*ErrorsRequest) ProtoReflect

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

func (*ErrorsRequest) Reset

func (x *ErrorsRequest) Reset()

func (*ErrorsRequest) String

func (x *ErrorsRequest) String() string

func (*ErrorsRequest) Validate

func (m *ErrorsRequest) Validate() error

Validate checks the field values on ErrorsRequest with the rules defined in the proto definition for this message. If any rules are violated, an error is returned.

type ErrorsRequestValidationError

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

ErrorsRequestValidationError is the validation error returned by ErrorsRequest.Validate if the designated constraints aren't met.

func (ErrorsRequestValidationError) Cause

Cause function returns cause value.

func (ErrorsRequestValidationError) Error

Error satisfies the builtin error interface

func (ErrorsRequestValidationError) ErrorName

func (e ErrorsRequestValidationError) ErrorName() string

ErrorName returns error name.

func (ErrorsRequestValidationError) Field

Field function returns field value.

func (ErrorsRequestValidationError) Key

Key function returns key value.

func (ErrorsRequestValidationError) Reason

Reason function returns reason value.

type InfocConf

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

func (*InfocConf) Descriptor deprecated

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

Deprecated: Use InfocConf.ProtoReflect.Descriptor instead.

func (*InfocConf) ProtoMessage

func (*InfocConf) ProtoMessage()

func (*InfocConf) ProtoReflect

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

func (*InfocConf) Reset

func (x *InfocConf) Reset()

func (*InfocConf) String

func (x *InfocConf) String() string

func (*InfocConf) Validate

func (m *InfocConf) Validate() error

Validate checks the field values on InfocConf with the rules defined in the proto definition for this message. If any rules are violated, an error is returned.

type InfocConfValidationError

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

InfocConfValidationError is the validation error returned by InfocConf.Validate if the designated constraints aren't met.

func (InfocConfValidationError) Cause

func (e InfocConfValidationError) Cause() error

Cause function returns cause value.

func (InfocConfValidationError) Error

func (e InfocConfValidationError) Error() string

Error satisfies the builtin error interface

func (InfocConfValidationError) ErrorName

func (e InfocConfValidationError) ErrorName() string

ErrorName returns error name.

func (InfocConfValidationError) Field

func (e InfocConfValidationError) Field() string

Field function returns field value.

func (InfocConfValidationError) Key

Key function returns key value.

func (InfocConfValidationError) Reason

func (e InfocConfValidationError) Reason() string

Reason function returns reason value.

type InfocCurrentReply

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

func (*InfocCurrentReply) Descriptor deprecated

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

Deprecated: Use InfocCurrentReply.ProtoReflect.Descriptor instead.

func (*InfocCurrentReply) ProtoMessage

func (*InfocCurrentReply) ProtoMessage()

func (*InfocCurrentReply) ProtoReflect

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

func (*InfocCurrentReply) Reset

func (x *InfocCurrentReply) Reset()

func (*InfocCurrentReply) String

func (x *InfocCurrentReply) String() string

func (*InfocCurrentReply) Validate

func (m *InfocCurrentReply) Validate() error

Validate checks the field values on InfocCurrentReply with the rules defined in the proto definition for this message. If any rules are violated, an error is returned.

type InfocCurrentReplyValidationError

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

InfocCurrentReplyValidationError is the validation error returned by InfocCurrentReply.Validate if the designated constraints aren't met.

func (InfocCurrentReplyValidationError) Cause

Cause function returns cause value.

func (InfocCurrentReplyValidationError) Error

Error satisfies the builtin error interface

func (InfocCurrentReplyValidationError) ErrorName

ErrorName returns error name.

func (InfocCurrentReplyValidationError) Field

Field function returns field value.

func (InfocCurrentReplyValidationError) Key

Key function returns key value.

func (InfocCurrentReplyValidationError) Reason

Reason function returns reason value.

type InfocCurrentRequest

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

func (*InfocCurrentRequest) Descriptor deprecated

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

Deprecated: Use InfocCurrentRequest.ProtoReflect.Descriptor instead.

func (*InfocCurrentRequest) ProtoMessage

func (*InfocCurrentRequest) ProtoMessage()

func (*InfocCurrentRequest) ProtoReflect

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

func (*InfocCurrentRequest) Reset

func (x *InfocCurrentRequest) Reset()

func (*InfocCurrentRequest) String

func (x *InfocCurrentRequest) String() string

func (*InfocCurrentRequest) Validate

func (m *InfocCurrentRequest) Validate() error

Validate checks the field values on InfocCurrentRequest with the rules defined in the proto definition for this message. If any rules are violated, an error is returned.

type InfocCurrentRequestValidationError

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

InfocCurrentRequestValidationError is the validation error returned by InfocCurrentRequest.Validate if the designated constraints aren't met.

func (InfocCurrentRequestValidationError) Cause

Cause function returns cause value.

func (InfocCurrentRequestValidationError) Error

Error satisfies the builtin error interface

func (InfocCurrentRequestValidationError) ErrorName

ErrorName returns error name.

func (InfocCurrentRequestValidationError) Field

Field function returns field value.

func (InfocCurrentRequestValidationError) Key

Key function returns key value.

func (InfocCurrentRequestValidationError) Reason

Reason function returns reason value.

type InfocPostReply

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

func (*InfocPostReply) Descriptor deprecated

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

Deprecated: Use InfocPostReply.ProtoReflect.Descriptor instead.

func (*InfocPostReply) ProtoMessage

func (*InfocPostReply) ProtoMessage()

func (*InfocPostReply) ProtoReflect

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

func (*InfocPostReply) Reset

func (x *InfocPostReply) Reset()

func (*InfocPostReply) String

func (x *InfocPostReply) String() string

func (*InfocPostReply) Validate

func (m *InfocPostReply) Validate() error

Validate checks the field values on InfocPostReply with the rules defined in the proto definition for this message. If any rules are violated, an error is returned.

type InfocPostReplyValidationError

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

InfocPostReplyValidationError is the validation error returned by InfocPostReply.Validate if the designated constraints aren't met.

func (InfocPostReplyValidationError) Cause

Cause function returns cause value.

func (InfocPostReplyValidationError) Error

Error satisfies the builtin error interface

func (InfocPostReplyValidationError) ErrorName

func (e InfocPostReplyValidationError) ErrorName() string

ErrorName returns error name.

func (InfocPostReplyValidationError) Field

Field function returns field value.

func (InfocPostReplyValidationError) Key

Key function returns key value.

func (InfocPostReplyValidationError) Reason

Reason function returns reason value.

type InfocPostRequest

type InfocPostRequest struct {
	Ics []*InfocConf `protobuf:"bytes,1,rep,name=ics,proto3" json:"ics,omitempty"`
	// contains filtered or unexported fields
}

func (*InfocPostRequest) Descriptor deprecated

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

Deprecated: Use InfocPostRequest.ProtoReflect.Descriptor instead.

func (*InfocPostRequest) GetIcs

func (x *InfocPostRequest) GetIcs() []*InfocConf

func (*InfocPostRequest) ProtoMessage

func (*InfocPostRequest) ProtoMessage()

func (*InfocPostRequest) ProtoReflect

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

func (*InfocPostRequest) Reset

func (x *InfocPostRequest) Reset()

func (*InfocPostRequest) String

func (x *InfocPostRequest) String() string

func (*InfocPostRequest) Validate

func (m *InfocPostRequest) Validate() error

Validate checks the field values on InfocPostRequest with the rules defined in the proto definition for this message. If any rules are violated, an error is returned.

type InfocPostRequestValidationError

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

InfocPostRequestValidationError is the validation error returned by InfocPostRequest.Validate if the designated constraints aren't met.

func (InfocPostRequestValidationError) Cause

Cause function returns cause value.

func (InfocPostRequestValidationError) Error

Error satisfies the builtin error interface

func (InfocPostRequestValidationError) ErrorName

ErrorName returns error name.

func (InfocPostRequestValidationError) Field

Field function returns field value.

func (InfocPostRequestValidationError) Key

Key function returns key value.

func (InfocPostRequestValidationError) Reason

Reason function returns reason value.

type SyncPosReply

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

func (*SyncPosReply) Descriptor deprecated

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

Deprecated: Use SyncPosReply.ProtoReflect.Descriptor instead.

func (*SyncPosReply) ProtoMessage

func (*SyncPosReply) ProtoMessage()

func (*SyncPosReply) ProtoReflect

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

func (*SyncPosReply) Reset

func (x *SyncPosReply) Reset()

func (*SyncPosReply) String

func (x *SyncPosReply) String() string

func (*SyncPosReply) Validate

func (m *SyncPosReply) Validate() error

Validate checks the field values on SyncPosReply with the rules defined in the proto definition for this message. If any rules are violated, an error is returned.

type SyncPosReplyValidationError

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

SyncPosReplyValidationError is the validation error returned by SyncPosReply.Validate if the designated constraints aren't met.

func (SyncPosReplyValidationError) Cause

Cause function returns cause value.

func (SyncPosReplyValidationError) Error

Error satisfies the builtin error interface

func (SyncPosReplyValidationError) ErrorName

func (e SyncPosReplyValidationError) ErrorName() string

ErrorName returns error name.

func (SyncPosReplyValidationError) Field

Field function returns field value.

func (SyncPosReplyValidationError) Key

Key function returns key value.

func (SyncPosReplyValidationError) Reason

Reason function returns reason value.

type SyncPosRequest

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

func (*SyncPosRequest) Descriptor deprecated

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

Deprecated: Use SyncPosRequest.ProtoReflect.Descriptor instead.

func (*SyncPosRequest) GetAddr

func (x *SyncPosRequest) GetAddr() string

func (*SyncPosRequest) ProtoMessage

func (*SyncPosRequest) ProtoMessage()

func (*SyncPosRequest) ProtoReflect

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

func (*SyncPosRequest) Reset

func (x *SyncPosRequest) Reset()

func (*SyncPosRequest) String

func (x *SyncPosRequest) String() string

func (*SyncPosRequest) Validate

func (m *SyncPosRequest) Validate() error

Validate checks the field values on SyncPosRequest with the rules defined in the proto definition for this message. If any rules are violated, an error is returned.

type SyncPosRequestValidationError

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

SyncPosRequestValidationError is the validation error returned by SyncPosRequest.Validate if the designated constraints aren't met.

func (SyncPosRequestValidationError) Cause

Cause function returns cause value.

func (SyncPosRequestValidationError) Error

Error satisfies the builtin error interface

func (SyncPosRequestValidationError) ErrorName

func (e SyncPosRequestValidationError) ErrorName() string

ErrorName returns error name.

func (SyncPosRequestValidationError) Field

Field function returns field value.

func (SyncPosRequestValidationError) Key

Key function returns key value.

func (SyncPosRequestValidationError) Reason

Reason function returns reason value.

type UnimplementedCanalServer

type UnimplementedCanalServer struct {
}

UnimplementedCanalServer must be embedded to have forward compatible implementations.

func (UnimplementedCanalServer) CheckMaster

func (UnimplementedCanalServer) Errors

func (UnimplementedCanalServer) InfocCurrent

func (UnimplementedCanalServer) InfocPost

func (UnimplementedCanalServer) SyncPos

type UnsafeCanalServer

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

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

Jump to

Keyboard shortcuts

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