Skip to content

Commit e46ab99

Browse files
committed
fix CLB force new bug and document issues
1 parent 8b9dff9 commit e46ab99

8 files changed

+16
-9
lines changed

CHANGELOG.md

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,9 @@
11
## 1.45.3 (Unreleased)
2+
3+
BUG FIXES:
4+
* Resource: `tencentcloud_clb_instance` fix force new when updating tags.
5+
* Resource: `tencentcloud_redis_backup_config` fix doc issues.
6+
27
## 1.45.2 (October 19, 2020)
38

49
BUG FIXES:

tencentcloud/resource_tc_clb_instance.go

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -134,7 +134,6 @@ func resourceTencentCloudClbInstance() *schema.Resource {
134134
"tags": {
135135
Type: schema.TypeMap,
136136
Optional: true,
137-
ForceNew: true,
138137
Description: "The available tags within this CLB.",
139138
},
140139
},

tencentcloud/resource_tc_clb_instance_test.go

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -53,6 +53,7 @@ func TestAccTencentCloudClbInstance_open(t *testing.T) {
5353
resource.TestCheckResourceAttrSet("tencentcloud_clb_instance.clb_open", "security_groups.0"),
5454
resource.TestCheckResourceAttr("tencentcloud_clb_instance.clb_open", "target_region_info_region", "ap-guangzhou"),
5555
resource.TestCheckResourceAttrSet("tencentcloud_clb_instance.clb_open", "target_region_info_vpc_id"),
56+
resource.TestCheckResourceAttr("tencentcloud_clb_instance.clb_open", "tags.test", "tf"),
5657
),
5758
},
5859
{
@@ -67,6 +68,7 @@ func TestAccTencentCloudClbInstance_open(t *testing.T) {
6768
resource.TestCheckResourceAttrSet("tencentcloud_clb_instance.clb_open", "security_groups.0"),
6869
resource.TestCheckResourceAttr("tencentcloud_clb_instance.clb_open", "target_region_info_region", "ap-guangzhou"),
6970
resource.TestCheckResourceAttrSet("tencentcloud_clb_instance.clb_open", "target_region_info_vpc_id"),
71+
resource.TestCheckResourceAttr("tencentcloud_clb_instance.clb_open", "tags.test", "test"),
7072
),
7173
},
7274
},
@@ -102,6 +104,7 @@ func TestAccTencentCloudClbInstance_internal(t *testing.T) {
102104
resource.TestCheckResourceAttr("tencentcloud_clb_instance.clb_internal", "project_id", "0"),
103105
resource.TestCheckResourceAttrSet("tencentcloud_clb_instance.clb_internal", "vpc_id"),
104106
resource.TestCheckResourceAttrSet("tencentcloud_clb_instance.clb_internal", "subnet_id"),
107+
resource.TestCheckResourceAttr("tencentcloud_clb_instance.clb_internal", "tags.test", "test"),
105108
),
106109
},
107110
{
@@ -248,7 +251,7 @@ resource "tencentcloud_clb_instance" "clb_internal" {
248251
project_id = 0
249252
250253
tags = {
251-
test = "tf1"
254+
test = "test"
252255
}
253256
}
254257
`
@@ -273,7 +276,7 @@ resource "tencentcloud_clb_instance" "clb_open" {
273276
security_groups = [tencentcloud_security_group.foo.id]
274277
275278
tags = {
276-
test = "tf"
279+
test = "test"
277280
}
278281
}
279282
`

tencentcloud/resource_tc_redis_backup_config.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
Use this data source to query which instance types of Redis are available in a specific region.
2+
Use this resource to create a backup config of redis.
33
44
Example Usage
55

tencentcloud/resource_tc_redis_instance.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -79,7 +79,7 @@ func resourceTencentCloudRedisInstance() *schema.Resource {
7979
Optional: true,
8080
ForceNew: true,
8181
ValidateFunc: validateIntegerMin(2),
82-
Description: "Instance type. Refer to `data.tencentcloud_redis_zone_config.list.type_id` get available values.",
82+
Description: "Instance type. Refer to `data.tencentcloud_redis_zone_config.list.type_id` or ([document](https://intl.cloud.tencent.com/document/product/239/32069)) get available values.",
8383
},
8484
"redis_shard_num": {
8585
Type: schema.TypeInt,

website/docs/r/clb_instance.html.markdown

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -56,7 +56,7 @@ The following arguments are supported:
5656
* `project_id` - (Optional, ForceNew) Id of the project within the CLB instance, '0' - Default Project.
5757
* `security_groups` - (Optional) Security groups of the CLB instance. Only supports 'OPEN' CLBs.
5858
* `subnet_id` - (Optional, ForceNew) Subnet id of the CLB. Effective only for CLB within the VPC. Only supports 'INTERNAL' CLBs.
59-
* `tags` - (Optional, ForceNew) The available tags within this CLB.
59+
* `tags` - (Optional) The available tags within this CLB.
6060
* `target_region_info_region` - (Optional) Region information of backend services are attached the CLB instance. Only supports 'OPEN' CLBs.
6161
* `target_region_info_vpc_id` - (Optional) Vpc information of backend services are attached the CLB instance. Only supports 'OPEN' CLBs.
6262
* `vpc_id` - (Optional, ForceNew) VPC id of the CLB.

website/docs/r/redis_backup_config.html.markdown

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,12 +4,12 @@ layout: "tencentcloud"
44
page_title: "TencentCloud: tencentcloud_redis_backup_config"
55
sidebar_current: "docs-tencentcloud-resource-redis_backup_config"
66
description: |-
7-
Use this data source to query which instance types of Redis are available in a specific region.
7+
Use this resource to create a backup config of redis.
88
---
99

1010
# tencentcloud_redis_backup_config
1111

12-
Use this data source to query which instance types of Redis are available in a specific region.
12+
Use this resource to create a backup config of redis.
1313

1414
## Example Usage
1515

website/docs/r/redis_instance.html.markdown

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -47,7 +47,7 @@ The following arguments are supported:
4747
* `security_groups` - (Optional, ForceNew) ID of security group. If both vpc_id and subnet_id are not set, this argument should not be set either.
4848
* `subnet_id` - (Optional, ForceNew) Specifies which subnet the instance should belong to.
4949
* `tags` - (Optional) Instance tags.
50-
* `type_id` - (Optional, ForceNew) Instance type. Refer to `data.tencentcloud_redis_zone_config.list.type_id` get available values.
50+
* `type_id` - (Optional, ForceNew) Instance type. Refer to `data.tencentcloud_redis_zone_config.list.type_id` or ([document](https://intl.cloud.tencent.com/document/product/239/32069)) get available values.
5151
* `type` - (Optional, ForceNew, **Deprecated**) It has been deprecated from version 1.33.1. Please use 'type_id' instead. Instance type. Available values: `cluster_ckv`,`cluster_redis5.0`,`cluster_redis`,`master_slave_ckv`,`master_slave_redis5.0`,`master_slave_redis`,`standalone_redis`, specific region support specific types, need to refer data `tencentcloud_redis_zone_config`.
5252
* `vpc_id` - (Optional, ForceNew) ID of the vpc with which the instance is to be associated.
5353

0 commit comments

Comments
 (0)