Documentation ¶
Index ¶
- Variables
- func NewSvcEndpoints() []*api.Endpoint
- func RegisterSvcHandler(s server.Server, hdlr SvcHandler, opts ...server.HandlerOption) error
- type AllSvc
- type FindAll
- type Response
- type SvcHandler
- type SvcId
- type SvcInfo
- func (*SvcInfo) Descriptor() ([]byte, []int)deprecated
- func (x *SvcInfo) GetId() int64
- func (x *SvcInfo) GetSvcExternalName() string
- func (x *SvcInfo) GetSvcName() string
- func (x *SvcInfo) GetSvcNamespace() string
- func (x *SvcInfo) GetSvcPodName() string
- func (x *SvcInfo) GetSvcPort() []*SvcPort
- func (x *SvcInfo) GetSvcTeamId() string
- func (x *SvcInfo) GetSvcType() string
- func (*SvcInfo) ProtoMessage()
- func (x *SvcInfo) ProtoReflect() protoreflect.Message
- func (x *SvcInfo) Reset()
- func (x *SvcInfo) String() string
- type SvcPort
- func (*SvcPort) Descriptor() ([]byte, []int)deprecated
- func (x *SvcPort) GetId() int64
- func (x *SvcPort) GetSvcId() int64
- func (x *SvcPort) GetSvcNodePort() int64
- func (x *SvcPort) GetSvcPort() int64
- func (x *SvcPort) GetSvcPortProtocol() string
- func (x *SvcPort) GetSvcTargetPort() int64
- func (*SvcPort) ProtoMessage()
- func (x *SvcPort) ProtoReflect() protoreflect.Message
- func (x *SvcPort) Reset()
- func (x *SvcPort) String() string
- type SvcService
Constants ¶
This section is empty.
Variables ¶
View Source
var File_proto_svc_svc_proto protoreflect.FileDescriptor
Functions ¶
func NewSvcEndpoints ¶
func RegisterSvcHandler ¶
func RegisterSvcHandler(s server.Server, hdlr SvcHandler, opts ...server.HandlerOption) error
Types ¶
type AllSvc ¶
type AllSvc struct { SvcInfo []*SvcInfo `protobuf:"bytes,1,rep,name=svc_info,json=svcInfo,proto3" json:"svc_info,omitempty"` // contains filtered or unexported fields }
func (*AllSvc) Descriptor
deprecated
func (*AllSvc) GetSvcInfo ¶
func (*AllSvc) ProtoMessage ¶
func (*AllSvc) ProtoMessage()
func (*AllSvc) ProtoReflect ¶
func (x *AllSvc) ProtoReflect() protoreflect.Message
type FindAll ¶
type FindAll struct {
// contains filtered or unexported fields
}
func (*FindAll) Descriptor
deprecated
func (*FindAll) ProtoMessage ¶
func (*FindAll) ProtoMessage()
func (*FindAll) ProtoReflect ¶
func (x *FindAll) ProtoReflect() protoreflect.Message
type Response ¶
type Response struct { Msg string `protobuf:"bytes,1,opt,name=msg,proto3" json:"msg,omitempty"` // contains filtered or unexported fields }
func (*Response) Descriptor
deprecated
func (*Response) ProtoMessage ¶
func (*Response) ProtoMessage()
func (*Response) ProtoReflect ¶
func (x *Response) ProtoReflect() protoreflect.Message
type SvcHandler ¶
type SvcHandler interface { //对外提供添加服务 AddSvc(context.Context, *SvcInfo, *Response) error DeleteSvc(context.Context, *SvcId, *Response) error UpdateSvc(context.Context, *SvcInfo, *Response) error FindSvcByID(context.Context, *SvcId, *SvcInfo) error FindAllSvc(context.Context, *FindAll, *AllSvc) error }
type SvcId ¶
type SvcId struct { Id int64 `protobuf:"varint,1,opt,name=id,proto3" json:"id,omitempty"` // contains filtered or unexported fields }
func (*SvcId) Descriptor
deprecated
func (*SvcId) ProtoMessage ¶
func (*SvcId) ProtoMessage()
func (*SvcId) ProtoReflect ¶
func (x *SvcId) ProtoReflect() protoreflect.Message
type SvcInfo ¶
type SvcInfo struct { Id int64 `protobuf:"varint,1,opt,name=id,proto3" json:"id,omitempty"` SvcNamespace string `protobuf:"bytes,2,opt,name=svc_namespace,json=svcNamespace,proto3" json:"svc_namespace,omitempty"` SvcName string `protobuf:"bytes,3,opt,name=svc_name,json=svcName,proto3" json:"svc_name,omitempty"` SvcPodName string `protobuf:"bytes,4,opt,name=svc_pod_name,json=svcPodName,proto3" json:"svc_pod_name,omitempty"` SvcType string `protobuf:"bytes,5,opt,name=svc_type,json=svcType,proto3" json:"svc_type,omitempty"` SvcExternalName string `protobuf:"bytes,6,opt,name=svc_external_name,json=svcExternalName,proto3" json:"svc_external_name,omitempty"` SvcTeamId string `protobuf:"bytes,7,opt,name=svc_team_id,json=svcTeamId,proto3" json:"svc_team_id,omitempty"` SvcPort []*SvcPort `protobuf:"bytes,8,rep,name=svc_port,json=svcPort,proto3" json:"svc_port,omitempty"` // contains filtered or unexported fields }
func (*SvcInfo) Descriptor
deprecated
func (*SvcInfo) GetSvcExternalName ¶
func (*SvcInfo) GetSvcName ¶
func (*SvcInfo) GetSvcNamespace ¶
func (*SvcInfo) GetSvcPodName ¶
func (*SvcInfo) GetSvcPort ¶
func (*SvcInfo) GetSvcTeamId ¶
func (*SvcInfo) GetSvcType ¶
func (*SvcInfo) ProtoMessage ¶
func (*SvcInfo) ProtoMessage()
func (*SvcInfo) ProtoReflect ¶
func (x *SvcInfo) ProtoReflect() protoreflect.Message
type SvcPort ¶
type SvcPort struct { Id int64 `protobuf:"varint,1,opt,name=id,proto3" json:"id,omitempty"` SvcId int64 `protobuf:"varint,2,opt,name=svc_id,json=svcId,proto3" json:"svc_id,omitempty"` SvcPort int64 `protobuf:"varint,3,opt,name=svc_port,json=svcPort,proto3" json:"svc_port,omitempty"` SvcTargetPort int64 `protobuf:"varint,4,opt,name=svc_target_port,json=svcTargetPort,proto3" json:"svc_target_port,omitempty"` SvcNodePort int64 `protobuf:"varint,5,opt,name=svc_node_port,json=svcNodePort,proto3" json:"svc_node_port,omitempty"` SvcPortProtocol string `protobuf:"bytes,6,opt,name=svc_port_protocol,json=svcPortProtocol,proto3" json:"svc_port_protocol,omitempty"` // contains filtered or unexported fields }
func (*SvcPort) Descriptor
deprecated
func (*SvcPort) GetSvcNodePort ¶
func (*SvcPort) GetSvcPort ¶
func (*SvcPort) GetSvcPortProtocol ¶
func (*SvcPort) GetSvcTargetPort ¶
func (*SvcPort) ProtoMessage ¶
func (*SvcPort) ProtoMessage()
func (*SvcPort) ProtoReflect ¶
func (x *SvcPort) ProtoReflect() protoreflect.Message
type SvcService ¶
type SvcService interface { //对外提供添加服务 AddSvc(ctx context.Context, in *SvcInfo, opts ...client.CallOption) (*Response, error) DeleteSvc(ctx context.Context, in *SvcId, opts ...client.CallOption) (*Response, error) UpdateSvc(ctx context.Context, in *SvcInfo, opts ...client.CallOption) (*Response, error) FindSvcByID(ctx context.Context, in *SvcId, opts ...client.CallOption) (*SvcInfo, error) FindAllSvc(ctx context.Context, in *FindAll, opts ...client.CallOption) (*AllSvc, error) }
func NewSvcService ¶
func NewSvcService(name string, c client.Client) SvcService
Click to show internal directories.
Click to hide internal directories.