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

Enable hinting a COLUMN_SCAN even when it requires a FETCH

    • Type: Icon: Improvement Improvement
    • Resolution: Unresolved
    • Priority: Icon: Major - P3 Major - P3
    • None
    • Affects Version/s: None
    • Component/s: None
    • None
    • Query Execution

      This is going to be tricky due to the observed problem below.

      Original Title

      Failure to allocate Snapshot ID slot for FETCH above COLUMN_SCAN

      Original Description

      I've observed this kind of failure in some of the passthrough suites which execute the columnstore index tests in a sharded cluster:

      [js_test:columnstore_eligibility] uncaught exception: Error: command failed: {
      [js_test:columnstore_eligibility] 	"ok" : 0,
      [js_test:columnstore_eligibility] 	"errmsg" : "Snapshot id slot is not defined",
      [js_test:columnstore_eligibility] 	"code" : 5290701,
      [js_test:columnstore_eligibility] 	"codeName" : "Location5290701",
      [js_test:columnstore_eligibility] 	"$clusterTime" : {
      [js_test:columnstore_eligibility] 		"clusterTime" : Timestamp(1651843587, 40),
      [js_test:columnstore_eligibility] 		"signature" : {
      [js_test:columnstore_eligibility] 			"hash" : BinData(0,"AAAAAAAAAAAAAAAAAAAAAAAAAAA="),
      [js_test:columnstore_eligibility] 			"keyId" : NumberLong(0)
      [js_test:columnstore_eligibility] 		}
      [js_test:columnstore_eligibility] 	},
      [js_test:columnstore_eligibility] 	"operationTime" : Timestamp(1651843587, 40)
      [js_test:columnstore_eligibility] } with original command request: {
      [js_test:columnstore_eligibility] 	"aggregate" : "columnstore_eligibility",
      [js_test:columnstore_eligibility] 	"pipeline" : [
      [js_test:columnstore_eligibility] 		{
      [js_test:columnstore_eligibility] 			"$group" : {
      [js_test:columnstore_eligibility] 				"_id" : "$a"
      [js_test:columnstore_eligibility] 			}
      [js_test:columnstore_eligibility] 		}
      [js_test:columnstore_eligibility] 	],
      [js_test:columnstore_eligibility] 	"explain" : true,
      [js_test:columnstore_eligibility] 	"cursor" : {
      [js_test:columnstore_eligibility] 
      [js_test:columnstore_eligibility] 	}, 

      This kind of plan should be rare but is possible for now until we do SERVER-65466. It will also be possible if the columnstore index was hinted after SERVER-62985 is merged.

            Assignee:
            backlog-query-execution [DO NOT USE] Backlog - Query Execution
            Reporter:
            charlie.swanson@mongodb.com Charlie Swanson
            Votes:
            0 Vote for this issue
            Watchers:
            4 Start watching this issue

              Created:
              Updated: