]> git.apps.os.sepia.ceph.com Git - ceph.git/commit
librbd: use the same IoCtx for each request
authorJosh Durgin <josh.durgin@inktank.com>
Wed, 27 Mar 2013 22:42:10 +0000 (15:42 -0700)
committerJosh Durgin <josh.durgin@inktank.com>
Tue, 23 Apr 2013 18:33:18 +0000 (11:33 -0700)
commitf2e490cb5b1f322e637d787e788733ac4b2496f4
tree504dd37eae0c3a49e00e8bccd0d82a93c0260cc8
parentcbb37fb5470f22949a4dbb747f428943cce4aca7
librbd: use the same IoCtx for each request

Before we were duplicating the IoCtx for each new request since they
could have a different snapshot context or read from a different
snapshot id. Since librados now supports setting these explicitly
for a given request, do that instead.

Since librados tracks outstanding requests on a per-IoCtx basis, this
also fixes a bug that causes flush() without caching to ignore
all the outstanding requests, since they were to separate,
duplicate IoCtxs.

Signed-off-by: Josh Durgin <josh.durgin@inktank.com>
(cherry picked from commit 860493e7ff0d87d02069b243fc1c8326ce0721f9)
src/librbd/AioRequest.cc
src/librbd/AioRequest.h