Hi Guys,
I need help with the below:
I haven't been able to find an example of how to send JSON response as
protobuff message. Please note that my JSON response changes so I cant
define the schema inside the protobuf message.
i've defined my message as:
message Entity {
// The entity's key.
string key = 1;
// The entity's properties.
google.protobuf.Struct data = 2;
}
as Struct seems to be the appropriate json equivalent in protobuf.
But if i try to send the below response back, i get error that "key" is not
defined.
{
"key": "xyz",
"data": {
"name": "joe",
"age": 28
}
}
Any examples in python/java to solve this are welcomed.
Thanks,
Sid
--
You received this message because you are subscribed to the Google Groups
"Protocol Buffers" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
To post to this group, send email to [email protected].
Visit this group at https://groups.google.com/group/protobuf.
For more options, visit https://groups.google.com/d/optout.