Thanks for that, I think there’s a far bigger use case than simply debugging for this: interoperation with comments that don’t use thrift.
Can I ask I really dumb question, being a member of generation z, mailing lists are quite alien to be, how do I do a full text search of it? Rollo > On 8 Feb 2021, at 11:39, Jens Geyer <jensge...@hotmail.com> wrote: > > > I might add that there is JSON protocol and SimpleJSON protocol. While the > forner is intended to works as a fully fledged protocol, the latter is not. > AFAIK the idea was to have a write-only, human-readable format. > > Regarding RPC in general and Thrift in particular there is a goal conflict: > The primary goal is to have RPC serialization/deserialization as fast as > possible, and this goal by no means includes human-readability as a > requirement (in fact, it's most often the exact opposite). > > Of course some other secondary use cases do exist, e.g. developers during > debugging sessions, maybe logging or whatever else comes to mind, but they > may also come with conflicting requirements - parsing human readable stuff is > usually way more complex than reading 8 bytes from a byte array that form a > double. > > Have fun, > JensG > > > -----Ursprüngliche Nachricht----- From: Jens Geyer > Sent: Monday, February 8, 2021 12:16 PM > To: user@thrift.apache.org > Subject: Re: Extending the SimpleJSONProtocol for reading > > Yes, there have been numerous attempts. You may be able to find via mailing > list search. > > Sent from mobile device. You know what that means... > > ________________________________ > From: Rollo Konig-Brock <roll...@gmail.com> > Sent: Monday, February 8, 2021 11:04:35 AM > To: user@thrift.apache.org <user@thrift.apache.org> > Subject: Extending the SimpleJSONProtocol for reading > > Hey all, > > I am looking to document a websocket connection and I’m considering Apache > Thrift with a SimpleJSON protocol. However you can’t deserialize using > SimpleJSON. > > I don’t quite see the practical problem of implementing read methods for > simple json; as long as the types defined in your structs are also JSON types > (that is, strings, floats, arrays, dicts, and bools), you can parse things. > > Before I go galivanting off to implement something wholly inadvisable, has > anyone attempted to do this? And what were the successes and failures? > > Rollo