gogo / grpc-example

An example of using Go gRPC and tools from the greater gRPC ecosystem together with the GoGo Protobuf Project.
Other
454 stars 88 forks source link

Is it possible to remove pointer on params and response in gRPC ? #36

Closed Elojah closed 4 years ago

Elojah commented 4 years ago

Hello gogo, thanks for your amazing library.

I use a lot [(gogoproto.nullable) = true]; and i recently switched to gRPC but i can't find a way to remove pointers on generated interface methods. e.g:

  // .proto:
    rpc Subscribe(dto.Subscribe) returns (google.protobuf.Empty);

  // .pb.go:
    Subscribe(ctx context.Context, in *dto.Subscribe, opts ...grpc.CallOption) (*types.Empty, error)

Instead i'd like to have

  // .pb.go:
    Subscribe(ctx context.Context, in dto.Subscribe, opts ...grpc.CallOption) (types.Empty, error)

Is there any way to do this with current extensions ?

Thanks

Elojah commented 4 years ago

Sorry, was for protobuf project :/