From cfc46163943f5f981d7a6e4d30a5a7268a8c654e Mon Sep 17 00:00:00 2001 From: arunma Date: Tue, 14 May 2024 14:27:09 +0800 Subject: [PATCH 1/2] fix(rds): [] support mem_size 512 --- tencentcloud/services/crs/resource_tc_redis_instance.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tencentcloud/services/crs/resource_tc_redis_instance.go b/tencentcloud/services/crs/resource_tc_redis_instance.go index 6b6bd7e3d8..567a7c6ac4 100644 --- a/tencentcloud/services/crs/resource_tc_redis_instance.go +++ b/tencentcloud/services/crs/resource_tc_redis_instance.go @@ -118,7 +118,7 @@ func ResourceTencentCloudRedisInstance() *schema.Resource { "mem_size": { Type: schema.TypeInt, Required: true, - ValidateFunc: tccommon.ValidateAllowedIntValue([]int{256, 1024, 2048, 4096, 8192, 12288, 16384, 20480, 24576, 32768, 40960, 49152, 65536}), + ValidateFunc: tccommon.ValidateAllowedIntValue([]int{256, 512, 1024, 2048, 4096, 8192, 12288, 16384, 20480, 24576, 32768, 40960, 49152, 65536}), Description: "The memory volume of an available instance(in MB), please refer to `tencentcloud_redis_zone_config.list[zone].shard_memories`. When redis is standard type, it represents total memory size of the instance; when Redis is cluster type, it represents memory size of per sharding.", }, "vpc_id": { From bea49031f978d4326c6fa65224b9e546f400c4cc Mon Sep 17 00:00:00 2001 From: arunma Date: Tue, 14 May 2024 14:55:16 +0800 Subject: [PATCH 2/2] fix: modify doc --- tencentcloud/services/crs/resource_tc_redis_instance.go | 2 +- website/docs/r/redis_instance.html.markdown | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/tencentcloud/services/crs/resource_tc_redis_instance.go b/tencentcloud/services/crs/resource_tc_redis_instance.go index 567a7c6ac4..dac712dae4 100644 --- a/tencentcloud/services/crs/resource_tc_redis_instance.go +++ b/tencentcloud/services/crs/resource_tc_redis_instance.go @@ -119,7 +119,7 @@ func ResourceTencentCloudRedisInstance() *schema.Resource { Type: schema.TypeInt, Required: true, ValidateFunc: tccommon.ValidateAllowedIntValue([]int{256, 512, 1024, 2048, 4096, 8192, 12288, 16384, 20480, 24576, 32768, 40960, 49152, 65536}), - Description: "The memory volume of an available instance(in MB), please refer to `tencentcloud_redis_zone_config.list[zone].shard_memories`. When redis is standard type, it represents total memory size of the instance; when Redis is cluster type, it represents memory size of per sharding.", + Description: "The memory volume of an available instance(in MB), please refer to `tencentcloud_redis_zone_config.list[zone].shard_memories`. When redis is standard type, it represents total memory size of the instance; when Redis is cluster type, it represents memory size of per sharding. `512MB` is supported only in master-slave instance.", }, "vpc_id": { Type: schema.TypeString, diff --git a/website/docs/r/redis_instance.html.markdown b/website/docs/r/redis_instance.html.markdown index d5efd6746a..92bb0fd037 100644 --- a/website/docs/r/redis_instance.html.markdown +++ b/website/docs/r/redis_instance.html.markdown @@ -239,7 +239,7 @@ resource "tencentcloud_redis_instance" "foo" { The following arguments are supported: * `availability_zone` - (Required, String, ForceNew) The available zone ID of an instance to be created, please refer to `tencentcloud_redis_zone_config.list`. -* `mem_size` - (Required, Int) The memory volume of an available instance(in MB), please refer to `tencentcloud_redis_zone_config.list[zone].shard_memories`. When redis is standard type, it represents total memory size of the instance; when Redis is cluster type, it represents memory size of per sharding. +* `mem_size` - (Required, Int) The memory volume of an available instance(in MB), please refer to `tencentcloud_redis_zone_config.list[zone].shard_memories`. When redis is standard type, it represents total memory size of the instance; when Redis is cluster type, it represents memory size of per sharding. `512MB` is supported only in master-slave instance. * `auto_renew_flag` - (Optional, Int, ForceNew) Auto-renew flag. 0 - default state (manual renewal); 1 - automatic renewal; 2 - explicit no automatic renewal. * `charge_type` - (Optional, String, ForceNew) The charge type of instance. Valid values: `PREPAID` and `POSTPAID`. Default value is `POSTPAID`. Note: TencentCloud International only supports `POSTPAID`. Caution that update operation on this field will delete old instances and create new with new charge type. * `force_delete` - (Optional, Bool) Indicate whether to delete Redis instance directly or not. Default is false. If set true, the instance will be deleted instead of staying recycle bin. Note: only works for `PREPAID` instance.