ALIYUN::KAFKA::Instance is used to create a Message Queue for Apache Kafka instance.
Syntax
{
"Type": "ALIYUN::KAFKA::Instance",
"Properties": {
"DeployType": Integer,
"DiskType": String,
"DeployOption": Map,
"EipMax": Integer,
"SpecType": String,
"IoMax": Integer,
"IoMaxSpec": String,
"DiskSize": Integer,
"TopicQuota": Integer,
"PayType": String,
"Tags": List,
"DeletionForce": Boolean,
"OpenConnector": Boolean
}
}
Properties
Property | Type | Required | Editable | Description | Constraint |
---|---|---|---|---|---|
DeployType | Integer | Yes | No | The network in which you deploy the instance. | Valid values:
|
DiskType | String | Yes | No | The category of the disk. | Valid values:
|
DeployOption | Map | No | No | The details of deployment options. | For more information, see DeployOption properties. |
EipMax | Integer | No | No | The Internet traffic. | This property is required when you set the DeployType property to 4. Valid values: 1 to 160. |
SpecType | String | No | Yes | The edition of the instance. | Valid values:
|
IoMax | Integer | No | Yes | The peak traffic. | You must specify the IoMax or IoMaxSpec property. If you specify both the properties, the value of the IoMaxSpec property takes precedence over the value of the IoMax property. We recommend that you specify only the IoMaxSpec property. For more information about the valid values, see Billing. |
IoMaxSpec | String | No | Yes | The traffic specification. | You must specify the IoMax or IoMaxSpec property. If you specify both the properties, the value of the IoMaxSpec property takes precedence over the value of the IoMax property. We recommend that you specify only the IoMaxSpec property. For more information about the valid values, see Billing. |
DiskSize | Integer | Yes | Yes | The size of the disk. | Valid values: 500 to 96000. Unit: GB. |
TopicQuota | Integer | Yes | Yes | The number of topics. | Valid values: 50 to 79. |
PayType | String | No | No | The billing cycle of the instance. | Valid values:
|
Tags | List | No | Yes | The tags of the instance. | You can add up to 20 tags. For more information, see Tags properties. |
DeletionForce | Boolean | No | Yes | Specifies whether to force delete the instance. | Default value: false. Valid values:
|
OpenConnector | Boolean | No | No | Specifies whether to enable the connector. | Default value: false. Valid values:
Note For more information about connectors, see Overview. |
Tags syntax
"Tags": [
{
"Key": String,
"Value": String
}
]
Tags properties
Property | Type | Required | Editable | Description | Constraint |
---|---|---|---|---|---|
Key | String | Yes | No | The key of the tag. | The tag key must be 1 to 128 characters in length, and cannot contain http:// or https:// . The tag key cannot start with aliyun or acs: . |
Value | String | No | No | The value of the tag. | The tag value must be 0 to 128 characters in length, and cannot contain http:// or https:// . The tag value cannot start with aliyun or acs: . |
DeployOption syntax
"DeployOption": {
"IsEipInner": Boolean,
"VpcId": String,
"ZoneId": String,
"VSwitchId": String,
"SecurityGroup": String,
"DeployModule": String,
"Name": String,
"IsSetUserAndPassword": Boolean,
"Username": String,
"Password": String,
"ServiceVersion": String,
"Config": Map
}
DeployOption properties
Property | Type | Required | Editable | Description | Constraint |
---|---|---|---|---|---|
IsEipInner | Boolean | No | No | Specifies whether the instance supports elastic IP addresses (EIPs). | Default value: false. Valid values:
You must specify the value of this property based on the instance type. If you use an Internet- and VPC-connected instance, set the IsEipInner property to true. If you use a VPC-connected instance, set the IsEipInner property to false. |
DeployModule | String | Yes | No | The deployment mode. | Valid values:
|
VpcId | String | No | No | The ID of the VPC in which you deploy the instance. | None. |
ZoneId | String | No | No | The ID of the zone in which you deploy the instance. | None. |
VSwitchId | String | Yes | No | The ID of the vSwitch in which you deploy the instance. | None. |
SecurityGroup | String | No | No | The security group of the instance. | If you do not specify this property, Message Queue for Apache Kafka automatically configures a security group for the instance. |
Name | String | No | No | The name of the instance. | None. |
IsSetUserAndPassword | Boolean | No | No | Specifies whether to configure a new username and password. | Only Internet- and VPC-connected instances are supported. Default value: false. Valid values:
|
Username | String | No | No | The username. | Only Internet- and VPC-connected instances are supported. The username must be 8 to 40 characters in length, and can contain letters and digits. |
Password | String | No | No | The password. | Only Internet- and VPC-connected instances are supported. The password must be 8 to 40 characters in length, and must contain lowercase letters, uppercase letters, and digits. |
ServiceVersion | String | No | No | The version of the Message Queue for Apache Kafka service that you deploy. | Valid values:
|
Config | Map | No | No | The initial configurations of the Message Queue for Apache Kafka service that you deploy. | The value must be a valid JSON string. Valid values:
|
Return values
Fn::GetAtt
- InstanceId: the ID of the instance.
- OrderId: the ID of the order.
- name: the name of the instance.
Examples
JSON
format{ "ROSTemplateFormatVersion": "2015-09-01", "Parameters": { "VpcId": { "Type": "String", "AssociationProperty": "ALIYUN::ECS::VPC::VPCId" }, "ZoneId": { "Type": "String", "AssociationProperty": "ALIYUN::ECS::ZoneId" }, "VSwitchId": { "Type": "String", "AssociationProperty": "ALIYUN::ECS::VSwitch::VSwitchId", "AssociationPropertyMetadata": { "VpcId": "${VpcId}", "ZoneId": "${ZoneId}" } }, "SecurityGroupId": { "Type": "String", "AssociationProperty": "ALIYUN::ECS::SecurityGroup::SecurityGroupId", "AssociationPropertyMetadata": { "VpcId": "${VpcId}" } } }, "Resources": { "Instance": { "Type": "ALIYUN::KAFKA::Instance", "Properties": { "DeployType": 5, "SpecType": "normal", "PayType": "Hour", "DiskType": "1", "DeployOption": { "VpcId": { "Ref": "VpcId" }, "ZoneId": { "Ref": "ZoneId" }, "VSwitchId": { "Ref": "VSwitchId" }, "SecurityGroup": { "Ref": "SecurityGroupId" }, "DeployModule": "vpc", "ServiceVersion": "0.10.2", "Config": { "kafka.log.retention.hours": "33" } }, "DeletionForce": "false", "DiskSize": 500, "TopicQuota": 50, "OpenConnector": "false", "IoMaxSpec": "alikafka.hw.2xlarge" } } }, "Outputs": { "InstanceId": { "Description": "Id of the instance. ", "Value": { "Fn::GetAtt": [ "Instance", "InstanceId" ] } }, "OrderId": { "Description": "Id of the order. ", "Value": { "Fn::GetAtt": [ "Instance", "OrderId" ] } }, "Name": { "Description": "Name of the instance.", "Value": { "Fn::GetAtt": [ "Instance", "Name" ] } } } }
To view more examples, visit Instance.json and Instance.yml. In the examples, the ALIYUN::KAFKA::Instance and ALIYUN::KAFKA::Topic resource types are used.