]> git.apps.os.sepia.ceph.com Git - ceph-ci.git/commitdiff
pybind/rados: drop auid arg to pool_create
authorSage Weil <sage@redhat.com>
Sat, 11 Aug 2018 19:00:58 +0000 (14:00 -0500)
committerSage Weil <sage@redhat.com>
Fri, 31 Aug 2018 14:27:36 +0000 (09:27 -0500)
Signed-off-by: Sage Weil <sage@redhat.com>
doc/rados/api/python.rst
src/pybind/rados/rados.pyx

index cf4a1790b3eb8315c7995935a05d5fd10a8fe580..977b603ff89cc60ea22e90c59b9befcc2119339e 100644 (file)
@@ -314,7 +314,7 @@ first.  You may list the available pools, create a pool, check to see if a pool
 exists,  and delete a pool.
 
 .. automethod:: Rados.list_pools()
-.. automethod:: Rados.create_pool(pool_name, auid=None, crush_rule=None)
+.. automethod:: Rados.create_pool(pool_name, crush_rule=None)
 .. automethod:: Rados.pool_exists()
 .. automethod:: Rados.delete_pool(pool_name)
 
@@ -331,7 +331,6 @@ invoking methods of the `Ioctx` and other classes.
 .. automethod:: Rados.open_ioctx(ioctx_name)
 .. automethod:: Ioctx.require_ioctx_open()
 .. automethod:: Ioctx.get_stats()
-.. automethod:: Ioctx.change_auid(auid)
 .. automethod:: Ioctx.get_last_version()
 .. automethod:: Ioctx.close()
 
index 44149a21c688511ab9f705bc5b42aaa24c2db879..be18a7a5c8619636426a115a46490dd8b5978e59 100644 (file)
@@ -141,9 +141,7 @@ cdef extern from "rados/librados.h" nogil:
     int64_t rados_pool_lookup(rados_t cluster, const char *pool_name)
     int rados_pool_reverse_lookup(rados_t cluster, int64_t id, char *buf, size_t maxlen)
     int rados_pool_create(rados_t cluster, const char *pool_name)
-    int rados_pool_create_with_auid(rados_t cluster, const char *pool_name, uint64_t auid)
     int rados_pool_create_with_crush_rule(rados_t cluster, const char *pool_name, uint8_t crush_rule_num)
-    int rados_pool_create_with_all(rados_t cluster, const char *pool_name, uint64_t auid, uint8_t crush_rule_num)
     int rados_pool_get_base_tier(rados_t cluster, int64_t pool, int64_t *base_tier)
     int rados_pool_list(rados_t cluster, char *buf, size_t len)
     int rados_pool_delete(rados_t cluster, const char *pool_name)
@@ -1023,19 +1021,15 @@ Rados object in state %s." % self.state)
         finally:
             free(name)
 
-    @requires(('pool_name', str_type), ('auid', opt(int)), ('crush_rule', opt(int)))
-    def create_pool(self, pool_name, auid=None, crush_rule=None):
+    @requires(('pool_name', str_type), ('crush_rule', opt(int)))
+    def create_pool(self, pool_name, crush_rule=None):
         """
         Create a pool:
-        - with default settings: if auid=None and crush_rule=None
-        - owned by a specific auid: auid given and crush_rule=None
-        - with a specific CRUSH rule: if auid=None and crush_rule given
-        - with a specific CRUSH rule and auid: if auid and crush_rule given
+        - with default settings: if crush_rule=None
+        - with a specific CRUSH rule: crush_rule given
 
         :param pool_name: name of the pool to create
         :type pool_name: str
-        :param auid: the id of the owner of the new pool
-        :type auid: int
         :param crush_rule: rule to use for placement in the new pool
         :type crush_rule: int
 
@@ -1047,24 +1041,14 @@ Rados object in state %s." % self.state)
         cdef:
             char *_pool_name = pool_name
             uint8_t _crush_rule
-            uint64_t _auid
 
-        if auid is None and crush_rule is None:
+        if crush_rule is None:
             with nogil:
                 ret = rados_pool_create(self.cluster, _pool_name)
-        elif auid is None:
-            _crush_rule = crush_rule
-            with nogil:
-                ret = rados_pool_create_with_crush_rule(self.cluster, _pool_name, _crush_rule)
-        elif crush_rule is None:
-            _auid = auid
-            with nogil:
-                ret = rados_pool_create_with_auid(self.cluster, _pool_name, _auid)
         else:
-            _auid = auid
             _crush_rule = crush_rule
             with nogil:
-                ret = rados_pool_create_with_all(self.cluster, _pool_name, _auid, _crush_rule)
+                ret = rados_pool_create_with_crush_rule(self.cluster, _pool_name, _crush_rule)
         if ret < 0:
             raise make_ex(ret, "error creating pool '%s'" % pool_name)