summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPeter Stachowski <peter@tesora.com>2014-05-06 12:42:48 -0400
committerPeter Stachowski <peter@tesora.com>2014-05-26 17:13:14 -0400
commit30c924e343a80b2ac6b576393ccb5a15b4185d54 (patch)
tree81e7eb9675857bba8dfbe3bb9908e9563d7ff1fc
parentd02764e597b331c0c692488477a9ce29045eb32a (diff)
downloadpython-troveclient-30c924e343a80b2ac6b576393ccb5a15b4185d54.tar.gz
Fixed positional order of arguments
The positional arguments of backup-create and configuration-attach were different from all other commands. 'Instance' is now the first argument for these commands as well. DocImpact: This potentially affects any user scripts that may exist. Any instructions like: 'trove backup-create mybackup myinstance' 'trove configuration-attach myconfig myinstance' should be changed to: 'trove backup-create myinstance mybackup.' 'trove configuration-attach myinstance myconfig' Change-Id: I2ff93a1a6e26f3e33a60cbf3d9ad5ee074307e8f Closes-Bug: #1281878
-rw-r--r--troveclient/v1/shell.py12
1 files changed, 6 insertions, 6 deletions
diff --git a/troveclient/v1/shell.py b/troveclient/v1/shell.py
index 6c1b69d..53a89ef 100644
--- a/troveclient/v1/shell.py
+++ b/troveclient/v1/shell.py
@@ -292,10 +292,10 @@ def do_backup_show(cs, args):
_print_instance(backup)
+@utils.arg('instance', metavar='<instance>', help='ID of the instance.')
@utils.arg('--limit', metavar='<limit>',
default=None,
help='Return up to N number of the most recent backups.')
-@utils.arg('instance', metavar='<instance>', help='ID of the instance.')
@utils.service_type('database')
def do_backup_list_instance(cs, args):
"""Lists available backups for an instance."""
@@ -332,8 +332,8 @@ def do_backup_delete(cs, args):
cs.backups.delete(args.backup)
-@utils.arg('name', metavar='<name>', help='Name of the backup.')
@utils.arg('instance', metavar='<instance>', help='ID of the instance.')
+@utils.arg('name', metavar='<name>', help='Name of the backup.')
@utils.arg('--description', metavar='<description>',
default=None,
help='An optional description for the backup.')
@@ -638,14 +638,14 @@ def do_datastore_version_show(cs, args):
# configuration group related functions
-@utils.arg('configuration',
- metavar='<configuration>',
- type=str,
- help='ID of the configuration group to attach to the instance.')
@utils.arg('instance',
metavar='<instance>',
type=str,
help='ID of the instance.')
+@utils.arg('configuration',
+ metavar='<configuration>',
+ type=str,
+ help='ID of the configuration group to attach to the instance.')
@utils.service_type('database')
def do_configuration_attach(cs, args):
"""Attaches a configuration group to an instance."""