Skip to content

Commit 99b7d0e

Browse files
authored
Merge branch 'GoogleCloudPlatform:main' into new-branch
2 parents 835b5aa + 3a77e6c commit 99b7d0e

File tree

7 files changed

+44
-99
lines changed

7 files changed

+44
-99
lines changed

docs/content/breaking-changes/make-a-breaking-change.md

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
---
2-
majorVersion: "6.0.0"
3-
upgradeGuide: "version_6_upgrade.html.markdown"
2+
majorVersion: "7.0.0"
3+
upgradeGuide: "version_7_upgrade.html.markdown"
44
title: "Make a breaking change"
55
summary: "Guidance on making a breaking changes"
66
weight: 20
@@ -65,7 +65,7 @@ The general process for contributing a breaking change to the
6565

6666
1. Make the `main` branch forwards-compatible with the major release
6767
2. Add deprecations and warnings to the `main` branch of `magic-modules`
68-
3. Add upgrade guide entries to the `FEATURE-BRANCH-major-release-6.0.0` branch of `magic-modules`
68+
3. Add upgrade guide entries to the `FEATURE-BRANCH-major-release-7.0.0` branch of `magic-modules`
6969
4. Make the breaking change on `FEATURE-BRANCH-major-release-{{% param "majorVersion" %}}`
7070

7171
These are covered in more detail in the following sections. The upgrade guide
@@ -200,7 +200,7 @@ with the following changes:
200200
1. Add the upgrade guide entries to
201201
[{{< param upgradeGuide >}}](https://github.com/GoogleCloudPlatform/magic-modules/blob/FEATURE-BRANCH-major-release-6.0.0/mmv1/third_party/terraform/website/docs/guides/{{< param upgradeGuide >}}). Entries should focus on the changes that users need to make when upgrading
202202
to `{{% param "majorVersion" %}}`, rather than how to write configurations
203-
after upgrading. See [Terraform provider for Google Cloud 5.0.0 Upgrade Guide](https://registry.terraform.io/providers/hashicorp/google/latest/docs/guides/version_5_upgrade)
203+
after upgrading. See [Terraform provider for Google Cloud 6.0.0 Upgrade Guide](https://registry.terraform.io/providers/hashicorp/google/latest/docs/guides/version_6_upgrade)
204204
and other upgrade guides for examples.
205205
1. Remove any deprecation notices and warnings (including in documentation) not already removed by the breaking change.
206206
1. When you create your pull request,

mmv1/products/secretmanager/Secret.yaml

Lines changed: 0 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -250,11 +250,3 @@ properties:
250250
description: |
251251
The Duration between rotation notifications. Must be in seconds and at least 3600s (1h) and at most 3153600000s (100 years).
252252
If rotationPeriod is set, `next_rotation_time` must be set. `next_rotation_time` will be advanced by this period when the service automatically sends rotation notifications.
253-
- name: 'tags'
254-
type: KeyValuePairs
255-
description: |
256-
A map of resource manager tags.
257-
Resource manager tag keys and values have the same definition as resource manager tags.
258-
Keys must be in the format tagKeys/{tag_key_id}, and values are in the format tagValues/{tag_key_value}.
259-
immutable: true
260-
ignore_read: true

mmv1/third_party/terraform/services/container/node_config.go.tmpl

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -875,12 +875,14 @@ func schemaNodeConfig() *schema.Schema {
875875
ForceNew: true,
876876
Description: `The runtime of each node in the node pool in seconds, terminated by 's'. Example: "3600s".`,
877877
},
878+
{{ if ne $.TargetVersionName `ga` -}}
878879
"flex_start" : {
879880
Type: schema.TypeBool,
880881
Optional: true,
881882
ForceNew: true,
882883
Description: `Enables Flex Start provisioning model for the node pool`,
883884
},
885+
{{- end }}
884886
},
885887
},
886888
}
@@ -1276,9 +1278,11 @@ func expandNodeConfig(v interface{}) *container.NodeConfig {
12761278
nc.MaxRunDuration = v.(string)
12771279
}
12781280

