Skip to content

Commit 6fb237b

Browse files
authored
Merge branch 'main' into renew-close-ephemeral-service-account-key
2 parents ece4899 + 3406635 commit 6fb237b

File tree

478 files changed

+19872
-4302
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

478 files changed

+19872
-4302
lines changed

.ci/infra/terraform/README.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -74,3 +74,5 @@ Quotas that will need to be adjusted to support all tests:
7474
- compute.googleapis.com/n2_cpus (us-central1) to 36+
7575
- VMware Engine standard 72 vCPUs nodes per region - southamerica-east1 to 21
7676
- logging.googleapis.com/log_buckets_count to 200
77+
- "Reasoning engine write requests per minute" for us-central1 to 20+
78+
- aiplatform.googleapis.com/in_use_customer_managed_encryption_keys to 5+

.ci/infra/terraform/main.tf

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -235,6 +235,7 @@ module "project-services" {
235235
"binaryauthorization.googleapis.com",
236236
"blockchainnodeengine.googleapis.com",
237237
"certificatemanager.googleapis.com",
238+
"ces.googleapis.com",
238239
"chronicle.googleapis.com",
239240
"cloudaicompanion.googleapis.com",
240241
"cloudapis.googleapis.com",

.ci/magician/cmd/collect_nightly_test_status.go

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -42,6 +42,7 @@ type TestInfo struct {
4242
Name string `json:"name"`
4343
Status string `json:"status"`
4444
Service string `json:"service"`
45+
Resource string `json:"resource"`
4546
ErrorMessage string `json:"error_message"`
4647
LogLink string `json:"log_link"`
4748
ProviderVersion string `json:"provider_version"`
@@ -187,6 +188,7 @@ func createTestReport(pVersion provider.Version, tc TeamcityClient, gcs Cloudsto
187188
Name: testResult.Name,
188189
Status: testResult.Status,
189190
Service: serviceName,
191+
Resource: convertTestNameToResource(testResult.Name),
190192
ErrorMessage: errorMessage,
191193
LogLink: logLink,
192194
ProviderVersion: strings.ToUpper(pVersion.String()),

.ci/magician/cmd/create_test_failure_ticket.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -200,7 +200,7 @@ func lastNDaysTestFailureMap(pVersion provider.Version, n int, now time.Time, gc
200200
if _, ok := testFailuresToday[testName]; !ok {
201201
testFailuresToday[testName] = &testFailure{
202202
TestName: testName,
203-
AffectedResource: convertTestNameToResource(testName),
203+
AffectedResource: testInfo.Resource,
204204
ErrorMessageLinks: map[provider.Version]string{provider.GA: "", provider.Beta: ""},
205205
DebugLogLinks: map[provider.Version]string{provider.GA: "", provider.Beta: ""},
206206
FailureRates: map[provider.Version]string{provider.GA: "N/A", provider.Beta: "N/A"},

.ci/magician/cmd/test_terraform_vcr.go

Lines changed: 2 additions & 51 deletions
Original file line numberDiff line numberDiff line change
@@ -450,65 +450,16 @@ func modifiedPackages(changedFiles []string, version provider.Version) (map[stri
450450
return services, runFullVCR
451451
}
452452

453-
func allSubFolders(root string) (map[string]struct{}, error) {
454-
subfolders := make(map[string]struct{})
455-
entries, err := os.ReadDir(root)
456-
if err != nil {
457-
return nil, fmt.Errorf("failed to read directory '%s': %w", root, err)
458-
}
459-
460-
for _, entry := range entries {
461-
if entry.IsDir() {
462-
subfolders[entry.Name()] = struct{}{}
463-
}
464-
}
465-
return subfolders, nil
466-
}
467-
468453
func runReplaying(runFullVCR bool, version provider.Version, services map[string]struct{}, vt *vcr.Tester) (vcr.Result, []string, error) {
469454
result := vcr.Result{}
470455
var testDirs []string
471456
var replayingErr error
472457
if runFullVCR {
473458
fmt.Println("runReplaying: full VCR tests")
474-
// result, replayingErr = vt.Run(vcr.RunOptions{
475-
// Mode: vcr.Replaying,
476-
// Version: version,
477-
// })
478-
479-
// temporary workaround
480-
serviceRoot := filepath.Join(vt.GetRepoPath(version), version.ProviderName(), "services")
481-
allServies, err := allSubFolders(serviceRoot)
482-
if err != nil {
483-
return result, testDirs, err
484-
}
485-
486-
var gkePath string
487-
var otherPaths []string
488-
for service := range allServies {
489-
servicePath := "./" + filepath.Join(version.ProviderName(), "services", service)
490-
if service == "container" {
491-
gkePath = servicePath
492-
continue
493-
}
494-
otherPaths = append(otherPaths, servicePath)
495-
}
496459
result, replayingErr = vt.Run(vcr.RunOptions{
497-
Mode: vcr.Replaying,
498-
Version: version,
499-
TestDirs: otherPaths,
500-
})
501-
// run gke replaying tests separately
502-
gkeResult, gkeReplayingErr := vt.Run(vcr.RunOptions{
503-
Mode: vcr.Replaying,
504-
Version: version,
505-
TestDirs: []string{gkePath},
460+
Mode: vcr.Replaying,
461+
Version: version,
506462
})
507-
replayingErr = errors.Join(replayingErr, gkeReplayingErr)
508-
result.PassedTests = append(result.PassedTests, gkeResult.PassedTests...)
509-
result.SkippedTests = append(result.SkippedTests, gkeResult.SkippedTests...)
510-
result.FailedTests = append(result.FailedTests, gkeResult.FailedTests...)
511-
result.Panics = append(result.Panics, gkeResult.Panics...)
512463
} else if len(services) > 0 {
513464
fmt.Printf("runReplaying: %d specific services: %v\n", len(services), services)
514465
for service := range services {

.ci/magician/github/membership_data.go

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -109,6 +109,10 @@ var (
109109
startDate: newDate(2025, 2, 25),
110110
endDate: newDate(2025, 3, 10),
111111
},
112+
{
113+
startDate: newDate(2025, 11, 11),
114+
endDate: newDate(2025, 11, 24),
115+
},
112116
},
113117
},
114118
"roaks3": {

.ci/magician/vcr/tester.go

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -140,10 +140,6 @@ func (vt *Tester) SetRepoPath(version provider.Version, repoPath string) {
140140
vt.repoPaths[version] = repoPath
141141
}
142142

143-
func (vt *Tester) GetRepoPath(version provider.Version) string {
144-
return vt.repoPaths[version]
145-
}
146-
147143
// Fetch the cassettes for the current version if not already fetched.
148144
// Should be run from the base dir.
149145
func (vt *Tester) FetchCassettes(version provider.Version, baseBranch, head string) error {

docs/content/convert/add-new-resource-tgc.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -232,7 +232,7 @@ export WRITE_FILES=true
232232
To run the unit tests locally, run the following from the root of the `terraform-google-conversion` repository:
233233

234234
```
235-
make test
235+
make test-local
236236
```
237237

238238
#### Run integration tests

docs/content/develop/set-up-dev-environment.md

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -34,10 +34,6 @@ development environment.
3434
# Add Go binaries to PATH
3535
export PATH=$PATH:$(go env GOPATH)/bin
3636
```
37-
1. Install goimports
38-
```bash
39-
go install golang.org/x/tools/cmd/goimports@latest
40-
```
4137
1. [Install terraform](https://developer.hashicorp.com/terraform/tutorials/aws-get-started/install-cli)
4238
1. Clone the `magic-modules` repository
4339
```bash
@@ -57,8 +53,6 @@ development environment.
5753
```
5854
Check for go in path...
5955
found!
60-
Check for goimports in path...
61-
found!
6256
Check for git in path...
6357
found!
6458
Check for terraform in path...

docs/content/reference/metadata.md

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -31,6 +31,10 @@ The version of the API used for this resource e.g., "v2".
3131

3232
The API "resource type kind" used for this resource e.g., "Function".
3333

34+
### `cai_asset_name_format`
35+
36+
The custom CAI asset name format for this resource is typically specified (e.g., //cloudsql.googleapis.com/projects/{{project}}/instances/{{name}}). If this format is not provided, the Terraform resource ID format is used instead.
37+
3438
### `api_variant_patterns`
3539

3640
The API URL patterns used by this resource that represent variants e.g., "folders/{folder}/feeds/{feed}". Each pattern must match the value defined in the API exactly. The use of `api_variant_patterns` is only meaningful when the resource type has multiple parent types available.

0 commit comments

Comments
 (0)