| 4651 | } |
| 4652 | |
| 4653 | bool Client::_flush(Inode *in, Context *onfinish) |
| 4654 | { |
| 4655 | ldout(cct, 10) << "_flush " << *in << dendl; |
| 4656 | |
| 4657 | if (!in->oset.dirty_or_tx) { |
| 4658 | ldout(cct, 10) << " nothing to flush" << dendl; |
| 4659 | onfinish->complete(0); |
| 4660 | return true; |
| 4661 | } |
| 4662 | |
| 4663 | if (objecter->osdmap_pool_full(in->layout.pool_id)) { |
| 4664 | ldout(cct, 8) << __func__ << ": FULL, purging for ENOSPC" << dendl; |
| 4665 | objectcacher->purge_set(&in->oset); |
| 4666 | if (onfinish) { |
| 4667 | onfinish->complete(-ENOSPC); |
| 4668 | } |
| 4669 | return true; |
| 4670 | } |
| 4671 | |
| 4672 | return objectcacher->flush_set(&in->oset, onfinish); |
| 4673 | } |
| 4674 | |
| 4675 | void Client::_flush_range(Inode *in, int64_t offset, uint64_t size) |
| 4676 | { |
no test coverage detected