MCPcopy Create free account
hub / github.com/ceph/ceph / _update_range

Method _update_range

src/osd/OSDMapMapping.cc:108–127  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

106}
107
108void OSDMapMapping::_update_range(
109 const OSDMap& osdmap,
110 int64_t pool,
111 unsigned pg_begin,
112 unsigned pg_end)
113{
114 auto i = pools.find(pool);
115 ceph_assert(i != pools.end());
116 ceph_assert(pg_begin <= pg_end);
117 ceph_assert(pg_end <= i->second.pg_num);
118 for (unsigned ps = pg_begin; ps < pg_end; ++ps) {
119 std::vector<int> up, acting;
120 int up_primary, acting_primary;
121 osdmap.pg_to_up_acting_osds(
122 pg_t(ps, pool),
123 &up, &up_primary, &acting, &acting_primary);
124 i->second.set(ps, std::move(up), up_primary,
125 std::move(acting), acting_primary);
126 }
127}
128
129// ---------------------------
130

Callers 1

processMethod · 0.80

Calls 5

pg_tClass · 0.85
findMethod · 0.45
endMethod · 0.45
pg_to_up_acting_osdsMethod · 0.45
setMethod · 0.45

Tested by

no test coverage detected