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

table autoscaling #37989

Draft
wants to merge 6 commits into
base: main
Choose a base branch
from
Draft
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
keyspaces table
  • Loading branch information
nikhil-goenka committed Jun 10, 2024
commit afaa3c6928d4512c2a259bc3b91a6e7da1cfe92b
26 changes: 25 additions & 1 deletion internal/service/keyspaces/table_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -292,7 +292,7 @@ func TestAccKeyspacesTable_update(t *testing.T) {
testAccCheckTableExists(ctx, resourceName, &v1),
acctest.CheckResourceAttrRegionalARN(resourceName, names.AttrARN, "cassandra", fmt.Sprintf("/keyspace/%s/table/%s", rName1, rName2)),
resource.TestCheckResourceAttr(resourceName, "capacity_specification.#", acctest.Ct1),
resource.TestCheckResourceAttr(resourceName, "capacity_specification.0.read_capacity_units", "200"),
resource.TestCheckResourceAttr(resourceName, "capacity_specification.0.read_capacity_units", "4000"),
resource.TestCheckResourceAttr(resourceName, "capacity_specification.0.throughput_mode", "PROVISIONED"),
resource.TestCheckResourceAttr(resourceName, "capacity_specification.0.write_capacity_units", "100"),
resource.TestCheckResourceAttr(resourceName, "comment.#", acctest.Ct1),
Expand Down Expand Up @@ -789,6 +789,18 @@ resource "aws_keyspaces_table" "test" {
}
}

auto_scaling_specification {
read_capacity_auto_scaling {
auto_scaling_disabled = false
minimum_units = 4000
scaling_policy {
target_tracking_scaling_policy_configuration {
target_value = 30
}
}
}
}

capacity_specification {
read_capacity_units = 200
throughput_mode = "PROVISIONED"
Expand Down Expand Up @@ -846,6 +858,18 @@ resource "aws_keyspaces_table" "test" {
throughput_mode = "PAY_PER_REQUEST"
}

auto_scaling_specification {
write_capacity_auto_scaling {
auto_scaling_disabled = false
minimum_units = 4000
scaling_policy {
target_tracking_scaling_policy_configuration {
target_value = 30
}
}
}
}

comment {
message = "TESTING"
}
Expand Down
Loading