Go package for serializing/deserializing Rust bincode?

101 views
Skip to first unread message

awaw...@gmail.com

unread,
Jun 20, 2026, 9:12:51 AM (4 days ago) Jun 20
to golang-nuts
One of the most popular serializing/deserializing format in Rust is bincode.
I wonder is there a Go package for dealing with data encoded in the above bincode format?
Thanks!

Jason E. Aten

unread,
Jun 21, 2026, 1:33:30 AM (3 days ago) Jun 21
to golang-nuts
but I would strongly recommend using a serialization format that allows for struct field versioning instead. 

Otherwise the moment you need to change your data structure, all other already stored data becomes
lost. Google needed field versioning so instead of using classic Sun XDR RPC, they created protocol buffers.
This let them do rolling cluster upgrades, as just one example, without taking down an
entire cluster of hundreds of computers at once to upgrade all the software on all machines in unison.

For more, see the discussion in the greenpack README. Greenpack is simply msgpack with a versioning convention.
https://github.com/glycerine/greenpack

awaw...@gmail.com

unread,
Jun 21, 2026, 1:54:03 AM (3 days ago) Jun 21
to golang-nuts
Thanks Jason for recommending the above package. However, it seems to cover only basic types and lack the ability to handle `struct`s.

Also, thanks for pointing out the important issue of versioning. I agree versioning is extremely critical, and I wonder why the Rust community never thought of that.
Bincode and Borsh are used by 99% of Rust programmers and yet both don't seem to do versioning.
Reply all
Reply to author
Forward
0 new messages