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

Make ClientEncryption compatible with a unconnected clients

    • 2
    • Not Needed

      The ClientEncryption class requires a dynamically provided `bson` library to use for encryption in FLE.  By default, the driver stores bson (the bson library) on the topology.  When a ClientEncryption is created, a user can provide bson manually.  If no bson library is provided, ClientEncryption pulls `bson` from the provided client's topology.  The topology isn't created on the MongoClient until the client is connected so for clients that are not connected the ClientEncryption constructor errors.

      Now that auto-connect works with the node driver, users could pass in an unconnected client to the clientencryption class but would receive an error.

      Acceptance Criteria

      • Export BSON from mongodb module as internal
      • Update libmongocrypt Node bindings tests to use the exported BSON and remove bson dev dependency
      • Attempt to use exported BSON from mongodb in the Node bindings and fallback to options.bson or topology.bson when not found.

            Assignee:
            durran.jordan@mongodb.com Durran Jordan
            Reporter:
            bailey.pearson@mongodb.com Bailey Pearson
            Neal Beeken
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

              Created:
              Updated:
              Resolved: