Details
-
Bug
-
Resolution: Duplicate
-
Major - P3
-
None
-
None
-
None
-
Minor Change
-
ALL
Description
When inserting a document larger than the allocated extents all existing docs are deleted but no error is generated.
> db.createCollection("capped_20b", {capped:true, size:20})
|
{ "ok" : 1 }
|
> db.capped_20b.insert({_id:1, text:"test"})
|
> db.capped_20b.stats( )
|
{
|
"ns" : "test.capped_20b",
|
"count" : 1,
|
"size" : 36,
|
"avgObjSize" : 36,
|
"storageSize" : 4096,
|
"numExtents" : 1,
|
"nindexes" : 0,
|
"lastExtentSize" : 4096,
|
"paddingFactor" : 1,
|
"flags" : 0,
|
"totalIndexSize" : 0,
|
"indexSizes" : {
|
|
|
},
|
"capped" : 1,
|
"max" : 2147483647,
|
"ok" : 1
|
}
|
> db.capped_20b.insert({_id:1, text:5KChar_String}) //5K character string insert
|
> db.capped_20b.stats( )
|
{
|
"ns" : "test.capped_20b",
|
"count" : 0,
|
"size" : 0,
|
"storageSize" : 4096,
|
"numExtents" : 1,
|
"nindexes" : 0,
|
"lastExtentSize" : 4096,
|
"paddingFactor" : 1,
|
"flags" : 0,
|
"totalIndexSize" : 0,
|
"indexSizes" : {
|
|
|
},
|
"capped" : 1,
|
"max" : 2147483647,
|
"ok" : 1
|
}
|
Attachments
Issue Links
- is related to
-
SERVER-2639 Inserting into a capped collection an object larger than max size fails silently
-
- Closed
-