mirror of
https://github.com/chai2010/advanced-go-programming-book.git
synced 2025-05-24 20:52:22 +00:00
1.1 KiB
Executable File
1.1 KiB
Executable File
category
category |
---|
documentation |
Examples
Examples are available under examples
directory.
proto/examplepb/echo_service.proto
,proto/examplepb/a_bit_of_everything.proto
,proto/examplepb/unannotated_echo_service.proto
: service definitionproto/examplepb/echo_service.pb.go
,proto/examplepb/a_bit_of_everything.pb.go
,proto/examplepb/unannotated_echo_service.pb.go
: [generated] stub of the serviceproto/examplepb/echo_service.pb.gw.go
,proto/examplepb/a_bit_of_everything.pb.gw.go
,proto/examplepb/uannotated_echo_service.pb.gw.go
: [generated] reverse proxy for the serviceproto/examplepb/unannotated_echo_service.yaml
: gRPC API Configuration forunannotated_echo_service.proto
server/main.go
: service implementationmain.go
: entrypoint of the generated reverse proxy
To use the same port for custom HTTP handlers (e.g. serving swagger.json
), gRPC-gateway, and a gRPC server, see this code example by CoreOS (and its accompanying blog post)