[SERVER-80929] Drop of sharded system.buckets yields confusing error Created: 09/Sep/23  Updated: 30/Jan/24  Resolved: 30/Jan/24

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

Type: Bug Priority: Major - P3
Reporter: Felipe Gasper Assignee: Backlog - Storage Execution Team
Resolution: Duplicate Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Issue Links:
Depends
depends on SERVER-84589 Error when directly dropping a sharde... Closed
Assigned Teams:
Storage Execution
Operating System: ALL
Steps To Reproduce:

See script given in description.

Participants:

 Description   

db = db.getSiblingDB("test");
db.getSiblingDB("admin").runCommand({ shardCollection: "test.weather", timeseries: { timeField: "timestamp", metaField: "metadata" }, key: {timestamp: 1} });
db.system.buckets.weather.drop()

The above fails with this error in v6.0.9:

MongoServerError: drop collection of a sharded time-series collection is not supported

This error is misleading; it seems quite possible to drop a sharded time-series collection, but it has to be done on the logical collection (i.e., the view) rather than the buckets.

Suggested revision:

Drop on a sharded time-series system.buckets collection is unsupported; drop the view instead.


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