Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: globalSecondaryIndex PAY_PER_REQUEST #266

Merged
merged 1 commit into from
Apr 24, 2024

Conversation

raizen-renatofilizzola
Copy link
Contributor

My source table has billing_mode PAY_PER_REQUEST and some global secondy indexes from this table too.
This change will fix the error below:

dynamodump -m restore -p profile -s sourceTable -d targetTable -r region --billingMode PAY_PER_REQUEST
About to delete table targetTable. Type 'yes' to continue: yes
INFO:botocore.tokens:Loading cached SSO token for profile
INFO:root:targetTable table deleted!
INFO:root:Starting restore for sourceTable to targetTable..
INFO:root:Creating targetTable table with temp write capacity of 25
ERROR:root:An error occurred (ValidationException) when calling the CreateTable operation: One or more parameter values were invalid: ProvisionedThroughput should not be specified for index: my-index when BillingMode is PAY_PER_REQUEST
Traceback (most recent call last):
  File "/home/renato-filizzola/.local/lib/python3.10/site-packages/dynamodump/dynamodump.py", line 960, in do_restore
    dynamo.create_table(
  File "/home/renato-filizzola/.local/lib/python3.10/site-packages/botocore/client.py", line 565, in _api_call
    return self._make_api_call(operation_name, kwargs)
  File "/home/renato-filizzola/.local/lib/python3.10/site-packages/botocore/client.py", line 1021, in _make_api_call
    raise error_class(parsed_response, operation_name)
botocore.exceptions.ClientError: An error occurred (ValidationException) when calling the CreateTable operation: One or more parameter values were invalid: ProvisionedThroughput should not be specified for index: my-index when BillingMode is PAY_PER_REQUEST

Copy link

sonarcloud bot commented Apr 15, 2024

Quality Gate Passed Quality Gate passed

Issues
0 New issues
0 Accepted issues

Measures
0 Security Hotspots
No data about Coverage
0.0% Duplication on New Code

See analysis details on SonarCloud

@bchew
Copy link
Owner

bchew commented Apr 24, 2024

Thanks @raizen-renatofilizzola!

@bchew bchew merged commit bd97684 into bchew:master Apr 24, 2024
21 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants