zserio icon indicating copy to clipboard operation
zserio copied to clipboard

Consider to create separated Zserio encoding guide

Open mikir opened this issue 2 years ago • 2 comments

Currently, there is no enconding guide available for Zserio. This is because at the beginning, zserio does not have a wire format.

However now, Zserio contains some advanced features like auto arrays, packed arrays, which encoding is described in Zserio Invisibles document.

But for example encoding of integers (Big Endian) is described in Zserio Language Overview document.

It would be probably better to create new Zserio encoding guide with all information regarding zserio encoding.

mikir avatar Mar 15 '22 08:03 mikir

An encoding guide would have been very helpful when we implemented go-zserio. We relied a lot on reverse engineering the expected behaviour from the zserio Python library and generated Python code to figure things out. It would also be very helpful if there was a set of validation data or tools that can be used to check if (de)serializing works correctly.

wichert avatar May 16 '22 09:05 wichert

Not sure if this is applicable for you but if you are using our Java extension mechanism, you might consider to use our tests for validation of serialization/deserialization:

We are using our test framework stored in test directory. There are plenty of small schema samples. Some of them produce binary blobs on the file system. Then, we are using script to compare that all generated blobs from all generators are the same.

mikir avatar May 17 '22 13:05 mikir

The encoding guide should cover also JSON format.

mikir avatar Feb 21 '23 11:02 mikir

The Zserio encoding guide does not cover JSON format and is available here.

JSON format document will be created separately within issue #471.

mikir avatar Aug 08 '23 07:08 mikir