File tree Expand file tree Collapse file tree 2 files changed +53
-0
lines changed
Expand file tree Collapse file tree 2 files changed +53
-0
lines changed Original file line number Diff line number Diff line change @@ -486,3 +486,12 @@ def list(self, pool_name):
486486 'num_images' : len (list (rbd .Group (ioctx , group ).list_images ()))
487487 })
488488 return result
489+
490+ @EndpointDoc ("Create an RBD Group" ,
491+ parameters = {
492+ 'pool_name' : (str , 'Name of the pool' ),
493+ 'name' : (str , 'Name of the group' ),
494+ })
495+ def create (self , pool_name , name ):
496+ with mgr .rados .open_ioctx (pool_name ) as ioctx :
497+ return self .rbd_inst .group_create (ioctx , name )
Original file line number Diff line number Diff line change @@ -1632,6 +1632,50 @@ paths:
16321632 summary: Display RBD Groups by pool name
16331633 tags:
16341634 - RbdGroup
1635+ post:
1636+ parameters:
1637+ - description: Name of the pool
1638+ in: path
1639+ name: pool_name
1640+ required: true
1641+ schema:
1642+ type: string
1643+ requestBody:
1644+ content:
1645+ application/json:
1646+ schema:
1647+ properties:
1648+ name:
1649+ description: Name of the group
1650+ type: string
1651+ required:
1652+ - name
1653+ type: object
1654+ responses:
1655+ '201':
1656+ content:
1657+ application/vnd.ceph.api.v1.0+json:
1658+ type: object
1659+ description: Resource created.
1660+ '202':
1661+ content:
1662+ application/vnd.ceph.api.v1.0+json:
1663+ type: object
1664+ description: Operation is still executing. Please check the task queue.
1665+ '400':
1666+ description: Operation exception. Please check the response body for details.
1667+ '401':
1668+ description: Unauthenticated access. Please login first.
1669+ '403':
1670+ description: Unauthorized access. Please check your permissions.
1671+ '500':
1672+ description: Unexpected error. Please check the response body for the stack
1673+ trace.
1674+ security:
1675+ - jwt: []
1676+ summary: Create an RBD Group
1677+ tags:
1678+ - RbdGroup
16351679 /api/block/pool/{pool_name}/namespace:
16361680 get:
16371681 parameters:
You can’t perform that action at this time.
0 commit comments