January 2019
Intermediate to advanced
520 pages
14h 32m
English
gRPC uses a special language for protocol declarations.There are two versions of the language—proto2 and proto3. We will use the second as it's more modern. Create a ring.proto file and add the following declaration:
syntax = "proto3";option java_multiple_files = true;option java_package = "rust.microservices.ring";option java_outer_classname = "RingProto";option objc_class_prefix = "RING";package ringproto;message Empty { }service Ring { rpc StartRollCall (Empty) returns (Empty); rpc MarkItself (Empty) returns (Empty);}
As you can see, we specified the syntax as proto3. Options give you the ability to set the properties for the generation of source files for different languages if you will interact with a service from other applications ...
Read now
Unlock full access