Skip to content

Resource: awsRedshiftserverlessUsageLimit

Creates a new Amazon Redshift Serverless Usage Limit.

Example Usage

/*Provider bindings are generated by running cdktf get.
See https://cdk.tf/provider-generation for more details.*/
import * as aws from "./.gen/providers/aws";
const awsRedshiftserverlessWorkgroupExample =
  new aws.redshiftserverlessWorkgroup.RedshiftserverlessWorkgroup(
    this,
    "example",
    {
      namespaceName:
        "${aws_redshiftserverless_namespace.example.namespace_name}",
      workgroupName: "example",
    }
  );
const awsRedshiftserverlessUsageLimitExample =
  new aws.redshiftserverlessUsageLimit.RedshiftserverlessUsageLimit(
    this,
    "example_1",
    {
      amount: 60,
      resourceArn: awsRedshiftserverlessWorkgroupExample.arn,
      usageType: "serverless-compute",
    }
  );
/*This allows the Terraform resource name to match the original name. You can remove the call if you don't need them to match.*/
awsRedshiftserverlessUsageLimitExample.overrideLogicalId("example");

Argument Reference

The following arguments are supported:

  • amount - (Required) The limit amount. If time-based, this amount is in Redshift Processing Units (RPU) consumed per hour. If data-based, this amount is in terabytes (TB) of data transferred between Regions in cross-account sharing. The value must be a positive number.
  • breachAction - (Optional) The action that Amazon Redshift Serverless takes when the limit is reached. Valid values are log, emitMetric, and deactivate. The default is log.
  • period - (Optional) The time period that the amount applies to. A weekly period begins on Sunday. Valid values are daily, weekly, and monthly. The default is monthly.
  • resourceArn - (Required) The Amazon Resource Name (ARN) of the Amazon Redshift Serverless resource to create the usage limit for.
  • usageType - (Required) The type of Amazon Redshift Serverless usage to create a usage limit for. Valid values are serverlessCompute or crossRegionDatasharing.

Attributes Reference

In addition to all arguments above, the following attributes are exported:

  • arn - Amazon Resource Name (ARN) of the Redshift Serverless Usage Limit.
  • id - The Redshift Usage Limit id.

Import

Redshift Serverless Usage Limits can be imported using the id, e.g.,

$ terraform import aws_redshiftserverless_usage_limit.example example-id