-
Type: Bug
-
Resolution: Gone away
-
Priority: Major - P3
-
None
-
Affects Version/s: None
-
Component/s: None
-
None
-
Catalog and Routing
-
ALL
-
CAR Team 2024-08-05
-
2
We have a two shard cluster. Create a timeseries collection on it, and then modify the bucketing params:
mongos> db.createCollection( "tscoll", { timeseries: { timeField: "timestamp", bucketMaxSpanSeconds: 100, bucketRoundingSeconds: 100 } } ) mongos> db.runCommand({ collMod: "tscoll", timeseries: { bucketRoundingSeconds: 201, bucketMaxSpanSeconds: 201 } })
We can see that the timeseriesBucketingParametersHaveChanged is set to true:
mongos> use admin mongos> db.aggregate([{$listCatalog: {}}, {$match: {name: /buckets.tscoll/}}]).pretty() { "db" : "test", "name" : "system.buckets.tscoll", "type" : "collection", "shard" : "shard-rs1", "md" : { "ns" : "test.system.buckets.tscoll", "options" : { ... "timeseries" : { "timeField" : "timestamp", "bucketRoundingSeconds" : 201, "bucketMaxSpanSeconds" : 201 } }, "indexes" : [ ], "timeseriesBucketsMayHaveMixedSchemaData" : false, "timeseriesBucketingParametersHaveChanged" : true }, "idxIdent" : { }, "ns" : "test.system.buckets.tscoll", "ident" : "collection-50-2538635120092599498" }
Initiate movePrimary:
mongos> db.adminCommand({movePrimary: 'test', to: 'shard-rs0'}) mongos> use admin mongos> db.aggregate([{$listCatalog: {}}, {$match: {name: /buckets.tscoll/}}]).pretty() { "db" : "test", "name" : "system.buckets.tscoll", "type" : "collection", "shard" : "shard-rs0", "ns" : "test.system.buckets.tscoll", "ident" : "collection-59-3693464124440949550", "md" : { "ns" : "test.system.buckets.tscoll", "options" : { ... "clusteredIndex" : true, "timeseries" : { "timeField" : "timestamp", "bucketRoundingSeconds" : 201, "bucketMaxSpanSeconds" : 201 } }, "indexes" : [ ], "timeseriesBucketsMayHaveMixedSchemaData" : false, "timeseriesBucketingParametersHaveChanged" : false } }
Found on base commit: cdbd4b3f1c03cac745e81f3b7d538775ce78992d
- related to
-
SERVER-87927 movePrimary + FCV downgrade race could potentially result in timeseriesBucketingParametersHaveChanged existing on 7.0
- Closed