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

Add schema resource #11018

Merged
merged 14 commits into from
Aug 13, 2024
Merged

Conversation

jialei-chen
Copy link
Member

This PR adds a new resource Schema to product DiscoveryEngine (b/340925271).

Release Note Template for Downstream PRs (will be copied)

`google_discovery_engine_schema`

@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.

google provider: Diff ( 5 files changed, 788 insertions(+), 2 deletions(-))
google-beta provider: Diff ( 5 files changed, 788 insertions(+), 2 deletions(-))
terraform-google-conversion: Diff ( 1 file changed, 69 insertions(+))
Open in Cloud Shell: Diff ( 4 files changed, 117 insertions(+))

@modular-magician
Copy link
Collaborator

Tests analytics

Total tests: 17
Passed tests: 8
Skipped tests: 0
Affected tests: 1

Click here to see the affected service packages
  • discoveryengine

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
  • TestAccDiscoveryEngineSchema_discoveryengineSchemaBasicExample

Get to know how VCR tests work

@modular-magician
Copy link
Collaborator

$\textcolor{red}{\textsf{Tests failed during RECORDING mode:}}$
TestAccDiscoveryEngineSchema_discoveryengineSchemaBasicExample[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
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.

google provider: Diff ( 5 files changed, 788 insertions(+), 2 deletions(-))
google-beta provider: Diff ( 5 files changed, 788 insertions(+), 2 deletions(-))
terraform-google-conversion: Diff ( 1 file changed, 69 insertions(+))
Open in Cloud Shell: Diff ( 4 files changed, 117 insertions(+))

@modular-magician
Copy link
Collaborator

Tests analytics

Total tests: 17
Passed tests: 8
Skipped tests: 0
Affected tests: 1

Click here to see the affected service packages
  • discoveryengine

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
  • TestAccDiscoveryEngineSchema_discoveryengineSchemaBasicExample

Get to know how VCR tests work

@modular-magician
Copy link
Collaborator

$\textcolor{red}{\textsf{Tests failed during RECORDING mode:}}$
TestAccDiscoveryEngineSchema_discoveryengineSchemaBasicExample[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
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.

google provider: Diff ( 5 files changed, 788 insertions(+), 2 deletions(-))
google-beta provider: Diff ( 5 files changed, 788 insertions(+), 2 deletions(-))
terraform-google-conversion: Diff ( 1 file changed, 69 insertions(+))
Open in Cloud Shell: Diff ( 4 files changed, 117 insertions(+))

@modular-magician
Copy link
Collaborator

Tests analytics

Total tests: 9
Passed tests: 8
Skipped tests: 0
Affected tests: 1

Click here to see the affected service packages
  • discoveryengine

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
  • TestAccDiscoveryEngineSchema_discoveryengineSchemaBasicExample

Get to know how VCR tests work

@modular-magician
Copy link
Collaborator

$\textcolor{red}{\textsf{Tests failed during RECORDING mode:}}$
TestAccDiscoveryEngineSchema_discoveryengineSchemaBasicExample[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
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.

google provider: Diff ( 5 files changed, 790 insertions(+), 2 deletions(-))
google-beta provider: Diff ( 5 files changed, 790 insertions(+), 2 deletions(-))
terraform-google-conversion: Diff ( 1 file changed, 69 insertions(+))
Open in Cloud Shell: Diff ( 4 files changed, 118 insertions(+))

@modular-magician
Copy link
Collaborator

Tests analytics

Total tests: 9
Passed tests: 8
Skipped tests: 0
Affected tests: 1

Click here to see the affected service packages
  • discoveryengine

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
  • TestAccDiscoveryEngineSchema_discoveryengineSchemaBasicExample

Get to know how VCR tests work

@modular-magician
Copy link
Collaborator

$\textcolor{red}{\textsf{Tests failed during RECORDING mode:}}$
TestAccDiscoveryEngineSchema_discoveryengineSchemaBasicExample[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

@jialei-chen jialei-chen marked this pull request as ready for review August 8, 2024 00:27
@github-actions github-actions bot requested a review from zli82016 August 8, 2024 00:28
Copy link

github-actions bot commented Aug 8, 2024

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

@zli82016, 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.

@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.

google provider: Diff ( 5 files changed, 790 insertions(+), 2 deletions(-))
google-beta provider: Diff ( 5 files changed, 790 insertions(+), 2 deletions(-))
terraform-google-conversion: Diff ( 1 file changed, 69 insertions(+))
Open in Cloud Shell: Diff ( 4 files changed, 118 insertions(+))

@modular-magician
Copy link
Collaborator

Tests analytics

Total tests: 9
Passed tests: 8
Skipped tests: 0
Affected tests: 1

Click here to see the affected service packages
  • discoveryengine

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
  • TestAccDiscoveryEngineSchema_discoveryengineSchemaBasicExample

Get to know how VCR tests work

@modular-magician
Copy link
Collaborator

$\textcolor{red}{\textsf{Tests failed during RECORDING mode:}}$
TestAccDiscoveryEngineSchema_discoveryengineSchemaBasicExample[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

@jialei-chen
Copy link
Member Author

Hi reviewer @zli82016 , I looked into the failed VCR test, tried to use either (1) JSON string or (2) jsonencode similar to this example to fix the "whitespace changes" error, but they didn't work and the acceptance test still failed.

From the Debug log, there were 6 requests and they all returned successfully as expected.

  1. Create the dependency resource DataStore
  2. Get the created dependency resource DataStore
  3. Create the resource Schema
  4. Get the created resource Schema
  5. Delete the resourced Schema
  6. Delete the dependency resource DataStore

Do you have any idea why it happened and how to fix this?

@zli82016
Copy link
Member

zli82016 commented Aug 8, 2024

Hi reviewer @zli82016 , I looked into the failed VCR test, tried to use either (1) JSON string or (2) jsonencode similar to this example to fix the "whitespace changes" error, but they didn't work and the acceptance test still failed.

From the Debug log, there were 6 requests and they all returned successfully as expected.

  1. Create the dependency resource DataStore
  2. Get the created dependency resource DataStore
  3. Create the resource Schema
  4. Get the created resource Schema
  5. Delete the resourced Schema
  6. Delete the dependency resource DataStore

Do you have any idea why it happened and how to fix this?

Hope the comment will fix the test.

@github-actions github-actions bot requested a review from zli82016 August 12, 2024 20:06
@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.

google provider: Diff ( 5 files changed, 812 insertions(+), 2 deletions(-))
google-beta provider: Diff ( 5 files changed, 812 insertions(+), 2 deletions(-))
terraform-google-conversion: Diff ( 1 file changed, 78 insertions(+))
Open in Cloud Shell: Diff ( 4 files changed, 118 insertions(+))

@modular-magician
Copy link
Collaborator

Tests analytics

Total tests: 9
Passed tests: 8
Skipped tests: 0
Affected tests: 1

Click here to see the affected service packages
  • discoveryengine

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
  • TestAccDiscoveryEngineSchema_discoveryengineSchemaBasicExample

Get to know how VCR tests work

@modular-magician
Copy link
Collaborator

$\textcolor{red}{\textsf{Tests failed during RECORDING mode:}}$
TestAccDiscoveryEngineSchema_discoveryengineSchemaBasicExample[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
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.

google provider: Diff ( 5 files changed, 802 insertions(+), 2 deletions(-))
google-beta provider: Diff ( 5 files changed, 802 insertions(+), 2 deletions(-))
terraform-google-conversion: Diff ( 1 file changed, 69 insertions(+))
Open in Cloud Shell: Diff ( 4 files changed, 118 insertions(+))

@modular-magician
Copy link
Collaborator

Tests analytics

Total tests: 9
Passed tests: 8
Skipped tests: 0
Affected tests: 1

Click here to see the affected service packages
  • discoveryengine

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
  • TestAccDiscoveryEngineSchema_discoveryengineSchemaBasicExample

Get to know how VCR tests work

@modular-magician
Copy link
Collaborator

$\textcolor{green}{\textsf{Tests passed during RECORDING mode:}}$
TestAccDiscoveryEngineSchema_discoveryengineSchemaBasicExample[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

@jialei-chen
Copy link
Member Author

Need to fix the test.

Thanks for helping review my changes! The create test has been fixed.

@jialei-chen
Copy link
Member Author

jialei-chen commented Aug 12, 2024

Can you also add the update test for the field json_schema? The doc is here

Thanks. Sure, will do it later after fixing the create test, since I estimate the same JSON string issue will happen for the udpate test.

The update test cannot be added at this time. Because our UpdateSchema API has not been fully ready yet and the field update_mask has a visibility restriction: it is only available for TRUSTED_TESTER: source code & corresponding Cloud doc

As for this PR, we can only support create & delete APIs. Will create a follow-up PR in the future once the update API is ready.

@github-actions github-actions bot requested a review from zli82016 August 13, 2024 18:22
@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.

google provider: Diff ( 5 files changed, 721 insertions(+), 2 deletions(-))
google-beta provider: Diff ( 5 files changed, 721 insertions(+), 2 deletions(-))
terraform-google-conversion: Diff ( 1 file changed, 69 insertions(+))
Open in Cloud Shell: Diff ( 4 files changed, 118 insertions(+))

@modular-magician
Copy link
Collaborator

Tests analytics

Total tests: 9
Passed tests: 8
Skipped tests: 0
Affected tests: 1

Click here to see the affected service packages
  • discoveryengine

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
  • TestAccDiscoveryEngineSchema_discoveryengineSchemaBasicExample

Get to know how VCR tests work

@modular-magician
Copy link
Collaborator

$\textcolor{green}{\textsf{Tests passed during RECORDING mode:}}$
TestAccDiscoveryEngineSchema_discoveryengineSchemaBasicExample[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

@github-actions github-actions bot requested a review from zli82016 August 13, 2024 20:46
@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.

google provider: Diff ( 5 files changed, 721 insertions(+), 2 deletions(-))
google-beta provider: Diff ( 5 files changed, 721 insertions(+), 2 deletions(-))
terraform-google-conversion: Diff ( 1 file changed, 69 insertions(+))
Open in Cloud Shell: Diff ( 4 files changed, 118 insertions(+))

@modular-magician
Copy link
Collaborator

Tests analytics

Total tests: 9
Passed tests: 9
Skipped tests: 0
Affected tests: 0

Click here to see the affected service packages
  • discoveryengine

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

View the build log

Copy link
Member

@zli82016 zli82016 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM. Thanks.

@zli82016 zli82016 merged commit 1f11e2a into GoogleCloudPlatform:main Aug 13, 2024
14 checks passed
BBBmau pushed a commit to bschaatsbergen/magic-modules that referenced this pull request Aug 21, 2024
rainshen49 pushed a commit to rainshen49/magic-modules that referenced this pull request Aug 21, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants