update
Signed-off-by: Vasiliy Tolstov <v.tolstov@unistack.org>
This commit is contained in:
parent
99ebab4260
commit
7bf66d519e
@ -1,5 +1,5 @@
|
||||
// Code generated by protoc-gen-go-micro. DO NOT EDIT.
|
||||
// protoc-gen-go-micro version: v3.4.0
|
||||
// protoc-gen-go-micro version: v3.4.2
|
||||
// source: test.proto
|
||||
|
||||
package pb
|
||||
@ -11,6 +11,8 @@ import (
|
||||
)
|
||||
|
||||
var (
|
||||
TestServiceName = "TestService"
|
||||
|
||||
TestServiceEndpoints = []api.Endpoint{}
|
||||
)
|
||||
|
||||
|
@ -1,5 +1,5 @@
|
||||
// Code generated by protoc-gen-go-micro. DO NOT EDIT.
|
||||
// protoc-gen-go-micro version: v3.4.0
|
||||
// protoc-gen-go-micro version: v3.4.2
|
||||
// source: test.proto
|
||||
|
||||
package pb
|
||||
|
@ -1,5 +1,5 @@
|
||||
// Code generated by protoc-gen-go-micro. DO NOT EDIT.
|
||||
// protoc-gen-go-micro version: v3.4.0
|
||||
// protoc-gen-go-micro version: v3.4.2
|
||||
// source: test.proto
|
||||
|
||||
package helloworld
|
||||
@ -12,6 +12,8 @@ import (
|
||||
)
|
||||
|
||||
var (
|
||||
TestName = "Test"
|
||||
|
||||
TestEndpoints = []api.Endpoint{}
|
||||
)
|
||||
|
||||
|
@ -1,5 +1,5 @@
|
||||
// Code generated by protoc-gen-go-micro. DO NOT EDIT.
|
||||
// protoc-gen-go-micro version: v3.4.0
|
||||
// protoc-gen-go-micro version: v3.4.2
|
||||
// source: test.proto
|
||||
|
||||
package helloworld
|
||||
|
@ -141,9 +141,11 @@ func TestHTTPClient(t *testing.T) {
|
||||
|
||||
// write response
|
||||
w.Header().Add("Content-Type", "application/json")
|
||||
w.Write(b)
|
||||
_, _ = w.Write(b)
|
||||
})
|
||||
go http.Serve(l, mux)
|
||||
go func() {
|
||||
_ = http.Serve(l, mux)
|
||||
}()
|
||||
|
||||
if err := reg.Register(ctx, ®ister.Service{
|
||||
Name: "test.service",
|
||||
@ -257,7 +259,7 @@ func TestHTTPClientStream(t *testing.T) {
|
||||
}
|
||||
|
||||
// write response
|
||||
rsp.Write(bufrw)
|
||||
_ = rsp.Write(bufrw)
|
||||
bufrw.Flush()
|
||||
|
||||
reader := bufio.NewReader(conn)
|
||||
@ -301,11 +303,13 @@ func TestHTTPClientStream(t *testing.T) {
|
||||
}
|
||||
|
||||
// write response
|
||||
rsp.Write(bufrw)
|
||||
_ = rsp.Write(bufrw)
|
||||
bufrw.Flush()
|
||||
}
|
||||
})
|
||||
go http.Serve(l, mux)
|
||||
go func() {
|
||||
_ = http.Serve(l, mux)
|
||||
}()
|
||||
|
||||
if err := reg.Register(ctx, ®ister.Service{
|
||||
Name: "test.service",
|
||||
|
@ -1,5 +1,5 @@
|
||||
// Code generated by protoc-gen-go-micro. DO NOT EDIT.
|
||||
// protoc-gen-go-micro version: v3.4.0
|
||||
// protoc-gen-go-micro version: v3.4.2
|
||||
// source: github.proto
|
||||
|
||||
package pb
|
||||
@ -11,6 +11,8 @@ import (
|
||||
)
|
||||
|
||||
var (
|
||||
GithubName = "Github"
|
||||
|
||||
GithubEndpoints = []api.Endpoint{
|
||||
api.Endpoint{
|
||||
Name: "Github.LookupUser",
|
||||
|
@ -1,5 +1,5 @@
|
||||
// Code generated by protoc-gen-go-micro. DO NOT EDIT.
|
||||
// protoc-gen-go-micro version: v3.4.0
|
||||
// protoc-gen-go-micro version: v3.4.2
|
||||
// source: github.proto
|
||||
|
||||
package pb
|
||||
|
@ -1,5 +1,5 @@
|
||||
// Code generated by protoc-gen-go-micro. DO NOT EDIT.
|
||||
// protoc-gen-go-micro version: v3.4.0
|
||||
// protoc-gen-go-micro version: v3.4.2
|
||||
// source: test.proto
|
||||
|
||||
package pb
|
||||
@ -12,6 +12,8 @@ import (
|
||||
)
|
||||
|
||||
var (
|
||||
TestName = "Test"
|
||||
|
||||
TestEndpoints = []api.Endpoint{}
|
||||
)
|
||||
|
||||
|
@ -1,5 +1,5 @@
|
||||
// Code generated by protoc-gen-go-micro. DO NOT EDIT.
|
||||
// protoc-gen-go-micro version: v3.4.0
|
||||
// protoc-gen-go-micro version: v3.4.2
|
||||
// source: test.proto
|
||||
|
||||
package pb
|
||||
|
@ -1,5 +1,5 @@
|
||||
// Code generated by protoc-gen-go-micro. DO NOT EDIT.
|
||||
// protoc-gen-go-micro version: v3.4.0
|
||||
// protoc-gen-go-micro version: v3.4.2
|
||||
// source: test.proto
|
||||
|
||||
package pb
|
||||
@ -11,6 +11,8 @@ import (
|
||||
)
|
||||
|
||||
var (
|
||||
TestName = "Test"
|
||||
|
||||
TestEndpoints = []api.Endpoint{}
|
||||
)
|
||||
|
||||
|
@ -1,5 +1,5 @@
|
||||
// Code generated by protoc-gen-go-micro. DO NOT EDIT.
|
||||
// protoc-gen-go-micro version: v3.4.0
|
||||
// protoc-gen-go-micro version: v3.4.2
|
||||
// source: test.proto
|
||||
|
||||
package pb
|
||||
|
@ -2,10 +2,12 @@ package flow
|
||||
|
||||
import (
|
||||
"context"
|
||||
"path/filepath"
|
||||
"testing"
|
||||
"time"
|
||||
|
||||
httpcli "github.com/unistack-org/micro-client-http/v3"
|
||||
jsoncodec "github.com/unistack-org/micro-codec-json/v3"
|
||||
jsonpbcodec "github.com/unistack-org/micro-codec-jsonpb/v3"
|
||||
httpsrv "github.com/unistack-org/micro-server-http/v3"
|
||||
pb "github.com/unistack-org/micro-tests/flow/proto"
|
||||
@ -21,7 +23,20 @@ import (
|
||||
|
||||
type handler struct{}
|
||||
|
||||
func (h *handler) DeleteUser(ctx context.Context, req *pb.DeleteUserReq, rsp *pb.DeleteUserRsp) error {
|
||||
return nil
|
||||
}
|
||||
|
||||
func (h *handler) UpdateUser(ctx context.Context, req *pb.UpdateUserReq, rsp *pb.UpdateUserRsp) error {
|
||||
return nil
|
||||
}
|
||||
|
||||
func (h *handler) MailUser(ctx context.Context, req *pb.MailUserReq, rsp *pb.MailUserRsp) error {
|
||||
return nil
|
||||
}
|
||||
|
||||
func (h *handler) LookupUser(ctx context.Context, req *pb.LookupUserReq, rsp *pb.LookupUserRsp) error {
|
||||
rsp.Birthday = "31.07.1986"
|
||||
return nil
|
||||
}
|
||||
|
||||
@ -29,9 +44,16 @@ func TestFlow(t *testing.T) {
|
||||
ctx, cancel := context.WithCancel(context.Background())
|
||||
defer cancel()
|
||||
|
||||
logger.DefaultLogger = logger.NewLogger(logger.WithLevel(logger.TraceLevel))
|
||||
logger.DefaultLogger = logger.NewLogger(logger.WithLevel(logger.DebugLevel))
|
||||
|
||||
s := store.DefaultStore
|
||||
if err := s.Init(store.Codec(jsoncodec.NewCodec())); err != nil {
|
||||
t.Fatal(err)
|
||||
}
|
||||
if err := s.Connect(ctx); err != nil {
|
||||
t.Fatal(err)
|
||||
}
|
||||
|
||||
c := client.NewClientCallOptions(
|
||||
httpcli.NewClient(
|
||||
client.ContentType("application/json"),
|
||||
@ -54,6 +76,7 @@ func TestFlow(t *testing.T) {
|
||||
httpsrv.NewServer(
|
||||
server.Codec("application/json", jsonpbcodec.NewCodec()),
|
||||
server.Address("127.0.0.1:7989"),
|
||||
httpsrv.RegisterRPCHandler(true),
|
||||
),
|
||||
),
|
||||
micro.Context(ctx),
|
||||
@ -81,7 +104,7 @@ func TestFlow(t *testing.T) {
|
||||
steps := []flow.Step{
|
||||
flow.NewCallStep("test", pb.TestServiceName, "LookupUser", flow.StepID("test.TestService.LookupUser")),
|
||||
flow.NewCallStep("test", pb.TestServiceName, "UpdateUser", flow.StepRequires("test.TestService.LookupUser")),
|
||||
flow.NewCallStep("test", pb.TestServiceName, "RemoveUser", flow.StepRequires("test.TestService.UpdateUser")),
|
||||
flow.NewCallStep("test", pb.TestServiceName, "DeleteUser", flow.StepRequires("test.TestService.UpdateUser")),
|
||||
flow.NewCallStep("test", pb.TestServiceName, "MailUser", flow.StepRequires("test.TestService.UpdateUser")),
|
||||
}
|
||||
w, err := f.WorkflowCreate(ctx, "test", steps...)
|
||||
@ -89,11 +112,25 @@ func TestFlow(t *testing.T) {
|
||||
t.Fatal(err)
|
||||
}
|
||||
|
||||
req := &pb.LookupUserReq{Name: "vtolstov"}
|
||||
id, err := w.Execute(ctx, req, flow.ExecuteTimeout(2*time.Second))
|
||||
req, err := jsonpbcodec.NewCodec().Marshal(&pb.LookupUserReq{Name: "vtolstov"})
|
||||
if err != nil {
|
||||
t.Fatal(err)
|
||||
}
|
||||
|
||||
t.Logf("execution id: %s", id)
|
||||
id, err := w.Execute(ctx, &flow.Message{Body: req}, flow.ExecuteTimeout(2*time.Second))
|
||||
keys, err := s.List(ctx)
|
||||
if err != nil {
|
||||
t.Fatal(err)
|
||||
}
|
||||
keys, err = store.NewNamespaceStore(s, filepath.Join("workflows", id)).List(ctx)
|
||||
if err != nil {
|
||||
t.Fatal(err)
|
||||
}
|
||||
keys, err = store.NewNamespaceStore(s, filepath.Join("steps", id)).List(ctx)
|
||||
if err != nil {
|
||||
t.Fatal(err)
|
||||
}
|
||||
_ = keys
|
||||
t.Logf("execution id: %s, result: %v", id, err)
|
||||
|
||||
}
|
||||
|
@ -24,6 +24,270 @@ const (
|
||||
_ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20)
|
||||
)
|
||||
|
||||
type MailUserReq struct {
|
||||
state protoimpl.MessageState
|
||||
sizeCache protoimpl.SizeCache
|
||||
unknownFields protoimpl.UnknownFields
|
||||
|
||||
Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"`
|
||||
}
|
||||
|
||||
func (x *MailUserReq) Reset() {
|
||||
*x = MailUserReq{}
|
||||
if protoimpl.UnsafeEnabled {
|
||||
mi := &file_test_proto_msgTypes[0]
|
||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||
ms.StoreMessageInfo(mi)
|
||||
}
|
||||
}
|
||||
|
||||
func (x *MailUserReq) String() string {
|
||||
return protoimpl.X.MessageStringOf(x)
|
||||
}
|
||||
|
||||
func (*MailUserReq) ProtoMessage() {}
|
||||
|
||||
func (x *MailUserReq) ProtoReflect() protoreflect.Message {
|
||||
mi := &file_test_proto_msgTypes[0]
|
||||
if protoimpl.UnsafeEnabled && x != nil {
|
||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||
if ms.LoadMessageInfo() == nil {
|
||||
ms.StoreMessageInfo(mi)
|
||||
}
|
||||
return ms
|
||||
}
|
||||
return mi.MessageOf(x)
|
||||
}
|
||||
|
||||
// Deprecated: Use MailUserReq.ProtoReflect.Descriptor instead.
|
||||
func (*MailUserReq) Descriptor() ([]byte, []int) {
|
||||
return file_test_proto_rawDescGZIP(), []int{0}
|
||||
}
|
||||
|
||||
func (x *MailUserReq) GetName() string {
|
||||
if x != nil {
|
||||
return x.Name
|
||||
}
|
||||
return ""
|
||||
}
|
||||
|
||||
type MailUserRsp struct {
|
||||
state protoimpl.MessageState
|
||||
sizeCache protoimpl.SizeCache
|
||||
unknownFields protoimpl.UnknownFields
|
||||
|
||||
Status string `protobuf:"bytes,1,opt,name=status,proto3" json:"status,omitempty"`
|
||||
}
|
||||
|
||||
func (x *MailUserRsp) Reset() {
|
||||
*x = MailUserRsp{}
|
||||
if protoimpl.UnsafeEnabled {
|
||||
mi := &file_test_proto_msgTypes[1]
|
||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||
ms.StoreMessageInfo(mi)
|
||||
}
|
||||
}
|
||||
|
||||
func (x *MailUserRsp) String() string {
|
||||
return protoimpl.X.MessageStringOf(x)
|
||||
}
|
||||
|
||||
func (*MailUserRsp) ProtoMessage() {}
|
||||
|
||||
func (x *MailUserRsp) ProtoReflect() protoreflect.Message {
|
||||
mi := &file_test_proto_msgTypes[1]
|
||||
if protoimpl.UnsafeEnabled && x != nil {
|
||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||
if ms.LoadMessageInfo() == nil {
|
||||
ms.StoreMessageInfo(mi)
|
||||
}
|
||||
return ms
|
||||
}
|
||||
return mi.MessageOf(x)
|
||||
}
|
||||
|
||||
// Deprecated: Use MailUserRsp.ProtoReflect.Descriptor instead.
|
||||
func (*MailUserRsp) Descriptor() ([]byte, []int) {
|
||||
return file_test_proto_rawDescGZIP(), []int{1}
|
||||
}
|
||||
|
||||
func (x *MailUserRsp) GetStatus() string {
|
||||
if x != nil {
|
||||
return x.Status
|
||||
}
|
||||
return ""
|
||||
}
|
||||
|
||||
type UpdateUserReq struct {
|
||||
state protoimpl.MessageState
|
||||
sizeCache protoimpl.SizeCache
|
||||
unknownFields protoimpl.UnknownFields
|
||||
|
||||
Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"`
|
||||
}
|
||||
|
||||
func (x *UpdateUserReq) Reset() {
|
||||
*x = UpdateUserReq{}
|
||||
if protoimpl.UnsafeEnabled {
|
||||
mi := &file_test_proto_msgTypes[2]
|
||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||
ms.StoreMessageInfo(mi)
|
||||
}
|
||||
}
|
||||
|
||||
func (x *UpdateUserReq) String() string {
|
||||
return protoimpl.X.MessageStringOf(x)
|
||||
}
|
||||
|
||||
func (*UpdateUserReq) ProtoMessage() {}
|
||||
|
||||
func (x *UpdateUserReq) ProtoReflect() protoreflect.Message {
|
||||
mi := &file_test_proto_msgTypes[2]
|
||||
if protoimpl.UnsafeEnabled && x != nil {
|
||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||
if ms.LoadMessageInfo() == nil {
|
||||
ms.StoreMessageInfo(mi)
|
||||
}
|
||||
return ms
|
||||
}
|
||||
return mi.MessageOf(x)
|
||||
}
|
||||
|
||||
// Deprecated: Use UpdateUserReq.ProtoReflect.Descriptor instead.
|
||||
func (*UpdateUserReq) Descriptor() ([]byte, []int) {
|
||||
return file_test_proto_rawDescGZIP(), []int{2}
|
||||
}
|
||||
|
||||
func (x *UpdateUserReq) GetName() string {
|
||||
if x != nil {
|
||||
return x.Name
|
||||
}
|
||||
return ""
|
||||
}
|
||||
|
||||
type UpdateUserRsp struct {
|
||||
state protoimpl.MessageState
|
||||
sizeCache protoimpl.SizeCache
|
||||
unknownFields protoimpl.UnknownFields
|
||||
}
|
||||
|
||||
func (x *UpdateUserRsp) Reset() {
|
||||
*x = UpdateUserRsp{}
|
||||
if protoimpl.UnsafeEnabled {
|
||||
mi := &file_test_proto_msgTypes[3]
|
||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||
ms.StoreMessageInfo(mi)
|
||||
}
|
||||
}
|
||||
|
||||
func (x *UpdateUserRsp) String() string {
|
||||
return protoimpl.X.MessageStringOf(x)
|
||||
}
|
||||
|
||||
func (*UpdateUserRsp) ProtoMessage() {}
|
||||
|
||||
func (x *UpdateUserRsp) ProtoReflect() protoreflect.Message {
|
||||
mi := &file_test_proto_msgTypes[3]
|
||||
if protoimpl.UnsafeEnabled && x != nil {
|
||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||
if ms.LoadMessageInfo() == nil {
|
||||
ms.StoreMessageInfo(mi)
|
||||
}
|
||||
return ms
|
||||
}
|
||||
return mi.MessageOf(x)
|
||||
}
|
||||
|
||||
// Deprecated: Use UpdateUserRsp.ProtoReflect.Descriptor instead.
|
||||
func (*UpdateUserRsp) Descriptor() ([]byte, []int) {
|
||||
return file_test_proto_rawDescGZIP(), []int{3}
|
||||
}
|
||||
|
||||
type DeleteUserReq struct {
|
||||
state protoimpl.MessageState
|
||||
sizeCache protoimpl.SizeCache
|
||||
unknownFields protoimpl.UnknownFields
|
||||
|
||||
Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"`
|
||||
}
|
||||
|
||||
func (x *DeleteUserReq) Reset() {
|
||||
*x = DeleteUserReq{}
|
||||
if protoimpl.UnsafeEnabled {
|
||||
mi := &file_test_proto_msgTypes[4]
|
||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||
ms.StoreMessageInfo(mi)
|
||||
}
|
||||
}
|
||||
|
||||
func (x *DeleteUserReq) String() string {
|
||||
return protoimpl.X.MessageStringOf(x)
|
||||
}
|
||||
|
||||
func (*DeleteUserReq) ProtoMessage() {}
|
||||
|
||||
func (x *DeleteUserReq) ProtoReflect() protoreflect.Message {
|
||||
mi := &file_test_proto_msgTypes[4]
|
||||
if protoimpl.UnsafeEnabled && x != nil {
|
||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||
if ms.LoadMessageInfo() == nil {
|
||||
ms.StoreMessageInfo(mi)
|
||||
}
|
||||
return ms
|
||||
}
|
||||
return mi.MessageOf(x)
|
||||
}
|
||||
|
||||
// Deprecated: Use DeleteUserReq.ProtoReflect.Descriptor instead.
|
||||
func (*DeleteUserReq) Descriptor() ([]byte, []int) {
|
||||
return file_test_proto_rawDescGZIP(), []int{4}
|
||||
}
|
||||
|
||||
func (x *DeleteUserReq) GetName() string {
|
||||
if x != nil {
|
||||
return x.Name
|
||||
}
|
||||
return ""
|
||||
}
|
||||
|
||||
type DeleteUserRsp struct {
|
||||
state protoimpl.MessageState
|
||||
sizeCache protoimpl.SizeCache
|
||||
unknownFields protoimpl.UnknownFields
|
||||
}
|
||||
|
||||
func (x *DeleteUserRsp) Reset() {
|
||||
*x = DeleteUserRsp{}
|
||||
if protoimpl.UnsafeEnabled {
|
||||
mi := &file_test_proto_msgTypes[5]
|
||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||
ms.StoreMessageInfo(mi)
|
||||
}
|
||||
}
|
||||
|
||||
func (x *DeleteUserRsp) String() string {
|
||||
return protoimpl.X.MessageStringOf(x)
|
||||
}
|
||||
|
||||
func (*DeleteUserRsp) ProtoMessage() {}
|
||||
|
||||
func (x *DeleteUserRsp) ProtoReflect() protoreflect.Message {
|
||||
mi := &file_test_proto_msgTypes[5]
|
||||
if protoimpl.UnsafeEnabled && x != nil {
|
||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||
if ms.LoadMessageInfo() == nil {
|
||||
ms.StoreMessageInfo(mi)
|
||||
}
|
||||
return ms
|
||||
}
|
||||
return mi.MessageOf(x)
|
||||
}
|
||||
|
||||
// Deprecated: Use DeleteUserRsp.ProtoReflect.Descriptor instead.
|
||||
func (*DeleteUserRsp) Descriptor() ([]byte, []int) {
|
||||
return file_test_proto_rawDescGZIP(), []int{5}
|
||||
}
|
||||
|
||||
type LookupUserReq struct {
|
||||
state protoimpl.MessageState
|
||||
sizeCache protoimpl.SizeCache
|
||||
@ -35,7 +299,7 @@ type LookupUserReq struct {
|
||||
func (x *LookupUserReq) Reset() {
|
||||
*x = LookupUserReq{}
|
||||
if protoimpl.UnsafeEnabled {
|
||||
mi := &file_test_proto_msgTypes[0]
|
||||
mi := &file_test_proto_msgTypes[6]
|
||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||
ms.StoreMessageInfo(mi)
|
||||
}
|
||||
@ -48,7 +312,7 @@ func (x *LookupUserReq) String() string {
|
||||
func (*LookupUserReq) ProtoMessage() {}
|
||||
|
||||
func (x *LookupUserReq) ProtoReflect() protoreflect.Message {
|
||||
mi := &file_test_proto_msgTypes[0]
|
||||
mi := &file_test_proto_msgTypes[6]
|
||||
if protoimpl.UnsafeEnabled && x != nil {
|
||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||
if ms.LoadMessageInfo() == nil {
|
||||
@ -61,7 +325,7 @@ func (x *LookupUserReq) ProtoReflect() protoreflect.Message {
|
||||
|
||||
// Deprecated: Use LookupUserReq.ProtoReflect.Descriptor instead.
|
||||
func (*LookupUserReq) Descriptor() ([]byte, []int) {
|
||||
return file_test_proto_rawDescGZIP(), []int{0}
|
||||
return file_test_proto_rawDescGZIP(), []int{6}
|
||||
}
|
||||
|
||||
func (x *LookupUserReq) GetName() string {
|
||||
@ -82,7 +346,7 @@ type LookupUserRsp struct {
|
||||
func (x *LookupUserRsp) Reset() {
|
||||
*x = LookupUserRsp{}
|
||||
if protoimpl.UnsafeEnabled {
|
||||
mi := &file_test_proto_msgTypes[1]
|
||||
mi := &file_test_proto_msgTypes[7]
|
||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||
ms.StoreMessageInfo(mi)
|
||||
}
|
||||
@ -95,7 +359,7 @@ func (x *LookupUserRsp) String() string {
|
||||
func (*LookupUserRsp) ProtoMessage() {}
|
||||
|
||||
func (x *LookupUserRsp) ProtoReflect() protoreflect.Message {
|
||||
mi := &file_test_proto_msgTypes[1]
|
||||
mi := &file_test_proto_msgTypes[7]
|
||||
if protoimpl.UnsafeEnabled && x != nil {
|
||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||
if ms.LoadMessageInfo() == nil {
|
||||
@ -108,7 +372,7 @@ func (x *LookupUserRsp) ProtoReflect() protoreflect.Message {
|
||||
|
||||
// Deprecated: Use LookupUserRsp.ProtoReflect.Descriptor instead.
|
||||
func (*LookupUserRsp) Descriptor() ([]byte, []int) {
|
||||
return file_test_proto_rawDescGZIP(), []int{1}
|
||||
return file_test_proto_rawDescGZIP(), []int{7}
|
||||
}
|
||||
|
||||
func (x *LookupUserRsp) GetBirthday() string {
|
||||
@ -129,7 +393,7 @@ type Error struct {
|
||||
func (x *Error) Reset() {
|
||||
*x = Error{}
|
||||
if protoimpl.UnsafeEnabled {
|
||||
mi := &file_test_proto_msgTypes[2]
|
||||
mi := &file_test_proto_msgTypes[8]
|
||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||
ms.StoreMessageInfo(mi)
|
||||
}
|
||||
@ -142,7 +406,7 @@ func (x *Error) String() string {
|
||||
func (*Error) ProtoMessage() {}
|
||||
|
||||
func (x *Error) ProtoReflect() protoreflect.Message {
|
||||
mi := &file_test_proto_msgTypes[2]
|
||||
mi := &file_test_proto_msgTypes[8]
|
||||
if protoimpl.UnsafeEnabled && x != nil {
|
||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||
if ms.LoadMessageInfo() == nil {
|
||||
@ -155,7 +419,7 @@ func (x *Error) ProtoReflect() protoreflect.Message {
|
||||
|
||||
// Deprecated: Use Error.ProtoReflect.Descriptor instead.
|
||||
func (*Error) Descriptor() ([]byte, []int) {
|
||||
return file_test_proto_rawDescGZIP(), []int{2}
|
||||
return file_test_proto_rawDescGZIP(), []int{8}
|
||||
}
|
||||
|
||||
func (x *Error) GetMsg() string {
|
||||
@ -175,28 +439,68 @@ var file_test_proto_rawDesc = []byte{
|
||||
0x69, 0x76, 0x32, 0x2f, 0x61, 0x6e, 0x6e, 0x6f, 0x74, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x2e,
|
||||
0x70, 0x72, 0x6f, 0x74, 0x6f, 0x1a, 0x1e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2f, 0x70, 0x72,
|
||||
0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2f, 0x77, 0x72, 0x61, 0x70, 0x70, 0x65, 0x72, 0x73, 0x2e,
|
||||
0x70, 0x72, 0x6f, 0x74, 0x6f, 0x22, 0x23, 0x0a, 0x0d, 0x4c, 0x6f, 0x6f, 0x6b, 0x75, 0x70, 0x55,
|
||||
0x70, 0x72, 0x6f, 0x74, 0x6f, 0x22, 0x21, 0x0a, 0x0b, 0x4d, 0x61, 0x69, 0x6c, 0x55, 0x73, 0x65,
|
||||
0x72, 0x52, 0x65, 0x71, 0x12, 0x12, 0x0a, 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x18, 0x01, 0x20, 0x01,
|
||||
0x28, 0x09, 0x52, 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x22, 0x25, 0x0a, 0x0b, 0x4d, 0x61, 0x69, 0x6c,
|
||||
0x55, 0x73, 0x65, 0x72, 0x52, 0x73, 0x70, 0x12, 0x16, 0x0a, 0x06, 0x73, 0x74, 0x61, 0x74, 0x75,
|
||||
0x73, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x06, 0x73, 0x74, 0x61, 0x74, 0x75, 0x73, 0x22,
|
||||
0x23, 0x0a, 0x0d, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x55, 0x73, 0x65, 0x72, 0x52, 0x65, 0x71,
|
||||
0x12, 0x12, 0x0a, 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04,
|
||||
0x6e, 0x61, 0x6d, 0x65, 0x22, 0x0f, 0x0a, 0x0d, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x55, 0x73,
|
||||
0x65, 0x72, 0x52, 0x73, 0x70, 0x22, 0x23, 0x0a, 0x0d, 0x44, 0x65, 0x6c, 0x65, 0x74, 0x65, 0x55,
|
||||
0x73, 0x65, 0x72, 0x52, 0x65, 0x71, 0x12, 0x12, 0x0a, 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x18, 0x01,
|
||||
0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x22, 0x2b, 0x0a, 0x0d, 0x4c, 0x6f,
|
||||
0x6f, 0x6b, 0x75, 0x70, 0x55, 0x73, 0x65, 0x72, 0x52, 0x73, 0x70, 0x12, 0x1a, 0x0a, 0x08, 0x62,
|
||||
0x69, 0x72, 0x74, 0x68, 0x64, 0x61, 0x79, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x62,
|
||||
0x69, 0x72, 0x74, 0x68, 0x64, 0x61, 0x79, 0x22, 0x19, 0x0a, 0x05, 0x45, 0x72, 0x72, 0x6f, 0x72,
|
||||
0x12, 0x10, 0x0a, 0x03, 0x6d, 0x73, 0x67, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x03, 0x6d,
|
||||
0x73, 0x67, 0x32, 0xab, 0x01, 0x0a, 0x0b, 0x54, 0x65, 0x73, 0x74, 0x53, 0x65, 0x72, 0x76, 0x69,
|
||||
0x63, 0x65, 0x12, 0x9b, 0x01, 0x0a, 0x0a, 0x4c, 0x6f, 0x6f, 0x6b, 0x75, 0x70, 0x55, 0x73, 0x65,
|
||||
0x72, 0x12, 0x13, 0x2e, 0x74, 0x65, 0x73, 0x74, 0x2e, 0x4c, 0x6f, 0x6f, 0x6b, 0x75, 0x70, 0x55,
|
||||
0x73, 0x65, 0x72, 0x52, 0x65, 0x71, 0x1a, 0x13, 0x2e, 0x74, 0x65, 0x73, 0x74, 0x2e, 0x4c, 0x6f,
|
||||
0x6f, 0x6b, 0x75, 0x70, 0x55, 0x73, 0x65, 0x72, 0x52, 0x73, 0x70, 0x22, 0x63, 0x92, 0x41, 0x3a,
|
||||
0x2a, 0x0a, 0x4c, 0x6f, 0x6f, 0x6b, 0x75, 0x70, 0x55, 0x73, 0x65, 0x72, 0x4a, 0x2c, 0x0a, 0x07,
|
||||
0x64, 0x65, 0x66, 0x61, 0x75, 0x6c, 0x74, 0x12, 0x21, 0x0a, 0x0e, 0x45, 0x72, 0x72, 0x6f, 0x72,
|
||||
0x20, 0x72, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x0f, 0x0a, 0x0d, 0x1a, 0x0b, 0x2e,
|
||||
0x74, 0x65, 0x73, 0x74, 0x2e, 0x45, 0x72, 0x72, 0x6f, 0x72, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x18,
|
||||
0x12, 0x16, 0x2f, 0x76, 0x31, 0x2f, 0x75, 0x73, 0x65, 0x72, 0x2f, 0x6c, 0x6f, 0x6f, 0x6b, 0x75,
|
||||
0x70, 0x2f, 0x7b, 0x6e, 0x61, 0x6d, 0x65, 0x7d, 0xba, 0xea, 0xff, 0xf9, 0x01, 0x02, 0x08, 0x05,
|
||||
0x42, 0x33, 0x5a, 0x31, 0x67, 0x69, 0x74, 0x68, 0x75, 0x62, 0x2e, 0x63, 0x6f, 0x6d, 0x2f, 0x75,
|
||||
0x6e, 0x69, 0x73, 0x74, 0x61, 0x63, 0x6b, 0x2d, 0x6f, 0x72, 0x67, 0x2f, 0x6d, 0x69, 0x63, 0x72,
|
||||
0x6f, 0x2d, 0x74, 0x65, 0x73, 0x74, 0x73, 0x2f, 0x66, 0x6c, 0x6f, 0x77, 0x2f, 0x70, 0x72, 0x6f,
|
||||
0x74, 0x6f, 0x3b, 0x70, 0x62, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33,
|
||||
0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x22, 0x0f, 0x0a, 0x0d, 0x44, 0x65,
|
||||
0x6c, 0x65, 0x74, 0x65, 0x55, 0x73, 0x65, 0x72, 0x52, 0x73, 0x70, 0x22, 0x23, 0x0a, 0x0d, 0x4c,
|
||||
0x6f, 0x6f, 0x6b, 0x75, 0x70, 0x55, 0x73, 0x65, 0x72, 0x52, 0x65, 0x71, 0x12, 0x12, 0x0a, 0x04,
|
||||
0x6e, 0x61, 0x6d, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x6e, 0x61, 0x6d, 0x65,
|
||||
0x22, 0x2b, 0x0a, 0x0d, 0x4c, 0x6f, 0x6f, 0x6b, 0x75, 0x70, 0x55, 0x73, 0x65, 0x72, 0x52, 0x73,
|
||||
0x70, 0x12, 0x1a, 0x0a, 0x08, 0x62, 0x69, 0x72, 0x74, 0x68, 0x64, 0x61, 0x79, 0x18, 0x01, 0x20,
|
||||
0x01, 0x28, 0x09, 0x52, 0x08, 0x62, 0x69, 0x72, 0x74, 0x68, 0x64, 0x61, 0x79, 0x22, 0x19, 0x0a,
|
||||
0x05, 0x45, 0x72, 0x72, 0x6f, 0x72, 0x12, 0x10, 0x0a, 0x03, 0x6d, 0x73, 0x67, 0x18, 0x01, 0x20,
|
||||
0x01, 0x28, 0x09, 0x52, 0x03, 0x6d, 0x73, 0x67, 0x32, 0xec, 0x04, 0x0a, 0x0b, 0x54, 0x65, 0x73,
|
||||
0x74, 0x53, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x12, 0x94, 0x01, 0x0a, 0x0a, 0x4c, 0x6f, 0x6f,
|
||||
0x6b, 0x75, 0x70, 0x55, 0x73, 0x65, 0x72, 0x12, 0x13, 0x2e, 0x74, 0x65, 0x73, 0x74, 0x2e, 0x4c,
|
||||
0x6f, 0x6f, 0x6b, 0x75, 0x70, 0x55, 0x73, 0x65, 0x72, 0x52, 0x65, 0x71, 0x1a, 0x13, 0x2e, 0x74,
|
||||
0x65, 0x73, 0x74, 0x2e, 0x4c, 0x6f, 0x6f, 0x6b, 0x75, 0x70, 0x55, 0x73, 0x65, 0x72, 0x52, 0x73,
|
||||
0x70, 0x22, 0x5c, 0x92, 0x41, 0x3a, 0x2a, 0x0a, 0x4c, 0x6f, 0x6f, 0x6b, 0x75, 0x70, 0x55, 0x73,
|
||||
0x65, 0x72, 0x4a, 0x2c, 0x0a, 0x07, 0x64, 0x65, 0x66, 0x61, 0x75, 0x6c, 0x74, 0x12, 0x21, 0x0a,
|
||||
0x0e, 0x45, 0x72, 0x72, 0x6f, 0x72, 0x20, 0x72, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12,
|
||||
0x0f, 0x0a, 0x0d, 0x1a, 0x0b, 0x2e, 0x74, 0x65, 0x73, 0x74, 0x2e, 0x45, 0x72, 0x72, 0x6f, 0x72,
|
||||
0x82, 0xd3, 0xe4, 0x93, 0x02, 0x11, 0x12, 0x0f, 0x2f, 0x76, 0x31, 0x2f, 0x75, 0x73, 0x65, 0x72,
|
||||
0x2f, 0x7b, 0x6e, 0x61, 0x6d, 0x65, 0x7d, 0xba, 0xea, 0xff, 0xf9, 0x01, 0x02, 0x08, 0x05, 0x12,
|
||||
0x97, 0x01, 0x0a, 0x0a, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x55, 0x73, 0x65, 0x72, 0x12, 0x13,
|
||||
0x2e, 0x74, 0x65, 0x73, 0x74, 0x2e, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x55, 0x73, 0x65, 0x72,
|
||||
0x52, 0x65, 0x71, 0x1a, 0x13, 0x2e, 0x74, 0x65, 0x73, 0x74, 0x2e, 0x55, 0x70, 0x64, 0x61, 0x74,
|
||||
0x65, 0x55, 0x73, 0x65, 0x72, 0x52, 0x73, 0x70, 0x22, 0x5f, 0x92, 0x41, 0x3a, 0x2a, 0x0a, 0x55,
|
||||
0x70, 0x64, 0x61, 0x74, 0x65, 0x55, 0x73, 0x65, 0x72, 0x4a, 0x2c, 0x0a, 0x07, 0x64, 0x65, 0x66,
|
||||
0x61, 0x75, 0x6c, 0x74, 0x12, 0x21, 0x0a, 0x0e, 0x45, 0x72, 0x72, 0x6f, 0x72, 0x20, 0x72, 0x65,
|
||||
0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x0f, 0x0a, 0x0d, 0x1a, 0x0b, 0x2e, 0x74, 0x65, 0x73,
|
||||
0x74, 0x2e, 0x45, 0x72, 0x72, 0x6f, 0x72, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x14, 0x1a, 0x0f, 0x2f,
|
||||
0x76, 0x31, 0x2f, 0x75, 0x73, 0x65, 0x72, 0x2f, 0x7b, 0x6e, 0x61, 0x6d, 0x65, 0x7d, 0x3a, 0x01,
|
||||
0x2a, 0xba, 0xea, 0xff, 0xf9, 0x01, 0x02, 0x08, 0x05, 0x12, 0x94, 0x01, 0x0a, 0x0a, 0x44, 0x65,
|
||||
0x6c, 0x65, 0x74, 0x65, 0x55, 0x73, 0x65, 0x72, 0x12, 0x13, 0x2e, 0x74, 0x65, 0x73, 0x74, 0x2e,
|
||||
0x44, 0x65, 0x6c, 0x65, 0x74, 0x65, 0x55, 0x73, 0x65, 0x72, 0x52, 0x65, 0x71, 0x1a, 0x13, 0x2e,
|
||||
0x74, 0x65, 0x73, 0x74, 0x2e, 0x44, 0x65, 0x6c, 0x65, 0x74, 0x65, 0x55, 0x73, 0x65, 0x72, 0x52,
|
||||
0x73, 0x70, 0x22, 0x5c, 0x92, 0x41, 0x3a, 0x2a, 0x0a, 0x44, 0x65, 0x6c, 0x65, 0x74, 0x65, 0x55,
|
||||
0x73, 0x65, 0x72, 0x4a, 0x2c, 0x0a, 0x07, 0x64, 0x65, 0x66, 0x61, 0x75, 0x6c, 0x74, 0x12, 0x21,
|
||||
0x0a, 0x0e, 0x45, 0x72, 0x72, 0x6f, 0x72, 0x20, 0x72, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65,
|
||||
0x12, 0x0f, 0x0a, 0x0d, 0x1a, 0x0b, 0x2e, 0x74, 0x65, 0x73, 0x74, 0x2e, 0x45, 0x72, 0x72, 0x6f,
|
||||
0x72, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x11, 0x2a, 0x0f, 0x2f, 0x76, 0x31, 0x2f, 0x75, 0x73, 0x65,
|
||||
0x72, 0x2f, 0x7b, 0x6e, 0x61, 0x6d, 0x65, 0x7d, 0xba, 0xea, 0xff, 0xf9, 0x01, 0x02, 0x08, 0x05,
|
||||
0x12, 0x94, 0x01, 0x0a, 0x08, 0x4d, 0x61, 0x69, 0x6c, 0x55, 0x73, 0x65, 0x72, 0x12, 0x11, 0x2e,
|
||||
0x74, 0x65, 0x73, 0x74, 0x2e, 0x4d, 0x61, 0x69, 0x6c, 0x55, 0x73, 0x65, 0x72, 0x52, 0x65, 0x71,
|
||||
0x1a, 0x11, 0x2e, 0x74, 0x65, 0x73, 0x74, 0x2e, 0x4d, 0x61, 0x69, 0x6c, 0x55, 0x73, 0x65, 0x72,
|
||||
0x52, 0x73, 0x70, 0x22, 0x62, 0x92, 0x41, 0x38, 0x2a, 0x08, 0x4d, 0x61, 0x69, 0x6c, 0x55, 0x73,
|
||||
0x65, 0x72, 0x4a, 0x2c, 0x0a, 0x07, 0x64, 0x65, 0x66, 0x61, 0x75, 0x6c, 0x74, 0x12, 0x21, 0x0a,
|
||||
0x0e, 0x45, 0x72, 0x72, 0x6f, 0x72, 0x20, 0x72, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12,
|
||||
0x0f, 0x0a, 0x0d, 0x1a, 0x0b, 0x2e, 0x74, 0x65, 0x73, 0x74, 0x2e, 0x45, 0x72, 0x72, 0x6f, 0x72,
|
||||
0x82, 0xd3, 0xe4, 0x93, 0x02, 0x19, 0x22, 0x14, 0x2f, 0x76, 0x31, 0x2f, 0x75, 0x73, 0x65, 0x72,
|
||||
0x2f, 0x7b, 0x6e, 0x61, 0x6d, 0x65, 0x7d, 0x2f, 0x6d, 0x61, 0x69, 0x6c, 0x3a, 0x01, 0x2a, 0xba,
|
||||
0xea, 0xff, 0xf9, 0x01, 0x02, 0x08, 0x05, 0x42, 0x33, 0x5a, 0x31, 0x67, 0x69, 0x74, 0x68, 0x75,
|
||||
0x62, 0x2e, 0x63, 0x6f, 0x6d, 0x2f, 0x75, 0x6e, 0x69, 0x73, 0x74, 0x61, 0x63, 0x6b, 0x2d, 0x6f,
|
||||
0x72, 0x67, 0x2f, 0x6d, 0x69, 0x63, 0x72, 0x6f, 0x2d, 0x74, 0x65, 0x73, 0x74, 0x73, 0x2f, 0x66,
|
||||
0x6c, 0x6f, 0x77, 0x2f, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x3b, 0x70, 0x62, 0x62, 0x06, 0x70, 0x72,
|
||||
0x6f, 0x74, 0x6f, 0x33,
|
||||
}
|
||||
|
||||
var (
|
||||
@ -211,17 +515,29 @@ func file_test_proto_rawDescGZIP() []byte {
|
||||
return file_test_proto_rawDescData
|
||||
}
|
||||
|
||||
var file_test_proto_msgTypes = make([]protoimpl.MessageInfo, 3)
|
||||
var file_test_proto_msgTypes = make([]protoimpl.MessageInfo, 9)
|
||||
var file_test_proto_goTypes = []interface{}{
|
||||
(*LookupUserReq)(nil), // 0: test.LookupUserReq
|
||||
(*LookupUserRsp)(nil), // 1: test.LookupUserRsp
|
||||
(*Error)(nil), // 2: test.Error
|
||||
(*MailUserReq)(nil), // 0: test.MailUserReq
|
||||
(*MailUserRsp)(nil), // 1: test.MailUserRsp
|
||||
(*UpdateUserReq)(nil), // 2: test.UpdateUserReq
|
||||
(*UpdateUserRsp)(nil), // 3: test.UpdateUserRsp
|
||||
(*DeleteUserReq)(nil), // 4: test.DeleteUserReq
|
||||
(*DeleteUserRsp)(nil), // 5: test.DeleteUserRsp
|
||||
(*LookupUserReq)(nil), // 6: test.LookupUserReq
|
||||
(*LookupUserRsp)(nil), // 7: test.LookupUserRsp
|
||||
(*Error)(nil), // 8: test.Error
|
||||
}
|
||||
var file_test_proto_depIdxs = []int32{
|
||||
0, // 0: test.TestService.LookupUser:input_type -> test.LookupUserReq
|
||||
1, // 1: test.TestService.LookupUser:output_type -> test.LookupUserRsp
|
||||
1, // [1:2] is the sub-list for method output_type
|
||||
0, // [0:1] is the sub-list for method input_type
|
||||
6, // 0: test.TestService.LookupUser:input_type -> test.LookupUserReq
|
||||
2, // 1: test.TestService.UpdateUser:input_type -> test.UpdateUserReq
|
||||
4, // 2: test.TestService.DeleteUser:input_type -> test.DeleteUserReq
|
||||
0, // 3: test.TestService.MailUser:input_type -> test.MailUserReq
|
||||
7, // 4: test.TestService.LookupUser:output_type -> test.LookupUserRsp
|
||||
3, // 5: test.TestService.UpdateUser:output_type -> test.UpdateUserRsp
|
||||
5, // 6: test.TestService.DeleteUser:output_type -> test.DeleteUserRsp
|
||||
1, // 7: test.TestService.MailUser:output_type -> test.MailUserRsp
|
||||
4, // [4:8] is the sub-list for method output_type
|
||||
0, // [0:4] is the sub-list for method input_type
|
||||
0, // [0:0] is the sub-list for extension type_name
|
||||
0, // [0:0] is the sub-list for extension extendee
|
||||
0, // [0:0] is the sub-list for field type_name
|
||||
@ -234,7 +550,7 @@ func file_test_proto_init() {
|
||||
}
|
||||
if !protoimpl.UnsafeEnabled {
|
||||
file_test_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} {
|
||||
switch v := v.(*LookupUserReq); i {
|
||||
switch v := v.(*MailUserReq); i {
|
||||
case 0:
|
||||
return &v.state
|
||||
case 1:
|
||||
@ -246,7 +562,7 @@ func file_test_proto_init() {
|
||||
}
|
||||
}
|
||||
file_test_proto_msgTypes[1].Exporter = func(v interface{}, i int) interface{} {
|
||||
switch v := v.(*LookupUserRsp); i {
|
||||
switch v := v.(*MailUserRsp); i {
|
||||
case 0:
|
||||
return &v.state
|
||||
case 1:
|
||||
@ -258,6 +574,78 @@ func file_test_proto_init() {
|
||||
}
|
||||
}
|
||||
file_test_proto_msgTypes[2].Exporter = func(v interface{}, i int) interface{} {
|
||||
switch v := v.(*UpdateUserReq); i {
|
||||
case 0:
|
||||
return &v.state
|
||||
case 1:
|
||||
return &v.sizeCache
|
||||
case 2:
|
||||
return &v.unknownFields
|
||||
default:
|
||||
return nil
|
||||
}
|
||||
}
|
||||
file_test_proto_msgTypes[3].Exporter = func(v interface{}, i int) interface{} {
|
||||
switch v := v.(*UpdateUserRsp); i {
|
||||
case 0:
|
||||
return &v.state
|
||||
case 1:
|
||||
return &v.sizeCache
|
||||
case 2:
|
||||
return &v.unknownFields
|
||||
default:
|
||||
return nil
|
||||
}
|
||||
}
|
||||
file_test_proto_msgTypes[4].Exporter = func(v interface{}, i int) interface{} {
|
||||
switch v := v.(*DeleteUserReq); i {
|
||||
case 0:
|
||||
return &v.state
|
||||
case 1:
|
||||
return &v.sizeCache
|
||||
case 2:
|
||||
return &v.unknownFields
|
||||
default:
|
||||
return nil
|
||||
}
|
||||
}
|
||||
file_test_proto_msgTypes[5].Exporter = func(v interface{}, i int) interface{} {
|
||||
switch v := v.(*DeleteUserRsp); i {
|
||||
case 0:
|
||||
return &v.state
|
||||
case 1:
|
||||
return &v.sizeCache
|
||||
case 2:
|
||||
return &v.unknownFields
|
||||
default:
|
||||
return nil
|
||||
}
|
||||
}
|
||||
file_test_proto_msgTypes[6].Exporter = func(v interface{}, i int) interface{} {
|
||||
switch v := v.(*LookupUserReq); i {
|
||||
case 0:
|
||||
return &v.state
|
||||
case 1:
|
||||
return &v.sizeCache
|
||||
case 2:
|
||||
return &v.unknownFields
|
||||
default:
|
||||
return nil
|
||||
}
|
||||
}
|
||||
file_test_proto_msgTypes[7].Exporter = func(v interface{}, i int) interface{} {
|
||||
switch v := v.(*LookupUserRsp); i {
|
||||
case 0:
|
||||
return &v.state
|
||||
case 1:
|
||||
return &v.sizeCache
|
||||
case 2:
|
||||
return &v.unknownFields
|
||||
default:
|
||||
return nil
|
||||
}
|
||||
}
|
||||
file_test_proto_msgTypes[8].Exporter = func(v interface{}, i int) interface{} {
|
||||
switch v := v.(*Error); i {
|
||||
case 0:
|
||||
return &v.state
|
||||
@ -276,7 +664,7 @@ func file_test_proto_init() {
|
||||
GoPackagePath: reflect.TypeOf(x{}).PkgPath(),
|
||||
RawDescriptor: file_test_proto_rawDesc,
|
||||
NumEnums: 0,
|
||||
NumMessages: 3,
|
||||
NumMessages: 9,
|
||||
NumExtensions: 0,
|
||||
NumServices: 1,
|
||||
},
|
||||
|
@ -26,9 +26,87 @@ service TestService {
|
||||
}
|
||||
}
|
||||
};
|
||||
option (micro.api.http) = { get: "/v1/user/lookup/{name}"; };
|
||||
option (micro.api.http) = { get: "/v1/user/{name}"; };
|
||||
option (micro.api.micro_method) = { timeout: 5; };
|
||||
};
|
||||
rpc UpdateUser(UpdateUserReq) returns (UpdateUserRsp) {
|
||||
option (micro.openapiv2.openapiv2_operation) = {
|
||||
operation_id: "UpdateUser";
|
||||
responses: {
|
||||
key: "default";
|
||||
value: {
|
||||
description: "Error response";
|
||||
schema: {
|
||||
json_schema: {
|
||||
ref: ".test.Error";
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
};
|
||||
option (micro.api.http) = { put: "/v1/user/{name}"; body:"*"; };
|
||||
option (micro.api.micro_method) = { timeout: 5; };
|
||||
};
|
||||
rpc DeleteUser(DeleteUserReq) returns (DeleteUserRsp) {
|
||||
option (micro.openapiv2.openapiv2_operation) = {
|
||||
operation_id: "DeleteUser";
|
||||
responses: {
|
||||
key: "default";
|
||||
value: {
|
||||
description: "Error response";
|
||||
schema: {
|
||||
json_schema: {
|
||||
ref: ".test.Error";
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
};
|
||||
option (micro.api.http) = { delete: "/v1/user/{name}"; };
|
||||
option (micro.api.micro_method) = { timeout: 5; };
|
||||
};
|
||||
rpc MailUser(MailUserReq) returns (MailUserRsp) {
|
||||
option (micro.openapiv2.openapiv2_operation) = {
|
||||
operation_id: "MailUser";
|
||||
responses: {
|
||||
key: "default";
|
||||
value: {
|
||||
description: "Error response";
|
||||
schema: {
|
||||
json_schema: {
|
||||
ref: ".test.Error";
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
};
|
||||
option (micro.api.http) = { post: "/v1/user/{name}/mail"; body:"*"; };
|
||||
option (micro.api.micro_method) = { timeout: 5; };
|
||||
};
|
||||
};
|
||||
|
||||
message MailUserReq {
|
||||
string name = 1;
|
||||
};
|
||||
|
||||
message MailUserRsp {
|
||||
string status = 1;
|
||||
};
|
||||
|
||||
message UpdateUserReq {
|
||||
string name = 1;
|
||||
};
|
||||
|
||||
message UpdateUserRsp {
|
||||
|
||||
};
|
||||
|
||||
message DeleteUserReq {
|
||||
string name = 1;
|
||||
};
|
||||
|
||||
message DeleteUserRsp {
|
||||
|
||||
};
|
||||
|
||||
message LookupUserReq {
|
||||
|
@ -1,5 +1,5 @@
|
||||
// Code generated by protoc-gen-go-micro. DO NOT EDIT.
|
||||
// protoc-gen-go-micro version: v3.4.1
|
||||
// protoc-gen-go-micro version: v3.4.2
|
||||
// source: test.proto
|
||||
|
||||
package pb
|
||||
@ -16,10 +16,30 @@ var (
|
||||
TestServiceEndpoints = []api.Endpoint{
|
||||
api.Endpoint{
|
||||
Name: "TestService.LookupUser",
|
||||
Path: []string{"/v1/user/lookup/{name}"},
|
||||
Path: []string{"/v1/user/{name}"},
|
||||
Method: []string{"GET"},
|
||||
Handler: "rpc",
|
||||
},
|
||||
api.Endpoint{
|
||||
Name: "TestService.UpdateUser",
|
||||
Path: []string{"/v1/user/{name}"},
|
||||
Method: []string{"PUT"},
|
||||
Body: "*",
|
||||
Handler: "rpc",
|
||||
},
|
||||
api.Endpoint{
|
||||
Name: "TestService.DeleteUser",
|
||||
Path: []string{"/v1/user/{name}"},
|
||||
Method: []string{"DELETE"},
|
||||
Handler: "rpc",
|
||||
},
|
||||
api.Endpoint{
|
||||
Name: "TestService.MailUser",
|
||||
Path: []string{"/v1/user/{name}/mail"},
|
||||
Method: []string{"POST"},
|
||||
Body: "*",
|
||||
Handler: "rpc",
|
||||
},
|
||||
}
|
||||
)
|
||||
|
||||
@ -29,8 +49,14 @@ func NewTestServiceEndpoints() []api.Endpoint {
|
||||
|
||||
type TestServiceClient interface {
|
||||
LookupUser(ctx context.Context, req *LookupUserReq, opts ...client.CallOption) (*LookupUserRsp, error)
|
||||
UpdateUser(ctx context.Context, req *UpdateUserReq, opts ...client.CallOption) (*UpdateUserRsp, error)
|
||||
DeleteUser(ctx context.Context, req *DeleteUserReq, opts ...client.CallOption) (*DeleteUserRsp, error)
|
||||
MailUser(ctx context.Context, req *MailUserReq, opts ...client.CallOption) (*MailUserRsp, error)
|
||||
}
|
||||
|
||||
type TestServiceServer interface {
|
||||
LookupUser(ctx context.Context, req *LookupUserReq, rsp *LookupUserRsp) error
|
||||
UpdateUser(ctx context.Context, req *UpdateUserReq, rsp *UpdateUserRsp) error
|
||||
DeleteUser(ctx context.Context, req *DeleteUserReq, rsp *DeleteUserRsp) error
|
||||
MailUser(ctx context.Context, req *MailUserReq, rsp *MailUserRsp) error
|
||||
}
|
||||
|
@ -1,18 +1,17 @@
|
||||
// Code generated by protoc-gen-go-micro. DO NOT EDIT.
|
||||
// protoc-gen-go-micro version: v3.4.1
|
||||
// protoc-gen-go-micro version: v3.4.2
|
||||
// source: test.proto
|
||||
|
||||
package pb
|
||||
|
||||
import (
|
||||
context "context"
|
||||
http "net/http"
|
||||
time "time"
|
||||
|
||||
v3 "github.com/unistack-org/micro-client-http/v3"
|
||||
api "github.com/unistack-org/micro/v3/api"
|
||||
client "github.com/unistack-org/micro/v3/client"
|
||||
server "github.com/unistack-org/micro/v3/server"
|
||||
http "net/http"
|
||||
time "time"
|
||||
)
|
||||
|
||||
type testServiceClient struct {
|
||||
@ -32,7 +31,7 @@ func (c *testServiceClient) LookupUser(ctx context.Context, req *LookupUserReq,
|
||||
)
|
||||
opts = append(opts,
|
||||
v3.Method(http.MethodGet),
|
||||
v3.Path("/v1/user/lookup/{name}"),
|
||||
v3.Path("/v1/user/{name}"),
|
||||
)
|
||||
opts = append(opts, client.WithRequestTimeout(time.Second*5))
|
||||
rsp := &LookupUserRsp{}
|
||||
@ -43,6 +42,65 @@ func (c *testServiceClient) LookupUser(ctx context.Context, req *LookupUserReq,
|
||||
return rsp, nil
|
||||
}
|
||||
|
||||
func (c *testServiceClient) UpdateUser(ctx context.Context, req *UpdateUserReq, opts ...client.CallOption) (*UpdateUserRsp, error) {
|
||||
errmap := make(map[string]interface{}, 1)
|
||||
errmap["default"] = &Error{}
|
||||
opts = append(opts,
|
||||
v3.ErrorMap(errmap),
|
||||
)
|
||||
opts = append(opts,
|
||||
v3.Method(http.MethodPut),
|
||||
v3.Path("/v1/user/{name}"),
|
||||
v3.Body("*"),
|
||||
)
|
||||
opts = append(opts, client.WithRequestTimeout(time.Second*5))
|
||||
rsp := &UpdateUserRsp{}
|
||||
err := c.c.Call(ctx, c.c.NewRequest(c.name, "TestService.UpdateUser", req), rsp, opts...)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
return rsp, nil
|
||||
}
|
||||
|
||||
func (c *testServiceClient) DeleteUser(ctx context.Context, req *DeleteUserReq, opts ...client.CallOption) (*DeleteUserRsp, error) {
|
||||
errmap := make(map[string]interface{}, 1)
|
||||
errmap["default"] = &Error{}
|
||||
opts = append(opts,
|
||||
v3.ErrorMap(errmap),
|
||||
)
|
||||
opts = append(opts,
|
||||
v3.Method(http.MethodDelete),
|
||||
v3.Path("/v1/user/{name}"),
|
||||
)
|
||||
opts = append(opts, client.WithRequestTimeout(time.Second*5))
|
||||
rsp := &DeleteUserRsp{}
|
||||
err := c.c.Call(ctx, c.c.NewRequest(c.name, "TestService.DeleteUser", req), rsp, opts...)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
return rsp, nil
|
||||
}
|
||||
|
||||
func (c *testServiceClient) MailUser(ctx context.Context, req *MailUserReq, opts ...client.CallOption) (*MailUserRsp, error) {
|
||||
errmap := make(map[string]interface{}, 1)
|
||||
errmap["default"] = &Error{}
|
||||
opts = append(opts,
|
||||
v3.ErrorMap(errmap),
|
||||
)
|
||||
opts = append(opts,
|
||||
v3.Method(http.MethodPost),
|
||||
v3.Path("/v1/user/{name}/mail"),
|
||||
v3.Body("*"),
|
||||
)
|
||||
opts = append(opts, client.WithRequestTimeout(time.Second*5))
|
||||
rsp := &MailUserRsp{}
|
||||
err := c.c.Call(ctx, c.c.NewRequest(c.name, "TestService.MailUser", req), rsp, opts...)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
return rsp, nil
|
||||
}
|
||||
|
||||
type testServiceServer struct {
|
||||
TestServiceServer
|
||||
}
|
||||
@ -54,9 +112,33 @@ func (h *testServiceServer) LookupUser(ctx context.Context, req *LookupUserReq,
|
||||
return h.TestServiceServer.LookupUser(ctx, req, rsp)
|
||||
}
|
||||
|
||||
func (h *testServiceServer) UpdateUser(ctx context.Context, req *UpdateUserReq, rsp *UpdateUserRsp) error {
|
||||
var cancel context.CancelFunc
|
||||
ctx, cancel = context.WithTimeout(ctx, time.Second*5)
|
||||
defer cancel()
|
||||
return h.TestServiceServer.UpdateUser(ctx, req, rsp)
|
||||
}
|
||||
|
||||
func (h *testServiceServer) DeleteUser(ctx context.Context, req *DeleteUserReq, rsp *DeleteUserRsp) error {
|
||||
var cancel context.CancelFunc
|
||||
ctx, cancel = context.WithTimeout(ctx, time.Second*5)
|
||||
defer cancel()
|
||||
return h.TestServiceServer.DeleteUser(ctx, req, rsp)
|
||||
}
|
||||
|
||||
func (h *testServiceServer) MailUser(ctx context.Context, req *MailUserReq, rsp *MailUserRsp) error {
|
||||
var cancel context.CancelFunc
|
||||
ctx, cancel = context.WithTimeout(ctx, time.Second*5)
|
||||
defer cancel()
|
||||
return h.TestServiceServer.MailUser(ctx, req, rsp)
|
||||
}
|
||||
|
||||
func RegisterTestServiceServer(s server.Server, sh TestServiceServer, opts ...server.HandlerOption) error {
|
||||
type testService interface {
|
||||
LookupUser(ctx context.Context, req *LookupUserReq, rsp *LookupUserRsp) error
|
||||
UpdateUser(ctx context.Context, req *UpdateUserReq, rsp *UpdateUserRsp) error
|
||||
DeleteUser(ctx context.Context, req *DeleteUserReq, rsp *DeleteUserRsp) error
|
||||
MailUser(ctx context.Context, req *MailUserReq, rsp *MailUserRsp) error
|
||||
}
|
||||
type TestService struct {
|
||||
testService
|
||||
|
13
go.mod
13
go.mod
@ -3,18 +3,20 @@ module github.com/unistack-org/micro-tests
|
||||
go 1.16
|
||||
|
||||
require (
|
||||
github.com/google/uuid v1.2.0
|
||||
github.com/google/uuid v1.3.0
|
||||
github.com/opentracing/opentracing-go v1.2.0
|
||||
github.com/prometheus/client_golang v1.10.0
|
||||
github.com/prometheus/client_model v0.2.0
|
||||
github.com/segmentio/kafka-go v0.4.16
|
||||
github.com/stretchr/testify v1.7.0
|
||||
github.com/unistack-org/micro-api-handler-rpc/v3 v3.3.0
|
||||
github.com/unistack-org/micro-api-router-register/v3 v3.2.2
|
||||
github.com/unistack-org/micro-api-router-static/v3 v3.2.1
|
||||
github.com/unistack-org/micro-broker-http/v3 v3.3.1
|
||||
github.com/unistack-org/micro-broker-segmentio/v3 v3.0.0-00010101000000-000000000000
|
||||
//github.com/unistack-org/micro-client-drpc/v3 v3.0.0-00010101000000-000000000000
|
||||
github.com/unistack-org/micro-client-grpc/v3 v3.3.3
|
||||
github.com/unistack-org/micro-client-http/v3 v3.4.0
|
||||
github.com/unistack-org/micro-client-http/v3 v3.4.5
|
||||
github.com/unistack-org/micro-codec-grpc/v3 v3.2.1
|
||||
github.com/unistack-org/micro-codec-json/v3 v3.2.1
|
||||
github.com/unistack-org/micro-codec-jsonpb/v3 v3.2.2
|
||||
@ -29,10 +31,10 @@ require (
|
||||
github.com/unistack-org/micro-proto v0.0.2
|
||||
github.com/unistack-org/micro-router-register/v3 v3.2.2
|
||||
github.com/unistack-org/micro-server-grpc/v3 v3.3.6
|
||||
github.com/unistack-org/micro-server-http/v3 v3.3.19
|
||||
github.com/unistack-org/micro-server-http/v3 v3.4.1
|
||||
github.com/unistack-org/micro-server-tcp/v3 v3.3.2
|
||||
github.com/unistack-org/micro-wrapper-trace-opentracing/v3 v3.2.0
|
||||
github.com/unistack-org/micro/v3 v3.4.5
|
||||
github.com/unistack-org/micro/v3 v3.4.9
|
||||
golang.org/x/sys v0.0.0-20210630005230-0f9fa26af87c // indirect
|
||||
google.golang.org/genproto v0.0.0-20210630183607-d20f26d13c79
|
||||
google.golang.org/grpc v1.39.0
|
||||
@ -46,5 +48,8 @@ require (
|
||||
//replace github.com/unistack-org/micro-server-http/v3 => ../micro-server-http
|
||||
//replace github.com/unistack-org/micro-client-http/v3 => ../micro-client-http
|
||||
//replace github.com/unistack-org/micro-client-drpc/v3 => ../micro-client-drpc
|
||||
replace github.com/unistack-org/micro-broker-segmentio/v3 => ../micro-broker-segmentio
|
||||
|
||||
//replace github.com/unistack-org/micro/v3 => ../micro
|
||||
|
||||
//replace github.com/unistack-org/micro-proto => ../micro-proto
|
||||
|
34
go.sum
34
go.sum
@ -119,6 +119,7 @@ github.com/docker/go-connections v0.4.0/go.mod h1:Gbd7IOopHjR8Iph03tsViu4nIes5Xh
|
||||
github.com/docker/go-units v0.4.0/go.mod h1:fgPhTUdO+D/Jk86RDLlptpiXQzgHJF7gydDDbaIK4Dk=
|
||||
github.com/dustin/go-humanize v0.0.0-20171111073723-bb3d318650d4/go.mod h1:HtrtbFcZ19U5GC7JDqmcUSB87Iq5E25KnS6fMYU6eOk=
|
||||
github.com/eapache/go-resiliency v1.1.0/go.mod h1:kFI+JgMyC7bLPUVY133qvEBtVayf5mFgVsvEsIPBvNs=
|
||||
github.com/eapache/go-xerial-snappy v0.0.0-20180814174437-776d5712da21 h1:YEetp8/yCZMuEPMUDHG0CW/brkkEp8mzqk2+ODEitlw=
|
||||
github.com/eapache/go-xerial-snappy v0.0.0-20180814174437-776d5712da21/go.mod h1:+020luEh2TKB4/GOp8oxxtq0Daoen/Cii55CzbTV6DU=
|
||||
github.com/eapache/queue v1.1.0/go.mod h1:6eCeP0CKFpHLu8blIFXhExK/dRa7WDZfr6jVFPTqq+I=
|
||||
github.com/edsrzf/mmap-go v1.0.0/go.mod h1:YO35OhQPt3KJa3ryjFM5Bs14WD66h8eGKpfaBNrHW5M=
|
||||
@ -140,8 +141,9 @@ github.com/fatih/color v1.7.0/go.mod h1:Zm6kSWBoL9eyXnKyktHP6abPY2pDugNf5Kwzbycv
|
||||
github.com/fatih/structs v1.1.0/go.mod h1:9NiDSp5zOcgEDl+j00MP/WkGVPOlPRLejGD8Ga6PJ7M=
|
||||
github.com/franela/goblin v0.0.0-20200105215937-c9ffbefa60db/go.mod h1:7dvUGVsVBjqR7JHJk0brhHOZYGmfBYOrK0ZhYMEtBr4=
|
||||
github.com/franela/goreq v0.0.0-20171204163338-bcd34c9993f8/go.mod h1:ZhphrRTfi2rbfLwlschooIH4+wKKDR4Pdxhh+TRoA20=
|
||||
github.com/frankban/quicktest v1.10.0 h1:Gfh+GAJZOAoKZsIZeZbdn2JF10kN1XHNvjsvQK8gVkE=
|
||||
github.com/frankban/quicktest v1.10.0/go.mod h1:ui7WezCLWMWxVWr1GETZY3smRy0G4KWq9vcPtJmFl7Y=
|
||||
github.com/frankban/quicktest v1.11.3 h1:8sXhOn0uLys67V8EsXLc6eszDs8VXWxL3iRvebPhedY=
|
||||
github.com/frankban/quicktest v1.11.3/go.mod h1:wRf/ReqHper53s+kmmSZizM8NamnL3IM0I9ntUbOk+k=
|
||||
github.com/fsnotify/fsnotify v1.4.7/go.mod h1:jwhsz4b93w/PPRr/qN1Yymfu8t87LnFCMoQvtojpjFo=
|
||||
github.com/ghodss/yaml v1.0.0/go.mod h1:4dBDuWmgqj2HViK6kFavaiC9ZROes6MMH2rRYeMEF04=
|
||||
github.com/go-acme/lego/v3 v3.4.0/go.mod h1:xYbLDuxq3Hy4bMUT1t9JIuz6GWIWb3m5X+TeTHYaT7M=
|
||||
@ -224,8 +226,9 @@ github.com/google/uuid v1.0.0/go.mod h1:TIyPZe4MgqvfeYDBFedMoGGpEw/LqOeaOT+nhxU+
|
||||
github.com/google/uuid v1.1.1/go.mod h1:TIyPZe4MgqvfeYDBFedMoGGpEw/LqOeaOT+nhxU+yHo=
|
||||
github.com/google/uuid v1.1.2/go.mod h1:TIyPZe4MgqvfeYDBFedMoGGpEw/LqOeaOT+nhxU+yHo=
|
||||
github.com/google/uuid v1.1.5/go.mod h1:TIyPZe4MgqvfeYDBFedMoGGpEw/LqOeaOT+nhxU+yHo=
|
||||
github.com/google/uuid v1.2.0 h1:qJYtXnJRWmpe7m/3XlyhrsLrEURqHRM2kxzoxXqyUDs=
|
||||
github.com/google/uuid v1.2.0/go.mod h1:TIyPZe4MgqvfeYDBFedMoGGpEw/LqOeaOT+nhxU+yHo=
|
||||
github.com/google/uuid v1.3.0 h1:t6JiXgmwXMjEs8VusXIJk2BXHsn+wx8BZdTaoZ5fu7I=
|
||||
github.com/google/uuid v1.3.0/go.mod h1:TIyPZe4MgqvfeYDBFedMoGGpEw/LqOeaOT+nhxU+yHo=
|
||||
github.com/googleapis/gax-go/v2 v2.0.4/go.mod h1:0Wqv26UfaUD9n4G6kQubkQ+KchISgw+vpHVxEJEs9eg=
|
||||
github.com/googleapis/gax-go/v2 v2.0.5/go.mod h1:DWXyrwAJ9X0FpwwEdw+IPEYBICEFu5mhpdKc/us6bOk=
|
||||
github.com/gophercloud/gophercloud v0.3.0/go.mod h1:vxM41WHh5uqHVBMZHzuwNOHh8XEoIEcSTewFxm1c5g8=
|
||||
@ -326,6 +329,8 @@ github.com/julienschmidt/httprouter v1.3.0/go.mod h1:JR6WtHb+2LUe8TCKY3cZOxFyyO8
|
||||
github.com/kisielk/errcheck v1.1.0/go.mod h1:EZBBE59ingxPouuu3KfxchcWSUPOHkagtvWXihfKN4Q=
|
||||
github.com/kisielk/errcheck v1.2.0/go.mod h1:/BMXB+zMLi60iA8Vv6Ksmxu/1UDYcXs4uQLJ+jE2L00=
|
||||
github.com/kisielk/gotool v1.0.0/go.mod h1:XhKaO+MFFWcvkIS/tQcRk01m1F5IRFswLeQ+oQHNcck=
|
||||
github.com/klauspost/compress v1.9.8 h1:VMAMUUOh+gaxKTMk+zqbjsSjsIcUcL/LF4o63i82QyA=
|
||||
github.com/klauspost/compress v1.9.8/go.mod h1:RyIbtBH6LamlWaDj8nUwkbUhJ87Yi3uG0guNDohfE1A=
|
||||
github.com/klauspost/cpuid v1.2.3 h1:CCtW0xUnWGVINKvE/WWOYKdsPV6mawAtvQuSl8guwQs=
|
||||
github.com/klauspost/cpuid v1.2.3/go.mod h1:Pj4uuM528wm8OyEC2QMXAi2YiTZ96dNQPGgoMS4s3ek=
|
||||
github.com/klauspost/cpuid/v2 v2.0.5 h1:qnfhwbFriwDIX51QncuNU5mEMf+6KE3t7O8V2KQl3Dg=
|
||||
@ -336,8 +341,9 @@ github.com/konsorten/go-windows-terminal-sequences v1.0.2/go.mod h1:T0+1ngSBFLxv
|
||||
github.com/konsorten/go-windows-terminal-sequences v1.0.3/go.mod h1:T0+1ngSBFLxvqU3pZ+m/2kptfBszLMUkC4ZK/EgS/cQ=
|
||||
github.com/kr/logfmt v0.0.0-20140226030751-b84e30acd515/go.mod h1:+0opPa2QZZtGFBFZlji/RkVcI2GknAs/DXo4wKdlNEc=
|
||||
github.com/kr/pretty v0.1.0/go.mod h1:dAy3ld7l9f0ibDNOQOHHMYYIIbhfbHSm3C4ZsoJORNo=
|
||||
github.com/kr/pretty v0.2.0 h1:s5hAObm+yFO5uHYt5dYjxi2rXrsnmRpJx4OYvIWUaQs=
|
||||
github.com/kr/pretty v0.2.0/go.mod h1:ipq/a2n7PKx3OHsz4KJII5eveXtPO4qwEXGdVfWzfnI=
|
||||
github.com/kr/pretty v0.2.1 h1:Fmg33tUaq4/8ym9TJN1x7sLJnHVwhP33CNkpYV/7rwI=
|
||||
github.com/kr/pretty v0.2.1/go.mod h1:ipq/a2n7PKx3OHsz4KJII5eveXtPO4qwEXGdVfWzfnI=
|
||||
github.com/kr/pty v1.1.1/go.mod h1:pFQYn66WHrOpPYNljwOMqo10TkYh1fy3cYio2l3bCsQ=
|
||||
github.com/kr/text v0.1.0/go.mod h1:4Jbv+DJW3UT/LiOwJeYQe1efqtUx/iVham/4vfdArNI=
|
||||
github.com/kr/text v0.2.0 h1:5Nx0Ya0ZqY2ygV366QzturHI13Jq95ApcVaJBhpS+AY=
|
||||
@ -449,6 +455,7 @@ github.com/performancecopilot/speed v3.0.0+incompatible/go.mod h1:/CLtqpZ5gBg1M9
|
||||
github.com/pierrec/lz4 v1.0.2-0.20190131084431-473cd7ce01a1/go.mod h1:3/3N9NVKO0jef7pBehbT1qWhCMrIgbYNnFAZCqQ5LRc=
|
||||
github.com/pierrec/lz4 v2.0.5+incompatible/go.mod h1:pdkljMzZIN41W+lC3N2tnIh5sFi+IEE17M5jbnwPHcY=
|
||||
github.com/pierrec/lz4 v2.5.2+incompatible/go.mod h1:pdkljMzZIN41W+lC3N2tnIh5sFi+IEE17M5jbnwPHcY=
|
||||
github.com/pierrec/lz4 v2.6.0+incompatible/go.mod h1:pdkljMzZIN41W+lC3N2tnIh5sFi+IEE17M5jbnwPHcY=
|
||||
github.com/pierrec/lz4 v2.6.1+incompatible h1:9UY3+iC23yxF0UfGaYrGplQ+79Rg+h/q9FV9ix19jjM=
|
||||
github.com/pierrec/lz4 v2.6.1+incompatible/go.mod h1:pdkljMzZIN41W+lC3N2tnIh5sFi+IEE17M5jbnwPHcY=
|
||||
github.com/pkg/errors v0.8.0/go.mod h1:bwawxfHBFNV+L2hUp1rHADufV3IMtnDRdf1r5NINEl0=
|
||||
@ -512,6 +519,8 @@ github.com/satori/go.uuid v1.2.0/go.mod h1:dA0hQrYB0VpLJoorglMZABFdXlWrHn1NEOzdh
|
||||
github.com/sean-/seed v0.0.0-20170313163322-e2103e2c3529/go.mod h1:DxrIzT+xaE7yg65j358z/aeFdxmN0P9QXhEzd20vsDc=
|
||||
github.com/segmentio/encoding v0.2.17 h1:cgfmPc44u1po1lz5bSgF00gLCROBjDNc7h+H7I20zpc=
|
||||
github.com/segmentio/encoding v0.2.17/go.mod h1:7E68jTSWMnNoYhHi1JbLd7NBSB6XfE4vzqhR88hDBQc=
|
||||
github.com/segmentio/kafka-go v0.4.16 h1:9dt78ehM9qzAkekA60D6A96RlqDzC3hnYYa8y5Szd+U=
|
||||
github.com/segmentio/kafka-go v0.4.16/go.mod h1:19+Eg7KwrNKy/PFhiIthEPkO8k+ac7/ZYXwYM9Df10w=
|
||||
github.com/shurcooL/sanitized_anchor_name v1.0.0/go.mod h1:1NzhyTcUVG4SuEtjjoZeVRXNmyL/1OwPU0+IJeTBvfc=
|
||||
github.com/silas/dag v0.0.0-20210121180416-41cf55125c34 h1:vBfVmA5mZhsQa2jr1FOL9nfA37N/jnbBmi5XUfviVTI=
|
||||
github.com/silas/dag v0.0.0-20210121180416-41cf55125c34/go.mod h1:7RTUFBdIRC9nZ7/3RyRNH1bdqIShrDejd1YbLwgPS+I=
|
||||
@ -558,8 +567,8 @@ github.com/unistack-org/micro-broker-http/v3 v3.3.1 h1:gs7TVth+rd2yOnikxstRlMIqS
|
||||
github.com/unistack-org/micro-broker-http/v3 v3.3.1/go.mod h1:jO77nTg/qTwT+JVQQdFENa3LzQ8sLNU1dp3sUElgog0=
|
||||
github.com/unistack-org/micro-client-grpc/v3 v3.3.3 h1:zKhxh45A4SP1b002fiFLK+vayL/YkHOpoCyZCRBmbm4=
|
||||
github.com/unistack-org/micro-client-grpc/v3 v3.3.3/go.mod h1:96DSXqLd5kSiep2brs+h7WvsZG+z3C2KO/NDaYA1Czk=
|
||||
github.com/unistack-org/micro-client-http/v3 v3.4.0 h1:N08hIEwx8HqAMI2GO8qfrexdGQcSoNsBr5doOo4lE88=
|
||||
github.com/unistack-org/micro-client-http/v3 v3.4.0/go.mod h1:0ocjoKcSEQv1K4sRj5gPCEXkPSEbA7qmNdFcr2MaGns=
|
||||
github.com/unistack-org/micro-client-http/v3 v3.4.5 h1:nvLIMW1Bdh6R1JVSOS40Hyr6nVuHSt0yPTmA3QxKuMM=
|
||||
github.com/unistack-org/micro-client-http/v3 v3.4.5/go.mod h1:Za26nIkbeBC12HIB5fUY1ixNbohUwqC/2nsrKJERxf8=
|
||||
github.com/unistack-org/micro-codec-grpc/v3 v3.2.1 h1:C+9DHTtRSvodlVOFo0+zMhBXoIye/hMleXlRv0o1yIU=
|
||||
github.com/unistack-org/micro-codec-grpc/v3 v3.2.1/go.mod h1:kaEdCPyWsa4o44cD4oS0+KzJWtshlXocZgnzEY+LZHQ=
|
||||
github.com/unistack-org/micro-codec-json/v3 v3.2.1 h1:nMRBnEvCttwX4yPAWuRSAvzcfLazRetqO4DpqJJHjY8=
|
||||
@ -588,8 +597,8 @@ github.com/unistack-org/micro-router-register/v3 v3.2.2 h1:lYCymDHkJfhZWYQ4+Sb7F
|
||||
github.com/unistack-org/micro-router-register/v3 v3.2.2/go.mod h1:Y9Qtlg4NHqq5rR6X6Jm+04LoSJMi7/OOCm2mRueZYTE=
|
||||
github.com/unistack-org/micro-server-grpc/v3 v3.3.6 h1:z4Koe7K4tVVs4XAo6C34XAvg+HH4/yW6pf/RFyTjkq0=
|
||||
github.com/unistack-org/micro-server-grpc/v3 v3.3.6/go.mod h1:nmh12MeWm8bTWwkf6pSxrcO+jlcV5VgpN3QAtcNm9C8=
|
||||
github.com/unistack-org/micro-server-http/v3 v3.3.19 h1:njrxK1X3XnfliOqBTb5pTChhfhxFnfU71tQNcU56ZEQ=
|
||||
github.com/unistack-org/micro-server-http/v3 v3.3.19/go.mod h1:rcuRcHLpdynsJFTvEcSV6sU+TdT8f7mczxmLNcIUxEU=
|
||||
github.com/unistack-org/micro-server-http/v3 v3.4.1 h1:Yj9eeMToXzDX78KBzobqSEPH4DYfUTNISS7qrntNJGg=
|
||||
github.com/unistack-org/micro-server-http/v3 v3.4.1/go.mod h1:Uck3mzXwaCmf0TZnM/9rDrptkxtgg7go0p8h7wBGIxo=
|
||||
github.com/unistack-org/micro-server-tcp/v3 v3.3.2 h1:x5FjxOuI61Jy6OzgCWElCRCWP9NffGNWajz/WJPEzdQ=
|
||||
github.com/unistack-org/micro-server-tcp/v3 v3.3.2/go.mod h1:981+kGQT3Js2LJrNaI2AyP/NcbnL7GU8WTnlRxj07Ao=
|
||||
github.com/unistack-org/micro-wrapper-trace-opentracing/v3 v3.2.0 h1:PvemkpeCVUWfCoKwt1XmJ8uGK9My/7T29qOVxtYJohw=
|
||||
@ -603,8 +612,10 @@ github.com/unistack-org/micro/v3 v3.3.16/go.mod h1:ETGcQQUcjxGaD44LUMX+0fgo8Loh7
|
||||
github.com/unistack-org/micro/v3 v3.3.17/go.mod h1:022EOEZZ789hZY3yB5ZSMXU6jLiadBgcNB/cpediV3c=
|
||||
github.com/unistack-org/micro/v3 v3.3.19/go.mod h1:LXmPfbJnJNvL0kQs8HfnkV3Wya2Wb+C7keVq++RCZnk=
|
||||
github.com/unistack-org/micro/v3 v3.4.0/go.mod h1:LXmPfbJnJNvL0kQs8HfnkV3Wya2Wb+C7keVq++RCZnk=
|
||||
github.com/unistack-org/micro/v3 v3.4.5 h1:4Rn6EkJz/web43XGZAPt4NtqDLV2SrYXZxdAfBKF9Ic=
|
||||
github.com/unistack-org/micro/v3 v3.4.5/go.mod h1:LXmPfbJnJNvL0kQs8HfnkV3Wya2Wb+C7keVq++RCZnk=
|
||||
github.com/unistack-org/micro/v3 v3.4.7/go.mod h1:LXmPfbJnJNvL0kQs8HfnkV3Wya2Wb+C7keVq++RCZnk=
|
||||
github.com/unistack-org/micro/v3 v3.4.8/go.mod h1:LXmPfbJnJNvL0kQs8HfnkV3Wya2Wb+C7keVq++RCZnk=
|
||||
github.com/unistack-org/micro/v3 v3.4.9 h1:IBCW/yxQijO/X+2zNzTdSsvzlgE0+y49bvjWemtY2zA=
|
||||
github.com/unistack-org/micro/v3 v3.4.9/go.mod h1:1ZkwpEqpiHiVhM2hiF9DamtpsF04oFybFhEQ4zEMcro=
|
||||
github.com/urfave/cli v0.0.0-20171014202726-7bc6a0acffa5/go.mod h1:70zkFmudgCuE/ngEzBv17Jvp/497gISqfk5gWijbERA=
|
||||
github.com/urfave/cli v1.20.0/go.mod h1:70zkFmudgCuE/ngEzBv17Jvp/497gISqfk5gWijbERA=
|
||||
github.com/urfave/cli v1.22.1/go.mod h1:Gos4lmkARVdJ6EkW0WaNv/tZAAMe9V7XWyB60NtXRu0=
|
||||
@ -613,6 +624,10 @@ github.com/valyala/fastrand v1.0.0/go.mod h1:HWqCzkrkg6QXT8V2EXWvXCoow7vLwOFN002
|
||||
github.com/valyala/histogram v1.1.2 h1:vOk5VrGjMBIoPR5k6wA8vBaC8toeJ8XO0yfRjFEc1h8=
|
||||
github.com/valyala/histogram v1.1.2/go.mod h1:CZAr6gK9dbD7hYx2s8WSPh0p5x5wETjC+2b3PJVtEdg=
|
||||
github.com/vultr/govultr v0.1.4/go.mod h1:9H008Uxr/C4vFNGLqKx232C206GL0PBHzOP0809bGNA=
|
||||
github.com/xdg/scram v0.0.0-20180814205039-7eeb5667e42c h1:u40Z8hqBAAQyv+vATcGgV0YCnDjqSL7/q/JyPhhJSPk=
|
||||
github.com/xdg/scram v0.0.0-20180814205039-7eeb5667e42c/go.mod h1:lB8K/P019DLNhemzwFU4jHLhdvlE6uDZjXFejJXr49I=
|
||||
github.com/xdg/stringprep v1.0.0 h1:d9X0esnoa3dFsV0FG35rAT0RIhYFlPq7MiP+DW89La0=
|
||||
github.com/xdg/stringprep v1.0.0/go.mod h1:Jhud4/sHMO4oL310DaZAKk9ZaJ08SJfe+sJh0HrGL1Y=
|
||||
github.com/xeipuuv/gojsonpointer v0.0.0-20180127040702-4e3ac2762d5f/go.mod h1:N2zxlSyiKSe5eX1tZViRH5QA0qijqEDrYZiPEAiq3wU=
|
||||
github.com/xeipuuv/gojsonreference v0.0.0-20180127040603-bd5ef7bd5415/go.mod h1:GwrjFmJcFw6At/Gs6z4yjiIwzuJ1/+UwLxMQDVQXShQ=
|
||||
github.com/xeipuuv/gojsonschema v1.1.0/go.mod h1:5yf86TLmAcydyeJq5YvxkGPE2fm/u4myDekKRoLuqhs=
|
||||
@ -645,6 +660,7 @@ golang.org/x/crypto v0.0.0-20181029021203-45a5f77698d3/go.mod h1:6SG95UA2DQfeDnf
|
||||
golang.org/x/crypto v0.0.0-20190211182817-74369b46fc67/go.mod h1:6SG95UA2DQfeDnfUPMdvaQW0Q7yPrPDi9nlGo2tz2b4=
|
||||
golang.org/x/crypto v0.0.0-20190308221718-c2843e01d9a2/go.mod h1:djNgcEr1/C05ACkg1iLfiJU5Ep61QUkGW8qpdssI0+w=
|
||||
golang.org/x/crypto v0.0.0-20190418165655-df01cb2cc480/go.mod h1:WFFai1msRO1wXaEeE5yQxYXgSfI8pQAWXbQop6sCtWE=
|
||||
golang.org/x/crypto v0.0.0-20190506204251-e1dfcc566284/go.mod h1:yigFU9vqHzYiE8UmvKecakEJjdnWj3jj499lnFckfCI=
|
||||
golang.org/x/crypto v0.0.0-20190510104115-cbcb75029529/go.mod h1:yigFU9vqHzYiE8UmvKecakEJjdnWj3jj499lnFckfCI=
|
||||
golang.org/x/crypto v0.0.0-20190605123033-f99c8df09eb5/go.mod h1:yigFU9vqHzYiE8UmvKecakEJjdnWj3jj499lnFckfCI=
|
||||
golang.org/x/crypto v0.0.0-20190701094942-4def268fd1a4/go.mod h1:yigFU9vqHzYiE8UmvKecakEJjdnWj3jj499lnFckfCI=
|
||||
|
@ -1,5 +1,5 @@
|
||||
// Code generated by protoc-gen-go-micro. DO NOT EDIT.
|
||||
// protoc-gen-go-micro version: v3.4.0
|
||||
// protoc-gen-go-micro version: v3.4.2
|
||||
// source: test.proto
|
||||
|
||||
package helloworld
|
||||
@ -12,6 +12,8 @@ import (
|
||||
)
|
||||
|
||||
var (
|
||||
TestName = "Test"
|
||||
|
||||
TestEndpoints = []api.Endpoint{
|
||||
api.Endpoint{
|
||||
Name: "Test.Call",
|
||||
|
@ -1,5 +1,5 @@
|
||||
// Code generated by protoc-gen-go-micro. DO NOT EDIT.
|
||||
// protoc-gen-go-micro version: v3.4.0
|
||||
// protoc-gen-go-micro version: v3.4.2
|
||||
// source: test.proto
|
||||
|
||||
package helloworld
|
||||
|
@ -1,5 +1,5 @@
|
||||
// Code generated by protoc-gen-go-micro. DO NOT EDIT.
|
||||
// protoc-gen-go-micro version: v3.4.0
|
||||
// protoc-gen-go-micro version: v3.4.2
|
||||
// source: test.proto
|
||||
|
||||
package pb
|
||||
@ -11,6 +11,8 @@ import (
|
||||
)
|
||||
|
||||
var (
|
||||
TestDoubleName = "TestDouble"
|
||||
|
||||
TestDoubleEndpoints = []api.Endpoint{
|
||||
api.Endpoint{
|
||||
Name: "TestDouble.CallDouble",
|
||||
@ -35,6 +37,8 @@ type TestDoubleServer interface {
|
||||
}
|
||||
|
||||
var (
|
||||
TestName = "Test"
|
||||
|
||||
TestEndpoints = []api.Endpoint{
|
||||
api.Endpoint{
|
||||
Name: "Test.CallRepeatedString",
|
||||
|
@ -1,5 +1,5 @@
|
||||
// Code generated by protoc-gen-go-micro. DO NOT EDIT.
|
||||
// protoc-gen-go-micro version: v3.4.0
|
||||
// protoc-gen-go-micro version: v3.4.2
|
||||
// source: test.proto
|
||||
|
||||
package pb
|
||||
|
Loading…
Reference in New Issue
Block a user