Skip to content

tencentcloud_clb_listener support HTTP health check for TCP listener #551

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 5 commits into from
Nov 20, 2020

Conversation

ttomzhou
Copy link
Contributor

resource

make testacc TESTARGS="-run TestAccTencentCloudClbListenerTCPWith*"  
==> Checking that code complies with gofmt requirements...
TF_ACC=1 go test ./... -v -run TestAccTencentCloudClbListenerTCPWith* -timeout 120m
?       github.com/tencentcloudstack/terraform-provider-tencentcloud    [no test files]
testing: warning: no tests to run
PASS
ok      github.com/tencentcloudstack/terraform-provider-tencentcloud/gendoc     (cached) [no tests to run]
=== RUN   TestAccTencentCloudClbListenerTCPWithTCP
--- PASS: TestAccTencentCloudClbListenerTCPWithTCP (29.39s)
=== RUN   TestAccTencentCloudClbListenerTCPWithHTTP
--- PASS: TestAccTencentCloudClbListenerTCPWithHTTP (33.08s)
=== RUN   TestAccTencentCloudClbListenerTCPWithCustomer
--- PASS: TestAccTencentCloudClbListenerTCPWithCustomer (39.01s)
PASS
ok      github.com/tencentcloudstack/terraform-provider-tencentcloud/tencentcloud       103.685s
?       github.com/tencentcloudstack/terraform-provider-tencentcloud/tencentcloud/connectivity  [no test files]
?       github.com/tencentcloudstack/terraform-provider-tencentcloud/tencentcloud/internal/helper       [no test files]
?       github.com/tencentcloudstack/terraform-provider-tencentcloud/tencentcloud/ratelimit     [no test files]

datasource

make testacc TESTARGS="-run TestAccTencentCloudClbListenersDataSource"
==> Checking that code complies with gofmt requirements...
TF_ACC=1 go test ./... -v -run TestAccTencentCloudClbListenersDataSource -timeout 120m
?       github.com/tencentcloudstack/terraform-provider-tencentcloud    [no test files]
testing: warning: no tests to run
PASS
ok      github.com/tencentcloudstack/terraform-provider-tencentcloud/gendoc     (cached) [no tests to run]
=== RUN   TestAccTencentCloudClbListenersDataSource
=== PAUSE TestAccTencentCloudClbListenersDataSource
=== CONT  TestAccTencentCloudClbListenersDataSource
--- PASS: TestAccTencentCloudClbListenersDataSource (35.79s)
PASS
ok      github.com/tencentcloudstack/terraform-provider-tencentcloud/tencentcloud       37.703s
?       github.com/tencentcloudstack/terraform-provider-tencentcloud/tencentcloud/connectivity  [no test files]
?       github.com/tencentcloudstack/terraform-provider-tencentcloud/tencentcloud/internal/helper       [no test files]
?       github.com/tencentcloudstack/terraform-provider-tencentcloud/tencentcloud/ratelimit     [no test files]

@@ -223,6 +273,16 @@ func dataSourceTencentCloudClbListenersRead(d *schema.ResourceData, meta interfa
mapping["health_check_interval_time"] = *listener.HealthCheck.IntervalTime
mapping["health_check_health_num"] = *listener.HealthCheck.HealthNum
mapping["health_check_unhealth_num"] = *listener.HealthCheck.UnHealthNum
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

这里可以一起把之前的写法也改了

"health_check_port": {
Type: schema.TypeInt,
Optional: true,
ValidateFunc: validateIntegerInRange(1, 65535),
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

看一下旧版本生成的tf资源,在新版本下apply会不会报错

@gailwang gailwang merged commit 8b47ee7 into tencentcloudstack:master Nov 20, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants