Preserve unknown Protobuf fields not implemented in Ocaml?

16 views
Skip to first unread message

Koen De Keyser

unread,
Jan 15, 2014, 9:10:18 AM1/15/14
to pi...@googlegroups.com
I noticed an old thread where it was requested to preserve the unknown fields, which was then implemented for the Erlang code generation. Am I correct that this currently is not available in the Ocaml code? I've been playing a bit with Piqi in Ocaml, but have not been able to get this to work. If so, are there any plans to add this feature to the Ocaml code generation as well?

thanks,

Koen

Anton Lavrik

unread,
Jan 16, 2014, 4:13:07 AM1/16/14
to pi...@googlegroups.com
Hi Koen,

Just pushed this to master [1]. I verified that the existing tests pass with and without --gen-preserve-unknown-fields However, I haven't tested preserving unknown fields per se.

Can you test it and let me know if it works?

By the way, things are done slightly differently in master compared to the stable piqi-ocaml release. Two notable changes include renaming and rewriting "piqic" as "piqic-ocaml" and changing the names of the runtime libraries. You can just follow the examples. They are up-to-date and so is doc/ocaml.md

Thanks,

Anton




--
You received this message because you are subscribed to the Google Groups "piqi" group.
To unsubscribe from this group and stop receiving emails from it, send an email to piqi+uns...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.

Koen De Keyser

unread,
Jan 17, 2014, 5:00:31 AM1/17/14
to pi...@googlegroups.com
Hi Anton,

Thanks for the fast reply and code changes. I've did a first quick test with a modified address book example, and this indeed works. I'm planning on testing some more and converting this scenario to an automated test. In the mean time, I forked the project on github to be able to contribute back. There was a small omission in the piqic-ocaml command line tool code, for which I've sent a pull request.

Koen

Anton Lavrik

unread,
Jan 18, 2014, 1:33:01 AM1/18/14
to pi...@googlegroups.com
Hi Koen,

I'm happy to hear it worked and thank you for your help with testing and for the fix. Welcome to the Piqi community!

By the way, I'm working on separating the ocaml-specific parts and moving them to a separate repository.This includes piqic-ocaml, piqirun-ocaml, ocaml examples, documentation and tests. I'll send an email to the list when it's done.

Anton



--
Reply all
Reply to author
Forward
0 new messages