*/
void Objecter::init()
{
- assert(!initialized.read());
+ assert(!initialized);
if (!logger) {
PerfCountersBuilder pcb(cct, "objecter", l_osdc_first, l_osdc_last);
cct->_conf->add_observer(this);
- initialized.set(1);
+ initialized = true;
}
/*
void Objecter::shutdown()
{
- assert(initialized.read());
+ assert(initialized);
unique_lock wl(rwlock);
- initialized.set(0);
+ initialized = false;
cct->_conf->remove_observer(this);
o->mtime = info->mtime;
o->target = info->target;
- o->tid = last_tid.inc();
+ o->tid = ++last_tid;
// do not resend this; we will send a new op to reregister
o->should_resend = false;
o->should_resend = false;
_send_op_account(o);
MOSDOp *m = _prepare_osd_op(o);
- o->tid = last_tid.inc();
+ o->tid = ++last_tid;
_session_op_assign(info->session, o);
_send_op(o, m);
info->ping_tid = o->tid;
void Objecter::handle_watch_notify(MWatchNotify *m)
{
shared_lock l(rwlock);
- if (!initialized.read()) {
+ if (!initialized) {
return;
}
ldout(cct, 10) << __func__ << " " << *m << dendl;
shared_lock l(rwlock);
- assert(initialized.read());
+ assert(initialized);
if (info->canceled) {
l.unlock();
bool Objecter::ms_dispatch(Message *m)
{
ldout(cct, 10) << __func__ << " " << cct << " " << *m << dendl;
- if (!initialized.read())
+ if (!initialized)
return false;
switch (m->get_type()) {
void Objecter::handle_osd_map(MOSDMap *m)
{
shunique_lock sul(rwlock, acquire_unique);
- if (!initialized.read())
+ if (!initialized)
return;
assert(osdmap);
// we are only called by C_Tick
tick_event = 0;
- if (!initialized.read()) {
+ if (!initialized) {
// we raced with shutdown
ldout(cct, 10) << __func__ << " raced with shutdown" << dendl;
return;
if (found)
toping.insert(s);
}
- if (num_homeless_ops.read() || !toping.empty()) {
+ if (num_homeless_ops || !toping.empty()) {
_maybe_request_map();
}
}
// Make sure we don't resechedule if we wake up after shutdown
- if (initialized.read()) {
+ if (initialized) {
tick_event = timer.reschedule_me(ceph::make_timespan(
cct->_conf->objecter_tick_interval));
}
ceph_tid_t *ptid,
int *ctx_budget)
{
- assert(initialized.read());
+ assert(initialized);
assert(op->ops.size() == op->out_bl.size());
assert(op->ops.size() == op->out_rval.size());
if (osd_timeout > timespan(0)) {
if (op->tid == 0)
- op->tid = last_tid.inc();
+ op->tid = ++last_tid;
auto tid = op->tid;
op->ontimeout = timer.add_event(osd_timeout,
[this, tid]() {
void Objecter::_send_op_account(Op *op)
{
- inflight_ops.inc();
+ inflight_ops++;
// add to gather set(s)
if (op->onfinish) {
- num_in_flight.inc();
+ num_in_flight++;
} else {
ldout(cct, 20) << " note: not requesting reply" << dendl;
}
OSDSession::unique_lock sl(s->lock);
if (op->tid == 0)
- op->tid = last_tid.inc();
+ op->tid = ++last_tid;
ldout(cct, 10) << "_op_submit oid " << op->target.base_oid
<< " '" << op->target.base_oloc << "' '"
sl.unlock();
put_session(s);
- ldout(cct, 5) << num_in_flight.read() << " in flight" << dendl;
+ ldout(cct, 5) << num_in_flight << " in flight" << dendl;
}
int Objecter::op_cancel(OSDSession *s, ceph_tid_t tid, int r)
{
- assert(initialized.read());
+ assert(initialized);
OSDSession::unique_lock sl(s->lock);
<< dendl;
Op *op = p->second;
if (op->onfinish) {
- num_in_flight.dec();
+ num_in_flight--;
op->onfinish->complete(r);
op->onfinish = NULL;
}
to->ops[op->tid] = op;
if (to->is_homeless()) {
- num_homeless_ops.inc();
+ num_homeless_ops++;
}
ldout(cct, 15) << __func__ << " " << to->osd << " " << op->tid << dendl;
// from->lock is locked
if (from->is_homeless()) {
- num_homeless_ops.dec();
+ num_homeless_ops--;
}
from->ops.erase(op->tid);
assert(op->session == NULL);
if (to->is_homeless()) {
- num_homeless_ops.inc();
+ num_homeless_ops++;
}
get_session(to);
// from->lock is locked unique
if (from->is_homeless()) {
- num_homeless_ops.dec();
+ num_homeless_ops--;
}
from->linger_ops.erase(op->linger_id);
// from->lock is locked
if (from->is_homeless()) {
- num_homeless_ops.dec();
+ num_homeless_ops--;
}
from->command_ops.erase(op->tid);
assert(op->tid);
if (to->is_homeless()) {
- num_homeless_ops.inc();
+ num_homeless_ops++;
}
get_session(to);
assert(!op->should_resend);
if (op->onfinish) {
delete op->onfinish;
- num_in_flight.dec();
+ num_in_flight--;
}
_finish_op(op, 0);
assert(check_latest_map_ops.find(op->tid) == check_latest_map_ops.end());
- inflight_ops.dec();
+ inflight_ops++;
op->put();
}
op->stamp = ceph::mono_clock::now();
hobject_t hobj = op->target.get_hobj();
- MOSDOp *m = new MOSDOp(client_inc.read(), op->tid,
+ MOSDOp *m = new MOSDOp(client_inc, op->tid,
hobj, op->target.actual_pgid,
osdmap->get_epoch(),
flags, op->features);
put_session(op->session);
op->session = NULL;
- inflight_ops.dec();
+ inflight_ops--;
}
/* This function DOES put the passed message before returning */
ceph_tid_t tid = m->get_tid();
shunique_lock sul(rwlock, ceph::acquire_shared);
- if (!initialized.read()) {
+ if (!initialized) {
m->put();
return;
}
(op->target.flags & CEPH_OSD_FLAG_WRITE)) {
ldout(cct, 7) << "retrying write after first reply: " << tid << dendl;
if (op->onfinish) {
- num_in_flight.dec();
+ num_in_flight--;
}
_session_op_remove(s, op);
sl.unlock();
if (m->is_redirect_reply()) {
ldout(cct, 5) << " got redirect reply; redirecting" << dendl;
if (op->onfinish)
- num_in_flight.dec();
+ num_in_flight--;
_session_op_remove(s, op);
sl.unlock();
put_session(s);
// new tid
s->ops.erase(op->tid);
- op->tid = last_tid.inc();
+ op->tid = ++last_tid;
_send_op(op);
sl.unlock();
// only ever get back one (type of) ack ever.
if (op->onfinish) {
- num_in_flight.dec();
+ num_in_flight--;
onfinish = op->onfinish;
op->onfinish = NULL;
}
ldout(cct, 15) << "handle_osd_op_reply completed tid " << tid << dendl;
_finish_op(op, 0);
- ldout(cct, 5) << num_in_flight.read() << " in flight" << dendl;
+ ldout(cct, 5) << num_in_flight << " in flight" << dendl;
// serialize completions
if (completion_lock.mutex()) {
{
ldout(cct, 10) << __func__ << " " << *m << dendl;
shunique_lock sul(rwlock, ceph::acquire_shared);
- if (!initialized.read()) {
+ if (!initialized) {
m->put();
return;
}
PoolOp *op = new PoolOp;
if (!op)
return -ENOMEM;
- op->tid = last_tid.inc();
+ op->tid = ++last_tid;
op->pool = pool;
op->name = snap_name;
op->onfinish = onfinish;
ldout(cct, 10) << "allocate_selfmanaged_snap; pool: " << pool << dendl;
PoolOp *op = new PoolOp;
if (!op) return -ENOMEM;
- op->tid = last_tid.inc();
+ op->tid = ++last_tid;
op->pool = pool;
C_SelfmanagedSnap *fin = new C_SelfmanagedSnap(psnapid, onfinish);
op->onfinish = fin;
PoolOp *op = new PoolOp;
if (!op)
return -ENOMEM;
- op->tid = last_tid.inc();
+ op->tid = ++last_tid;
op->pool = pool;
op->name = snap_name;
op->onfinish = onfinish;
<< snap << dendl;
PoolOp *op = new PoolOp;
if (!op) return -ENOMEM;
- op->tid = last_tid.inc();
+ op->tid = ++last_tid;
op->pool = pool;
op->onfinish = onfinish;
op->pool_op = POOL_OP_DELETE_UNMANAGED_SNAP;
PoolOp *op = new PoolOp;
if (!op)
return -ENOMEM;
- op->tid = last_tid.inc();
+ op->tid = ++last_tid;
op->pool = 0;
op->name = name;
op->onfinish = onfinish;
void Objecter::_do_delete_pool(int64_t pool, Context *onfinish)
{
PoolOp *op = new PoolOp;
- op->tid = last_tid.inc();
+ op->tid = ++last_tid;
op->pool = pool;
op->name = "delete";
op->onfinish = onfinish;
ldout(cct, 10) << "change_pool_auid " << pool << " to " << auid << dendl;
PoolOp *op = new PoolOp;
if (!op) return -ENOMEM;
- op->tid = last_tid.inc();
+ op->tid = ++last_tid;
op->pool = pool;
op->name = "change_pool_auid";
op->onfinish = onfinish;
{
FUNCTRACE();
shunique_lock sul(rwlock, acquire_shared);
- if (!initialized.read()) {
+ if (!initialized) {
sul.unlock();
m->put();
return;
int Objecter::pool_op_cancel(ceph_tid_t tid, int r)
{
- assert(initialized.read());
+ assert(initialized);
unique_lock wl(rwlock);
ldout(cct, 10) << "get_pool_stats " << pools << dendl;
PoolStatOp *op = new PoolStatOp;
- op->tid = last_tid.inc();
+ op->tid = ++last_tid;
op->pools = pools;
op->pool_stats = result;
op->onfinish = onfinish;
ceph_tid_t tid = m->get_tid();
unique_lock wl(rwlock);
- if (!initialized.read()) {
+ if (!initialized) {
m->put();
return;
}
int Objecter::pool_stat_op_cancel(ceph_tid_t tid, int r)
{
- assert(initialized.read());
+ assert(initialized);
unique_lock wl(rwlock);
unique_lock l(rwlock);
StatfsOp *op = new StatfsOp;
- op->tid = last_tid.inc();
+ op->tid = ++last_tid;
op->stats = &result;
op->onfinish = onfinish;
if (mon_timeout > timespan(0)) {
void Objecter::handle_fs_stats_reply(MStatfsReply *m)
{
unique_lock wl(rwlock);
- if (!initialized.read()) {
+ if (!initialized) {
m->put();
return;
}
int Objecter::statfs_op_cancel(ceph_tid_t tid, int r)
{
- assert(initialized.read());
+ assert(initialized);
unique_lock wl(rwlock);
void Objecter::ms_handle_connect(Connection *con)
{
ldout(cct, 10) << "ms_handle_connect " << con << dendl;
- if (!initialized.read())
+ if (!initialized)
return;
if (con->get_peer_type() == CEPH_ENTITY_TYPE_MON)
bool Objecter::ms_handle_reset(Connection *con)
{
- if (!initialized.read())
+ if (!initialized)
return false;
if (con->get_peer_type() == CEPH_ENTITY_TYPE_OSD) {
OSDSession *session = static_cast<OSDSession*>(con->get_priv());
ldout(cct, 1) << "ms_handle_reset " << con << " session " << session
<< " osd." << session->osd << dendl;
unique_lock wl(rwlock);
- if (!initialized.read()) {
+ if (!initialized) {
wl.unlock();
return false;
}
AuthAuthorizer **authorizer,
bool force_new)
{
- if (!initialized.read())
+ if (!initialized)
return false;
if (dest_type == CEPH_ENTITY_TYPE_MON)
return true;
void Objecter::_dump_active()
{
- ldout(cct, 20) << "dump_active .. " << num_homeless_ops.read() << " homeless"
+ ldout(cct, 20) << "dump_active .. " << num_homeless_ops << " homeless"
<< dendl;
for (map<int, OSDSession *>::iterator siter = osd_sessions.begin();
siter != osd_sessions.end(); ++siter) {
void Objecter::handle_command_reply(MCommandReply *m)
{
unique_lock wl(rwlock);
- if (!initialized.read()) {
+ if (!initialized) {
m->put();
return;
}
{
shunique_lock sul(rwlock, ceph::acquire_unique);
- ceph_tid_t tid = last_tid.inc();
+ ceph_tid_t tid = ++last_tid;
ldout(cct, 10) << "_submit_command " << tid << " " << c->cmd << dendl;
c->tid = tid;
int Objecter::command_op_cancel(OSDSession *s, ceph_tid_t tid, int r)
{
- assert(initialized.read());
+ assert(initialized);
unique_lock wl(rwlock);
delete osdmap;
assert(homeless_session->get_nref() == 1);
- assert(num_homeless_ops.read() == 0);
+ assert(num_homeless_ops == 0);
homeless_session->put();
assert(osd_sessions.empty());
using Dispatcher::cct;
std::multimap<string,string> crush_location;
- atomic_t initialized;
+ std::atomic<bool> initialized{false};
private:
- atomic64_t last_tid;
- atomic_t inflight_ops;
- atomic_t client_inc;
+ std::atomic<uint64_t> last_tid{0};
+ std::atomic<unsigned> inflight_ops{0};
+ std::atomic<int> client_inc{-1};
uint64_t max_linger_id;
- atomic_t num_in_flight;
- atomic_t global_op_flags; // flags which are applied to each IO op
+ std::atomic<unsigned> num_in_flight{0};
+ std::atomic<int> global_op_flags{0}; // flags which are applied to each IO op
bool keep_balanced_budget;
bool honor_osdmap_full;
bool osdmap_full_try;
map<ceph_tid_t,PoolStatOp*> poolstat_ops;
map<ceph_tid_t,StatfsOp*> statfs_ops;
map<ceph_tid_t,PoolOp*> pool_ops;
- atomic_t num_homeless_ops;
+ std::atomic<unsigned> num_homeless_ops{0};
OSDSession *homeless_session;
double osd_timeout) :
Dispatcher(cct_), messenger(m), monc(mc), finisher(fin),
trace_endpoint("0.0.0.0", 0, "Objecter"),
- osdmap(new OSDMap), initialized(0), last_tid(0), client_inc(-1),
- max_linger_id(0), num_in_flight(0), global_op_flags(0),
+ osdmap(new OSDMap),
+ max_linger_id(0),
keep_balanced_budget(false), honor_osdmap_full(true), osdmap_full_try(false),
blacklist_events_enabled(false),
last_seen_osdmap_version(0), last_seen_pgmap_version(0),
logger(NULL), tick_event(0), m_request_state_hook(NULL),
- num_homeless_ops(0),
homeless_session(new OSDSession(cct, -1)),
mon_timeout(ceph::make_timespan(mon_timeout)),
osd_timeout(ceph::make_timespan(osd_timeout)),
void op_submit(Op *op, ceph_tid_t *ptid = NULL, int *ctx_budget = NULL);
bool is_active() {
shared_lock l(rwlock);
- return !((!inflight_ops.read()) && linger_ops.empty() &&
+ return !((!inflight_ops) && linger_ops.empty() &&
poolstat_ops.empty() && statfs_ops.empty());
}
void dump_pool_stat_ops(Formatter *fmt) const;
void dump_statfs_ops(Formatter *fmt) const;
- int get_client_incarnation() const { return client_inc.read(); }
- void set_client_incarnation(int inc) { client_inc.set(inc); }
+ int get_client_incarnation() const { return client_inc; }
+ void set_client_incarnation(int inc) { client_inc = inc; }
bool have_map(epoch_t epoch);
/// wait for epoch; true if we already have it
void _get_latest_version(epoch_t oldest, epoch_t neweset, Context *fin);
/** Get the current set of global op flags */
- int get_global_op_flags() { return global_op_flags.read(); }
+ int get_global_op_flags() const { return global_op_flags; }
/** Add a flag to the global op flags, not really atomic operation */
void add_global_op_flags(int flag) {
- global_op_flags.set(global_op_flags.read() | flag);
+ global_op_flags.fetch_or(flag);
}
- /** Clear the passed flags from the global op flag set, not really
- atomic operation */
+ /** Clear the passed flags from the global op flag set */
void clear_global_op_flag(int flags) {
- global_op_flags.set(global_op_flags.read() & ~flags);
+ global_op_flags.fetch_and(~flags);
}
/// cancel an in-progress request with the given return code
Context *oncommit, version_t *objver = NULL,
osd_reqid_t reqid = osd_reqid_t(),
ZTracer::Trace *parent_trace = nullptr) {
- Op *o = new Op(oid, oloc, op.ops, flags | global_op_flags.read() |
+ Op *o = new Op(oid, oloc, op.ops, flags | global_op_flags |
CEPH_OSD_FLAG_WRITE, oncommit, objver, nullptr, parent_trace);
o->priority = op.priority;
o->mtime = mtime;
int *data_offset = NULL,
uint64_t features = 0,
ZTracer::Trace *parent_trace = nullptr) {
- Op *o = new Op(oid, oloc, op.ops, flags | global_op_flags.read() |
+ Op *o = new Op(oid, oloc, op.ops, flags | global_op_flags |
CEPH_OSD_FLAG_READ, onack, objver, data_offset, parent_trace);
o->priority = op.priority;
o->snapid = snapid;
int *ctx_budget) {
Op *o = new Op(object_t(), oloc,
op.ops,
- flags | global_op_flags.read() | CEPH_OSD_FLAG_READ |
+ flags | global_op_flags | CEPH_OSD_FLAG_READ |
CEPH_OSD_FLAG_IGNORE_OVERLAY,
onack, NULL);
o->target.precalc_pgid = true;
int i = init_ops(ops, 1, extra_ops);
ops[i].op.op = CEPH_OSD_OP_STAT;
C_Stat *fin = new C_Stat(psize, pmtime, onfinish);
- Op *o = new Op(oid, oloc, ops, flags | global_op_flags.read() |
+ Op *o = new Op(oid, oloc, ops, flags | global_op_flags |
CEPH_OSD_FLAG_READ, fin, objver);
o->snapid = snap;
o->outbl = &fin->bl;
ops[i].op.extent.truncate_size = 0;
ops[i].op.extent.truncate_seq = 0;
ops[i].op.flags = op_flags;
- Op *o = new Op(oid, oloc, ops, flags | global_op_flags.read() |
+ Op *o = new Op(oid, oloc, ops, flags | global_op_flags |
CEPH_OSD_FLAG_READ, onfinish, objver, nullptr, parent_trace);
o->snapid = snap;
o->outbl = pbl;
ops[i].op.extent.truncate_seq = 0;
ops[i].indata = cmp_bl;
ops[i].op.flags = op_flags;
- Op *o = new Op(oid, oloc, ops, flags | global_op_flags.read() |
+ Op *o = new Op(oid, oloc, ops, flags | global_op_flags |
CEPH_OSD_FLAG_READ, onfinish, objver);
o->snapid = snap;
return o;
ops[i].op.extent.truncate_size = trunc_size;
ops[i].op.extent.truncate_seq = trunc_seq;
ops[i].op.flags = op_flags;
- Op *o = new Op(oid, oloc, ops, flags | global_op_flags.read() |
+ Op *o = new Op(oid, oloc, ops, flags | global_op_flags |
CEPH_OSD_FLAG_READ, onfinish, objver);
o->snapid = snap;
o->outbl = pbl;
ops[i].op.extent.length = len;
ops[i].op.extent.truncate_size = 0;
ops[i].op.extent.truncate_seq = 0;
- Op *o = new Op(oid, oloc, ops, flags | global_op_flags.read() |
+ Op *o = new Op(oid, oloc, ops, flags | global_op_flags |
CEPH_OSD_FLAG_READ, onfinish, objver);
o->snapid = snap;
o->outbl = pbl;
ops[i].op.xattr.value_len = 0;
if (name)
ops[i].indata.append(name);
- Op *o = new Op(oid, oloc, ops, flags | global_op_flags.read() |
+ Op *o = new Op(oid, oloc, ops, flags | global_op_flags |
CEPH_OSD_FLAG_READ, onfinish, objver);
o->snapid = snap;
o->outbl = pbl;
int i = init_ops(ops, 1, extra_ops);
ops[i].op.op = CEPH_OSD_OP_GETXATTRS;
C_GetAttrs *fin = new C_GetAttrs(attrset, onfinish);
- Op *o = new Op(oid, oloc, ops, flags | global_op_flags.read() |
+ Op *o = new Op(oid, oloc, ops, flags | global_op_flags |
CEPH_OSD_FLAG_READ, fin, objver);
o->snapid = snap;
o->outbl = &fin->bl;
snapid_t snap, bufferlist *pbl, int flags,
Context *onfinish, version_t *objver = NULL,
ObjectOperation *extra_ops = NULL) {
- return read(oid, oloc, 0, 0, snap, pbl, flags | global_op_flags.read() |
+ return read(oid, oloc, 0, 0, snap, pbl, flags | global_op_flags |
CEPH_OSD_FLAG_READ, onfinish, objver, extra_ops);
}
const SnapContext& snapc, int flags,
Context *oncommit,
version_t *objver = NULL) {
- Op *o = new Op(oid, oloc, ops, flags | global_op_flags.read() |
+ Op *o = new Op(oid, oloc, ops, flags | global_op_flags |
CEPH_OSD_FLAG_WRITE, oncommit, objver);
o->mtime = mtime;
o->snapc = snapc;
ops[i].op.extent.truncate_seq = 0;
ops[i].indata = bl;
ops[i].op.flags = op_flags;
- Op *o = new Op(oid, oloc, ops, flags | global_op_flags.read() |
+ Op *o = new Op(oid, oloc, ops, flags | global_op_flags |
CEPH_OSD_FLAG_WRITE, oncommit, objver,
nullptr, parent_trace);
o->mtime = mtime;
ops[i].op.extent.truncate_size = 0;
ops[i].op.extent.truncate_seq = 0;
ops[i].indata = bl;
- Op *o = new Op(oid, oloc, ops, flags | global_op_flags.read() |
+ Op *o = new Op(oid, oloc, ops, flags | global_op_flags |
CEPH_OSD_FLAG_WRITE, oncommit, objver);
o->mtime = mtime;
o->snapc = snapc;
ops[i].op.extent.truncate_seq = trunc_seq;
ops[i].indata = bl;
ops[i].op.flags = op_flags;
- Op *o = new Op(oid, oloc, ops, flags | global_op_flags.read() |
+ Op *o = new Op(oid, oloc, ops, flags | global_op_flags |
CEPH_OSD_FLAG_WRITE, oncommit, objver);
o->mtime = mtime;
o->snapc = snapc;
ops[i].op.extent.length = bl.length();
ops[i].indata = bl;
ops[i].op.flags = op_flags;
- Op *o = new Op(oid, oloc, ops, flags | global_op_flags.read() |
+ Op *o = new Op(oid, oloc, ops, flags | global_op_flags |
CEPH_OSD_FLAG_WRITE, oncommit, objver);
o->mtime = mtime;
o->snapc = snapc;
ops[i].op.writesame.data_length = bl.length();
ops[i].indata = bl;
ops[i].op.flags = op_flags;
- Op *o = new Op(oid, oloc, ops, flags | global_op_flags.read() |
+ Op *o = new Op(oid, oloc, ops, flags | global_op_flags |
CEPH_OSD_FLAG_WRITE, oncommit, objver);
o->mtime = mtime;
o->snapc = snapc;
ops[i].op.extent.offset = trunc_size;
ops[i].op.extent.truncate_size = trunc_size;
ops[i].op.extent.truncate_seq = trunc_seq;
- Op *o = new Op(oid, oloc, ops, flags | global_op_flags.read() |
+ Op *o = new Op(oid, oloc, ops, flags | global_op_flags |
CEPH_OSD_FLAG_WRITE, oncommit, objver);
o->mtime = mtime;
o->snapc = snapc;
ops[i].op.op = CEPH_OSD_OP_ZERO;
ops[i].op.extent.offset = off;
ops[i].op.extent.length = len;
- Op *o = new Op(oid, oloc, ops, flags | global_op_flags.read() |
+ Op *o = new Op(oid, oloc, ops, flags | global_op_flags |
CEPH_OSD_FLAG_WRITE, oncommit, objver);
o->mtime = mtime;
o->snapc = snapc;
int i = init_ops(ops, 1, extra_ops);
ops[i].op.op = CEPH_OSD_OP_CREATE;
ops[i].op.flags = create_flags;
- Op *o = new Op(oid, oloc, ops, global_flags | global_op_flags.read() |
+ Op *o = new Op(oid, oloc, ops, global_flags | global_op_flags |
CEPH_OSD_FLAG_WRITE, oncommit, objver);
o->mtime = mtime;
o->snapc = snapc;
vector<OSDOp> ops;
int i = init_ops(ops, 1, extra_ops);
ops[i].op.op = CEPH_OSD_OP_DELETE;
- Op *o = new Op(oid, oloc, ops, flags | global_op_flags.read() |
+ Op *o = new Op(oid, oloc, ops, flags | global_op_flags |
CEPH_OSD_FLAG_WRITE, oncommit, objver);
o->mtime = mtime;
o->snapc = snapc;
if (name)
ops[i].indata.append(name);
ops[i].indata.append(bl);
- Op *o = new Op(oid, oloc, ops, flags | global_op_flags.read() |
+ Op *o = new Op(oid, oloc, ops, flags | global_op_flags |
CEPH_OSD_FLAG_WRITE, oncommit, objver);
o->mtime = mtime;
o->snapc = snapc;
ops[i].op.xattr.value_len = 0;
if (name)
ops[i].indata.append(name);
- Op *o = new Op(oid, oloc, ops, flags | global_op_flags.read() |
+ Op *o = new Op(oid, oloc, ops, flags | global_op_flags |
CEPH_OSD_FLAG_WRITE, oncommit, objver);
o->mtime = mtime;
o->snapc = snapc;