magic-modules icon indicating copy to clipboard operation
magic-modules copied to clipboard

feat: support nfs and gcs in cloudrun and cloudrunv2 GA provider

Open bskaplan opened this issue 1 year ago • 28 comments

Move nfs, and gcs/csi to GA provider in cloudrun and cloudrunv2

Release Note Template for Downstream PRs (will be copied)

cloudrun: support nfs and csi volumes (for cloud storage fuse) for cloudrun Service in GA provider
cloudrunv2: support nfs and gcs volumes for cloudrun Job in GA provider and update docs for both Service and Job

bskaplan avatar Aug 20 '24 20:08 bskaplan

Hello! I am a robot. Tests will require approval from a repository maintainer to run.

@melinath, a repository maintainer, has been assigned to review your changes. If you have not received review feedback within 2 business days, please leave a comment on this PR asking them to take a look.

You can help make sure that review is quick by doing a self-review and by running impacted tests locally.

github-actions[bot] avatar Aug 20 '24 20:08 github-actions[bot]

Hi there, I'm the Modular magician. I've detected the following information about your changes:

Diff report

Your PR generated some diffs in downstreams - here they are.

google provider: Diff ( 9 files changed, 830 insertions(+), 12 deletions(-)) google-beta provider: Diff ( 7 files changed, 77 insertions(+), 22 deletions(-))

modular-magician avatar Aug 20 '24 21:08 modular-magician

Tests analytics

Total tests: 73 Passed tests: 66 Skipped tests: 5 Affected tests: 2

Click here to see the affected service packages
  • cloudrun
  • cloudrunv2
#### Non-exercised tests

Tests were added that are GA-only additions and require manual runs:

  • TestAccCloudRunService_csiVolume
  • TestAccCloudRunV2Job_cloudrunv2JobWithGcsUpdate
  • TestAccCloudRunV2Job_cloudrunv2JobWithNfsUpdate
  • TestAccCloudRunV2Service_cloudrunv2ServiceGcsVolume

Action taken

Found 2 affected test(s) by replaying old test recordings. Starting RECORDING based on the most recent commit. Click here to see the affected tests
  • TestAccCloudRunService_changeVolume
  • TestAccCloudRunService_csiVolume

Get to know how VCR tests work

modular-magician avatar Aug 20 '24 21:08 modular-magician

Hi there, I'm the Modular magician. I've detected the following information about your changes:

Diff report

Your PR generated some diffs in downstreams - here they are.

google provider: Diff ( 9 files changed, 830 insertions(+), 12 deletions(-)) google-beta provider: Diff ( 7 files changed, 77 insertions(+), 22 deletions(-))

modular-magician avatar Aug 20 '24 21:08 modular-magician

$\textcolor{green}{\textsf{Tests passed during RECORDING mode:}}$ TestAccCloudRunService_csiVolume[Debug log]

$\textcolor{green}{\textsf{No issues found for passed tests after REPLAYING rerun.}}$


$\textcolor{red}{\textsf{Tests failed during RECORDING mode:}}$ TestAccCloudRunService_changeVolume[Error message] [Debug log]

$\textcolor{red}{\textsf{Errors occurred during RECORDING mode. Please fix them to complete your PR.}}$

View the build log or the debug log for each test

modular-magician avatar Aug 20 '24 21:08 modular-magician

Tests analytics

Total tests: 73 Passed tests: 67 Skipped tests: 5 Affected tests: 1

Click here to see the affected service packages
  • cloudrunv2
  • cloudrun
#### Non-exercised tests

Tests were added that are GA-only additions and require manual runs:

  • TestAccCloudRunService_csiVolume
  • TestAccCloudRunV2Job_cloudrunv2JobWithGcsUpdate
  • TestAccCloudRunV2Job_cloudrunv2JobWithNfsUpdate
  • TestAccCloudRunV2Service_cloudrunv2ServiceGcsVolume

Action taken

Found 1 affected test(s) by replaying old test recordings. Starting RECORDING based on the most recent commit. Click here to see the affected tests
  • TestAccCloudRunService_changeVolume

Get to know how VCR tests work

modular-magician avatar Aug 20 '24 21:08 modular-magician

$\textcolor{red}{\textsf{Tests failed during RECORDING mode:}}$ TestAccCloudRunService_changeVolume[Error message] [Debug log]

$\textcolor{red}{\textsf{Errors occurred during RECORDING mode. Please fix them to complete your PR.}}$

View the build log or the debug log for each test

modular-magician avatar Aug 20 '24 21:08 modular-magician

@bskaplan could you add the resource name to the release notes? Something like: added x fields to the Y resource (ga)

melinath avatar Aug 20 '24 21:08 melinath

It looks like the failing test is likely related. I think it might be because testAccCloudRunService_cloudRunServiceWithEmptyDirVolume sets "run.googleapis.com/launch-stage" = "BETA" in metadata.annotations but that was removed from testAccCloudRunService_cloudRunServiceUpdateWithGcsVolume in this PR. I'm a little unsure why it's showing up as a diff in effective_annotations though!

I think this is caused by a bad interaction between the Cloud Run v1 provider and the effective_annotations feature, related to my change but not caused by it. When we switch from empty_dir (a beta feature in Cloud Run) to cloud storage (now a GA feature), Cloud Run removes the launch-stage annotation from the API response. Since the change to consider cloud storage a GA feature is on the server, I get the exact same error running the existing test against a clean copy of terraform-provider-google-beta.

bskaplan avatar Aug 21 '24 16:08 bskaplan

Hi there, I'm the Modular magician. I've detected the following information about your changes:

Diff report

Your PR generated some diffs in downstreams - here they are.

google provider: Diff ( 9 files changed, 791 insertions(+), 12 deletions(-)) google-beta provider: Diff ( 7 files changed, 80 insertions(+), 33 deletions(-))

modular-magician avatar Aug 21 '24 17:08 modular-magician

Tests analytics

Total tests: 73 Passed tests: 67 Skipped tests: 5 Affected tests: 1

Click here to see the affected service packages
  • cloudrun
  • cloudrunv2
#### Non-exercised tests

Tests were added that are GA-only additions and require manual runs:

  • TestAccCloudRunService_csiVolume
  • TestAccCloudRunV2Job_cloudrunv2JobWithGcsUpdate
  • TestAccCloudRunV2Job_cloudrunv2JobWithNfsUpdate
  • TestAccCloudRunV2Service_cloudrunv2ServiceGcsVolume

Action taken

Found 1 affected test(s) by replaying old test recordings. Starting RECORDING based on the most recent commit. Click here to see the affected tests
  • TestAccCloudRunService_emptyDirVolume

Get to know how VCR tests work

modular-magician avatar Aug 21 '24 17:08 modular-magician

$\textcolor{green}{\textsf{Tests passed during RECORDING mode:}}$ TestAccCloudRunService_emptyDirVolume[Debug log]

$\textcolor{green}{\textsf{No issues found for passed tests after REPLAYING rerun.}}$


$\textcolor{green}{\textsf{All tests passed!}}$

View the build log or the debug log for each test

modular-magician avatar Aug 21 '24 17:08 modular-magician

Filed https://github.com/hashicorp/terraform-provider-google/issues/19206 to follow up on the effective_annotations issue.

bskaplan avatar Aug 21 '24 17:08 bskaplan

Running tests in GA to be safe:

  • https://hashicorp.teamcity.com/buildConfiguration/TerraformProviders_GoogleCloud_GOOGLE_MMUPSTREAMTESTS_GOOGLE_PACKAGE_CLOUDRUN/222906
  • https://hashicorp.teamcity.com/buildConfiguration/TerraformProviders_GoogleCloud_GOOGLE_MMUPSTREAMTESTS_GOOGLE_PACKAGE_CLOUDRUNV2/222907

