Re: [protobuf] Merging / extending 2 different Message types

2017-05-26 Thread 'Adam Cozzette' via Protocol Buffers
I think the typical way to do this would be to just store CommonParams as a submessage in each of your request types. The one problem is that this means the fields would not be at the top-level of the JSON as you wanted to have. So I think you have to choose to either go with this approach and live

[protobuf] Merging / extending 2 different Message types

2017-05-17 Thread Ciprian Caba
Hi guys, I want to use protobufs on c++ for directly serializing some server requests into data objects. However, these requests share some common fields (eg: ts, auth-key, so on) - let's call them CommonParams I will have multiple requests, eg: CreateAccountRequest, ReadAccountRequest, Delete