Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Datastream Stream resource #6806

Merged
merged 42 commits into from
Jan 4, 2023
Merged

Datastream Stream resource #6806

merged 42 commits into from
Jan 4, 2023

Conversation

melinath
Copy link
Member

@melinath melinath commented Nov 9, 2022

Initial implementation of datastream stream resource. Resolved hashicorp/terraform-provider-google#10810

This does not cover all the fields in this very large resource. In particular I'm excluding CMEK fields and oracle & postgres (because those require specific handwritten tests) and oracle & postgres support (because that requires separate, non-automated testing.)

If this PR is for Terraform, I acknowledge that I have:

  • Searched through the issue tracker for an open issue that this either resolves or contributes to, commented on it to claim it, and written "fixes {url}" or "part of {url}" in this PR description. If there were no relevant open issues, I opened one and commented that I would like to work on it (not necessary for very small changes).
  • Generated Terraform, and ran make test and make lint to ensure it passes unit and linter tests.
  • Ensured that all new fields I added that can be set by a user appear in at least one example (for generated resources) or third_party test (for handwritten resources or update tests).
  • Ran relevant acceptance tests (If the acceptance tests do not yet pass or you are unable to run them, please let your reviewer know).
  • Read the Release Notes Guide before writing my release note below.

Release Note Template for Downstream PRs (will be copied)

`google_datastream_stream`

@modular-magician
Copy link
Collaborator

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.

Terraform GA: Diff ( 9 files changed, 5319 insertions(+), 6 deletions(-))
Terraform Beta: Diff ( 9 files changed, 5319 insertions(+), 6 deletions(-))
TF Validator: Diff ( 3 files changed, 1643 insertions(+), 3 deletions(-))
TF OiCS: Diff ( 8 files changed, 508 insertions(+))

@modular-magician
Copy link
Collaborator

Tests analytics

Total tests: 2237
Passed tests 1993
Skipped tests: 241
Failed tests: 3

Action taken

Triggering VCR tests in RECORDING mode for the tests that failed during VCR. Click here to see the failed tests
TestAccDatastreamStream_datastreamStreamFullExample|TestAccDatastreamStream_datastreamStreamBasicExample|TestAccComputeForwardingRule_update

@modular-magician
Copy link
Collaborator

Tests passed during RECORDING mode:
TestAccComputeForwardingRule_update[Debug log]

Tests failed during RECORDING mode:
TestAccDatastreamStream_datastreamStreamFullExample[Error message] [Debug log]
TestAccDatastreamStream_datastreamStreamBasicExample[Error message] [Debug log]

Please fix these to complete your PR
View the build log or the debug log for each test

mmv1/products/datastream/api.yaml Outdated Show resolved Hide resolved
mmv1/products/datastream/api.yaml Outdated Show resolved Hide resolved
mmv1/products/datastream/api.yaml Outdated Show resolved Hide resolved
mmv1/products/datastream/api.yaml Show resolved Hide resolved
mmv1/products/datastream/api.yaml Show resolved Hide resolved
mmv1/products/datastream/api.yaml Show resolved Hide resolved
@modular-magician
Copy link
Collaborator

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.

Terraform GA: Diff ( 9 files changed, 7205 insertions(+), 6 deletions(-))
Terraform Beta: Diff ( 9 files changed, 7205 insertions(+), 6 deletions(-))
TF Validator: Diff ( 3 files changed, 2330 insertions(+), 3 deletions(-))
TF OiCS: Diff ( 8 files changed, 508 insertions(+))

@modular-magician
Copy link
Collaborator

Tests analytics

Total tests: 2237
Passed tests 1992
Skipped tests: 241
Failed tests: 4

Action taken

Triggering VCR tests in RECORDING mode for the tests that failed during VCR. Click here to see the failed tests
TestAccFirebaserulesRelease_BasicRelease|TestAccDatastreamStream_datastreamStreamFullExample|TestAccDatastreamStream_datastreamStreamBasicExample|TestAccComputeForwardingRule_update

@modular-magician
Copy link
Collaborator

Tests passed during RECORDING mode:
TestAccFirebaserulesRelease_BasicRelease[Debug log]
TestAccComputeForwardingRule_update[Debug log]

Tests failed during RECORDING mode:
TestAccDatastreamStream_datastreamStreamFullExample[Error message] [Debug log]
TestAccDatastreamStream_datastreamStreamBasicExample[Error message] [Debug log]

Please fix these to complete your PR
View the build log or the debug log for each test

mmv1/products/datastream/api.yaml Outdated Show resolved Hide resolved
mmv1/products/datastream/api.yaml Outdated Show resolved Hide resolved
@modular-magician
Copy link
Collaborator

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.

Terraform GA: Diff ( 9 files changed, 7254 insertions(+), 6 deletions(-))
Terraform Beta: Diff ( 9 files changed, 7254 insertions(+), 6 deletions(-))
TF Validator: Diff ( 3 files changed, 2340 insertions(+), 3 deletions(-))
TF OiCS: Diff ( 8 files changed, 509 insertions(+))

@modular-magician
Copy link
Collaborator

Tests analytics

Total tests: 2253
Passed tests 2010
Skipped tests: 241
Failed tests: 2

Action taken

Triggering VCR tests in RECORDING mode for the tests that failed during VCR. Click here to see the failed tests
TestAccDatastreamStream_datastreamStreamFullExample|TestAccDatastreamStream_datastreamStreamBasicExample

@modular-magician
Copy link
Collaborator

Tests failed during RECORDING mode:
TestAccDatastreamStream_datastreamStreamFullExample[Error message] [Debug log]
TestAccDatastreamStream_datastreamStreamBasicExample[Error message] [Debug log]

Please fix these to complete your PR
View the build log or the debug log for each test

@modular-magician
Copy link
Collaborator

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.

Terraform GA: Diff ( 9 files changed, 3732 insertions(+), 6 deletions(-))
Terraform Beta: Diff ( 9 files changed, 3732 insertions(+), 6 deletions(-))
TF Validator: Diff ( 3 files changed, 1041 insertions(+), 3 deletions(-))
TF OiCS: Diff ( 8 files changed, 509 insertions(+))

@modular-magician
Copy link
Collaborator

Tests analytics

Total tests: 2283
Passed tests 2034
Skipped tests: 244
Failed tests: 5

Action taken

Triggering VCR tests in RECORDING mode for the tests that failed during VCR. Click here to see the failed tests
TestAccLoggingBucketConfigProject_cmekSettings|TestAccDatastreamStream_datastreamStreamFullExample|TestAccDatastreamStream_datastreamStreamBasicExample|TestAccFirebaserulesRelease_BasicRelease|TestAccComputeForwardingRule_update

@modular-magician
Copy link
Collaborator

Tests passed during RECORDING mode:
TestAccLoggingBucketConfigProject_cmekSettings[Debug log]
TestAccFirebaserulesRelease_BasicRelease[Debug log]
TestAccComputeForwardingRule_update[Debug log]

Tests failed during RECORDING mode:
TestAccDatastreamStream_datastreamStreamFullExample[Error message] [Debug log]
TestAccDatastreamStream_datastreamStreamBasicExample[Error message] [Debug log]

Please fix these to complete your PR
View the build log or the debug log for each test

@melinath melinath requested review from a team, c2thorn, shuyama1 and iperetz-goo and removed request for a team and c2thorn November 29, 2022 19:28
@modular-magician
Copy link
Collaborator

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.

Terraform GA: Diff ( 11 files changed, 4086 insertions(+), 7 deletions(-))
Terraform Beta: Diff ( 11 files changed, 4086 insertions(+), 7 deletions(-))
TF Validator: Diff ( 4 files changed, 1052 insertions(+), 4 deletions(-))
TF OiCS: Diff ( 8 files changed, 509 insertions(+))

@modular-magician
Copy link
Collaborator

Tests analytics

Total tests: 2305
Passed tests 2053
Skipped tests: 244
Failed tests: 8

Action taken

Triggering VCR tests in RECORDING mode for the tests that failed during VCR. Click here to see the failed tests
TestAccFirebaserulesRelease_BasicRelease|TestAccDatastreamStream_update|TestAccDatastreamStream_datastreamStreamFullExample|TestAccDatastreamStream_datastreamStreamBasicExample|TestAccCloudFunctions2Function_fullUpdate|TestAccCloudfunctions2function_cloudfunctions2BasicAuditlogsExample|TestAccCloudfunctions2function_cloudfunctions2BasicGcsExample|TestAccLoggingBucketConfigProject_cmekSettings

@modular-magician
Copy link
Collaborator

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.

Terraform GA: Diff ( 12 files changed, 4142 insertions(+), 7 deletions(-))
Terraform Beta: Diff ( 12 files changed, 4142 insertions(+), 7 deletions(-))
TF Validator: Diff ( 4 files changed, 1052 insertions(+), 4 deletions(-))
TF OiCS: Diff ( 9 files changed, 513 insertions(+))

@modular-magician
Copy link
Collaborator

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.

Terraform GA: Diff ( 12 files changed, 4142 insertions(+), 7 deletions(-))
Terraform Beta: Diff ( 12 files changed, 4142 insertions(+), 7 deletions(-))
TF Validator: Diff ( 4 files changed, 1052 insertions(+), 4 deletions(-))
TF OiCS: Diff ( 9 files changed, 513 insertions(+))

@modular-magician
Copy link
Collaborator

Tests analytics

Total tests: 2359
Passed tests 2107
Skipped tests: 247
Failed tests: 5

Action taken

Triggering VCR tests in RECORDING mode for the tests that failed during VCR. Click here to see the failed tests
TestAccDatastreamStream_update|TestAccDatastreamStream_datastreamStreamFullExample|TestAccDatastreamStream_datastreamStreamBasicExample|TestAccContainerCluster_withInvalidGatewayApiConfigChannel|TestAccLoggingBucketConfigProject_cmekSettings

@modular-magician
Copy link
Collaborator

Tests passed during RECORDING mode:
TestAccDatastreamStream_datastreamStreamFullExample[Debug log]
TestAccDatastreamStream_datastreamStreamBasicExample[Debug log]
TestAccContainerCluster_withInvalidGatewayApiConfigChannel[Debug log]
TestAccLoggingBucketConfigProject_cmekSettings[Debug log]

Tests failed during RECORDING mode:
TestAccDatastreamStream_update[Error message] [Debug log]

Please fix these to complete your PR
View the build log or the debug log for each test

@juancalvof
Copy link

Looking forward to this merge. Thanks for the effort! :)

@melinath
Copy link
Member Author

melinath commented Jan 3, 2023

/gcbrun

@modular-magician
Copy link
Collaborator

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.

Terraform GA: Diff ( 12 files changed, 4142 insertions(+), 7 deletions(-))
Terraform Beta: Diff ( 12 files changed, 4142 insertions(+), 7 deletions(-))
TF Validator: Diff ( 4 files changed, 1052 insertions(+), 4 deletions(-))
TF OiCS: Diff ( 9 files changed, 513 insertions(+))

@modular-magician
Copy link
Collaborator

Tests analytics

Total tests: 2385
Passed tests 2132
Skipped tests: 248
Failed tests: 5

Action taken

Triggering VCR tests in RECORDING mode for the tests that failed during VCR. Click here to see the failed tests
TestAccLoggingBucketConfigProject_cmekSettings|TestAccDatastreamStream_update|TestAccDatastreamStream_datastreamStreamFullExample|TestAccDatastreamStream_datastreamStreamBasicExample|TestAccContainerCluster_withInvalidGatewayApiConfigChannel

@modular-magician
Copy link
Collaborator

Tests passed during RECORDING mode:
TestAccLoggingBucketConfigProject_cmekSettings[Debug log]
TestAccDatastreamStream_datastreamStreamFullExample[Debug log]
TestAccDatastreamStream_datastreamStreamBasicExample[Debug log]
TestAccContainerCluster_withInvalidGatewayApiConfigChannel[Debug log]

Tests failed during RECORDING mode:
TestAccDatastreamStream_update[Error message] [Debug log]

Please fix these to complete your PR
View the build log or the debug log for each test

@modular-magician
Copy link
Collaborator

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.

Terraform GA: Diff ( 12 files changed, 4155 insertions(+), 7 deletions(-))
Terraform Beta: Diff ( 12 files changed, 4155 insertions(+), 7 deletions(-))
TF Validator: Diff ( 4 files changed, 1052 insertions(+), 4 deletions(-))
TF OiCS: Diff ( 9 files changed, 513 insertions(+))

@modular-magician
Copy link
Collaborator

Tests analytics

Total tests: 2389
Passed tests 2135
Skipped tests: 248
Failed tests: 6

Action taken

Triggering VCR tests in RECORDING mode for the tests that failed during VCR. Click here to see the failed tests
TestAccFirebaserulesRelease_BasicRelease|TestAccDatastreamStream_datastreamStreamFullExample|TestAccDatastreamStream_datastreamStreamBasicExample|TestAccDatastreamStream_update|TestAccContainerCluster_withInvalidGatewayApiConfigChannel|TestAccComputeForwardingRule_update

@modular-magician
Copy link
Collaborator

Tests passed during RECORDING mode:
TestAccFirebaserulesRelease_BasicRelease[Debug log]
TestAccDatastreamStream_datastreamStreamFullExample[Debug log]
TestAccDatastreamStream_datastreamStreamBasicExample[Debug log]
TestAccDatastreamStream_update[Debug log]
TestAccContainerCluster_withInvalidGatewayApiConfigChannel[Debug log]
TestAccComputeForwardingRule_update[Debug log]

All tests passed
View the build log or the debug log for each test

@melinath
Copy link
Member Author

melinath commented Jan 4, 2023

@shuyama1 This is now ready for review!

@melinath melinath merged commit ba93120 into main Jan 4, 2023
@melinath melinath deleted the b-233804820-stream branch January 4, 2023 22:36
i-laird pushed a commit to i-laird/magic-modules that referenced this pull request Jan 10, 2023
* Added initial datastream Stream structure

* Added basic test for datastream

* Removed oracle support since it's hard to test

* Added some additional fields that could not previously be handled

* Added full example for datastream stream with MySQL -> GCS

* Removed additional references to oracle on datastream stream

* cleaned up api.yaml and terraform.yaml

* Revert "Removed additional references to oracle on datastream stream"

This reverts commit 6ce0d70.

* Revert "Removed oracle support since it's hard to test"

This reverts commit 732cf30.

* Added oracleSourceConfig.dropLargeObjects and oracleSourceConfig.streamLargeObjects

* Require a value inside jsonFileFormat

* Require a value inside bigqueryDestinationConfig

* Corrected type of fileRotationMb

* Added state field and added default_from_api to a few fields

* Fixed typo

* Corrected name of default_value property

* Removed support for oracle and postgres from Datastream Stream

This simplifies the PR; also they are not automatically testable

* Converted status field to be computed

We will likely want to use either default_from_api or use a desired_state field because this field is only partially specified

* Added desired_state field

* removed input: true from stream

* ignore read on stream connection profiles

* Added update test

* Added unit test for customizediff

* Added unit tests for customize diff

* Added external providers

* gofmt

* Corrected deletion_protection usage

* Updates due to code review

* Cleaned up test issues

* Corrections to tests

* Fixed test issues

* Added gcs file format to fix tests

* Added projectNumberDiffSuppress

* Added default_from_api for fileRotationMb

* Corrected labels usage in tests

* Corrected stream update verb

* Cleaned up references to google_storage_bucket.bucket.name

* Source / destination profile are not updatable

* Marked column length fields as output-only

* Made update test use checks instead of importstateverify for state / desired_state

* gofmt

* Add state to update mask if desired_state is changed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
5 participants