Allow passing Mongo instance as first argument to Mongo ctor

XMLWordPrintableJSON

    • Type: Task
    • Resolution: Fixed
    • Priority: Major - P3
    • 1.6.1
    • Affects Version/s: None
    • Component/s: Shell API
    • None
    • 1
    • Iteration Octopus
    • Needed
    • Hide

      Mongo(db.getMongo()) now creates a Mongo instance with the same connection string as the original Mongo instance.

      Show
      Mongo(db.getMongo()) now creates a Mongo instance with the same connection string as the original Mongo instance.

      This is a hopefully less controversial alternative to MONGOSH-545. I frequently find myself writing Mongo(db.getMongo()._uri), but since _uri is not public or supported and might not become at any point, it would be nice if at least Mongo(db.getMongo()) worked (with the same semantics).

              Assignee:
              Anna Henningsen
              Reporter:
              Anna Henningsen
              Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

                Created:
                Updated:
                Resolved: