MongoDB Enterprise > db.createCollection("c", {timeseries: {timeField: "t"}})
|
{ "ok" : 1 }
|
MongoDB Enterprise > db.system.views.find()
|
{ "_id" : "test.c", "viewOn" : "system.buckets.c", "pipeline" : [ { "$_internalUnpackBucket" : { "timeField" : "t", "bucketMaxSpanSeconds" : 3600 } } ] }
|
MongoDB Enterprise > db.adminCommand({applyOps: [{"op": "d", "ns": "test.system.views", "o": {"_id": "test.c"}}]})
|
{ "applied" : 1, "results" : [ true ], "ok" : 1 }
|
MongoDB Enterprise > db.system.views.find()
|
MongoDB Enterprise > db.c.insert({t: ISODate()})
|
WriteResult({ "nInserted" : 1 })
|
MongoDB Enterprise > db.system.buckets.find()
|
MongoDB Enterprise > db.system.buckets.c.find()
|
{ "_id" : ObjectId("63e574602386bee9e7ef7a75"), "control" : { "version" : 1, "min" : { "_id" : ObjectId("63e574734ba6a20dd8db3782"), "t" : ISODate("2023-02-09T22:32:00Z") }, "max" : { "_id" : ObjectId("63e574734ba6a20dd8db3782"), "t" : ISODate("2023-02-09T22:32:19.951Z") } }, "data" : { "_id" : { "0" : ObjectId("63e574734ba6a20dd8db3782") }, "t" : { "0" : ISODate("2023-02-09T22:32:19.951Z") } } }
|