Skip to content

Commit

Permalink
Merge pull request #11521 from c2thorn/main (#19214)
Browse files Browse the repository at this point in the history
Merge 6.0 branch into main

[upstream:33e0634155d56642a6c64174a611267eaaedf084]

Signed-off-by: Modular Magician <[email protected]>
  • Loading branch information
modular-magician authored Aug 21, 2024
1 parent 4960d0b commit 14bf312
Show file tree
Hide file tree
Showing 5 changed files with 4 additions and 59 deletions.
3 changes: 3 additions & 0 deletions .changelog/11521.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
```release-note:none

```
11 changes: 0 additions & 11 deletions google/services/bigquery/resource_bigquery_table.go
Original file line number Diff line number Diff line change
Expand Up @@ -1252,14 +1252,6 @@ func ResourceBigQueryTable() *schema.Resource {
Description: `Whether Terraform will be prevented from destroying the instance. When the field is set to true or unset in Terraform state, a terraform apply or terraform destroy that would delete the table will fail. When the field is set to false, deleting the table is allowed.`,
},

"allow_resource_tags_on_deletion": {
Type: schema.TypeBool,
Optional: true,
Default: false,
Description: `**Deprecated** Whether or not to allow table deletion when there are still resource tags attached.`,
Deprecated: `This field is deprecated and will be removed in a future major release. The default behavior will be allowing the presence of resource tags on deletion after the next major release.`,
},

// TableConstraints: [Optional] Defines the primary key and foreign keys.
"table_constraints": {
Type: schema.TypeList,
Expand Down Expand Up @@ -2938,9 +2930,6 @@ func resourceBigQueryTableImport(d *schema.ResourceData, meta interface{}) ([]*s
if err := d.Set("deletion_protection", true); err != nil {
return nil, fmt.Errorf("Error setting deletion_protection: %s", err)
}
if err := d.Set("allow_resource_tags_on_deletion", false); err != nil {
return nil, fmt.Errorf("Error setting allow_resource_tags_on_deletion: %s", err)
}

// Replace import id for the resource id
id, err := tpgresource.ReplaceVars(d, config, "projects/{{project}}/datasets/{{dataset_id}}/tables/{{table_id}}")
Expand Down
46 changes: 0 additions & 46 deletions google/services/compute/resource_compute_instance_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -1731,20 +1731,6 @@ func TestAccComputeInstance_guestAcceleratorSkip(t *testing.T) {
testAccCheckComputeInstanceLacksGuestAccelerator(&instance),
),
},
// Recreate with guest_accelerator = []
{
Config: testAccComputeInstance_guestAcceleratorEmptyBlock(instanceName),
Check: resource.ComposeTestCheckFunc(
testAccCheckComputeInstanceExists(t, "google_compute_instance.foobar", &instance),
testAccCheckComputeInstanceLacksGuestAccelerator(&instance),
),
},
// Check that count = 0 is the same as empty block []
{
Config: testAccComputeInstance_guestAccelerator(instanceName, 0),
ExpectNonEmptyPlan: false,
PlanOnly: true,
},
},
})

Expand Down Expand Up @@ -6526,38 +6512,6 @@ resource "google_compute_instance" "foobar" {
`, instance, count)
}

func testAccComputeInstance_guestAcceleratorEmptyBlock(instance string) string {
return fmt.Sprintf(`
data "google_compute_image" "my_image" {
family = "debian-11"
project = "debian-cloud"
}
resource "google_compute_instance" "foobar" {
name = "%s"
machine_type = "n1-standard-1" // can't be e2 because of guest_accelerator
zone = "us-east1-d"
boot_disk {
initialize_params {
image = data.google_compute_image.my_image.self_link
}
}
network_interface {
network = "default"
}
scheduling {
# Instances with guest accelerators do not support live migration.
on_host_maintenance = "TERMINATE"
}
guest_accelerator = []
}
`, instance)
}

func testAccComputeInstance_minCpuPlatform(instance string) string {
return fmt.Sprintf(`
data "google_compute_image" "my_image" {
Expand Down
1 change: 1 addition & 0 deletions google/services/resourcemanager/resource_google_project.go
Original file line number Diff line number Diff line change
Expand Up @@ -509,6 +509,7 @@ func resourceGoogleProjectDelete(d *schema.ResourceData, meta interface{}) error
return err
}
deletionPolicy := d.Get("deletion_policy").(string)

if deletionPolicy == "PREVENT" {
return fmt.Errorf("Cannot destroy project as deletion_policy is set to PREVENT.")
} else if deletionPolicy == "ABANDON" {
Expand Down
2 changes: 0 additions & 2 deletions website/docs/r/sql_database_instance.html.markdown
Original file line number Diff line number Diff line change
Expand Up @@ -381,8 +381,6 @@ This setting can be updated, but it cannot be removed after it is set.

* `server_ca_mode` - (Optional) Specify how the server certificate's Certificate Authority is hosted. Supported value is `GOOGLE_MANAGED_INTERNAL_CA`.

* `server_ca_mode` - (Optional) Specify how the server certificate's Certificate Authority is hosted. Supported value is `GOOGLE_MANAGED_INTERNAL_CA`.

* `allocated_ip_range` - (Optional) The name of the allocated ip range for the private ip CloudSQL instance. For example: "google-managed-services-default". If set, the instance ip will be created in the allocated range. The range name must comply with [RFC 1035](https://datatracker.ietf.org/doc/html/rfc1035). Specifically, the name must be 1-63 characters long and match the regular expression [a-z]([-a-z0-9]*[a-z0-9])?.

* `enable_private_path_for_google_cloud_services` - (Optional) Whether Google Cloud services such as BigQuery are allowed to access data in this Cloud SQL instance over a private IP connection. SQLSERVER database type is not supported.
Expand Down

0 comments on commit 14bf312

Please sign in to comment.