uint64_t expire_pos;
uint64_t unused_field;
uint64_t write_pos;
- string magic;
+ std::string magic;
file_layout_t layout; //< The mapping from byte stream offsets
// to RADOS objects
stream_format_t stream_format; //< The encoding of LogEvents
f->close_section(); // journal_header
}
- static void generate_test_instances(list<Header*> &ls)
+ static void generate_test_instances(std::list<Header*> &ls)
{
ls.push_back(new Header());
void _reread_head(Context *onfinish);
void _set_layout(file_layout_t const *l);
- list<Context*> waitfor_recover;
+ std::list<Context*> waitfor_recover;
void _read_head(Context *on_finish, bufferlist *bl);
void _finish_read_head(int r, bufferlist& bl);
void _finish_reread_head(int r, bufferlist& bl, Context *finish);
uint64_t waiting_for_zero_pos;
interval_set<uint64_t> pending_zero; // non-contig bits we've zeroed
- list<Context*> waitfor_prezero;
+ std::list<Context*> waitfor_prezero;
std::map<uint64_t, uint64_t> pending_safe; // flush_pos -> safe_pos
// when safe through given offset
// read buffer. unused_field + read_buf.length() == prefetch_pos.
bufferlist read_buf;
- map<uint64_t,bufferlist> prefetch_buf;
+ std::map<uint64_t,bufferlist> prefetch_buf;
uint64_t fetch_len; // how much to read at a time
uint64_t temp_fetch_len;
class MStatfsReply;
class MCommandReply;
class MWatchNotify;
+struct ObjectOperation;
template<typename T>
struct EnumerationContext;
template<typename t>
set_handler(CB_ObjectOperation_stat(psize, nullptr, nullptr, pts, prval, nullptr));
out_rval.back() = prval;
}
- void stat(uint64_t *psize, ceph::real_time *pmtime, nullptr_t) {
+ void stat(uint64_t *psize, ceph::real_time *pmtime, std::nullptr_t) {
add_op(CEPH_OSD_OP_STAT);
set_handler(CB_ObjectOperation_stat(psize, pmtime, nullptr, nullptr, nullptr,
nullptr));
}
- void stat(uint64_t *psize, time_t *ptime, nullptr_t) {
+ void stat(uint64_t *psize, time_t *ptime, std::nullptr_t) {
add_op(CEPH_OSD_OP_STAT);
set_handler(CB_ObjectOperation_stat(psize, nullptr, ptime, nullptr, nullptr,
nullptr));
}
- void stat(uint64_t *psize, struct timespec *pts, nullptr_t) {
+ void stat(uint64_t *psize, struct timespec *pts, std::nullptr_t) {
add_op(CEPH_OSD_OP_STAT);
set_handler(CB_ObjectOperation_stat(psize, nullptr, nullptr, pts, nullptr,
nullptr));
}
- void stat(uint64_t *psize, nullptr_t, nullptr_t) {
+ void stat(uint64_t *psize, std::nullptr_t, std::nullptr_t) {
add_op(CEPH_OSD_OP_STAT);
set_handler(CB_ObjectOperation_stat(psize, nullptr, nullptr, nullptr,
nullptr, nullptr));
ceph::buffer::list bl;
add_xattr(CEPH_OSD_OP_RMXATTR, name, bl);
}
- void setxattrs(map<string, ceph::buffer::list>& attrs) {
+ void setxattrs(std::map<std::string, ceph::buffer::list>& attrs) {
using ceph::encode;
ceph::buffer::list bl;
encode(attrs, bl);
out_ec.back() = ec;
}
- void omap_cmp(const std::map<std::string, pair<ceph::buffer::list,int> > &assertions,
+ void omap_cmp(const std::map<std::string, std::pair<ceph::buffer::list,int> > &assertions,
int *prval) {
using ceph::encode;
OSDOp &op = add_op(CEPH_OSD_OP_OMAP_CMP);
}
void omap_cmp(const boost::container::flat_map<
- std::string, pair<ceph::buffer::list, int>>& assertions,
+ std::string, std::pair<ceph::buffer::list, int>>& assertions,
boost::system::error_code *ec) {
OSDOp &op = add_op(CEPH_OSD_OP_OMAP_CMP);
ceph::buffer::list bl;
out_ec.back() = ec;
}
- void omap_set(const map<string, ceph::buffer::list> &map) {
+ void omap_set(const std::map<std::string, ceph::buffer::list> &map) {
ceph::buffer::list bl;
encode(map, bl);
add_data(CEPH_OSD_OP_OMAPSETVALS, 0, bl.length(), bl);
}
- void omap_set(const boost::container::flat_map<string, ceph::buffer::list>& map) {
+ void omap_set(const boost::container::flat_map<std::string, ceph::buffer::list>& map) {
ceph::buffer::list bl;
encode(map, bl);
add_data(CEPH_OSD_OP_OMAPSETVALS, 0, bl.length(), bl);
out_rval.back() = prval;
}
}
- void list_watchers(vector<neorados::ObjWatcher>* out,
+ void list_watchers(std::vector<neorados::ObjWatcher>* out,
boost::system::error_code* ec) {
add_op(CEPH_OSD_OP_LIST_WATCHERS);
set_handler(CB_ObjectOperation_decodewatchersneo(out, nullptr, ec));
CommandOp(
int target_osd,
- std::vector<string>&& cmd,
+ std::vector<std::string>&& cmd,
ceph::buffer::list&& inbl,
decltype(onfinish)&& onfinish)
: cmd(std::move(cmd)),
CommandOp(
pg_t pgid,
- std::vector<string>&& cmd,
+ std::vector<std::string>&& cmd,
ceph::buffer::list&& inbl,
decltype(onfinish)&& onfinish)
: cmd(std::move(cmd)),
watch_pending_async.push_back(ceph::coarse_mono_clock::now());
}
void finished_async() {
- unique_lock l(watch_lock);
+ std::unique_lock l(watch_lock);
ceph_assert(!watch_pending_async.empty());
watch_pending_async.pop_front();
}
template<typename Callback, typename...Args>
decltype(auto) with_osdmap(Callback&& cb, Args&&... args) {
- shared_lock l(rwlock);
+ std::shared_lock l(rwlock);
return std::forward<Callback>(cb)(*osdmap, std::forward<Args>(args)...);
}
template<typename CompletionToken>
auto wait_for_osd_map(CompletionToken&& token) {
boost::asio::async_completion<CompletionToken, void()> init(token);
- unique_lock l(rwlock);
+ std::unique_lock l(rwlock);
if (osdmap->get_epoch()) {
l.unlock();
boost::asio::post(std::move(init.completion_handler));