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

Enable success of all upsert commands with _id in the query through writeWithoutShardKey protocol

    • Type: Icon: Task Task
    • Resolution: Fixed
    • Priority: Icon: Major - P3 Major - P3
    • 7.0.0-rc0
    • Affects Version/s: None
    • Component/s: None
    • Labels:
      None
    • Sharding NYC
    • Fully Compatible
    • Sharding NYC 2023-04-03

      Currently, update commands with

      {upsert: true}

      that filter on _id error with:

       {
      	"nMatched" : 0,
      	"nUpserted" : 0,
      	"nModified" : 0,
      	"writeError" : {
      		"code" : 65,
      		"errmsg" : " :: and :: Shard key update is not allowed without specifying the full shard key in the queryFor sharded collections getOwnershipFilter cannot be relied on without a valid shard versionFor sharded collections getOwnershipFilter cannot be relied on without a valid shard version",
      		"errInfo" : {
      			"causedBy" : [
      				{
      					"index" : 0,
      					"code" : 31025,
      					"errmsg" : "Shard key update is not allowed without specifying the full shard key in the query"
      				},
      				{
      					"index" : 0,
      					"code" : 7032301,
      					"errmsg" : "For sharded collections getOwnershipFilter cannot be relied on without a valid shard version"
      				},
      				{
      					"index" : 0,
      					"code" : 7032301,
      					"errmsg" : "For sharded collections getOwnershipFilter cannot be relied on without a valid shard version"
      				}
      			]
      		}
      	}
      }
      

            Assignee:
            sanika.phanse@mongodb.com Sanika Phanse (Inactive)
            Reporter:
            sanika.phanse@mongodb.com Sanika Phanse (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

              Created:
              Updated:
              Resolved: