mirror of
https://github.com/ceph/ceph
synced 2025-02-22 10:37:15 +00:00
Merge pull request #13918 from liupan1111/wip-fix-performance-filestore
os/filestore: queue ondisk completion before apply work Reviewed-by: Sage Weil <sage@redhat.com>
This commit is contained in:
commit
ab06dd445d
@ -2270,18 +2270,19 @@ void FileStore::_journaled_ahead(OpSequencer *osr, Op *o, Context *ondisk)
|
||||
|
||||
o->trace.event("writeahead journal finished");
|
||||
|
||||
// this should queue in order because the journal does it's completions in order.
|
||||
queue_op(osr, o);
|
||||
|
||||
list<Context*> to_queue;
|
||||
osr->dequeue_journal(&to_queue);
|
||||
|
||||
// do ondisk completions async, to prevent any onreadable_sync completions
|
||||
// getting blocked behind an ondisk completion.
|
||||
if (ondisk) {
|
||||
dout(10) << " queueing ondisk " << ondisk << dendl;
|
||||
ondisk_finishers[osr->id % m_ondisk_finisher_num]->queue(ondisk);
|
||||
}
|
||||
|
||||
// this should queue in order because the journal does it's completions in order.
|
||||
queue_op(osr, o);
|
||||
|
||||
list<Context*> to_queue;
|
||||
osr->dequeue_journal(&to_queue);
|
||||
|
||||
if (!to_queue.empty()) {
|
||||
ondisk_finishers[osr->id % m_ondisk_finisher_num]->queue(to_queue);
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user