BugZero found this defect 18 days ago.
Data sources
All data on this page is proprietary to BugZero® or gathered from public sources
5/2/2024
MongoDB Server
6.0.0
7.0.0
8.0.0-rc0
7.3.0
8.1.0-rc0
No fixed releases provided.
Consider the following sequence: A client requests a dropDatabase(dbName) to a sharded cluster The DDL request is served by the primary shard, until the point on which all the collections under dbName get removed from the local catalog; secondary nodes replicate the collection removals; Before reaching the stage on which the dropDatabase op entry is written onto the oplog, the primary shard receives a shutdown (for restart) signal, so that the DDL is interrupted; Upon restart, the newly spawned process is elected as the RS primary As part of the initialisation routine, the newly spawned process fills up its DatabaseHolder (the in-memory cache of existing database names, according to the collection names retrieved from the local catalog): due to step 2, dbName is no longer present; When the sharding DDL coordinator resumes the execution of dropDatabase(dbName), the absence of dbName from DatabaseHolder causes the function in charge of executing step 1 to early exit, skipping the instruction to generate the op entry about the completion of the DDL on the local node.