melinath avatar Aug 22 '24 17:08 melinath

Hi there, I'm the Modular magician. I've detected the following information about your changes:

Diff report

Your PR generated some diffs in downstreams - here they are.

google provider: Diff ( 10 files changed, 809 insertions(+), 16 deletions(-)) google-beta provider: Diff ( 10 files changed, 93 insertions(+), 40 deletions(-)) Open in Cloud Shell: Diff ( 2 files changed, 1 insertion(+), 2 deletions(-))

modular-magician avatar Aug 22 '24 21:08 modular-magician

Tests analytics

Total tests: 73 Passed tests: 61 Skipped tests: 11 Affected tests: 1

Click here to see the affected service packages
  • cloudrunv2
  • cloudrun
#### Non-exercised tests

Tests were added that are GA-only additions and require manual runs:

  • TestAccCloudRunService_csiVolume
  • TestAccCloudRunV2Job_cloudrunv2JobWithGcsUpdate
  • TestAccCloudRunV2Job_cloudrunv2JobWithNfsUpdate
  • TestAccCloudRunV2Service_cloudrunv2ServiceGcsVolume

Action taken

Found 1 affected test(s) by replaying old test recordings. Starting RECORDING based on the most recent commit. Click here to see the affected tests
  • TestAccCloudRunService_emptyDirVolume

Get to know how VCR tests work

modular-magician avatar Aug 22 '24 21:08 modular-magician

$\textcolor{green}{\textsf{Tests passed during RECORDING mode:}}$ TestAccCloudRunService_emptyDirVolume[Debug log]

$\textcolor{green}{\textsf{No issues found for passed tests after REPLAYING rerun.}}$


$\textcolor{green}{\textsf{All tests passed!}}$

View the build log or the debug log for each test

modular-magician avatar Aug 22 '24 21:08 modular-magician

Had some merge conflicts because it looks like the v6 changes were moved to main. It doesn't look like the current unit test failures are related to my change though, none of them are in Cloud Run tests.

bskaplan avatar Aug 22 '24 22:08 bskaplan

Running tests in GA again.

Cloudrun: https://hashicorp.teamcity.com/buildConfiguration/TerraformProviders_GoogleCloud_GOOGLE_MMUPSTREAMTESTS_GOOGLE_PACKAGE_CLOUDRUN/223359?hideTestsFromDependencies=false&hideProblemsFromDependencies=false&expandBuildChangesSection=true Cloudrunv2: https://hashicorp.teamcity.com/buildConfiguration/TerraformProviders_GoogleCloud_GOOGLE_MMUPSTREAMTESTS_GOOGLE_PACKAGE_CLOUDRUNV2/223360?hideTestsFromDependencies=false&hideProblemsFromDependencies=false

melinath avatar Aug 23 '24 16:08 melinath

ok, got that one passing locally now.

bskaplan avatar Aug 23 '24 17:08 bskaplan

Hi there, I'm the Modular magician. I've detected the following information about your changes:

Diff report

Your PR generated some diffs in downstreams - here they are.

google provider: Diff ( 10 files changed, 808 insertions(+), 16 deletions(-)) google-beta provider: Diff ( 10 files changed, 93 insertions(+), 41 deletions(-)) Open in Cloud Shell: Diff ( 2 files changed, 1 insertion(+), 2 deletions(-))

modular-magician avatar Aug 23 '24 17:08 modular-magician

Tests analytics

Total tests: 73 Passed tests: 62 Skipped tests: 11 Affected tests: 0

Click here to see the affected service packages
  • cloudrun
  • cloudrunv2
#### Non-exercised tests

Tests were added that are GA-only additions and require manual runs:

  • TestAccCloudRunService_csiVolume
  • TestAccCloudRunV2Job_cloudrunv2JobWithGcsUpdate
  • TestAccCloudRunV2Job_cloudrunv2JobWithNfsUpdate
  • TestAccCloudRunV2Service_cloudrunv2ServiceGcsVolume $\textcolor{green}{\textsf{All tests passed!}}$

View the build log

modular-magician avatar Aug 23 '24 18:08 modular-magician

@melinath This PR has been waiting for review for 3 weekdays. Please take a look! Use the label disable-review-reminders to disable these notifications.

github-actions[bot] avatar Aug 28 '24 09:08 github-actions[bot]

Hi there, I'm the Modular magician. I've detected the following information about your changes:

Diff report

Your PR generated some diffs in downstreams - here they are.

google provider: Diff ( 10 files changed, 808 insertions(+), 16 deletions(-)) google-beta provider: Diff ( 10 files changed, 93 insertions(+), 41 deletions(-)) Open in Cloud Shell: Diff ( 2 files changed, 1 insertion(+), 2 deletions(-))

modular-magician avatar Aug 28 '24 17:08 modular-magician

Tests analytics

Total tests: 73 Passed tests: 62 Skipped tests: 11 Affected tests: 0

Click here to see the affected service packages
  • cloudrun
  • cloudrunv2
#### Non-exercised tests

Tests were added that are GA-only additions and require manual runs:

  • TestAccCloudRunService_csiVolume
  • TestAccCloudRunV2Job_cloudrunv2JobWithGcsUpdate
  • TestAccCloudRunV2Job_cloudrunv2JobWithNfsUpdate
  • TestAccCloudRunV2Service_cloudrunv2ServiceGcsVolume $\textcolor{green}{\textsf{All tests passed!}}$

View the build log

modular-magician avatar Aug 28 '24 17:08 modular-magician

Hi there, I'm the Modular magician. I've detected the following information about your changes:

Diff report

Your PR generated some diffs in downstreams - here they are.

google provider: Diff ( 10 files changed, 803 insertions(+), 16 deletions(-)) google-beta provider: Diff ( 10 files changed, 87 insertions(+), 45 deletions(-)) Open in Cloud Shell: Diff ( 2 files changed, 1 insertion(+), 2 deletions(-))

modular-magician avatar Aug 28 '24 23:08 modular-magician

Tests analytics

Total tests: 73 Passed tests: 62 Skipped tests: 11 Affected tests: 0

Click here to see the affected service packages
  • cloudrun
  • cloudrunv2
#### Non-exercised tests

Tests were added that are GA-only additions and require manual runs:

  • TestAccCloudRunService_csiVolume
  • TestAccCloudRunV2Job_cloudrunv2JobWithGcsUpdate
  • TestAccCloudRunV2Job_cloudrunv2JobWithNfsUpdate
  • TestAccCloudRunV2Service_cloudrunv2ServiceGcsVolume $\textcolor{green}{\textsf{All tests passed!}}$

View the build log

modular-magician avatar Aug 28 '24 23:08 modular-magician

GA tests:

CloudRun: https://hashicorp.teamcity.com/buildConfiguration/TerraformProviders_GoogleCloud_GOOGLE_MMUPSTREAMTESTS_GOOGLE_PACKAGE_CLOUDRUN/226387?hideTestsFromDependencies=false&hideProblemsFromDependencies=false&expandBuildChangesSection=true CloudRunV2: https://hashicorp.teamcity.com/buildConfiguration/TerraformProviders_GoogleCloud_GOOGLE_MMUPSTREAMTESTS_GOOGLE_PACKAGE_CLOUDRUNV2/226388?hideTestsFromDependencies=false&hideProblemsFromDependencies=false

melinath avatar Aug 29 '24 15:08 melinath

@melinath This PR has been waiting for review for 3 weekdays. Please take a look! Use the label disable-review-reminders to disable these notifications.

github-actions[bot] avatar Sep 02 '24 09:09 github-actions[bot]