Skip to content

Commit

Permalink
fix: skip fail operation capture while add same region replica (#1374)
Browse files Browse the repository at this point in the history
* fix: skip fail operation capture while add same region replica

* changelog 1374
  • Loading branch information
Kagashino authored Nov 9, 2022
1 parent dfd1cb2 commit cfcad97
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 0 deletions.
3 changes: 3 additions & 0 deletions .changelog/1374.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
```release-note:enhancement
resource/tencentcloud_tcr_instance: fix: skip fail operation capture while add same region replica
```
4 changes: 4 additions & 0 deletions tencentcloud/resource_tc_tcr_instance.go
Original file line number Diff line number Diff line change
Expand Up @@ -770,6 +770,10 @@ func resourceTencentCloudTcrReplicationSet(ctx context.Context, d *schema.Resour
if ok {
code := sdkErr.GetCode()
message := sdkErr.GetMessage()
// Skip fail operation capture while add same region replica
if code == tcr.FAILEDOPERATION {
return resource.NonRetryableError(sdkErr)
}
if code == tcr.INTERNALERROR_ERRORCONFLICT {
return resource.RetryableError(err)
}
Expand Down

0 comments on commit cfcad97

Please sign in to comment.