Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Replace bincode with borsh #452

Merged
merged 8 commits into from
Nov 25, 2023
Merged

Replace bincode with borsh #452

merged 8 commits into from
Nov 25, 2023

Conversation

kayabaNerve
Copy link
Member

Replaces a non-canonical encoding with a canonical encoding which additionally may be faster slightly faster, yet at least is effectively the same.

Also fixes multiple issues such as:

  • Usage of bincode (a non-canonical format) in transcripts
  • create_db! not binding to type in set, correction of which raised further errors

And causes improvements such as:

  • No-longer JSON encoding processor messages in a nested byte buffer. A further PR should move message-queue off HTTP JSON-RPC to raw sockets entirely.
  • Not needing a Vec for some processor messages, as we can now use [u8; 64]
  • 10-20% reduced disk usage, per generic benchmark results present in https://github.com/djkoloski/rust_serialization_benchmark.

While this was initially meant to be an experiment like the QUIC branch, the observed issues and included fixes necessitate merging of this branch or porting it to a new PR and merging that.

Replaces a non-canonical encoding with a canonical encoding which additionally
should be faster.

Also fixes an issue where we used bincode in transcripts where it cannot be
trusted.

This ended up fixing a myriad of other bugs observed, unfortunately.
Accordingly, it either has to be merged or the bug fixes from it must be ported
to a new PR.
@kayabaNerve kayabaNerve added bug Something isn't working improvement This could be better processor coordinator labels Nov 25, 2023
@kayabaNerve kayabaNerve merged commit b296be8 into develop Nov 25, 2023
19 checks passed
@kayabaNerve kayabaNerve deleted the borsh branch November 25, 2023 09:01
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working coordinator improvement This could be better processor
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant