ParallelPGMapper *m;
WQ(ParallelPGMapper *m_, ThreadPool *tp)
- : ThreadPool::WorkQueue<Item>("ParallelPGMapper::WQ",
- ceph::timespan::zero(),
- ceph::timespan::zero(),
- tp),
+ : ThreadPool::WorkQueue<Item>(
+ "ParallelPGMapper::WQ",
+ ceph::make_timespan(m_->cct->_conf->threadpool_default_timeout),
+ ceph::timespan::zero(),
+ tp),
m(m_) {}
bool _enqueue(Item *i) override {
mapping->_finish(*osdmap);
}
};
+ friend class OSDMapTest;
+ // for testing only
+ void update(const OSDMap& map);
public:
void get(pg_t pgid,
}
}
- const mempool::osdmap_mapping::vector<pg_t>& get_osd_acting_pgs(unsigned osd) {
+ const mempool::osdmap_mapping::vector<pg_t>& get_osd_acting_pgs(unsigned osd) {
ceph_assert(osd < acting_rmap.size());
return acting_rmap[osd];
}
- void update(const OSDMap& map);
void update(const OSDMap& map, pg_t pgid);
std::unique_ptr<MappingJob> start_update(