]> git.apps.os.sepia.ceph.com Git - ceph.git/commit
osd: flush pg on activate _after_ we queue our transaction
authorSage Weil <sage@newdream.net>
Sun, 12 Feb 2012 05:47:42 +0000 (21:47 -0800)
committerSage Weil <sage@newdream.net>
Sun, 12 Feb 2012 05:47:42 +0000 (21:47 -0800)
commit3796c4ab8fd55bd37b84a7af0e33cf19fe4d8688
treee237a5fbb43c47fb009921b2138404d3c0ee15ff
parent4d8e9a5ebb8eb255f3a816243c29cf1c9f776a3c
osd: flush pg on activate _after_ we queue our transaction

We recently added a flush on activate, but we are still building the
transaction (the caller queues it), so calling osr.flush() here is totally
useless.

Instead, set a flag 'need_flush', and do the flush the next time we receive
some work.

This has the added benefit of doing the flush in the worker thread, outside
of osd_lock.

Signed-off-by: Sage Weil <sage@newdream.net>
src/osd/PG.cc
src/osd/PG.h