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: Adds ProvisionedThroughput to table schema #46

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

gHerzmann
Copy link

@gHerzmann gHerzmann commented Sep 13, 2021

Was receiving the following error when trying to create a table using billing_mode = "PROVISIONED":

ClientError: An error occurred (ValidationException) when calling the CreateTable operation: No provisioned throughput specified for the table

This is the code to reproduce the issue:

from falcano.attributes import UnicodeAttribute
from falcano.model import Model

class BaseModel(Model):
    class Meta(Model.Meta):
        table_name = "tablename"
        host = 'http://localhost:8000'
        read_capacity_units = 1
        write_capacity_units = 1
        billing_mode = "PROVISIONED"

    pk = UnicodeAttribute(hash_key=True)
    sk = UnicodeAttribute(range_key=True)

BaseModel.create_table(wait=True)

Although the ProvisionedThroughput key was being added to the index schema, it was not being added to the table schema.

Copy link
Contributor

@erictwalker18 erictwalker18 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

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.

2 participants