-
Notifications
You must be signed in to change notification settings - Fork 1.8k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feat: Add MongoOptions interface #2616
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM, with one small readability nit
ba4fe1f
to
e61706c
Compare
Adds MongoOptions representing the internal view of the specified options. NODE-2698
e61706c
to
956b500
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM, left a single thought but I don't feel strong about it at all
/** | ||
* Turn these options into a reusable connection URI | ||
*/ | ||
toURI(): string; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
toURI(): string; | |
toConnectionString(): string; |
just a thought? I'm the one that introduced calling it a URI, but I think the consensus across the drivers and the company is calling it a connection string
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Connection String URI Format
It's one of those both ways is right, I'll leave it as is, and we can consider renaming it when we get to the ticket that implements it since there might be some questions about how we want to expose it. These options are supposed to be internal, kind of, so is it something we'd want people to use: client.options.toURI()
or would we surface something on the client itself.
Adds MongoOptions representing the internal view of the specified options.
NODE-2698
A number of options are seemingly omitted but instead are brought in by extending NodeJS's connection options. Particularly with tls options we have a number of translations from ssl to tls options and then another set of translations to NodeJS's equivalent definition. I've left documentation of the equivalent names and they will be resolved by the following work.