[SERVER-83104] Remove the multi-version compatibility patch for `capped` and `numInitialChunk` in change stream shard events tests Created: 10/Nov/23  Updated: 16/Nov/23

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

Type: Bug Priority: Major - P3
Reporter: Enrico Golfieri Assignee: Backlog - Catalog and Routing
Resolution: Unresolved Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Assigned Teams:
Catalog and Routing
Operating System: ALL
Participants:

 Description   

`numInitialChunks` field was not longer supported starting from 7.2 and it has been removed as part of the "shard event" of the change stream.
However in 7.0 numInitialChunks was always sent with a default value of 0.
In case of 7.0 mongos sending a `shardCollection` to a 7.0 shard in a multiversion suite the following tests will fail:

  • shard_collection_event.js
  • ddl_commits_trigger_placement_op_entries.js

The 2 tests do a strict comparison between the bson object received by the change stream and bson object expected by the test. 

To counter that, in SERVER-82877 a special check has been added that removes the `numInitialChunks` from the event coming from the change stream. 

Once 8.0 becomes last lts, we know numInitialChunks is guaranteed not to be part of the change stream and we can safely remove the check.

 

The same applies for the field `capped` which was added to _shardsvrCreateCollection in SERVER-81188 with default value false.
 
 


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