]> git.apps.os.sepia.ceph.com Git - ceph-ci.git/commitdiff
librados: mark all auid calls deprecated
authorSage Weil <sage@redhat.com>
Sat, 11 Aug 2018 17:26:22 +0000 (12:26 -0500)
committerSage Weil <sage@redhat.com>
Fri, 31 Aug 2018 14:26:19 +0000 (09:26 -0500)
Signed-off-by: Sage Weil <sage@redhat.com>
src/include/rados/librados.h
src/include/rados/librados.hpp

index fb9989014ed2fb4478e1804c4095958c1a9a47aa..2c02ad7e0222f19a9cba851ceb7b5a284b6b7d40 100644 (file)
@@ -817,7 +817,6 @@ CEPH_RADOS_API int rados_pool_reverse_lookup(rados_t cluster, int64_t id,
 /**
  * Create a pool with default settings
  *
- * The default owner is the admin user (auid 0).
  * The default crush rule is rule 0.
  *
  * @param cluster the cluster in which the pool will be created
@@ -827,10 +826,10 @@ CEPH_RADOS_API int rados_pool_reverse_lookup(rados_t cluster, int64_t id,
 CEPH_RADOS_API int rados_pool_create(rados_t cluster, const char *pool_name);
 
 /**
- * Create a pool owned by a specific auid
+ * Create a pool owned by a specific auid.
  *
- * The auid is the authenticated user id to give ownership of the pool.
- * TODO: document auid and the rest of the auth system
+ * DEPRECATED: auid support has been removed, and this call will be removed in a future
+ * release.
  *
  * @param cluster the cluster in which the pool will be created
  * @param pool_name the name of the new pool
@@ -839,7 +838,8 @@ CEPH_RADOS_API int rados_pool_create(rados_t cluster, const char *pool_name);
  */
 CEPH_RADOS_API int rados_pool_create_with_auid(rados_t cluster,
                                                const char *pool_name,
-                                               uint64_t auid);
+                                               uint64_t auid)
+  __attribute__((deprecated));
 
 /**
  * Create a pool with a specific CRUSH rule
@@ -856,6 +856,9 @@ CEPH_RADOS_API int rados_pool_create_with_crush_rule(rados_t cluster,
 /**
  * Create a pool with a specific CRUSH rule and auid
  *
+ * DEPRECATED: auid support has been removed and this call will be removed
+ * in a future release.
+ *
  * This is a combination of rados_pool_create_with_crush_rule() and
  * rados_pool_create_with_auid().
  *
@@ -868,7 +871,8 @@ CEPH_RADOS_API int rados_pool_create_with_crush_rule(rados_t cluster,
 CEPH_RADOS_API int rados_pool_create_with_all(rados_t cluster,
                                               const char *pool_name,
                                               uint64_t auid,
-                                             uint8_t crush_rule_num);
+                                             uint8_t crush_rule_num)
+  __attribute__((deprecated));
 
 /**
  * Returns the pool that is the base tier for this pool.
@@ -899,6 +903,8 @@ CEPH_RADOS_API int rados_pool_delete(rados_t cluster, const char *pool_name);
 /**
  * Attempt to change an io context's associated auid "owner"
  *
+ * DEPRECATED: auid support has been removed and this call has no effect.
+ *
  * Requires that you have write permission on both the current and new
  * auid.
  *
@@ -906,16 +912,22 @@ CEPH_RADOS_API int rados_pool_delete(rados_t cluster, const char *pool_name);
  * @param auid the auid you wish the io to have.
  * @returns 0 on success, negative error code on failure
  */
-CEPH_RADOS_API int rados_ioctx_pool_set_auid(rados_ioctx_t io, uint64_t auid);
+CEPH_RADOS_API int rados_ioctx_pool_set_auid(rados_ioctx_t io, uint64_t auid)
+  __attribute__((deprecated));
+
 
 /**
  * Get the auid of a pool
  *
+ * DEPRECATED: auid support has been removed and this call always reports
+ * CEPH_AUTH_UID_DEFAULT (-1).
+
  * @param io pool to query
  * @param auid where to store the auid
  * @returns 0 on success, negative error code on failure
  */
-CEPH_RADOS_API int rados_ioctx_pool_get_auid(rados_ioctx_t io, uint64_t *auid);
+CEPH_RADOS_API int rados_ioctx_pool_get_auid(rados_ioctx_t io, uint64_t *auid)
+  __attribute__((deprecated));
 
 /* deprecated, use rados_ioctx_pool_requires_alignment2 instead */
 CEPH_RADOS_API int rados_ioctx_pool_requires_alignment(rados_ioctx_t io)
index 3355e0c4c034bfc02dd06aeb0794d67afdc77aa0..b14154eff4c3eff7e44bf0f7e4dfb6982ee8bbee 100644 (file)
@@ -719,13 +719,16 @@ namespace librados
     void dup(const IoCtx& rhs);
 
     // set pool auid
-    int set_auid(uint64_t auid_);
+    int set_auid(uint64_t auid_)
+      __attribute__ ((deprecated));
 
     // set pool auid
-    int set_auid_async(uint64_t auid_, PoolAsyncCompletion *c);
+    int set_auid_async(uint64_t auid_, PoolAsyncCompletion *c)
+      __attribute__ ((deprecated));
 
     // get pool auid
-    int get_auid(uint64_t *auid_);
+    int get_auid(uint64_t *auid_)
+      __attribute__ ((deprecated));
 
     uint64_t get_instance_id() const;
 
@@ -1330,11 +1333,15 @@ namespace librados
       std::map<std::string,std::string>&& status);
 
     int pool_create(const char *name);
-    int pool_create(const char *name, uint64_t auid);
-    int pool_create(const char *name, uint64_t auid, uint8_t crush_rule);
+    int pool_create(const char *name, uint64_t auid)
+      __attribute__ ((deprecated));
+    int pool_create(const char *name, uint64_t auid, uint8_t crush_rule)
+      __attribute__ ((deprecated));
     int pool_create_async(const char *name, PoolAsyncCompletion *c);
-    int pool_create_async(const char *name, uint64_t auid, PoolAsyncCompletion *c);
-    int pool_create_async(const char *name, uint64_t auid, uint8_t crush_rule, PoolAsyncCompletion *c);
+    int pool_create_async(const char *name, uint64_t auid, PoolAsyncCompletion *c)
+      __attribute__ ((deprecated));
+    int pool_create_async(const char *name, uint64_t auid, uint8_t crush_rule, PoolAsyncCompletion *c)
+      __attribute__ ((deprecated));
     int pool_get_base_tier(int64_t pool, int64_t* base_tier);
     int pool_delete(const char *name);
     int pool_delete_async(const char *name, PoolAsyncCompletion *c);