Implement round-tripping of BigDecimal values

XMLWordPrintableJSON

    • Type: Improvement
    • Resolution: Fixed
    • Priority: Unknown
    • bson-5.0.0
    • Affects Version/s: None
    • Component/s: BSON
    • None
    • None
    • None
    • None
    • None
    • None
    • None

      The goal of this ticket is to be able to do something like:

      Hash.from_bson({a: BigDecimal('42')}.to_bson)
      

      ... and have that return ...

      {a: BigDecimal('42')}
      

      ... as originally composed.

      This might require a global override or flag to make Decimal128 values deserialize into BigDecimal objects (since currently those are deserialized into BSON::Decimal128 objects). We discussed having such an override in a separate file that must be manually `require`d by user applications.

            Assignee:
            Neil Shweky (Inactive)
            Reporter:
            Oleg Pudeyev (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated:
              Resolved: