[SERVER-47842] [4.4] listIndexes with includeBuildUUIDs=true in FCV 4.2 reports in-progress index build as completed Created: 29/Apr/20  Updated: 16/Nov/20  Resolved: 16/Nov/20

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

Type: Bug Priority: Minor - P4
Reporter: Benety Goh Assignee: Benety Goh
Resolution: Won't Fix Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Issue Links:
Related
is related to SERVER-46659 Make initial sync work with two phase... Closed
is related to SERVER-37839 Identify in-progress index builds as ... Closed
is related to SERVER-37980 Add a function to the index builds in... Closed
is related to SERVER-44408 Persist index build UUID to the durab... Closed
Operating System: ALL
Sprint: Execution Team 2020-06-29, Execution Team 2020-07-13, Execution Team 2020-09-21, Execution Team 2020-11-16, Execution Team 2020-11-30
Participants:

 Description   

On a collection t with two indexes a_1 (ready) and b_1 (in-progress), the listIndexes command with the option includeBuildUUIDs set to true reports slightly different results for the index b_1 across 4.4 (with FCV=4.2) and a 4.2 binary:

4.2 binary:

foo:PRIMARY> db.runCommand({listIndexes: 't', includeBuildUUIDs: true})
{
	"cursor" : {
		"id" : NumberLong(0),
		"ns" : "test.t",
		"firstBatch" : [
			{
				"v" : 2,
				"key" : {
					"_id" : 1
				},
				"name" : "_id_",
				"ns" : "test.t"
			},
			{
				"v" : 2,
				"key" : {
					"a" : 1
				},
				"name" : "a_1",
				"ns" : "test.t"
			},
			{
				"spec" : {
					"v" : 2,
					"key" : {
						"b" : 1
					},
					"name" : "b_1",
					"ns" : "test.t"
				},
				"buildUUID" : UUID("2deadfcd-c9c3-4f18-8875-3a2f30294bf3")
			}
		]
	},
	"ok" : 1,
        ...
}
 

4.4 binary (with FCV 4.2):

 foo:PRIMARY> db.runCommand({listIndexes: 't', includeBuildUUIDs: true})
{
	"cursor" : {
		"id" : NumberLong(0),
		"ns" : "test.t",
		"firstBatch" : [
			{
				"v" : 2,
				"key" : {
					"_id" : 1
				},
				"name" : "_id_"
			},
			{
				"v" : 2,
				"key" : {
					"a" : 1
				},
				"name" : "a_1"
			},
			{
				"v" : 2,
				"key" : {
					"b" : 1
				},
				"name" : "b_1"
			}
		]
	},
	"ok" : 1,
        ...
}

The includeBuildUUIDs option is an experimental option for the listIndexes command in 4.2 and is not currently used in 4.4 (with FCV 4.2).



 Comments   
Comment by Benety Goh [ 16/Nov/20 ]

The FCV 4.2 and listIndexes option combination described in this ticket is not used in production.

Comment by Benety Goh [ 13/Nov/20 ]

When the includeBuildUUIDs option was first introduced in SERVER-37839, the listIndexes command would return a randomly generated index build UUID. We started returning the real index build UUID (saved in the durable catalog in SERVER-44408) in SERVER-37980 which is intended to support downstream processes in identifying two-phase index builds.

It would be confusing to re-introduce the random UUID behavior in FCV 4.2, especially since downstream processes running in either FCV 4.2 or 4.2 binaries are not expected to use the includeBuildUUIDs option.

Generated at Thu Feb 08 05:15:24 UTC 2024 using Jira 9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66.