1281+
{{ if ne $.TargetVersionName `ga` -}}
12791282
if v,ok := nodeConfig["flex_start"]; ok {
12801283
nc.FlexStart = v.(bool)
12811284
}
1285+
{{- end }}
12821286

12831287
{{ if ne $.TargetVersionName `ga` -}}
12841288
if v, ok := nodeConfig["host_maintenance_policy"]; ok {
@@ -1711,7 +1715,9 @@ func flattenNodeConfig(c *container.NodeConfig, v interface{}) []map[string]inte
17111715
"node_group": c.NodeGroup,
17121716
"advanced_machine_features": flattenAdvancedMachineFeaturesConfig(c.AdvancedMachineFeatures),
17131717
"max_run_duration": c.MaxRunDuration,
1718+
{{- if ne $.TargetVersionName "ga" }}
17141719
"flex_start": c.FlexStart,
1720+
{{- end }}
17151721
"sole_tenant_config": flattenSoleTenantConfig(c.SoleTenantConfig),
17161722
"fast_socket": flattenFastSocket(c.FastSocket),
17171723
"resource_manager_tags": flattenResourceManagerTags(c.ResourceManagerTags),

mmv1/third_party/terraform/services/container/resource_container_cluster_test.go.tmpl

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -503,7 +503,7 @@ func TestAccContainerCluster_withMaxRunDuration(t *testing.T) {
503503
})
504504
}
505505

506-
506+
{{ if ne $.TargetVersionName `ga` -}}
507507
func TestAccContainerCluster_withFlexStart(t *testing.T) {
508508
t.Parallel()
509509

@@ -535,6 +535,7 @@ func TestAccContainerCluster_withFlexStart(t *testing.T) {
535535
},
536536
})
537537
}
538+
{{- end }}
538539

539540
func TestAccContainerCluster_withILBSubsetting(t *testing.T) {
540541
t.Parallel()
@@ -7154,6 +7155,7 @@ resource "google_container_cluster" "max_run_duration" {
71547155
`, clusterName, npName, duration, networkName, subnetworkName)
71557156
}
71567157

7158+
{{ if ne $.TargetVersionName `ga` -}}
71577159
func testAccContainerCluster_withFlexStart(clusterName, npName, networkName, subnetworkName string) string {
71587160
return fmt.Sprintf(`
71597161
resource "google_container_cluster" "flex_start" {
@@ -7199,6 +7201,7 @@ resource "google_container_cluster" "flex_start" {
71997201
}
72007202
`, clusterName, npName, networkName, subnetworkName)
72017203
}
7204+
{{- end }}
72027205

72037206
func testAccContainerCluster_withILBSubSetting(clusterName, npName, networkName, subnetworkName string) string {
72047207
return fmt.Sprintf(`

mmv1/third_party/terraform/services/container/resource_container_node_pool_test.go.tmpl

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4545,6 +4545,7 @@ resource "google_container_node_pool" "np" {
45454545
`, clusterName, networkName, subnetworkName, np)
45464546
}
45474547

4548+
{{ if ne $.TargetVersionName `ga` -}}
45484549
func TestAccContainerNodePool_withFlexStart(t *testing.T) {
45494550
t.Parallel()
45504551

@@ -4618,6 +4619,7 @@ resource "google_container_node_pool" "np" {
46184619
}
46194620
`, clusterName, networkName, subnetworkName, np)
46204621
}
4622+
{{- end }}
46214623

46224624
func TestAccContainerNodePool_tpuTopology(t *testing.T) {
46234625
t.Parallel()

mmv1/third_party/terraform/services/secretmanager/resource_secret_manager_secret_test.go.tmpl

Lines changed: 27 additions & 85 deletions
Original file line numberDiff line numberDiff line change
@@ -25,9 +25,9 @@ func TestAccSecretManagerSecret_import(t *testing.T) {
2525
Config: testAccSecretManagerSecret_basic(context),
2626
},
2727
{
28-
ResourceName: "google_secret_manager_secret.secret-basic",
29-
ImportState: true,
30-
ImportStateVerify: true,
28+
ResourceName: "google_secret_manager_secret.secret-basic",
29+
ImportState: true,
30+
ImportStateVerify: true,
3131
ImportStateVerifyIgnore: []string{"ttl", "labels", "terraform_labels"},
3232
},
3333
},
@@ -54,9 +54,9 @@ func TestAccSecretManagerSecret_cmek(t *testing.T) {
5454
Config: testAccSecretMangerSecret_cmek(context1),
5555
},
5656
{
57-
ResourceName: "google_secret_manager_secret.secret-basic",
58-
ImportState: true,
59-
ImportStateVerify: true,
57+
ResourceName: "google_secret_manager_secret.secret-basic",
58+
ImportState: true,
59+
ImportStateVerify: true,
6060
ImportStateVerifyIgnore: []string{"ttl", "labels", "terraform_labels"},
6161
},
6262
},
@@ -79,27 +79,27 @@ func TestAccSecretManagerSecret_annotationsUpdate(t *testing.T) {
7979
Config: testAccSecretManagerSecret_annotationsBasic(context),
8080
},
8181
{
82-
ResourceName: "google_secret_manager_secret.secret-with-annotations",
83-
ImportState: true,
84-
ImportStateVerify: true,
82+
ResourceName: "google_secret_manager_secret.secret-with-annotations",
83+
ImportState: true,
84+
ImportStateVerify: true,
8585
ImportStateVerifyIgnore: []string{"ttl", "labels", "terraform_labels", "annotations"},
8686
},
8787
{
8888
Config: testAccSecretManagerSecret_annotationsUpdate(context),
8989
},
9090
{
91-
ResourceName: "google_secret_manager_secret.secret-with-annotations",
92-
ImportState: true,
93-
ImportStateVerify: true,
91+
ResourceName: "google_secret_manager_secret.secret-with-annotations",
92+
ImportState: true,
93+
ImportStateVerify: true,
9494
ImportStateVerifyIgnore: []string{"ttl", "labels", "terraform_labels", "annotations"},
9595
},
9696
{
9797
Config: testAccSecretManagerSecret_annotationsBasic(context),
9898
},
9999
{
100-
ResourceName: "google_secret_manager_secret.secret-with-annotations",
101-
ImportState: true,
102-
ImportStateVerify: true,
100+
ResourceName: "google_secret_manager_secret.secret-with-annotations",
101+
ImportState: true,
102+
ImportStateVerify: true,
103103
ImportStateVerifyIgnore: []string{"ttl", "labels", "terraform_labels", "annotations"},
104104
},
105105
},
@@ -122,36 +122,36 @@ func TestAccSecretManagerSecret_versionAliasesUpdate(t *testing.T) {
122122
Config: testAccSecretManagerSecret_basicWithSecretVersions(context),
123123
},
124124
{
125-
ResourceName: "google_secret_manager_secret.secret-basic",
126-
ImportState: true,
127-
ImportStateVerify: true,
125+
ResourceName: "google_secret_manager_secret.secret-basic",
126+
ImportState: true,
127+
ImportStateVerify: true,
128128
ImportStateVerifyIgnore: []string{"ttl", "labels", "terraform_labels"},
129129
},
130130
{
131131
Config: testAccSecretManagerSecret_versionAliasesBasic(context),
132132
},
133133
{
134-
ResourceName: "google_secret_manager_secret.secret-basic",
135-
ImportState: true,
136-
ImportStateVerify: true,
134+
ResourceName: "google_secret_manager_secret.secret-basic",
135+
ImportState: true,
136+
ImportStateVerify: true,
137137
ImportStateVerifyIgnore: []string{"ttl", "labels", "terraform_labels"},
138138
},
139139
{
140140
Config: testAccSecretManagerSecret_versionAliasesUpdate(context),
141141
},
142142
{
143-
ResourceName: "google_secret_manager_secret.secret-basic",
144-
ImportState: true,
145-
ImportStateVerify: true,
143+
ResourceName: "google_secret_manager_secret.secret-basic",
144+
ImportState: true,
145+
ImportStateVerify: true,
146146
ImportStateVerifyIgnore: []string{"ttl", "labels", "terraform_labels"},
147147
},
148148
{
149149
Config: testAccSecretManagerSecret_basicWithSecretVersions(context),
150150
},
151151
{
152-
ResourceName: "google_secret_manager_secret.secret-basic",
153-
ImportState: true,
154-
ImportStateVerify: true,
152+
ResourceName: "google_secret_manager_secret.secret-basic",
153+
ImportState: true,
154+
ImportStateVerify: true,
155155
ImportStateVerifyIgnore: []string{"ttl", "labels", "terraform_labels"},
156156
},
157157
},
@@ -464,36 +464,6 @@ func TestAccSecretManagerSecret_updateBetweenTtlAndExpireTime(t *testing.T) {
464464
})
465465
}
466466

