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

Spike: Consistent ssl option handling

    • 2
    • Not Needed
    • Not Needed
    • Hide

      1. What would you like to communicate to the user about this feature?
      2. Would you like the user to see examples of the syntax and/or executable code and its output?
      3. Which versions of the driver/connector does this apply to?

      Show
      1. What would you like to communicate to the user about this feature? 2. Would you like the user to see examples of the syntax and/or executable code and its output? 3. Which versions of the driver/connector does this apply to?

      Context:
      Currently, currently we support nodejs-equivalents of the ssl/tls options in addition to the mongo-specific ssl- and tls- prefixed ones. However, ssl-prefixed options aren't driver spec anymore, they were removed in the common spec in favor of tls-prefixed ones, which means we should probably move away from supporting them.

      Our mongo_client.ts code comment about the option equivalencies does not have the full set of equivalencies indicated (e.g., there are some ssl options that don't have tls equivalents indicated).

      Moreover, sslPass is marked deprecated:true in the options parser, but none of the other options are marked similarly, and it's not marked deprecated in the TS definition of the client options.

      We should decide which set of options we are going to support moving forward, because supporting multiple equivalent options is likely to lead to use confusion and the precedence of equivalent options relative to each other is not clearly defined, so it ends up being left up to chance.

      Note: Shell already warns users on ssl-prefixed options and translates them to preferred equivalents.

      AC

      • Cross reference the drivers spec to determine exactly which tls/ssl related options must be supported for spec compliance (double check whether we want the same or different set for connection string vs client constructor)
      • Confirm the current option precedence behavior for equivalent options as well as those with overlapping functionality
      • Update the code comment in mongo_client.ts to clearly denote options required for spec compliance and the option equivalencies
      • Determine which options should be deprecated and file a follow up ticket for the deprecations

            Assignee:
            durran.jordan@mongodb.com Durran Jordan
            Reporter:
            daria.pardue@mongodb.com Daria Pardue
            Daria Pardue
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

              Created:
              Updated:
              Resolved: