DATASOURCE::NLB::LoadBalancers is used to query the basic information about created Network Load Balancer (NLB) instances.
Syntax
{
"Type": "DATASOURCE::NLB::LoadBalancers",
"Properties": {
"LoadBalancerNames": List,
"AddressIpVersion": String,
"LoadBalancerBussinessStatus": String,
"ZoneId": String,
"ResourceGroupId": String,
"VpcIds": List,
"LoadBalancerIds": List,
"AddressType": String,
"LoadBalancerStatus": String,
"Tags": List,
"Ipv6AddressType": String,
"RefreshOptions": String
}
}
Properties
Property | Type | Required | Editable | Description | Constraint |
LoadBalancerNames | List | No | Yes | The names of the NLB instances. | You can query up to 20 instances in a request. |
AddressIpVersion | String | No | Yes | The protocol version. | Valid values:
|
LoadBalancerBussinessStatus | String | No | Yes | The business status of the NLB instance. | Valid values:
|
ZoneId | String | No | Yes | The zone ID. | None. |
ResourceGroupId | String | No | Yes | The ID of the resource group. | None. |
VpcIds | List | No | Yes | The IDs of the virtual private clouds (VPCs) in which the NLB instances reside. | You can query up to 10 VPCs in a request. |
LoadBalancerIds | List | No | Yes | The IDs of the NLB instances. | You can query up to 20 instances in a request. |
AddressType | String | No | Yes | The type of the IPv4 address that is used by the NLB instance. | Valid values:
|
LoadBalancerStatus | String | No | Yes | The status of the NLB instance. | Valid values:
|
Tags | List | No | Yes | The tags of the NLB instance. | You can add up to 20 tags in a request. |
Ipv6AddressType | String | No | Yes | The type of the IPv6 address that is used by the NLB instance. | Valid values:
|
RefreshOptions | String | No | Yes | The refresh policy for data source resources when the stack is updated. | Valid values:
|
Tags syntax
"Tags": [
{
"Value": String,
"Key": String
}
]
Tags properties
Property | Type | Required | Editable | Description | Constraint |
Value | String | No | No | The tag value. | The tag value can be up to 128 characters in length and cannot contain |
Key | String | Yes | No | The tag key. | The tag key must be 1 to 128 characters in length and cannot contain |
Return values
Fn::GetAtt
LoadBalancerIds: the IDs of the NLB instances.
LoadBalancers: details of the NLB instances.
Property | Type | Description | Constraint |
LoadBalancerIds | List | The IDs of the NLB instances. | None. |
LoadBalancers | List | Details of the NLB instances. | None. |
LoadBalancerId | String | The ID of the NLB instance. | None. |
LoadBalancerName | String | The name of the NLB instance. | None. |
LoadBalancerType | String | The type of the Server Load Balancer (SLB) instance. | Only Network may be returned, which indicates that the instance is an NLB instance. |
AddressType | String | The type of the IPv4 address that is used by the NLB instance. | Valid values:
|
AddressIpVersion | String | The protocol version. | Valid values:
|
Ipv6AddressType | String | The type of the IPv6 address that is used by the NLB instance. | Valid values:
|
LoadBalancerStatus | String | The status of the NLB instance. | Valid values:
|
LoadBalancerBusinessStatus | String | The business status of the NLB instance. | Valid values:
|
VpcId | String | The ID of the VPC in which the NLB instance resides. | None. |
CreateTime | String | The time when the NLB instance was created. | The time follows the ISO 8601 standard in the yyyy-MM-ddTHH:mm:ssZ format. The time is displayed in UTC. |
ResourceGroupId | String | The ID of the resource group. | None. |
DNSName | String | The domain name. | None. |
BandwidthPackageId | String | The ID of the Internet Shared Bandwidth instance that is associated with the Internet-facing instance. | None. |
SecurityGroupIds | List | The security groups to which the NLB instance is added. | [ "sg-bp67acfmxazb4p****" ] |
CrossZoneEnabled | Boolean | Indicates whether cross-zone load balancing is enabled for the NLB instance. | Valid values:
|
Tags | List | The tags. | Example:
|
PayType | String | The billing method of the NLB instance. | Only PostPay may be returned, which indicates that the instance uses the pay-as-you-go billing method. |
Examples
ROSTemplateFormatVersion: '2015-09-01'
Parameters: {}
Resources:
ExtensionDataSource:
Type: DATASOURCE::NLB::LoadBalancers
Properties:
AddressIpVersion: ipv4
Outputs:
LoadBalancerIds:
Description: The list of load balancer IDs.
Value:
Fn::GetAtt:
- ExtensionDataSource
- LoadBalancerIds
LoadBalancers:
Description: The list of load balancers.
Value:
Fn::GetAtt:
- ExtensionDataSource
- LoadBalancers
{
"ROSTemplateFormatVersion": "2015-09-01",
"Parameters": {
},
"Resources": {
"ExtensionDataSource": {
"Type": "DATASOURCE::NLB::LoadBalancers",
"Properties": {
"AddressIpVersion": "ipv4"
}
}
},
"Outputs": {
"LoadBalancerIds": {
"Description": "The list of load balancer IDs.",
"Value": {
"Fn::GetAtt": [
"ExtensionDataSource",
"LoadBalancerIds"
]
}
},
"LoadBalancers": {
"Description": "The list of load balancers.",
"Value": {
"Fn::GetAtt": [
"ExtensionDataSource",
"LoadBalancers"
]
}
}
}
}