summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorEliot Horowitz <eliot@10gen.com>2012-07-15 22:22:49 -0400
committerEliot Horowitz <eliot@10gen.com>2012-07-27 16:28:58 -0400
commit8e42151eccd3766bd0ad0320340d930ad0cc54ed (patch)
tree68f366453b873576f23b788556683e1e8cb7ea30
parent6701b6ea856ec2b34fe85429f5e920c86cb8391d (diff)
downloadmongo-8e42151eccd3766bd0ad0320340d930ad0cc54ed.tar.gz
SERVER-6391 - lower sleep times when yielding
-rw-r--r--db/client.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/db/client.cpp b/db/client.cpp
index c1a359c759e..693a022df3c 100644
--- a/db/client.cpp
+++ b/db/client.cpp
@@ -572,8 +572,8 @@ namespace mongo {
if ( readers )
*readers = r;
- int time = r * 100;
- time += w * 500;
+ int time = r * 10; // we have to be nice to readers since they don't have priority
+ time += w; // writers are greedy, so we can be mean tot hem
time = min( time , 1000000 );