From a91e1e78a177d382470d62e0e28ff04a1f34a7a0 Mon Sep 17 00:00:00 2001 From: Andrew Z Allen Date: Sun, 20 May 2018 15:48:52 -0600 Subject: [PATCH] Regenerate example files (#656) --- .../proto/examplepb/a_bit_of_everything.pb.go | 54 +++++++++---------- examples/proto/examplepb/echo_service.pb.go | 14 ++--- .../proto/examplepb/flow_combination.pb.go | 28 +++++----- examples/proto/examplepb/stream.pb.go | 14 ++--- .../examplepb/unannotated_echo_service.pb.go | 14 ++--- examples/proto/examplepb/wrappers.pb.go | 10 ++-- 6 files changed, 67 insertions(+), 67 deletions(-) diff --git a/examples/proto/examplepb/a_bit_of_everything.pb.go b/examples/proto/examplepb/a_bit_of_everything.pb.go index 64a70461dfd..520dae9c337 100644 --- a/examples/proto/examplepb/a_bit_of_everything.pb.go +++ b/examples/proto/examplepb/a_bit_of_everything.pb.go @@ -592,8 +592,9 @@ var _ grpc.ClientConn // is compatible with the grpc package it is being compiled against. const _ = grpc.SupportPackageIsVersion4 -// Client API for ABitOfEverythingService service - +// ABitOfEverythingServiceClient is the client API for ABitOfEverythingService service. +// +// For semantics around ctx use and closing/ending streaming RPCs, please refer to https://godoc.org/google.golang.org/grpc#ClientConn.NewStream. type ABitOfEverythingServiceClient interface { Create(ctx context.Context, in *ABitOfEverything, opts ...grpc.CallOption) (*ABitOfEverything, error) CreateBody(ctx context.Context, in *ABitOfEverything, opts ...grpc.CallOption) (*ABitOfEverything, error) @@ -627,7 +628,7 @@ func NewABitOfEverythingServiceClient(cc *grpc.ClientConn) ABitOfEverythingServi func (c *aBitOfEverythingServiceClient) Create(ctx context.Context, in *ABitOfEverything, opts ...grpc.CallOption) (*ABitOfEverything, error) { out := new(ABitOfEverything) - err := grpc.Invoke(ctx, "/grpc.gateway.examples.examplepb.ABitOfEverythingService/Create", in, out, c.cc, opts...) + err := c.cc.Invoke(ctx, "/grpc.gateway.examples.examplepb.ABitOfEverythingService/Create", in, out, opts...) if err != nil { return nil, err } @@ -636,7 +637,7 @@ func (c *aBitOfEverythingServiceClient) Create(ctx context.Context, in *ABitOfEv func (c *aBitOfEverythingServiceClient) CreateBody(ctx context.Context, in *ABitOfEverything, opts ...grpc.CallOption) (*ABitOfEverything, error) { out := new(ABitOfEverything) - err := grpc.Invoke(ctx, "/grpc.gateway.examples.examplepb.ABitOfEverythingService/CreateBody", in, out, c.cc, opts...) + err := c.cc.Invoke(ctx, "/grpc.gateway.examples.examplepb.ABitOfEverythingService/CreateBody", in, out, opts...) if err != nil { return nil, err } @@ -645,7 +646,7 @@ func (c *aBitOfEverythingServiceClient) CreateBody(ctx context.Context, in *ABit func (c *aBitOfEverythingServiceClient) Lookup(ctx context.Context, in *sub2.IdMessage, opts ...grpc.CallOption) (*ABitOfEverything, error) { out := new(ABitOfEverything) - err := grpc.Invoke(ctx, "/grpc.gateway.examples.examplepb.ABitOfEverythingService/Lookup", in, out, c.cc, opts...) + err := c.cc.Invoke(ctx, "/grpc.gateway.examples.examplepb.ABitOfEverythingService/Lookup", in, out, opts...) if err != nil { return nil, err } @@ -654,7 +655,7 @@ func (c *aBitOfEverythingServiceClient) Lookup(ctx context.Context, in *sub2.IdM func (c *aBitOfEverythingServiceClient) Update(ctx context.Context, in *ABitOfEverything, opts ...grpc.CallOption) (*empty.Empty, error) { out := new(empty.Empty) - err := grpc.Invoke(ctx, "/grpc.gateway.examples.examplepb.ABitOfEverythingService/Update", in, out, c.cc, opts...) + err := c.cc.Invoke(ctx, "/grpc.gateway.examples.examplepb.ABitOfEverythingService/Update", in, out, opts...) if err != nil { return nil, err } @@ -663,7 +664,7 @@ func (c *aBitOfEverythingServiceClient) Update(ctx context.Context, in *ABitOfEv func (c *aBitOfEverythingServiceClient) Delete(ctx context.Context, in *sub2.IdMessage, opts ...grpc.CallOption) (*empty.Empty, error) { out := new(empty.Empty) - err := grpc.Invoke(ctx, "/grpc.gateway.examples.examplepb.ABitOfEverythingService/Delete", in, out, c.cc, opts...) + err := c.cc.Invoke(ctx, "/grpc.gateway.examples.examplepb.ABitOfEverythingService/Delete", in, out, opts...) if err != nil { return nil, err } @@ -672,7 +673,7 @@ func (c *aBitOfEverythingServiceClient) Delete(ctx context.Context, in *sub2.IdM func (c *aBitOfEverythingServiceClient) GetQuery(ctx context.Context, in *ABitOfEverything, opts ...grpc.CallOption) (*empty.Empty, error) { out := new(empty.Empty) - err := grpc.Invoke(ctx, "/grpc.gateway.examples.examplepb.ABitOfEverythingService/GetQuery", in, out, c.cc, opts...) + err := c.cc.Invoke(ctx, "/grpc.gateway.examples.examplepb.ABitOfEverythingService/GetQuery", in, out, opts...) if err != nil { return nil, err } @@ -681,7 +682,7 @@ func (c *aBitOfEverythingServiceClient) GetQuery(ctx context.Context, in *ABitOf func (c *aBitOfEverythingServiceClient) Echo(ctx context.Context, in *sub.StringMessage, opts ...grpc.CallOption) (*sub.StringMessage, error) { out := new(sub.StringMessage) - err := grpc.Invoke(ctx, "/grpc.gateway.examples.examplepb.ABitOfEverythingService/Echo", in, out, c.cc, opts...) + err := c.cc.Invoke(ctx, "/grpc.gateway.examples.examplepb.ABitOfEverythingService/Echo", in, out, opts...) if err != nil { return nil, err } @@ -690,7 +691,7 @@ func (c *aBitOfEverythingServiceClient) Echo(ctx context.Context, in *sub.String func (c *aBitOfEverythingServiceClient) DeepPathEcho(ctx context.Context, in *ABitOfEverything, opts ...grpc.CallOption) (*ABitOfEverything, error) { out := new(ABitOfEverything) - err := grpc.Invoke(ctx, "/grpc.gateway.examples.examplepb.ABitOfEverythingService/DeepPathEcho", in, out, c.cc, opts...) + err := c.cc.Invoke(ctx, "/grpc.gateway.examples.examplepb.ABitOfEverythingService/DeepPathEcho", in, out, opts...) if err != nil { return nil, err } @@ -699,7 +700,7 @@ func (c *aBitOfEverythingServiceClient) DeepPathEcho(ctx context.Context, in *AB func (c *aBitOfEverythingServiceClient) NoBindings(ctx context.Context, in *duration.Duration, opts ...grpc.CallOption) (*empty.Empty, error) { out := new(empty.Empty) - err := grpc.Invoke(ctx, "/grpc.gateway.examples.examplepb.ABitOfEverythingService/NoBindings", in, out, c.cc, opts...) + err := c.cc.Invoke(ctx, "/grpc.gateway.examples.examplepb.ABitOfEverythingService/NoBindings", in, out, opts...) if err != nil { return nil, err } @@ -708,7 +709,7 @@ func (c *aBitOfEverythingServiceClient) NoBindings(ctx context.Context, in *dura func (c *aBitOfEverythingServiceClient) Timeout(ctx context.Context, in *empty.Empty, opts ...grpc.CallOption) (*empty.Empty, error) { out := new(empty.Empty) - err := grpc.Invoke(ctx, "/grpc.gateway.examples.examplepb.ABitOfEverythingService/Timeout", in, out, c.cc, opts...) + err := c.cc.Invoke(ctx, "/grpc.gateway.examples.examplepb.ABitOfEverythingService/Timeout", in, out, opts...) if err != nil { return nil, err } @@ -717,7 +718,7 @@ func (c *aBitOfEverythingServiceClient) Timeout(ctx context.Context, in *empty.E func (c *aBitOfEverythingServiceClient) ErrorWithDetails(ctx context.Context, in *empty.Empty, opts ...grpc.CallOption) (*empty.Empty, error) { out := new(empty.Empty) - err := grpc.Invoke(ctx, "/grpc.gateway.examples.examplepb.ABitOfEverythingService/ErrorWithDetails", in, out, c.cc, opts...) + err := c.cc.Invoke(ctx, "/grpc.gateway.examples.examplepb.ABitOfEverythingService/ErrorWithDetails", in, out, opts...) if err != nil { return nil, err } @@ -726,7 +727,7 @@ func (c *aBitOfEverythingServiceClient) ErrorWithDetails(ctx context.Context, in func (c *aBitOfEverythingServiceClient) GetMessageWithBody(ctx context.Context, in *MessageWithBody, opts ...grpc.CallOption) (*empty.Empty, error) { out := new(empty.Empty) - err := grpc.Invoke(ctx, "/grpc.gateway.examples.examplepb.ABitOfEverythingService/GetMessageWithBody", in, out, c.cc, opts...) + err := c.cc.Invoke(ctx, "/grpc.gateway.examples.examplepb.ABitOfEverythingService/GetMessageWithBody", in, out, opts...) if err != nil { return nil, err } @@ -735,15 +736,14 @@ func (c *aBitOfEverythingServiceClient) GetMessageWithBody(ctx context.Context, func (c *aBitOfEverythingServiceClient) PostWithEmptyBody(ctx context.Context, in *Body, opts ...grpc.CallOption) (*empty.Empty, error) { out := new(empty.Empty) - err := grpc.Invoke(ctx, "/grpc.gateway.examples.examplepb.ABitOfEverythingService/PostWithEmptyBody", in, out, c.cc, opts...) + err := c.cc.Invoke(ctx, "/grpc.gateway.examples.examplepb.ABitOfEverythingService/PostWithEmptyBody", in, out, opts...) if err != nil { return nil, err } return out, nil } -// Server API for ABitOfEverythingService service - +// ABitOfEverythingServiceServer is the server API for ABitOfEverythingService service. type ABitOfEverythingServiceServer interface { Create(context.Context, *ABitOfEverything) (*ABitOfEverything, error) CreateBody(context.Context, *ABitOfEverything) (*ABitOfEverything, error) @@ -1066,8 +1066,9 @@ var _ABitOfEverythingService_serviceDesc = grpc.ServiceDesc{ Metadata: "examples/proto/examplepb/a_bit_of_everything.proto", } -// Client API for CamelCaseServiceName service - +// CamelCaseServiceNameClient is the client API for CamelCaseServiceName service. +// +// For semantics around ctx use and closing/ending streaming RPCs, please refer to https://godoc.org/google.golang.org/grpc#ClientConn.NewStream. type CamelCaseServiceNameClient interface { Empty(ctx context.Context, in *empty.Empty, opts ...grpc.CallOption) (*empty.Empty, error) } @@ -1082,15 +1083,14 @@ func NewCamelCaseServiceNameClient(cc *grpc.ClientConn) CamelCaseServiceNameClie func (c *camelCaseServiceNameClient) Empty(ctx context.Context, in *empty.Empty, opts ...grpc.CallOption) (*empty.Empty, error) { out := new(empty.Empty) - err := grpc.Invoke(ctx, "/grpc.gateway.examples.examplepb.camelCaseServiceName/Empty", in, out, c.cc, opts...) + err := c.cc.Invoke(ctx, "/grpc.gateway.examples.examplepb.camelCaseServiceName/Empty", in, out, opts...) if err != nil { return nil, err } return out, nil } -// Server API for CamelCaseServiceName service - +// CamelCaseServiceNameServer is the server API for CamelCaseServiceName service. type CamelCaseServiceNameServer interface { Empty(context.Context, *empty.Empty) (*empty.Empty, error) } @@ -1130,8 +1130,9 @@ var _CamelCaseServiceName_serviceDesc = grpc.ServiceDesc{ Metadata: "examples/proto/examplepb/a_bit_of_everything.proto", } -// Client API for AnotherServiceWithNoBindings service - +// AnotherServiceWithNoBindingsClient is the client API for AnotherServiceWithNoBindings service. +// +// For semantics around ctx use and closing/ending streaming RPCs, please refer to https://godoc.org/google.golang.org/grpc#ClientConn.NewStream. type AnotherServiceWithNoBindingsClient interface { NoBindings(ctx context.Context, in *empty.Empty, opts ...grpc.CallOption) (*empty.Empty, error) } @@ -1146,15 +1147,14 @@ func NewAnotherServiceWithNoBindingsClient(cc *grpc.ClientConn) AnotherServiceWi func (c *anotherServiceWithNoBindingsClient) NoBindings(ctx context.Context, in *empty.Empty, opts ...grpc.CallOption) (*empty.Empty, error) { out := new(empty.Empty) - err := grpc.Invoke(ctx, "/grpc.gateway.examples.examplepb.AnotherServiceWithNoBindings/NoBindings", in, out, c.cc, opts...) + err := c.cc.Invoke(ctx, "/grpc.gateway.examples.examplepb.AnotherServiceWithNoBindings/NoBindings", in, out, opts...) if err != nil { return nil, err } return out, nil } -// Server API for AnotherServiceWithNoBindings service - +// AnotherServiceWithNoBindingsServer is the server API for AnotherServiceWithNoBindings service. type AnotherServiceWithNoBindingsServer interface { NoBindings(context.Context, *empty.Empty) (*empty.Empty, error) } diff --git a/examples/proto/examplepb/echo_service.pb.go b/examples/proto/examplepb/echo_service.pb.go index 905eaa93a44..42a70d155e9 100644 --- a/examples/proto/examplepb/echo_service.pb.go +++ b/examples/proto/examplepb/echo_service.pb.go @@ -419,8 +419,9 @@ var _ grpc.ClientConn // is compatible with the grpc package it is being compiled against. const _ = grpc.SupportPackageIsVersion4 -// Client API for EchoService service - +// EchoServiceClient is the client API for EchoService service. +// +// For semantics around ctx use and closing/ending streaming RPCs, please refer to https://godoc.org/google.golang.org/grpc#ClientConn.NewStream. type EchoServiceClient interface { // Echo method receives a simple message and returns it. // @@ -443,7 +444,7 @@ func NewEchoServiceClient(cc *grpc.ClientConn) EchoServiceClient { func (c *echoServiceClient) Echo(ctx context.Context, in *SimpleMessage, opts ...grpc.CallOption) (*SimpleMessage, error) { out := new(SimpleMessage) - err := grpc.Invoke(ctx, "/grpc.gateway.examples.examplepb.EchoService/Echo", in, out, c.cc, opts...) + err := c.cc.Invoke(ctx, "/grpc.gateway.examples.examplepb.EchoService/Echo", in, out, opts...) if err != nil { return nil, err } @@ -452,7 +453,7 @@ func (c *echoServiceClient) Echo(ctx context.Context, in *SimpleMessage, opts .. func (c *echoServiceClient) EchoBody(ctx context.Context, in *SimpleMessage, opts ...grpc.CallOption) (*SimpleMessage, error) { out := new(SimpleMessage) - err := grpc.Invoke(ctx, "/grpc.gateway.examples.examplepb.EchoService/EchoBody", in, out, c.cc, opts...) + err := c.cc.Invoke(ctx, "/grpc.gateway.examples.examplepb.EchoService/EchoBody", in, out, opts...) if err != nil { return nil, err } @@ -461,15 +462,14 @@ func (c *echoServiceClient) EchoBody(ctx context.Context, in *SimpleMessage, opt func (c *echoServiceClient) EchoDelete(ctx context.Context, in *SimpleMessage, opts ...grpc.CallOption) (*SimpleMessage, error) { out := new(SimpleMessage) - err := grpc.Invoke(ctx, "/grpc.gateway.examples.examplepb.EchoService/EchoDelete", in, out, c.cc, opts...) + err := c.cc.Invoke(ctx, "/grpc.gateway.examples.examplepb.EchoService/EchoDelete", in, out, opts...) if err != nil { return nil, err } return out, nil } -// Server API for EchoService service - +// EchoServiceServer is the server API for EchoService service. type EchoServiceServer interface { // Echo method receives a simple message and returns it. // diff --git a/examples/proto/examplepb/flow_combination.pb.go b/examples/proto/examplepb/flow_combination.pb.go index 20b2402f9d0..55be4381b5e 100644 --- a/examples/proto/examplepb/flow_combination.pb.go +++ b/examples/proto/examplepb/flow_combination.pb.go @@ -254,8 +254,9 @@ var _ grpc.ClientConn // is compatible with the grpc package it is being compiled against. const _ = grpc.SupportPackageIsVersion4 -// Client API for FlowCombination service - +// FlowCombinationClient is the client API for FlowCombination service. +// +// For semantics around ctx use and closing/ending streaming RPCs, please refer to https://godoc.org/google.golang.org/grpc#ClientConn.NewStream. type FlowCombinationClient interface { RpcEmptyRpc(ctx context.Context, in *EmptyProto, opts ...grpc.CallOption) (*EmptyProto, error) RpcEmptyStream(ctx context.Context, in *EmptyProto, opts ...grpc.CallOption) (FlowCombination_RpcEmptyStreamClient, error) @@ -279,7 +280,7 @@ func NewFlowCombinationClient(cc *grpc.ClientConn) FlowCombinationClient { func (c *flowCombinationClient) RpcEmptyRpc(ctx context.Context, in *EmptyProto, opts ...grpc.CallOption) (*EmptyProto, error) { out := new(EmptyProto) - err := grpc.Invoke(ctx, "/grpc.gateway.examples.examplepb.FlowCombination/RpcEmptyRpc", in, out, c.cc, opts...) + err := c.cc.Invoke(ctx, "/grpc.gateway.examples.examplepb.FlowCombination/RpcEmptyRpc", in, out, opts...) if err != nil { return nil, err } @@ -287,7 +288,7 @@ func (c *flowCombinationClient) RpcEmptyRpc(ctx context.Context, in *EmptyProto, } func (c *flowCombinationClient) RpcEmptyStream(ctx context.Context, in *EmptyProto, opts ...grpc.CallOption) (FlowCombination_RpcEmptyStreamClient, error) { - stream, err := grpc.NewClientStream(ctx, &_FlowCombination_serviceDesc.Streams[0], c.cc, "/grpc.gateway.examples.examplepb.FlowCombination/RpcEmptyStream", opts...) + stream, err := c.cc.NewStream(ctx, &_FlowCombination_serviceDesc.Streams[0], "/grpc.gateway.examples.examplepb.FlowCombination/RpcEmptyStream", opts...) if err != nil { return nil, err } @@ -319,7 +320,7 @@ func (x *flowCombinationRpcEmptyStreamClient) Recv() (*EmptyProto, error) { } func (c *flowCombinationClient) StreamEmptyRpc(ctx context.Context, opts ...grpc.CallOption) (FlowCombination_StreamEmptyRpcClient, error) { - stream, err := grpc.NewClientStream(ctx, &_FlowCombination_serviceDesc.Streams[1], c.cc, "/grpc.gateway.examples.examplepb.FlowCombination/StreamEmptyRpc", opts...) + stream, err := c.cc.NewStream(ctx, &_FlowCombination_serviceDesc.Streams[1], "/grpc.gateway.examples.examplepb.FlowCombination/StreamEmptyRpc", opts...) if err != nil { return nil, err } @@ -353,7 +354,7 @@ func (x *flowCombinationStreamEmptyRpcClient) CloseAndRecv() (*EmptyProto, error } func (c *flowCombinationClient) StreamEmptyStream(ctx context.Context, opts ...grpc.CallOption) (FlowCombination_StreamEmptyStreamClient, error) { - stream, err := grpc.NewClientStream(ctx, &_FlowCombination_serviceDesc.Streams[2], c.cc, "/grpc.gateway.examples.examplepb.FlowCombination/StreamEmptyStream", opts...) + stream, err := c.cc.NewStream(ctx, &_FlowCombination_serviceDesc.Streams[2], "/grpc.gateway.examples.examplepb.FlowCombination/StreamEmptyStream", opts...) if err != nil { return nil, err } @@ -385,7 +386,7 @@ func (x *flowCombinationStreamEmptyStreamClient) Recv() (*EmptyProto, error) { func (c *flowCombinationClient) RpcBodyRpc(ctx context.Context, in *NonEmptyProto, opts ...grpc.CallOption) (*EmptyProto, error) { out := new(EmptyProto) - err := grpc.Invoke(ctx, "/grpc.gateway.examples.examplepb.FlowCombination/RpcBodyRpc", in, out, c.cc, opts...) + err := c.cc.Invoke(ctx, "/grpc.gateway.examples.examplepb.FlowCombination/RpcBodyRpc", in, out, opts...) if err != nil { return nil, err } @@ -394,7 +395,7 @@ func (c *flowCombinationClient) RpcBodyRpc(ctx context.Context, in *NonEmptyProt func (c *flowCombinationClient) RpcPathSingleNestedRpc(ctx context.Context, in *SingleNestedProto, opts ...grpc.CallOption) (*EmptyProto, error) { out := new(EmptyProto) - err := grpc.Invoke(ctx, "/grpc.gateway.examples.examplepb.FlowCombination/RpcPathSingleNestedRpc", in, out, c.cc, opts...) + err := c.cc.Invoke(ctx, "/grpc.gateway.examples.examplepb.FlowCombination/RpcPathSingleNestedRpc", in, out, opts...) if err != nil { return nil, err } @@ -403,7 +404,7 @@ func (c *flowCombinationClient) RpcPathSingleNestedRpc(ctx context.Context, in * func (c *flowCombinationClient) RpcPathNestedRpc(ctx context.Context, in *NestedProto, opts ...grpc.CallOption) (*EmptyProto, error) { out := new(EmptyProto) - err := grpc.Invoke(ctx, "/grpc.gateway.examples.examplepb.FlowCombination/RpcPathNestedRpc", in, out, c.cc, opts...) + err := c.cc.Invoke(ctx, "/grpc.gateway.examples.examplepb.FlowCombination/RpcPathNestedRpc", in, out, opts...) if err != nil { return nil, err } @@ -411,7 +412,7 @@ func (c *flowCombinationClient) RpcPathNestedRpc(ctx context.Context, in *Nested } func (c *flowCombinationClient) RpcBodyStream(ctx context.Context, in *NonEmptyProto, opts ...grpc.CallOption) (FlowCombination_RpcBodyStreamClient, error) { - stream, err := grpc.NewClientStream(ctx, &_FlowCombination_serviceDesc.Streams[3], c.cc, "/grpc.gateway.examples.examplepb.FlowCombination/RpcBodyStream", opts...) + stream, err := c.cc.NewStream(ctx, &_FlowCombination_serviceDesc.Streams[3], "/grpc.gateway.examples.examplepb.FlowCombination/RpcBodyStream", opts...) if err != nil { return nil, err } @@ -443,7 +444,7 @@ func (x *flowCombinationRpcBodyStreamClient) Recv() (*EmptyProto, error) { } func (c *flowCombinationClient) RpcPathSingleNestedStream(ctx context.Context, in *SingleNestedProto, opts ...grpc.CallOption) (FlowCombination_RpcPathSingleNestedStreamClient, error) { - stream, err := grpc.NewClientStream(ctx, &_FlowCombination_serviceDesc.Streams[4], c.cc, "/grpc.gateway.examples.examplepb.FlowCombination/RpcPathSingleNestedStream", opts...) + stream, err := c.cc.NewStream(ctx, &_FlowCombination_serviceDesc.Streams[4], "/grpc.gateway.examples.examplepb.FlowCombination/RpcPathSingleNestedStream", opts...) if err != nil { return nil, err } @@ -475,7 +476,7 @@ func (x *flowCombinationRpcPathSingleNestedStreamClient) Recv() (*EmptyProto, er } func (c *flowCombinationClient) RpcPathNestedStream(ctx context.Context, in *NestedProto, opts ...grpc.CallOption) (FlowCombination_RpcPathNestedStreamClient, error) { - stream, err := grpc.NewClientStream(ctx, &_FlowCombination_serviceDesc.Streams[5], c.cc, "/grpc.gateway.examples.examplepb.FlowCombination/RpcPathNestedStream", opts...) + stream, err := c.cc.NewStream(ctx, &_FlowCombination_serviceDesc.Streams[5], "/grpc.gateway.examples.examplepb.FlowCombination/RpcPathNestedStream", opts...) if err != nil { return nil, err } @@ -506,8 +507,7 @@ func (x *flowCombinationRpcPathNestedStreamClient) Recv() (*EmptyProto, error) { return m, nil } -// Server API for FlowCombination service - +// FlowCombinationServer is the server API for FlowCombination service. type FlowCombinationServer interface { RpcEmptyRpc(context.Context, *EmptyProto) (*EmptyProto, error) RpcEmptyStream(*EmptyProto, FlowCombination_RpcEmptyStreamServer) error diff --git a/examples/proto/examplepb/stream.pb.go b/examples/proto/examplepb/stream.pb.go index c598d8a548b..cc0c274c8ea 100644 --- a/examples/proto/examplepb/stream.pb.go +++ b/examples/proto/examplepb/stream.pb.go @@ -34,8 +34,9 @@ var _ grpc.ClientConn // is compatible with the grpc package it is being compiled against. const _ = grpc.SupportPackageIsVersion4 -// Client API for StreamService service - +// StreamServiceClient is the client API for StreamService service. +// +// For semantics around ctx use and closing/ending streaming RPCs, please refer to https://godoc.org/google.golang.org/grpc#ClientConn.NewStream. type StreamServiceClient interface { BulkCreate(ctx context.Context, opts ...grpc.CallOption) (StreamService_BulkCreateClient, error) List(ctx context.Context, in *empty.Empty, opts ...grpc.CallOption) (StreamService_ListClient, error) @@ -51,7 +52,7 @@ func NewStreamServiceClient(cc *grpc.ClientConn) StreamServiceClient { } func (c *streamServiceClient) BulkCreate(ctx context.Context, opts ...grpc.CallOption) (StreamService_BulkCreateClient, error) { - stream, err := grpc.NewClientStream(ctx, &_StreamService_serviceDesc.Streams[0], c.cc, "/grpc.gateway.examples.examplepb.StreamService/BulkCreate", opts...) + stream, err := c.cc.NewStream(ctx, &_StreamService_serviceDesc.Streams[0], "/grpc.gateway.examples.examplepb.StreamService/BulkCreate", opts...) if err != nil { return nil, err } @@ -85,7 +86,7 @@ func (x *streamServiceBulkCreateClient) CloseAndRecv() (*empty.Empty, error) { } func (c *streamServiceClient) List(ctx context.Context, in *empty.Empty, opts ...grpc.CallOption) (StreamService_ListClient, error) { - stream, err := grpc.NewClientStream(ctx, &_StreamService_serviceDesc.Streams[1], c.cc, "/grpc.gateway.examples.examplepb.StreamService/List", opts...) + stream, err := c.cc.NewStream(ctx, &_StreamService_serviceDesc.Streams[1], "/grpc.gateway.examples.examplepb.StreamService/List", opts...) if err != nil { return nil, err } @@ -117,7 +118,7 @@ func (x *streamServiceListClient) Recv() (*ABitOfEverything, error) { } func (c *streamServiceClient) BulkEcho(ctx context.Context, opts ...grpc.CallOption) (StreamService_BulkEchoClient, error) { - stream, err := grpc.NewClientStream(ctx, &_StreamService_serviceDesc.Streams[2], c.cc, "/grpc.gateway.examples.examplepb.StreamService/BulkEcho", opts...) + stream, err := c.cc.NewStream(ctx, &_StreamService_serviceDesc.Streams[2], "/grpc.gateway.examples.examplepb.StreamService/BulkEcho", opts...) if err != nil { return nil, err } @@ -147,8 +148,7 @@ func (x *streamServiceBulkEchoClient) Recv() (*sub.StringMessage, error) { return m, nil } -// Server API for StreamService service - +// StreamServiceServer is the server API for StreamService service. type StreamServiceServer interface { BulkCreate(StreamService_BulkCreateServer) error List(*empty.Empty, StreamService_ListServer) error diff --git a/examples/proto/examplepb/unannotated_echo_service.pb.go b/examples/proto/examplepb/unannotated_echo_service.pb.go index 7e2dd22f1c7..733ab6e8162 100644 --- a/examples/proto/examplepb/unannotated_echo_service.pb.go +++ b/examples/proto/examplepb/unannotated_echo_service.pb.go @@ -102,8 +102,9 @@ var _ grpc.ClientConn // is compatible with the grpc package it is being compiled against. const _ = grpc.SupportPackageIsVersion4 -// Client API for UnannotatedEchoService service - +// UnannotatedEchoServiceClient is the client API for UnannotatedEchoService service. +// +// For semantics around ctx use and closing/ending streaming RPCs, please refer to https://godoc.org/google.golang.org/grpc#ClientConn.NewStream. type UnannotatedEchoServiceClient interface { // Echo method receives a simple message and returns it. // @@ -126,7 +127,7 @@ func NewUnannotatedEchoServiceClient(cc *grpc.ClientConn) UnannotatedEchoService func (c *unannotatedEchoServiceClient) Echo(ctx context.Context, in *UnannotatedSimpleMessage, opts ...grpc.CallOption) (*UnannotatedSimpleMessage, error) { out := new(UnannotatedSimpleMessage) - err := grpc.Invoke(ctx, "/grpc.gateway.examples.examplepb.UnannotatedEchoService/Echo", in, out, c.cc, opts...) + err := c.cc.Invoke(ctx, "/grpc.gateway.examples.examplepb.UnannotatedEchoService/Echo", in, out, opts...) if err != nil { return nil, err } @@ -135,7 +136,7 @@ func (c *unannotatedEchoServiceClient) Echo(ctx context.Context, in *Unannotated func (c *unannotatedEchoServiceClient) EchoBody(ctx context.Context, in *UnannotatedSimpleMessage, opts ...grpc.CallOption) (*UnannotatedSimpleMessage, error) { out := new(UnannotatedSimpleMessage) - err := grpc.Invoke(ctx, "/grpc.gateway.examples.examplepb.UnannotatedEchoService/EchoBody", in, out, c.cc, opts...) + err := c.cc.Invoke(ctx, "/grpc.gateway.examples.examplepb.UnannotatedEchoService/EchoBody", in, out, opts...) if err != nil { return nil, err } @@ -144,15 +145,14 @@ func (c *unannotatedEchoServiceClient) EchoBody(ctx context.Context, in *Unannot func (c *unannotatedEchoServiceClient) EchoDelete(ctx context.Context, in *UnannotatedSimpleMessage, opts ...grpc.CallOption) (*UnannotatedSimpleMessage, error) { out := new(UnannotatedSimpleMessage) - err := grpc.Invoke(ctx, "/grpc.gateway.examples.examplepb.UnannotatedEchoService/EchoDelete", in, out, c.cc, opts...) + err := c.cc.Invoke(ctx, "/grpc.gateway.examples.examplepb.UnannotatedEchoService/EchoDelete", in, out, opts...) if err != nil { return nil, err } return out, nil } -// Server API for UnannotatedEchoService service - +// UnannotatedEchoServiceServer is the server API for UnannotatedEchoService service. type UnannotatedEchoServiceServer interface { // Echo method receives a simple message and returns it. // diff --git a/examples/proto/examplepb/wrappers.pb.go b/examples/proto/examplepb/wrappers.pb.go index 878c410dc3e..a5065f9d378 100644 --- a/examples/proto/examplepb/wrappers.pb.go +++ b/examples/proto/examplepb/wrappers.pb.go @@ -115,8 +115,9 @@ var _ grpc.ClientConn // is compatible with the grpc package it is being compiled against. const _ = grpc.SupportPackageIsVersion4 -// Client API for WrappersService service - +// WrappersServiceClient is the client API for WrappersService service. +// +// For semantics around ctx use and closing/ending streaming RPCs, please refer to https://godoc.org/google.golang.org/grpc#ClientConn.NewStream. type WrappersServiceClient interface { Create(ctx context.Context, in *Wrappers, opts ...grpc.CallOption) (*Wrappers, error) } @@ -131,15 +132,14 @@ func NewWrappersServiceClient(cc *grpc.ClientConn) WrappersServiceClient { func (c *wrappersServiceClient) Create(ctx context.Context, in *Wrappers, opts ...grpc.CallOption) (*Wrappers, error) { out := new(Wrappers) - err := grpc.Invoke(ctx, "/grpc.gateway.examples.examplepb.WrappersService/Create", in, out, c.cc, opts...) + err := c.cc.Invoke(ctx, "/grpc.gateway.examples.examplepb.WrappersService/Create", in, out, opts...) if err != nil { return nil, err } return out, nil } -// Server API for WrappersService service - +// WrappersServiceServer is the server API for WrappersService service. type WrappersServiceServer interface { Create(context.Context, *Wrappers) (*Wrappers, error) }