Uploaded image for project: 'C++ Driver'
  1. C++ Driver
  2. CXX-1197

Client and pool initialization should fail if no instance configured

    XMLWordPrintable

    Details

    • Type: New Feature
    • Status: Open
    • Priority: Major - P3
    • Resolution: Unresolved
    • Affects Version/s: None
    • Fix Version/s: Not planned
    • Component/s: Implementation
    • Labels:
      None

      Description

      Programs that use mongocxx functionality without first creating a mongocxx::instance object are ill-formed. We should attempt to detect this scenario, fail fast, and provide readable error messages to users, where possible.

      One approach to address this is to have the mongocxx::client and mongocxx::pool constructors fail if no instance is configured. This will cover many ill-formed programs, but not all.

        Attachments

          Issue Links

            Activity

              People

              Assignee:
              Unassigned
              Reporter:
              rassi J Rassi
              Participants:
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

                Dates

                Created:
                Updated: