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

Improve mongocxx::instance documentation

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Major - P3
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: 3.2.0-rc0
    • Component/s: Documentation
    • Labels:
      None
    • Story Points:
      1
    • Sprint:
      Perl/CXX 2017-03-24

      Description

      mongocxx::instance is under-documented and difficult to use correctly. We should make the following improvements to our documentation of mongocxx::instance:

      • The mongocxx "Quick Start" page under "Tutorial for mongocxx" does not mention mongocxx::instance. We should add a section which explains what mongocxx::instance is, and also makes a recommendation to users on how to manage this object.
      • All mongocxx examples should contain a code comment indicating that creating a mongocxx::instance object is necessary to initialize the driver.
      • The class comment for instance.hpp should be expanded. In particular, it should:
        • Indicate explicitly that the mongocxx::instance constructor initializes the driver and that mongocxx::instance destructor shuts down the driver.
        • Explain that instantiating mongocxx::instance more than once in the same program is an error (even if the objects have non-overlapping lifetimes).
        • Contain a short example of basic correct usage of mongocxx::instance.
        • Contain an example of common incorrect usage of mongocxx::instance.
        • Refer users to the "instance_management" example for advanced mongocxx::instance usage.

        Attachments

          Issue Links

            Activity

              People

              • Votes:
                0 Vote for this issue
                Watchers:
                2 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved: