diff --git a/source/applications/design-notes.txt b/source/applications/design-notes.txt index bfcaafb9354..f23035f4ca8 100644 --- a/source/applications/design-notes.txt +++ b/source/applications/design-notes.txt @@ -53,10 +53,10 @@ Consider: Type Sensitive Fields ~~~~~~~~~~~~~~~~~~~~~ -MongoDB data is stored in the :meta-driver:`BSON ` -format, a binary encoded serialization of JSON-like documents. BSON -encodes additional type information. See `bsonspec.org -`_ for more information. +MongoDB data is stored in the BSON format, a binary encoded +serialization of JSON-like documents. BSON encodes additional type +information. See `bsonspec.org `_ +for more information. Consider the following document which has a field ``x`` with the *string* value ``"123"``: diff --git a/source/core/cursors.txt b/source/core/cursors.txt index bf4514ab20d..34f4a933ee2 100644 --- a/source/core/cursors.txt +++ b/source/core/cursors.txt @@ -41,11 +41,10 @@ Closure of Inactive Cursors By default, the server will automatically close the cursor after 10 minutes of inactivity or if client has exhausted the cursor. To -override this behavior, you can specify the ``noTimeout`` -:meta-driver:`wire protocol flag ` in -your query; however, you should either close the cursor manually or -exhaust the cursor. In the :program:`mongo` shell, you can set the -``noTimeout`` flag: +override this behavior, you can specify the ``noTimeout`` flag in your +query using :method:`cursor.addOption()`; however, you should either +close the cursor manually or exhaust the cursor. In the +:program:`mongo` shell, you can set the ``noTimeout`` flag: .. code-block:: javascript diff --git a/source/includes/apiargs-method-cursor.addOption-param.yaml b/source/includes/apiargs-method-cursor.addOption-param.yaml index f614f41d18b..5c1a021fb21 100644 --- a/source/includes/apiargs-method-cursor.addOption-param.yaml +++ b/source/includes/apiargs-method-cursor.addOption-param.yaml @@ -1,11 +1,8 @@ arg_name: param description: | - ``OP_QUERY`` wire protocol flag. See :meta-driver:`MongoDB wire - protocol ` - for more information on MongoDB Wire Protocols and the OP_QUERY flags. - For the :program:`mongo` shell, you can use :ref:`cursor flags - `. For the driver-specific list, see your :doc:`driver - documentation `. + ``OP_QUERY`` wire protocol flag. For the :program:`mongo` shell, + you can use the cursor flags listed below. For the driver-specific + list, see your :doc:`driver documentation `. interface: method name: flag operation: cursor.addOption diff --git a/source/reference/method/cursor.addOption.txt b/source/reference/method/cursor.addOption.txt index 4ea910f5066..f9a22aeb433 100644 --- a/source/reference/method/cursor.addOption.txt +++ b/source/reference/method/cursor.addOption.txt @@ -24,22 +24,38 @@ Flags The :program:`mongo` shell provides several additional cursor flags to modify the behavior of the cursor. -.. data:: DBQuery.Option.tailable - -.. data:: DBQuery.Option.slaveOk - -.. data:: DBQuery.Option.oplogReplay - -.. data:: DBQuery.Option.noTimeout - -.. data:: DBQuery.Option.awaitData - -.. data:: DBQuery.Option.exhaust - -.. data:: DBQuery.Option.partial - -For a description of the flags, see -:meta-driver:`MongoDB wire protocol `. +.. list-table:: + :header-rows: 1 + :widths: 30 70 + + * - Flag + - Description + + * - .. data:: DBQuery.Option.tailable + - Sets the cursor not to close once the last data is + received, allowing the query to continue returning data added + after the initial results were exhausted. + + * - .. data:: DBQuery.Option.slaveOk + - Allows querying of a replica slave. + + * - .. data:: DBQuery.Option.noTimeout + - Prevents the server from timing out idle cursors. + + * - .. data:: DBQuery.Option.awaitData + - For use with .. data:: DBQuery.Option.tailable; sets the cursor + to block and await data for a while rather than returning no + data. The cursor will return no data once the timeout has + expired. + + * - .. data:: DBQuery.Option.exhaust + - Sets the cursor to return all data returned by the + query at once rather than splitting the results into batches. + + * - .. data:: DBQuery.Option.partial + - Sets the cursor to return partial data from a query against a + sharded cluster in which some shards do not respond rather than + throwing an error. Example ------- diff --git a/source/release-notes/2.0.txt b/source/release-notes/2.0.txt index 8163b5c6c2c..9ffc6bf4f64 100644 --- a/source/release-notes/2.0.txt +++ b/source/release-notes/2.0.txt @@ -322,8 +322,6 @@ command will report whether any inserts have failed, not just the last one. If multiple errors occur, the client will only receive the most recent :dbcommand:`getLastError` results. -See :meta-driver:`OP_INSERT `. - .. include:: /includes/note-bulk-inserts-on-sharded-clusters.rst Map Reduce diff --git a/source/tutorial/create-tailable-cursor.txt b/source/tutorial/create-tailable-cursor.txt index a9ba0af6dff..2464d69ee16 100644 --- a/source/tutorial/create-tailable-cursor.txt +++ b/source/tutorial/create-tailable-cursor.txt @@ -54,10 +54,7 @@ Consider the following behaviors related to tailable cursors: A *dead* cursor has an id of ``0``. See your :doc:`driver documentation ` for the -driver-specific method to specify the tailable cursor. For more -information on the details of specifying a tailable cursor, see -:meta-driver:`MongoDB wire protocol ` -documentation. +driver-specific method to specify the tailable cursor. C++ Example -----------