diff --git a/cinderclient/shell_utils.py b/cinderclient/shell_utils.py index 0bfecae8c..35802f85b 100644 --- a/cinderclient/shell_utils.py +++ b/cinderclient/shell_utils.py @@ -21,8 +21,7 @@ from cinderclient import utils _quota_resources = ['volumes', 'snapshots', 'gigabytes', 'backups', 'backup_gigabytes', - 'consistencygroups', 'per_volume_gigabytes', - 'groups', ] + 'per_volume_gigabytes', 'groups', ] _quota_infos = ['Type', 'In_use', 'Reserved', 'Limit'] diff --git a/cinderclient/tests/unit/v2/fakes.py b/cinderclient/tests/unit/v2/fakes.py index 900a4f2cc..04c179d92 100644 --- a/cinderclient/tests/unit/v2/fakes.py +++ b/cinderclient/tests/unit/v2/fakes.py @@ -627,7 +627,6 @@ class FakeHTTPClient(base_client.HTTPClient): 'gigabytes': 1, 'backups': 1, 'backup_gigabytes': 1, - 'consistencygroups': 1, 'per_volume_gigabytes': 1, }}) def get_os_quota_sets_test_defaults(self): @@ -639,7 +638,6 @@ class FakeHTTPClient(base_client.HTTPClient): 'gigabytes': 1, 'backups': 1, 'backup_gigabytes': 1, - 'consistencygroups': 1, 'per_volume_gigabytes': 1, }}) def put_os_quota_sets_test(self, body, **kw): @@ -654,7 +652,6 @@ class FakeHTTPClient(base_client.HTTPClient): 'gigabytes': 1, 'backups': 1, 'backup_gigabytes': 1, - 'consistencygroups': 2, 'per_volume_gigabytes': 1, }}) def delete_os_quota_sets_1234(self, **kw): diff --git a/cinderclient/tests/unit/v2/test_quotas.py b/cinderclient/tests/unit/v2/test_quotas.py index 6dd20b01d..bb29e4d8e 100644 --- a/cinderclient/tests/unit/v2/test_quotas.py +++ b/cinderclient/tests/unit/v2/test_quotas.py @@ -41,7 +41,6 @@ class QuotaSetsTest(utils.TestCase): q.update(gigabytes=2000) q.update(backups=2) q.update(backup_gigabytes=2000) - q.update(consistencygroups=2) q.update(per_volume_gigabytes=100) cs.assert_called('PUT', '/os-quota-sets/test') self._assert_request_id(q) @@ -54,7 +53,6 @@ class QuotaSetsTest(utils.TestCase): self.assertEqual(q.gigabytes, q2.gigabytes) self.assertEqual(q.backups, q2.backups) self.assertEqual(q.backup_gigabytes, q2.backup_gigabytes) - self.assertEqual(q.consistencygroups, q2.consistencygroups) self.assertEqual(q.per_volume_gigabytes, q2.per_volume_gigabytes) q2.volumes = 0 self.assertNotEqual(q.volumes, q2.volumes) @@ -66,8 +64,6 @@ class QuotaSetsTest(utils.TestCase): self.assertNotEqual(q.backups, q2.backups) q2.backup_gigabytes = 0 self.assertNotEqual(q.backup_gigabytes, q2.backup_gigabytes) - q2.consistencygroups = 0 - self.assertNotEqual(q.consistencygroups, q2.consistencygroups) q2.per_volume_gigabytes = 0 self.assertNotEqual(q.per_volume_gigabytes, q2.per_volume_gigabytes) q2.get() @@ -76,7 +72,6 @@ class QuotaSetsTest(utils.TestCase): self.assertEqual(q.gigabytes, q2.gigabytes) self.assertEqual(q.backups, q2.backups) self.assertEqual(q.backup_gigabytes, q2.backup_gigabytes) - self.assertEqual(q.consistencygroups, q2.consistencygroups) self.assertEqual(q.per_volume_gigabytes, q2.per_volume_gigabytes) self._assert_request_id(q) self._assert_request_id(q2) diff --git a/cinderclient/v2/shell.py b/cinderclient/v2/shell.py index c22116eda..2e1e46a12 100644 --- a/cinderclient/v2/shell.py +++ b/cinderclient/v2/shell.py @@ -978,10 +978,6 @@ def do_quota_defaults(cs, args): metavar='', type=int, default=None, help='The new "backup_gigabytes" quota value. Default=None.') -@utils.arg('--consistencygroups', - metavar='', - type=int, default=None, - help='The new "consistencygroups" quota value. Default=None.') @utils.arg('--volume-type', metavar='', default=None, diff --git a/cinderclient/v3/shell.py b/cinderclient/v3/shell.py index a389f0959..94aecb1a9 100644 --- a/cinderclient/v3/shell.py +++ b/cinderclient/v3/shell.py @@ -743,10 +743,6 @@ def do_group_type_key(cs, args): metavar='', type=int, default=None, help='The new "backup_gigabytes" quota value. Default=None.') -@utils.arg('--consistencygroups', - metavar='', - type=int, default=None, - help='The new "consistencygroups" quota value. Default=None.') @utils.arg('--groups', metavar='', type=int, default=None, diff --git a/releasenotes/notes/remove-cg-quota-9d4120b62f09cc5c.yaml b/releasenotes/notes/remove-cg-quota-9d4120b62f09cc5c.yaml new file mode 100644 index 000000000..6f4d4d429 --- /dev/null +++ b/releasenotes/notes/remove-cg-quota-9d4120b62f09cc5c.yaml @@ -0,0 +1,3 @@ +--- +other: + - The useless consistencygroup quota operation has been removed.