]> git.apps.os.sepia.ceph.com Git - ceph-ci.git/commit
osd/OSDMap: new calc_pg_role() that takes a pg_shard_t
authorSage Weil <sage@redhat.com>
Mon, 9 Dec 2019 15:41:31 +0000 (09:41 -0600)
committerSage Weil <sage@redhat.com>
Mon, 9 Dec 2019 15:50:13 +0000 (09:50 -0600)
commitb76053359125f09e075c1ccd88ec09270b1bee22
tree3b27fe4006a144a134492746e434abb667f78bb0
parent0637c269552d9da09faa8c57b50fcae6df38731f
osd/OSDMap: new calc_pg_role() that takes a pg_shard_t

If you have an acting set like [0,1,2,1] then osd.1 has two possible roles
(1 and 3).  If we simply return the first one we see then we can't
correctly calculate a role for a pg like 1.0s3.  Take pg_shard_t instead.

Signed-off-by: Sage Weil <sage@redhat.com>
src/osd/OSDMap.cc
src/osd/OSDMap.h