Queries with the awaitData option use this notifier object to wait for more data to be inserted into the capped collection.
More...
#include <collection.h>
Queries with the awaitData option use this notifier object to wait for more data to be inserted into the capped collection.
◆ CappedInsertNotifier()
mongo::CappedInsertNotifier::CappedInsertNotifier |
( |
| ) |
|
◆ getVersion()
uint64_t mongo::CappedInsertNotifier::getVersion |
( |
| ) |
const |
|
inline |
Returns the version for use as an additional wake condition when used above.
◆ isDead()
bool mongo::CappedInsertNotifier::isDead |
( |
| ) |
|
Returns true if no new insert notification will occur.
◆ kill()
void mongo::CappedInsertNotifier::kill |
( |
| ) |
|
Cancels the notifier if the collection is dropped/invalidated, and wakes all waiting.
◆ notifyAll()
void mongo::CappedInsertNotifier::notifyAll |
( |
| ) |
|
Wakes up all threads waiting.
◆ waitUntil()
void mongo::CappedInsertNotifier::waitUntil |
( |
uint64_t |
prevVersion, |
|
|
Date_t |
deadline |
|
) |
| const |
Waits until 'deadline', or until notifyAll() is called to indicate that new data is available in the capped collection.
NOTE: Waiting threads can be signaled by calling kill or notify* methods.
◆ _dead
bool mongo::CappedInsertNotifier::_dead |
|
private |
◆ _mutex
stdx::mutex mongo::CappedInsertNotifier::_mutex |
|
mutableprivate |
◆ _notifier
stdx::condition_variable mongo::CappedInsertNotifier::_notifier |
|
mutableprivate |
◆ _version
uint64_t mongo::CappedInsertNotifier::_version |
|
private |
The documentation for this class was generated from the following files:
- /home/louis/git/mongodbsource.github.io/src/src/mongo/db/catalog/collection.h
- /home/louis/git/mongodbsource.github.io/src/src/mongo/db/catalog/collection.cpp