Uploaded image for project: 'Node.js Driver'
  1. Node.js Driver
  2. NODE-4356

Update implementation of rewrapManyDataKey to use UpdateOne operations

    • Type: Icon: Task Task
    • Resolution: Done
    • Priority: Icon: Unknown Unknown
    • None
    • Affects Version/s: None
    • Component/s: None
    • Not Needed

      rewrapManyDataKey currently works by performing a rewrap operation using the state machine, and then performs a bulkWrite operation to replace each modified key in the key vault (using ReplaceOne).  https://github.com/mongodb/libmongocrypt/pull/382 updates the return value of the rewrap operation in the state machine to include only the necessary keys for an update operation instead of the whole documents.  Without updating our implementation of rewrapManyDataKey, we now will replace documents in the keyvault with incomplete documents.

      Acceptance Criteria

      • Update the internals of rewrapManyDataKey to use a bulkWrite of UpdateOne operations instead of ReplaceOne operations.

            Assignee:
            anna.henningsen@mongodb.com Anna Henningsen
            Reporter:
            bailey.pearson@mongodb.com Bailey Pearson
            Bailey Pearson
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated:
              Resolved: