summaryrefslogtreecommitdiff
path: root/util/concurrency
diff options
context:
space:
mode:
authordwight <dwight@10gen.com>2010-12-13 00:21:08 -0500
committerdwight <dwight@10gen.com>2010-12-13 00:21:08 -0500
commitd7a05a90da0827cf4dfcc1dd7fafc0cfe2893948 (patch)
tree97a5becbf6dd802019714f31c2301fa3ccb1d6e4 /util/concurrency
parentd4042c9c502d930e6064409d1aea5683e89ed5df (diff)
downloadmongo-d7a05a90da0827cf4dfcc1dd7fafc0cfe2893948.tar.gz
dur getlasterror wait for group commit via fsync:1
Diffstat (limited to 'util/concurrency')
-rw-r--r--util/concurrency/README6
-rw-r--r--util/concurrency/synchronization.cpp2
-rw-r--r--util/concurrency/synchronization.h2
3 files changed, 5 insertions, 5 deletions
diff --git a/util/concurrency/README b/util/concurrency/README
index 31b47ce955f..1d72a1ce4ec 100644
--- a/util/concurrency/README
+++ b/util/concurrency/README
@@ -14,6 +14,6 @@ value.h
Atomic wrapper for values/objects that are copy constructable / assignable
thread_pool.h
spinlock.h
-synchronization.h
- A class to establish a sinchronization point between two threads. One thread is the waiter and one
- is the notifier. After the notification event, both proceed normally.
+synchronization.h
+ A class to establish a sinchronization point between two threads. One thread is the waiter and one
+ is the notifier. After the notification event, both proceed normally.
diff --git a/util/concurrency/synchronization.cpp b/util/concurrency/synchronization.cpp
index 3148799bd7b..5639c888a32 100644
--- a/util/concurrency/synchronization.cpp
+++ b/util/concurrency/synchronization.cpp
@@ -39,7 +39,7 @@ namespace mongo {
NotifyAll::NotifyAll() : _mutex("NotifyAll"), _counter(0) { }
- void NotifyAll::waitToBeNotified() {
+ void NotifyAll::wait() {
scoped_lock lock( _mutex );
unsigned long long old = _counter;
while( old == _counter ) {
diff --git a/util/concurrency/synchronization.h b/util/concurrency/synchronization.h
index b03efa3faec..353b9568c6b 100644
--- a/util/concurrency/synchronization.h
+++ b/util/concurrency/synchronization.h
@@ -59,7 +59,7 @@ namespace mongo {
/** awaits the next notifyAll() call by another thread. notifications that preceed this
call are ignored -- we are looking for a fresh event.
*/
- void waitToBeNotified();
+ void wait();
/** may be called multiple times. notifies all waiters */
void notifyAll();