» alicloud_sag_qos_policy

Provides a Sag qos policy resource. You need to create a QoS policy to set priorities, rate limits, and quintuple rules for different messages.

For information about Sag Qos Policy and how to use it, see What is Qos Policy.

» Example Usage

Basic Usage

resource "alicloud_sag_qos" "default" {
  name        = "tf-testAccSagQosName"
resource "alicloud_sag_qos_policy" "default" {
  qos_id =       "${alicloud_sag_qos.default.id}"
  name =       "tf-testSagQosPolicyName"
  description =     "tf-testSagQosPolicyDescription"
  priority =         "1"
  ip_protocol =      "ALL"
  source_cidr =      ""
  source_port_range =    "-1/-1"
  dest_cidr =       ""
  dest_port_range = "-1/-1"
  start_time =      "2019-10-25T16:41:33+0800"
  end_time =        "2019-10-26T16:41:33+0800"

» Argument Reference

The following arguments are supported:

  • qos_id - (Required) The instance ID of the QoS policy to which the quintuple rule is created.
  • name - (Optional) The name of the QoS policy.
  • description - (Optional) The description of the QoS policy.
  • priority - (Required) The priority of the quintuple rule. A smaller value indicates a higher priority. If the priorities of two quintuple rules are the same, the rule created earlier is applied first.Value range: 1 to 7.
  • ip_protocol - (Required) The transport layer protocol.
  • source_cidr - (Required) The source CIDR block.
  • source_port_range - (Required) The source port range of the transport layer.
  • dest_cidr - (Required) The destination CIDR block.
  • dest_port_range - (Required) The destination port range.
  • start_time - (Optional) The time when the quintuple rule takes effect.
  • end_time - (Optional) The expiration time of the quintuple rule.

» Attributes Reference

The following attributes are exported:

  • id - The ID of the Qos Policy id and formates as <qos_id>:<qos_policy_id>.

» Import

The Sag Qos Policy can be imported using the id, e.g.

$ terraform import alicloud_sag_qos_policy.example qos-abc123456:qospy-abc123456