diff options
author | Joey Hess <joeyh@joeyh.name> | 2017-04-21 12:16:38 -0400 |
---|---|---|
committer | Joey Hess <joeyh@joeyh.name> | 2017-04-21 13:19:06 -0400 |
commit | e336a4fdf3d55f01b8c2871ceb906544a493eeb7 (patch) | |
tree | b3af043b4323b0f353baef44439d786ae6d55bd2 /TODO | |
parent | c4a04ead453bf783b79c5c0b263f657275794b25 (diff) | |
download | debug-me-e336a4fdf3d55f01b8c2871ceb906544a493eeb7.tar.gz |
use cereal for efficient serialization for wire format
I tried both binary and cereal. For a ActivityMessage that takes 341
bytes in JSON and has a dataSize of 129, both used 165 bytes. Went with
cereal since lazy bytestrings are not needed, and I might want to use
https://hackage.haskell.org/package/safecopy later.
(Perhaps I should be using protocol buffers or something to make it
easier for non-haskell implementations? But that would complicate things
a lot.)
Diffstat (limited to 'TODO')
-rw-r--r-- | TODO | 6 |
1 files changed, 2 insertions, 4 deletions
@@ -1,7 +1,5 @@ -* JSON serialization of signatures uses base64, and - does not compress well. gzip -9 of just the base64 signature - is 113 bytes, double the 64 byte actual size. Find a more efficient - encoding for bytestrings in JSON. +* Use protobuf for serialization, to make non-haskell implementations + easier? * Leave the prevMessage out of Activity serialization to save BW. Do include it in the data that gets signed, so it can be recovered by trying each likely (recently seen) Activity as the prevMessage, and |