Skip to content

No longer generate register...Server function in pb.gw.go? #1195

@chaowanggrab

Description

@chaowanggrab

I have protoc 3.11.4 and latest grpc-gateway

We used to run something like
protoc -I/usr/local/include -I. \ -I$GOPATH/src \ -I$GOPATH/src/github.com/grpc-ecosystem/grpc-gateway/third_party/googleapis \ --go_out=plugins=grpc:. \ --grpc-gateway_out=logtostderr=true:. \ --swagger_out=logtostderr=true:. \ example/echo_service.proto in order to update the apis.

Before, it generates Register...Server(ctx context.Context, mux *runtime.ServeMux, server {{$svc.GetName}}Server) error {} function (https://github.com/grpc-ecosystem/grpc-gateway/blob/master/protoc-gen-grpc-gateway/internal/gengateway/template.go#L564). However, now the generated pb.gw.go does not have the server related functions.

I simply follow the readme and it would not get to service related functions too. But I am not sure it's only happen on mine or not. I noticed in the examples folder, the server related functions are still occur in pb.gw.go.

Did I miss anything?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions