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

[v6 nice to have] Standardize Connection String Validation Errors and MongoParseError

    • Type: Icon: Improvement Improvement
    • Resolution: Unresolved
    • Priority: Icon: Unknown Unknown
    • None
    • Affects Version/s: None
    • Component/s: None

      We use MongoAPIError interchangeably with MongoParseError when parsing connection string, and, moreover, the connection string module has its own version of the MongoParseError. It would be good to standardize the returned error from validating MongoClient options to at least extend from the same class in all of these different cases. We should probably have a separate type for connection string validation errors because we also use MongoParseError when we are literally unable to parse a message (from, e.g. message_stream), so we should not use a "parse error" in situations where we are able to parse options but they happen to be invalid.

      Any connection string validation should extend from MongoAPIError.

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

              Created:
              Updated: