Details
-
Bug
-
Resolution: Done
-
Major - P3
-
None
-
3.3.1
-
None
-
ALL
Description
If I move the assert after a second call to compact, the test succeeds.
db.a.drop();
|
for(i=0;i<25000;i++) { db.a.insert({x:i, y:"asdfasdfasdfasdfasdfasdfasdfasdfasdf"}); }
|
db.adminCommand('fsync'); // force checkpoint
|
var collectionSize = db.a.stats().storageSize;
|
print("coll size: " + collectionSize);
|
|
|
print("Remove all docs...");
|
db.a.remove({});
|
db.adminCommand('fsync'); // force checkpoint
|
print("table size: " + db.a.stats().storageSize);
|
|
|
print("Run 1st compact...");
|
db.a.runCommand('compact');
|
db.adminCommand('fsync'); // force checkpoint
|
print("table size: " + db.a.stats().storageSize);
|
|
|
assert.gt(collectionSize, db.a.stats().storageSize, "collection size should be smaller after compact");
|
Attachments
Issue Links
- related to
-
SERVER-22370 compact does not run over indexes in WiredTiger
-
- Closed
-