Uploaded image for project: 'Rust Driver'
  1. Rust Driver
  2. RUST-1992

bson: decouple en/decoding from [de]serialization

    • Type: Icon: Task Task
    • Resolution: Unresolved
    • Priority: Icon: Unknown Unknown
    • bson-3.0.0
    • Affects Version/s: None
    • Component/s: None
    • None
    • Rust Drivers

      The Rust bson crate supports all of these features:

      • en/decoding bson values from byte buffers
      • en/decoding bson values from extjson values
      • [de]serializing arbitrary values from byte buffers containing encoded bson
      • [de]serializing arbitrary values from bson values
      • [de]serializing bson values from arbitrary formats

      The en/decoding functionality is core to bson; [de]serialization is Rust-specific integration with serde and ideally would be implemented in terms of the core en/decoding and be optional behind a feature flag.

      Unfortunately, right now both the public API and internal implementation have badly conflated en/decoding and [de]serialization. Fixing this will give more consistent behavior and API and make the library code much more maintainable.

            Assignee:
            abraham.egnor@mongodb.com Abraham Egnor
            Reporter:
            abraham.egnor@mongodb.com Abraham Egnor
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated: