Please sign in to comment.
Buffer writes to the mongodb socket internally.
Previously, writes to the mongodb socket happened immediately. However, this will inevitable overflow the send buffer. So now, we store commands in a buffer and write them out on the next write event window. Inserting 1000+ things still is an edge case where performance suffers, since you'll be memcpy'ing and growing the buffer each time. But at least now it will not segfault.
- Loading branch information...
Showing with 275 additions and 99 deletions.
|@@ -1,4 +1,5 @@|
|node tests/test_bson.js||for f in `ls tests/test_*.js`; do|
|node tests/test_mongo.js||node $f|
Oops, something went wrong.