Re: [protobuf] Any vs. oneof in message wrappers

2016-05-18 Thread 'David Koch' via Protocol Buffers
Hi Feng, Thank you for the answer. Good point about redundant type information in the header message. Regards, /David On Monday, May 16, 2016 at 11:01:47 PM UTC+2, Feng Xiao wrote: > > > > On Mon, May 16, 2016 at 11:30 AM, 'David Koch' via Protocol Buffers < > prot

[protobuf] Any vs. oneof in message wrappers

2016-05-16 Thread &#x27;David Koch&#x27; via Protocol Buffers
Our platform generates/processes different types of proto3 messages with Kafka as buffer. We currently store this type as part of the Kafka message key so message consumers know which class to use for de-serialization. I want to add the type to the serialized message in order to not rely on the

Re: [protobuf] Overriding default field names in JSON serialization

2016-04-29 Thread &#x27;David Koch&#x27; via Protocol Buffers
format will then be: > { > "@id": "..some value..." > } > > On Mon, Apr 25, 2016 at 5:54 AM, 'David Koch' via Protocol Buffers < > prot...@googlegroups.com > wrote: > >> Hello, >> >> Using the JSON printing/parsing utilit

[protobuf] Overriding default field names in JSON serialization

2016-04-25 Thread &#x27;David Koch&#x27; via Protocol Buffers
Hello, Using the JSON printing/parsing utilities in proto3 - is it possible to override the default JSON field names generated? If so, how can this be achieved? I use the standard way to instantiate the printer and parser for now: private static JsonFormat.TypeRegistry registry = JsonFormat.Ty