Set of namespaced proto files added

This commit is contained in:
Anton Repin
2019-04-21 23:58:40 -07:00
parent c26bbbb9bc
commit 8f7aad1a84
5 changed files with 39 additions and 0 deletions

View File

@@ -0,0 +1,8 @@
syntax = "proto3";
package proto_example.common.items;
enum ItemType {
DEFAULT = 0;
SUPERIOR = 1;
FLAWLESS = 2;
}

View File

@@ -0,0 +1,8 @@
syntax = "proto3";
package proto_example.common.shipments;
message ShipmentType {
string from = 1;
string to = 2;
string carrier = 3;
}

View File

@@ -0,0 +1,11 @@
syntax = "proto3";
package proto_example.orders;
import public "common/item_types.proto";
import public "common/shipment_types.proto";
message Order {
int32 id = 1;
repeated common.items.ItemType itemTypes = 2;
common.shipments.ShipmentType shipmentType = 3;
}

View File

@@ -0,0 +1,9 @@
syntax = "proto3";
import "orders/message.proto";
package proto_example.orders;
service OrderService {
rpc Find(Order) returns (Order);
rpc Sync(stream Order) returns (stream Order);
rpc SyncCall(stream Order) returns (stream Order);
}

View File

@@ -0,0 +1,3 @@
syntax = "proto3";
package proto_example;
import public "orders/service.proto";