X-Git-Url: https://gerrit.opnfv.org/gerrit/gitweb?a=blobdiff_plain;f=src%2Fceph%2Fsrc%2Fcls%2Frefcount%2Fcls_refcount_client.h;fp=src%2Fceph%2Fsrc%2Fcls%2Frefcount%2Fcls_refcount_client.h;h=0000000000000000000000000000000000000000;hb=7da45d65be36d36b880cc55c5036e96c24b53f00;hp=654cc00f3248bb8dfb3bf90ed6159f84cdfb0589;hpb=691462d09d0987b47e112d6ee8740375df3c51b2;p=stor4nfv.git diff --git a/src/ceph/src/cls/refcount/cls_refcount_client.h b/src/ceph/src/cls/refcount/cls_refcount_client.h deleted file mode 100644 index 654cc00..0000000 --- a/src/ceph/src/cls/refcount/cls_refcount_client.h +++ /dev/null @@ -1,38 +0,0 @@ -#ifndef CEPH_CLS_REFCOUNT_CLIENT_H -#define CEPH_CLS_REFCOUNT_CLIENT_H - -#include "include/types.h" - -namespace librados { - class ObjectWriteOperation; - class IoCtx; -} - -/* - * refcount objclass - * - * The refcount objclass implements a refcounting scheme that allows having multiple references - * to a single rados object. The canonical way to use it is to add a reference and to remove a - * reference using a specific tag. This way we ensure that refcounting operations are idempotent, - * that is, a single client can only increase/decrease the refcount once using a single tag, so - * any replay of operations (implicit or explicit) is possible. - * - * So, the regular usage would be to create an object, to increase the refcount. Then, when - * wanting to have another reference to it, increase the refcount using a different tag. When - * removing a reference it is required to drop the refcount (using the same tag that was used - * for that reference). When the refcount drops to zero, the object is removed automaticfally. - * - * In order to maintain backwards compatibility with objects that were created without having - * their refcount increased, the implicit_ref was added. Any object that was created without - * having it's refcount increased (explicitly) is having an implicit refcount of 1. Since - * we don't have a tag for this refcount, we consider this tag as a wildcard. So if the refcount - * is being decreased by an unknown tag and we still have one wildcard tag, we'll accept it - * as the relevant tag, and the refcount will be decreased. - */ - -void cls_refcount_get(librados::ObjectWriteOperation& op, const string& tag, bool implicit_ref = false); -void cls_refcount_put(librados::ObjectWriteOperation& op, const string& tag, bool implicit_ref = false); -void cls_refcount_set(librados::ObjectWriteOperation& op, list& refs); -int cls_refcount_read(librados::IoCtx& io_ctx, string& oid, list *refs, bool implicit_ref = false); - -#endif