grpc-examples

module
v0.0.0-...-b79924e Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jul 21, 2016 License: Apache-2.0

README

Helloworld example for examining version control of grpc.

Expected behavior when updating client version:

Supposing the version of client is newer than server, expected behaviors on following scenarios:

  • Adding new interfaces: the call to the server will report an error. This is expected.
  • Removing a interface: client will no longer call the removed interface, so there is no problem.
  • Updating a message by adding a field: client could continue make request with old versioned server, but server don't see newly added field, which is expected.
  • Updating a message by deprecating a field: by following the rule, although it is deprecated, old server won't realize any difference if the deprecated field is continue setting value.
  • Removing a message: this should be included on above cases (interface's request/response message couldn't be removed unless the interface is also removed togather, all other messages are field of request/response message).

Directories

Path Synopsis
api
v1/helloworld
Package helloworld is a generated protocol buffer package.
Package helloworld is a generated protocol buffer package.
v2/helloworld
Package helloworld is a generated protocol buffer package.
Package helloworld is a generated protocol buffer package.
v3/helloworld
Package helloworld is a generated protocol buffer package.
Package helloworld is a generated protocol buffer package.
v4/helloworld
Package helloworld is a generated protocol buffer package.
Package helloworld is a generated protocol buffer package.
v5/helloworld
Package helloworld is a generated protocol buffer package.
Package helloworld is a generated protocol buffer package.
client
v1
* First version of grpc helloworld service
* First version of grpc helloworld service
v2
* Version 2 of grpc helloworld service * This version deprecated HelloRequest.Name and replaced it with HelloRequest.User * Since `name` is not removed yet, client could continue setting value for name in * order to be compatible with old versions.
* Version 2 of grpc helloworld service * This version deprecated HelloRequest.Name and replaced it with HelloRequest.User * Since `name` is not removed yet, client could continue setting value for name in * order to be compatible with old versions.
v3
* Version 3 of grpc helloworld service * This version removes HelloRequest.Name.
* Version 3 of grpc helloworld service * This version removes HelloRequest.Name.
v4
* Version 4 of grpc helloworld service * This version changes SayHello to stream response.
* Version 4 of grpc helloworld service * This version changes SayHello to stream response.
v5
* Version 5 of grpc helloworld service * This version adds SayNewHello which returns a stream resp * To keep compatible with old versions (e.g.
* Version 5 of grpc helloworld service * This version adds SayNewHello which returns a stream resp * To keep compatible with old versions (e.g.
server
v1
* First version of grpc helloworld service * We will keep server always in v1 and change the version to check what will happen
* First version of grpc helloworld service * We will keep server always in v1 and change the version to check what will happen

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL