Skip to content

Commit 9b7af99

Browse files
authored
feat(loadbalancer): add support for in-place updates (#1373)
relates to STACKITTPR-605 and #1326
1 parent c7fabc1 commit 9b7af99

File tree

7 files changed

+629
-187
lines changed

7 files changed

+629
-187
lines changed

docs/data-sources/loadbalancer.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -43,6 +43,7 @@ data "stackit_loadbalancer" "example" {
4343
- `private_address` (String) Transient private Load Balancer IP address. It can change any time.
4444
- `security_group_id` (String) The ID of the egress security group assigned to the Load Balancer's internal machines. This ID is essential for allowing traffic from the Load Balancer to targets in different networks or STACKIT Network areas (SNA). To enable this, create a security group rule for your target VMs and set the `remote_security_group_id` of that rule to this value. This is typically used when `disable_security_group_assignment` is set to `true`.
4545
- `target_pools` (Attributes List) List of all target pools which will be used in the Load Balancer. Limited to 20. (see [below for nested schema](#nestedatt--target_pools))
46+
- `version` (String) Load balancer resource version.
4647

4748
<a id="nestedatt--listeners"></a>
4849
### Nested Schema for `listeners`

docs/resources/loadbalancer.md

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -247,6 +247,7 @@ import {
247247
- `id` (String) Terraform's internal resource ID. It is structured as "`project_id`","region","`name`".
248248
- `private_address` (String) Transient private Load Balancer IP address. It can change any time.
249249
- `security_group_id` (String) The ID of the egress security group assigned to the Load Balancer's internal machines. This ID is essential for allowing traffic from the Load Balancer to targets in different networks or STACKIT network areas (SNA). To enable this, create a security group rule for your target VMs and set the `remote_security_group_id` of that rule to this value. This is typically used when `disable_security_group_assignment` is set to `true`.
250+
- `version` (String) Load balancer resource version. This is needed to have concurrency safe updates.
250251

251252
<a id="nestedatt--listeners"></a>
252253
### Nested Schema for `listeners`
@@ -365,7 +366,7 @@ Optional:
365366
Optional:
366367

367368
- `credentials_ref` (String) Credentials reference for logs. Not changeable after creation.
368-
- `push_url` (String) Credentials reference for logs. Not changeable after creation.
369+
- `push_url` (String) The ARGUS/Loki remote write Push URL to ship the logs to. Not changeable after creation.
369370

370371

371372
<a id="nestedatt--options--observability--metrics"></a>
@@ -374,4 +375,4 @@ Optional:
374375
Optional:
375376

376377
- `credentials_ref` (String) Credentials reference for metrics. Not changeable after creation.
377-
- `push_url` (String) Credentials reference for metrics. Not changeable after creation.
378+
- `push_url` (String) The ARGUS/Prometheus remote write Push URL to ship the metrics to. Not changeable after creation.

stackit/internal/services/loadbalancer/loadbalancer/datasource.go

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -112,6 +112,7 @@ func (r *loadBalancerDataSource) Schema(_ context.Context, _ datasource.SchemaRe
112112
"tcp_options_idle_timeout": "Time after which an idle connection is closed. The default value is set to 5 minutes, and the maximum value is one hour.",
113113
"udp_options": "Options that are specific to the UDP protocol.",
114114
"udp_options_idle_timeout": "Time after which an idle session is closed. The default value is set to 1 minute, and the maximum value is 2 minutes.",
115+
"version": "Load balancer resource version.",
115116
}
116117

117118
resp.Schema = schema.Schema{
@@ -375,6 +376,10 @@ func (r *loadBalancerDataSource) Schema(_ context.Context, _ datasource.SchemaRe
375376
Description: descriptions["security_group_id"],
376377
Computed: true,
377378
},
379+
"version": schema.StringAttribute{
380+
Description: descriptions["version"],
381+
Computed: true,
382+
},
378383
},
379384
}
380385
}

0 commit comments

Comments
 (0)