Documentation
¶
Index ¶
- Variables
- type Request
- func (*Request) Descriptor() ([]byte, []int)deprecated
- func (x *Request) GetMetadata() map[string][]byte
- func (x *Request) GetMethodName() string
- func (x *Request) GetPayload() []byte
- func (x *Request) GetRequestId() uint32
- func (x *Request) GetServiceName() string
- func (*Request) ProtoMessage()
- func (x *Request) ProtoReflect() protoreflect.Message
- func (x *Request) Reset()
- func (x *Request) String() string
- type Response
- func (*Response) Descriptor() ([]byte, []int)deprecated
- func (x *Response) GetMetadata() map[string][]byte
- func (x *Response) GetPayload() []byte
- func (x *Response) GetRequestId() uint32
- func (x *Response) GetRetCode() uint32
- func (x *Response) GetRetMsg() string
- func (*Response) ProtoMessage()
- func (x *Response) ProtoReflect() protoreflect.Message
- func (x *Response) Reset()
- func (x *Response) String() string
Constants ¶
This section is empty.
Variables ¶
View Source
var File_msg_proto protoreflect.FileDescriptor
Functions ¶
This section is empty.
Types ¶
type Request ¶
type Request struct {
RequestId uint32 `protobuf:"varint,1,opt,name=request_id,json=requestId,proto3" json:"request_id,omitempty"` // 一次请求的唯一ID
ServiceName string `protobuf:"bytes,2,opt,name=service_name,json=serviceName,proto3" json:"service_name,omitempty"` // 服务名
MethodName string `protobuf:"bytes,3,opt,name=method_name,json=methodName,proto3" json:"method_name,omitempty"` // 方法名
Metadata map[string][]byte `` // 传递的数据
/* 157-byte string literal not displayed */
Payload []byte `protobuf:"bytes,5,opt,name=payload,proto3" json:"payload,omitempty"` // body
// contains filtered or unexported fields
}
func (*Request) Descriptor
deprecated
func (*Request) GetMetadata ¶
func (*Request) GetMethodName ¶
func (*Request) GetPayload ¶
func (*Request) GetRequestId ¶
func (*Request) GetServiceName ¶
func (*Request) ProtoMessage ¶
func (*Request) ProtoMessage()
func (*Request) ProtoReflect ¶
func (x *Request) ProtoReflect() protoreflect.Message
type Response ¶
type Response struct {
RetCode uint32 `protobuf:"varint,1,opt,name=ret_code,json=retCode,proto3" json:"ret_code,omitempty"` // 错误码 成功请求为 0
RequestId uint32 `protobuf:"varint,2,opt,name=request_id,json=requestId,proto3" json:"request_id,omitempty"` // 一次请求的唯一ID
RetMsg string `protobuf:"bytes,3,opt,name=ret_msg,json=retMsg,proto3" json:"ret_msg,omitempty"` // 错误消息 成功为success,错误会返回错误信息
Metadata map[string][]byte `` // 传递的数据
/* 157-byte string literal not displayed */
Payload []byte `protobuf:"bytes,5,opt,name=payload,proto3" json:"payload,omitempty"` // body
// contains filtered or unexported fields
}
func (*Response) Descriptor
deprecated
func (*Response) GetMetadata ¶
func (*Response) GetPayload ¶
func (*Response) GetRequestId ¶
func (*Response) GetRetCode ¶
func (*Response) ProtoMessage ¶
func (*Response) ProtoMessage()
func (*Response) ProtoReflect ¶
func (x *Response) ProtoReflect() protoreflect.Message
Click to show internal directories.
Click to hide internal directories.