diff --git a/PendingReleaseNotes b/PendingReleaseNotes index 67919e541184e..ccbe0596b70bc 100644 --- a/PendingReleaseNotes +++ b/PendingReleaseNotes @@ -11,3 +11,10 @@ v0.68 offender, has been removed. This breaks compatibility with pre-bobtail librbd clients by preventing them from creating new images. + +* librados now returns on commit instead of ack for synchronous calls. + This is a bit safer in the case where both OSDs and the client crash, and + is probably how it should have been acting from the beginning. Users are + unlikely to notice but it could result in lower performance in some + circumstances. Those who care should switch to using the async interfaces, + which let you specify safety semantics precisely. \ No newline at end of file diff --git a/src/include/rados/librados.h b/src/include/rados/librados.h index 4a5be3d177795..6f5e454c8e88d 100644 --- a/src/include/rados/librados.h +++ b/src/include/rados/librados.h @@ -24,7 +24,7 @@ extern "C" { #endif #define LIBRADOS_VER_MAJOR 0 -#define LIBRADOS_VER_MINOR 53 +#define LIBRADOS_VER_MINOR 68 #define LIBRADOS_VER_EXTRA 0 #define LIBRADOS_VERSION(maj, min, extra) ((maj << 16) + (min << 8) + extra) diff --git a/src/librados/IoCtxImpl.cc b/src/librados/IoCtxImpl.cc index ce9743a54b36c..c79005854584e 100644 --- a/src/librados/IoCtxImpl.cc +++ b/src/librados/IoCtxImpl.cc @@ -504,14 +504,14 @@ int librados::IoCtxImpl::operate(const object_t& oid, ::ObjectOperation *o, int r; eversion_t ver; - Context *onack = new C_SafeCond(&mylock, &cond, &done, &r); + Context *oncommit = new C_SafeCond(&mylock, &cond, &done, &r); int op = o->ops[0].op.op; ldout(client->cct, 10) << ceph_osd_op_name(op) << " oid=" << oid << " nspace=" << oloc.nspace << dendl; lock->Lock(); objecter->mutate(oid, oloc, *o, snapc, ut, 0, - onack, NULL, &ver); + NULL, oncommit, &ver); lock->Unlock(); mylock.Lock();