Skip to content

Replace flatbuffers #2121

@ry

Description

@ry

Our benchmarks are finally at the point where we're able to measure the overhead of serialization. The gap below is due to serialization:
Screen Shot 2019-04-15 at 1 13 19 PM
Flatbuffers appears to now be our bottleneck (see benchmarks in #1966)

Here are our requirements for a new serialization library:

  1. Supports Rust and TypeScript.
  2. Generated Rust code complicates our build system. Ideally we could specify the message schema using Rust structs to avoid this.
  3. Must be able to serialize into existing byte slice (&[u8] in Rust or Uint8Array in JS). That is, it should not return a newly allocated slice.
  4. Must support (at minimum) String and i32 types within a struct.
  5. At minimum be able to handle 200k serialization/deserialization per second. But probably needs to be more like 2m/sec in order to close the above throughput gap

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions