Skip to content

Commit

Permalink
Merge pull request #100 from frac/master
Browse files Browse the repository at this point in the history
Remove deprecated cli options
  • Loading branch information
mergify[bot] authored Nov 28, 2018
2 parents 72cdf3e + 4a9d96c commit 5e81639
Show file tree
Hide file tree
Showing 2 changed files with 0 additions and 41 deletions.
36 changes: 0 additions & 36 deletions gnocchiclient/v1/metric_cli.py
Original file line number Diff line number Diff line change
Expand Up @@ -62,15 +62,6 @@ def take_action(self, parsed_args):
return utils.list2cols(self.COLS, metrics)


class DeprecatedCliMetricList(CliMetricList):
"""Deprecated: List metrics."""

def take_action(self, parsed_args):
LOG_DEP.warning('This command has been deprecated. '
'Please use "metric list" instead.')
return super(DeprecatedCliMetricList, self).take_action(parsed_args)


class CliMetricShow(CliMetricWithResourceID, show.ShowOne):
"""Show a metric."""

Expand All @@ -92,15 +83,6 @@ def take_action(self, parsed_args):
return self.dict2columns(metric)


class DeprecatedCliMetricShow(CliMetricShow):
"""Deprecated: Show a metric."""

def take_action(self, parsed_args):
LOG_DEP.warning('This command has been deprecated. '
'Please use "metric show" instead.')
return super(DeprecatedCliMetricShow, self).take_action(parsed_args)


class CliMetricCreateBase(show.ShowOne, CliMetricWithResourceID):
def get_parser(self, prog_name):
parser = super(CliMetricCreateBase, self).get_parser(prog_name)
Expand Down Expand Up @@ -138,15 +120,6 @@ def take_action(self, parsed_args):
return self.dict2columns(metric)


class DeprecatedCliMetricCreate(CliMetricCreate):
"""Deprecated: Create a metric."""

def take_action(self, parsed_args):
LOG_DEP.warning('This command has been deprecated. '
'Please use "metric create" instead.')
return super(DeprecatedCliMetricCreate, self).take_action(parsed_args)


class CliMetricDelete(CliMetricWithResourceID):
"""Delete a metric."""

Expand All @@ -162,15 +135,6 @@ def take_action(self, parsed_args):
metric=metric, resource_id=parsed_args.resource_id)


class DeprecatedCliMetricDelete(CliMetricDelete):
"""Deprecated: Delete a metric."""

def take_action(self, parsed_args):
LOG_DEP.warning('This command has been deprecated. '
'Please use "metric delete" instead.')
return super(DeprecatedCliMetricDelete, self).take_action(parsed_args)


class CliMeasuresReturn(lister.Lister):
def get_parser(self, prog_name):
parser = super(CliMeasuresReturn, self).get_parser(prog_name)
Expand Down
5 changes: 0 additions & 5 deletions setup.cfg
Original file line number Diff line number Diff line change
Expand Up @@ -57,11 +57,6 @@ openstack.metric.v1 =
metric_archive-policy-rule_show = gnocchiclient.v1.archive_policy_rule_cli:CliArchivePolicyRuleShow
metric_archive-policy-rule_create = gnocchiclient.v1.archive_policy_rule_cli:CliArchivePolicyRuleCreate
metric_archive-policy-rule_delete = gnocchiclient.v1.archive_policy_rule_cli:CliArchivePolicyRuleDelete
# FIXME(rabel): Deprecate metric_metric entry points
metric_metric_list = gnocchiclient.v1.metric_cli:DeprecatedCliMetricList
metric_metric_show = gnocchiclient.v1.metric_cli:DeprecatedCliMetricShow
metric_metric_create = gnocchiclient.v1.metric_cli:DeprecatedCliMetricCreate
metric_metric_delete = gnocchiclient.v1.metric_cli:DeprecatedCliMetricDelete
metric_list = gnocchiclient.v1.metric_cli:CliMetricList
metric_show = gnocchiclient.v1.metric_cli:CliMetricShow
metric_create = gnocchiclient.v1.metric_cli:CliMetricCreate
Expand Down

0 comments on commit 5e81639

Please sign in to comment.