467-
func TestAccSecretManagerSecret_tags(t *testing.T) {
468-
t.Parallel()
469-
470-
tagKey := acctest.BootstrapSharedTestTagKey(t, "secret_manager_secret-tagkey")
471-
472-
context := map[string]interface{}{
473-
"org": envvar.GetTestOrgFromEnv(t),
474-
"tagKey": tagKey,
475-
"tagValue": acctest.BootstrapSharedTestTagValue(t, "secret_manager_secret-tagvalue", tagKey),
476-
"random_suffix": acctest.RandString(t, 10),
477-
}
478-
479-
acctest.VcrTest(t, resource.TestCase{
480-
PreCheck: func() { acctest.AccTestPreCheck(t) },
481-
ProtoV5ProviderFactories: acctest.ProtoV5ProviderFactories(t),
482-
CheckDestroy: testAccCheckSecretManagerSecretDestroyProducer(t),
483-
Steps: []resource.TestStep{
484-
{
485-
Config: testAccSecretManagerSecret_tags(context),
486-
},
487-
{
488-
ResourceName: "google_secret_manager_secret.secret-tags",
489-
ImportState: true,
490-
ImportStateVerify: true,
491-
ImportStateVerifyIgnore: []string{"ttl", "labels", "terraform_labels", "tags"},
492-
},
493-
},
494-
})
495-
}
496-
497467
func testAccSecretManagerSecret_basic(context map[string]interface{}) string {
498468
return acctest.Nprintf(`
499469
resource "google_secret_manager_secret" "secret-basic" {
@@ -1250,31 +1220,3 @@ resource "google_secret_manager_secret" "secret-basic" {
12501220
}
12511221
`, context)
12521222
}
1253-
1254-
func testAccSecretManagerSecret_tags(context map[string]interface{}) string {
1255-
return acctest.Nprintf(`
1256-
resource "google_secret_manager_secret" "secret-tags" {
1257-
secret_id = "tf-test-secret-%{random_suffix}"
1258-
1259-
labels = {
1260-
label = "my-label"
1261-
}
1262-
1263-
replication {
1264-
user_managed {
1265-
replicas {
1266-
location = "us-central1"
1267-
}
1268-
replicas {
1269-
location = "us-east1"
1270-
}
1271-
}
1272-
}
1273-
1274-
ttl = "3600s"
1275-
tags = {
1276-
"%{org}/%{tagKey}" = "%{tagValue}"
1277-
}
1278-
}
1279-
`, context)
1280-
}

mmv1/third_party/terraform/website/docs/r/container_cluster.html.markdown

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -931,7 +931,7 @@ gvnic {
931931

932932
* `max_run_duration` - (Optional) The runtime of each node in the node pool in seconds, terminated by 's'. Example: "3600s".
933933

934-
* `flex_start` - (Optional) Enables Flex Start provisioning model for the node pool.
934+
* `flex_start` - (Optional, [Beta](https://terraform.io/docs/providers/google/guides/provider_versions.html))) Enables Flex Start provisioning model for the node pool.
935935

936936
* `local_ssd_count` - (Optional) The amount of local SSD disks that will be
937937
attached to each cluster node. Defaults to 0.

0 commit comments

Comments
 (0)