Skip to content

Commit b0e7bf0

Browse files
authored
chore: update usage in readme (#212)
1 parent 0daba52 commit b0e7bf0

File tree

1 file changed

+25
-56
lines changed

1 file changed

+25
-56
lines changed

README.md

Lines changed: 25 additions & 56 deletions
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,6 @@ Suitable for DynamoDB usages of smaller data volume which do not warrant the usa
1515

1616
dynamodump supports local DynamoDB instances as well (tested with [DynamoDB Local](https://docs.aws.amazon.com/amazondynamodb/latest/developerguide/DynamoDBLocal.html)).
1717

18-
1918
## Table of Contents
2019

2120
- [Installation](#installation)
@@ -35,82 +34,52 @@ pip install dynamodump
3534
## Usage
3635

3736
```
38-
usage: dynamodump [-h] [-a {zip,tar}] [-b BUCKET]
39-
[-m {backup,restore,empty}] [-r REGION] [--host HOST]
40-
[--port PORT] [--accessKey ACCESSKEY]
41-
[--secretKey SECRETKEY] [-p PROFILE] [-s SRCTABLE]
42-
[-d DESTTABLE] [--prefixSeparator PREFIXSEPARATOR]
43-
[--noSeparator] [--readCapacity READCAPACITY] [-t TAG]
44-
[--writeCapacity WRITECAPACITY] [--schemaOnly]
45-
[--dataOnly] [--noConfirm] [--skipThroughputUpdate]
46-
[--billingMode BILLING_MODE] [--dumpPath DUMPPATH] [--log LOG]
47-
[-f FILTEROPTION]
37+
usage: dynamodump.py [-h] [-a {zip,tar}] [-b BUCKET] [-m {backup,restore,empty}] [-r REGION] [--host HOST] [--port PORT] [--accessKey ACCESSKEY] [--secretKey SECRETKEY] [-p PROFILE] [-s SRCTABLE] [-d DESTTABLE]
38+
[--prefixSeparator PREFIXSEPARATOR] [--noSeparator] [--readCapacity READCAPACITY] [-t TAG] [--writeCapacity WRITECAPACITY] [--schemaOnly] [--dataOnly] [--noConfirm] [--skipThroughputUpdate]
39+
[--dumpPath DUMPPATH] [--billingMode {PROVISIONED,PAY_PER_REQUEST}] [--log LOG] [--limit LIMIT] [-f FILTEROPTION]
4840
4941
Simple DynamoDB backup/restore/empty.
5042
51-
optional arguments:
43+
options:
5244
-h, --help show this help message and exit
5345
-a {zip,tar}, --archive {zip,tar}
54-
Type of compressed archive to create.If unset, don't
55-
create archive
46+
Type of compressed archive to create. If unset, don't create archive
5647
-b BUCKET, --bucket BUCKET
57-
S3 bucket in which to store or retrieve backups.[must
58-
already exist]
48+
S3 bucket in which to store or retrieve backups. [must already exist]
5949
-m {backup,restore,empty}, --mode {backup,restore,empty}
6050
Operation to perform
6151
-r REGION, --region REGION
62-
AWS region to use, e.g. 'us-west-1'. Can use
63-
AWS_DEFAULT_REGION for local testing. Use 'local' for
64-
local DynamoDB testing
65-
--host HOST Host of local DynamoDB [required only for local]
52+
AWS region to use, e.g. 'us-west-1'. Can use any region for local testing
53+
--host HOST Host of local DynamoDB. This parameter initialises dynamodump for local DynamoDB testing [required only for local]
6654
--port PORT Port of local DynamoDB [required only for local]
6755
--accessKey ACCESSKEY
6856
Access key of local DynamoDB [required only for local]
6957
--secretKey SECRETKEY
7058
Secret key of local DynamoDB [required only for local]
7159
-p PROFILE, --profile PROFILE
72-
AWS credentials file profile to use. Allows you to use
73-
a profile instead accessKey, secretKey authentication
60+
AWS credentials file profile to use. Allows you to use a profile instead accessKey, secretKey authentication
7461
-s SRCTABLE, --srcTable SRCTABLE
75-
Source DynamoDB table name to backup or restore from,
76-
use 'tablename*' for wildcard prefix selection or '*'
77-
for all tables. Mutually exclusive with --tag
62+
Source DynamoDB table name to backup or restore from, use 'tablename*' for wildcard prefix selection or '*' for all tables. Mutually exclusive with --tag
7863
-d DESTTABLE, --destTable DESTTABLE
79-
Destination DynamoDB table name to backup or restore
80-
to, use 'tablename*' for wildcard prefix selection
81-
(defaults to use '-' separator) [optional, defaults to
82-
source]
64+
Destination DynamoDB table name to backup or restore to, use 'tablename*' for wildcard prefix selection (defaults to use '-' separator) [optional, defaults to source]
8365
--prefixSeparator PREFIXSEPARATOR
84-
Specify a different prefix separator, e.g. '.'
85-
[optional]
86-
--noSeparator Overrides the use of a prefix separator for backup
87-
wildcard searches [optional]
66+
Specify a different prefix separator, e.g. '.' [optional]
67+
--noSeparator Overrides the use of a prefix separator for backup wildcard searches [optional]
8868
--readCapacity READCAPACITY
89-
Change the temp read capacity of the DynamoDB table to
90-
backup from [optional]
91-
-t TAG, --tag TAG Tag to use for identifying tables to back up. Mutually
92-
exclusive with srcTable. Provided as KEY=VALUE
69+
Change the temp read capacity of the DynamoDB table to backup from [optional]
70+
-t TAG, --tag TAG Tag to use for identifying tables to back up. Mutually exclusive with srcTable. Provided as KEY=VALUE
9371
--writeCapacity WRITECAPACITY
94-
Change the temp write capacity of the DynamoDB table
95-
to restore to [defaults to 25, optional]
96-
--schemaOnly Backup or restore the schema only. Do not
97-
backup/restore data. Can be used with both backup and
98-
restore modes. Cannot be used with the --dataOnly
99-
[optional]
100-
--dataOnly Restore data only. Do not delete/recreate schema
101-
[optional for restore]
102-
--noConfirm Don't ask for confirmation before deleting existing
103-
schemas.
72+
Change the temp write capacity of the DynamoDB table to restore to [defaults to 25, optional]
73+
--schemaOnly Backup or restore the schema only. Do not backup/restore data. Can be used with both backup and restore modes. Cannot be used with the --dataOnly [optional]
74+
--dataOnly Restore data only. Do not delete/recreate schema [optional for restore]
75+
--noConfirm Don't ask for confirmation before deleting existing schemas.
10476
--skipThroughputUpdate
105-
Skip updating throughput values across tables
106-
[optional]
107-
--billingMode BILLING_MODE
108-
Set billing mode between PROVISIONED|PAY_PER_REQUEST
109-
(defaults to use 'PROVISIONED') [optional]
110-
--dumpPath DUMPPATH Directory to place and search for DynamoDB table
111-
backups (defaults to use 'dump') [optional]
112-
--log LOG Logging level - DEBUG|INFO|WARNING|ERROR|CRITICAL
113-
[optional]
77+
Skip updating throughput values across tables [optional]
78+
--dumpPath DUMPPATH Directory to place and search for DynamoDB table backups (defaults to use 'dump') [optional]
79+
--billingMode {PROVISIONED,PAY_PER_REQUEST}
80+
Set billing mode between PROVISIONED|PAY_PER_REQUEST (defaults to use 'PROVISIONED') [optional]
81+
--log LOG Logging level - DEBUG|INFO|WARNING|ERROR|CRITICAL [optional]
82+
--limit LIMIT Limit option for backup, will stop the back up process after number of backed up items reaches the limit [optional]
11483
-f FILTEROPTION, --filterOption FILTEROPTION
11584
Filter option for backup, JSON file of which keys are ['FilterExpression', 'ExpressionAttributeNames', 'ExpressionAttributeValues']
11685
```

0 commit comments

Comments
 (0)