void ObjectCacher::flusher_entry()
{
ldout(cct, 10) << "flusher start" << dendl;
- writeback_handler.get_client_lock();
lock.Lock();
while (!flusher_stop) {
loff_t all = get_stat_tx() + get_stat_rx() + get_stat_clean() +
if (!max) {
// back off the lock to avoid starving other threads
lock.Unlock();
- writeback_handler.put_client_lock();
- writeback_handler.get_client_lock();
lock.Lock();
continue;
}
if (flusher_stop)
break;
- writeback_handler.put_client_lock();
flusher_cond.WaitInterval(cct, lock, seconds(1));
- lock.Unlock();
-
- writeback_handler.get_client_lock();
- lock.Lock();
}
/* Wait for reads to finish. This is only possible if handling
}
lock.Unlock();
- writeback_handler.put_client_lock();
ldout(cct, 10) << "flusher finish" << dendl;
}