Uploaded image for project: 'Core Server'
  1. Core Server
  2. SERVER-9738

mongos should set the CursorNotFound bit when the cursor is not found

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Major - P3
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: 2.4.7, 2.5.1
    • Component/s: Sharding
    • Labels:
      None
    • Operating System:
      ALL

      Description

      MongoDB Status as of October 9th, 2013

      ISSUE SUMMARY
      mongos does not set the CursorNotFound bit in the response when the cursor is not found for unsharded collections. Instead it sets the QueryFailure bit. See the response definition here.

      USER IMPACT
      The wrong message will be returned to the user through their client driver. It is present in versions of MongoDB prior to and including v2.4.6.

      SOLUTION
      The issue has been solved by bringing the behavior of mongos into accordance with mongod and mongos with sharded collections.

      WORKAROUNDS
      None

      PATCHES
      Production release v2.4.7 contains the fix for this issue, and production release v2.6.0 will contain the fix as well.

      Original Description

      Instead, it sets the QueryFailure bit.

      See http://docs.mongodb.org/meta-driver/latest/legacy/mongodb-wire-protocol/#op-reply.

      Drivers typically have different exception types for these two bits, so end up throwing a different exception when running against a shard cluster.

        Attachments

          Activity

            People

            • Votes:
              1 Vote for this issue
              Watchers:
              6 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: