meta

package
v0.2.1 Latest Latest
Warning

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

Go to latest
Published: Mar 6, 2023 License: Apache-2.0 Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	MetaResponse_Status_name = map[int32]string{
		0: "ERROR",
		1: "SUCCESS",
	}
	MetaResponse_Status_value = map[string]int32{
		"ERROR":   0,
		"SUCCESS": 1,
	}
)

Enum value maps for MetaResponse_Status.

View Source
var MetaRoute_ServiceDesc = grpc.ServiceDesc{
	ServiceName: "grpcMeta.MetaRoute",
	HandlerType: (*MetaRouteServer)(nil),
	Methods: []grpc.MethodDesc{
		{
			MethodName: "RegisterMetaInfo",
			Handler:    _MetaRoute_RegisterMetaInfo_Handler,
		},
		{
			MethodName: "HeartBeat",
			Handler:    _MetaRoute_HeartBeat_Handler,
		},
	},
	Streams:  []grpc.StreamDesc{},
	Metadata: "meta.proto",
}

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

Functions

func RegisterMetaRouteServer

func RegisterMetaRouteServer(s grpc.ServiceRegistrar, srv MetaRouteServer)

Types

type MetaInfo

type MetaInfo struct {
	JobId    string `protobuf:"bytes,1,opt,name=job_id,json=jobId,proto3" json:"job_id,omitempty"`
	ChName   string `protobuf:"bytes,2,opt,name=ch_name,json=chName,proto3" json:"ch_name,omitempty"`
	Me       string `protobuf:"bytes,3,opt,name=me,proto3" json:"me,omitempty"`
	Other    string `protobuf:"bytes,4,opt,name=other,proto3" json:"other,omitempty"`
	Group    string `protobuf:"bytes,5,opt,name=group,proto3" json:"group,omitempty"`
	Endpoint string `protobuf:"bytes,6,opt,name=endpoint,proto3" json:"endpoint,omitempty"`
	// contains filtered or unexported fields
}

func (*MetaInfo) Descriptor deprecated

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

Deprecated: Use MetaInfo.ProtoReflect.Descriptor instead.

func (*MetaInfo) GetChName

func (x *MetaInfo) GetChName() string

func (*MetaInfo) GetEndpoint

func (x *MetaInfo) GetEndpoint() string

func (*MetaInfo) GetGroup added in v0.2.0

func (x *MetaInfo) GetGroup() string

func (*MetaInfo) GetJobId

func (x *MetaInfo) GetJobId() string

func (*MetaInfo) GetMe

func (x *MetaInfo) GetMe() string

func (*MetaInfo) GetOther

func (x *MetaInfo) GetOther() string

func (*MetaInfo) ProtoMessage

func (*MetaInfo) ProtoMessage()

func (*MetaInfo) ProtoReflect

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

func (*MetaInfo) Reset

func (x *MetaInfo) Reset()

func (*MetaInfo) String

func (x *MetaInfo) String() string

type MetaResponse

type MetaResponse struct {
	Status    MetaResponse_Status `protobuf:"varint,1,opt,name=status,proto3,enum=grpcMeta.MetaResponse_Status" json:"status,omitempty"`
	Endpoints []string            `protobuf:"bytes,2,rep,name=endpoints,proto3" json:"endpoints,omitempty"`
	// contains filtered or unexported fields
}

func (*MetaResponse) Descriptor deprecated

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

Deprecated: Use MetaResponse.ProtoReflect.Descriptor instead.

func (*MetaResponse) GetEndpoints

func (x *MetaResponse) GetEndpoints() []string

func (*MetaResponse) GetStatus

func (x *MetaResponse) GetStatus() MetaResponse_Status

func (*MetaResponse) ProtoMessage

func (*MetaResponse) ProtoMessage()

func (*MetaResponse) ProtoReflect

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

func (*MetaResponse) Reset

func (x *MetaResponse) Reset()

func (*MetaResponse) String

func (x *MetaResponse) String() string

type MetaResponse_Status

type MetaResponse_Status int32
const (
	MetaResponse_ERROR   MetaResponse_Status = 0 // default
	MetaResponse_SUCCESS MetaResponse_Status = 1
)

func (MetaResponse_Status) Descriptor

func (MetaResponse_Status) Enum

func (MetaResponse_Status) EnumDescriptor deprecated

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

Deprecated: Use MetaResponse_Status.Descriptor instead.

func (MetaResponse_Status) Number

func (MetaResponse_Status) String

func (x MetaResponse_Status) String() string

func (MetaResponse_Status) Type

type MetaRouteClient

type MetaRouteClient interface {
	RegisterMetaInfo(ctx context.Context, in *MetaInfo, opts ...grpc.CallOption) (*MetaResponse, error)
	HeartBeat(ctx context.Context, in *MetaInfo, opts ...grpc.CallOption) (*MetaResponse, error)
}

MetaRouteClient is the client API for MetaRoute 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 NewMetaRouteClient

func NewMetaRouteClient(cc grpc.ClientConnInterface) MetaRouteClient

type MetaRouteServer

type MetaRouteServer interface {
	RegisterMetaInfo(context.Context, *MetaInfo) (*MetaResponse, error)
	HeartBeat(context.Context, *MetaInfo) (*MetaResponse, error)
	// contains filtered or unexported methods
}

MetaRouteServer is the server API for MetaRoute service. All implementations must embed UnimplementedMetaRouteServer for forward compatibility

type UnimplementedMetaRouteServer

type UnimplementedMetaRouteServer struct {
}

UnimplementedMetaRouteServer must be embedded to have forward compatible implementations.

func (UnimplementedMetaRouteServer) HeartBeat

func (UnimplementedMetaRouteServer) RegisterMetaInfo

type UnsafeMetaRouteServer

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

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

Jump to

Keyboard shortcuts

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