Uploaded image for project: 'Compass '
  1. Compass
  2. COMPASS-7803

Investigate changes in SERVER-43411: add base64 and UUID conversion functions or add BinData $convert

    • Type: Icon: Investigation Investigation
    • Resolution: Done
    • Priority: Icon: Major - P3 Major - P3
    • No version
    • Affects Version/s: None
    • Component/s: None
    • None
    • Not Needed
    • Developer Tools

      Original Downstream Change Summary

      $convert now supports conversions between string and BinData. These conversions must specify a top-level 'format' argument, which can be any of the following: "base64", "base64url", "hex", "uuid", "utf8". A new $toUUID shorthand expression was introduced to convert UUID strings to UUIDs, and $toString now supports BinData input.

      Description of Linked Ticket

      Since $convert doesn't work with BinData types, and there are no helper functions for binary data, nor for UUID in particular, it's very difficult to do something like converting UUID that's stored as a string to a proper BinData format.

      Example: I have string "867dee52-c331-484e-92d1-c56479b8e67e" and I want to have UUID("867dee52-c331-484e-92d1-c56479b8e67e") which is BinData(4, "hn3uUsMxSE6S0cVkebjmfg==") and there doesn't seem to be a way to do that server-side.

            Assignee:
            Unassigned Unassigned
            Reporter:
            backlog-server-pm Backlog - Core Eng Program Management Team
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

              Created:
              Updated:
              Resolved: