[SERVER-66284] Enable hinting a COLUMN_SCAN even when it requires a FETCH Created: 06/May/22  Updated: 24/Jan/23

Status: Open
Project: Core Server
Component/s: None
Affects Version/s: None
Fix Version/s: None

Type: Improvement Priority: Major - P3
Reporter: Charlie Swanson Assignee: Backlog - Query Execution
Resolution: Unresolved Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Issue Links:
Depends
depends on SERVER-62985 Change query planner to generate colu... Closed
Related
is related to SERVER-65466 Include shard filters in columnar ind... Closed
is related to SERVER-66101 Plumb column index information from c... Closed
Assigned Teams:
Query Execution
Participants:

 Description   

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.


Generated at Thu Feb 08 06:04:59 UTC 2024 using Jira 9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66.