diff --git a/.release-please-manifest.json b/.release-please-manifest.json index 4d22cbf32873..05a1fb0f5a19 100644 --- a/.release-please-manifest.json +++ b/.release-please-manifest.json @@ -507,6 +507,8 @@ "google-cloud-optimization+FILLER": "0.0.0", "google-cloud-optimization-v1": "0.9.2", "google-cloud-optimization-v1+FILLER": "0.0.0", + "google-cloud-oracle_database-v1": "0.0.1", + "google-cloud-oracle_database-v1+FILLER": "0.0.0", "google-cloud-orchestration-airflow-service": "1.4.1", "google-cloud-orchestration-airflow-service+FILLER": "0.0.0", "google-cloud-orchestration-airflow-service-v1": "1.1.0", diff --git a/google-cloud-oracle_database-v1/.OwlBot.yaml b/google-cloud-oracle_database-v1/.OwlBot.yaml new file mode 100644 index 000000000000..6e18260a014c --- /dev/null +++ b/google-cloud-oracle_database-v1/.OwlBot.yaml @@ -0,0 +1,3 @@ +deep-copy-regex: + - source: /google/cloud/oracledatabase/v1/[^/]+-ruby/(.*) + dest: /owl-bot-staging/google-cloud-oracle_database-v1/$1 diff --git a/google-cloud-oracle_database-v1/.gitignore b/google-cloud-oracle_database-v1/.gitignore new file mode 100644 index 000000000000..0135b6bc6cfc --- /dev/null +++ b/google-cloud-oracle_database-v1/.gitignore @@ -0,0 +1,22 @@ +# Ignore bundler lockfiles +Gemfile.lock +gems.locked + +# Ignore documentation output +doc/* +.yardoc/* + +# Ignore test output +coverage/* + +# Ignore build artifacts +pkg/* + +# Ignore files commonly present in certain dev environments +.vagrant +.DS_STORE +.idea +*.iml + +# Ignore synth output +__pycache__ diff --git a/google-cloud-oracle_database-v1/.owlbot-manifest.json b/google-cloud-oracle_database-v1/.owlbot-manifest.json new file mode 100644 index 000000000000..748b03de2037 --- /dev/null +++ b/google-cloud-oracle_database-v1/.owlbot-manifest.json @@ -0,0 +1,104 @@ +{ + "generated": [ + ".gitignore", + ".repo-metadata.json", + ".rubocop.yml", + ".toys.rb", + ".yardopts", + "AUTHENTICATION.md", + "CHANGELOG.md", + "Gemfile", + "LICENSE.md", + "README.md", + "Rakefile", + "gapic_metadata.json", + "google-cloud-oracle_database-v1.gemspec", + "lib/google-cloud-oracle_database-v1.rb", + "lib/google/cloud/oracle_database/v1.rb", + "lib/google/cloud/oracle_database/v1/bindings_override.rb", + "lib/google/cloud/oracle_database/v1/oracle_database.rb", + "lib/google/cloud/oracle_database/v1/oracle_database/credentials.rb", + "lib/google/cloud/oracle_database/v1/oracle_database/paths.rb", + "lib/google/cloud/oracle_database/v1/oracle_database/rest.rb", + "lib/google/cloud/oracle_database/v1/oracle_database/rest/client.rb", + "lib/google/cloud/oracle_database/v1/oracle_database/rest/operations.rb", + "lib/google/cloud/oracle_database/v1/oracle_database/rest/service_stub.rb", + "lib/google/cloud/oracle_database/v1/rest.rb", + "lib/google/cloud/oracle_database/v1/version.rb", + "lib/google/cloud/oracledatabase/v1/autonomous_database_character_set_pb.rb", + "lib/google/cloud/oracledatabase/v1/autonomous_database_pb.rb", + "lib/google/cloud/oracledatabase/v1/autonomous_db_backup_pb.rb", + "lib/google/cloud/oracledatabase/v1/autonomous_db_version_pb.rb", + "lib/google/cloud/oracledatabase/v1/common_pb.rb", + "lib/google/cloud/oracledatabase/v1/db_node_pb.rb", + "lib/google/cloud/oracledatabase/v1/db_server_pb.rb", + "lib/google/cloud/oracledatabase/v1/db_system_shape_pb.rb", + "lib/google/cloud/oracledatabase/v1/entitlement_pb.rb", + "lib/google/cloud/oracledatabase/v1/exadata_infra_pb.rb", + "lib/google/cloud/oracledatabase/v1/gi_version_pb.rb", + "lib/google/cloud/oracledatabase/v1/location_metadata_pb.rb", + "lib/google/cloud/oracledatabase/v1/oracledatabase_pb.rb", + "lib/google/cloud/oracledatabase/v1/oracledatabase_services_pb.rb", + "lib/google/cloud/oracledatabase/v1/vm_cluster_pb.rb", + "proto_docs/README.md", + "proto_docs/google/api/client.rb", + "proto_docs/google/api/field_behavior.rb", + "proto_docs/google/api/field_info.rb", + "proto_docs/google/api/launch_stage.rb", + "proto_docs/google/api/resource.rb", + "proto_docs/google/cloud/oracledatabase/v1/autonomous_database.rb", + "proto_docs/google/cloud/oracledatabase/v1/autonomous_database_character_set.rb", + "proto_docs/google/cloud/oracledatabase/v1/autonomous_db_backup.rb", + "proto_docs/google/cloud/oracledatabase/v1/autonomous_db_version.rb", + "proto_docs/google/cloud/oracledatabase/v1/common.rb", + "proto_docs/google/cloud/oracledatabase/v1/db_node.rb", + "proto_docs/google/cloud/oracledatabase/v1/db_server.rb", + "proto_docs/google/cloud/oracledatabase/v1/db_system_shape.rb", + "proto_docs/google/cloud/oracledatabase/v1/entitlement.rb", + "proto_docs/google/cloud/oracledatabase/v1/exadata_infra.rb", + "proto_docs/google/cloud/oracledatabase/v1/gi_version.rb", + "proto_docs/google/cloud/oracledatabase/v1/location_metadata.rb", + "proto_docs/google/cloud/oracledatabase/v1/oracledatabase.rb", + "proto_docs/google/cloud/oracledatabase/v1/vm_cluster.rb", + "proto_docs/google/longrunning/operations.rb", + "proto_docs/google/protobuf/any.rb", + "proto_docs/google/protobuf/duration.rb", + "proto_docs/google/protobuf/empty.rb", + "proto_docs/google/protobuf/timestamp.rb", + "proto_docs/google/rpc/status.rb", + "proto_docs/google/type/datetime.rb", + "proto_docs/google/type/dayofweek.rb", + "proto_docs/google/type/month.rb", + "proto_docs/google/type/timeofday.rb", + "snippets/Gemfile", + "snippets/oracle_database/create_autonomous_database.rb", + "snippets/oracle_database/create_cloud_exadata_infrastructure.rb", + "snippets/oracle_database/create_cloud_vm_cluster.rb", + "snippets/oracle_database/delete_autonomous_database.rb", + "snippets/oracle_database/delete_cloud_exadata_infrastructure.rb", + "snippets/oracle_database/delete_cloud_vm_cluster.rb", + "snippets/oracle_database/generate_autonomous_database_wallet.rb", + "snippets/oracle_database/get_autonomous_database.rb", + "snippets/oracle_database/get_cloud_exadata_infrastructure.rb", + "snippets/oracle_database/get_cloud_vm_cluster.rb", + "snippets/oracle_database/list_autonomous_database_backups.rb", + "snippets/oracle_database/list_autonomous_database_character_sets.rb", + "snippets/oracle_database/list_autonomous_databases.rb", + "snippets/oracle_database/list_autonomous_db_versions.rb", + "snippets/oracle_database/list_cloud_exadata_infrastructures.rb", + "snippets/oracle_database/list_cloud_vm_clusters.rb", + "snippets/oracle_database/list_db_nodes.rb", + "snippets/oracle_database/list_db_servers.rb", + "snippets/oracle_database/list_db_system_shapes.rb", + "snippets/oracle_database/list_entitlements.rb", + "snippets/oracle_database/list_gi_versions.rb", + "snippets/oracle_database/restore_autonomous_database.rb", + "snippets/snippet_metadata_google.cloud.oracledatabase.v1.json", + "test/google/cloud/oracle_database/v1/oracle_database_rest_test.rb", + "test/helper.rb" + ], + "static": [ + ".OwlBot.yaml", + ".owlbot.rb" + ] +} diff --git a/google-cloud-oracle_database-v1/.owlbot.rb b/google-cloud-oracle_database-v1/.owlbot.rb new file mode 100644 index 000000000000..1dd7e1e8b4db --- /dev/null +++ b/google-cloud-oracle_database-v1/.owlbot.rb @@ -0,0 +1,30 @@ +# Copyright 2024 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# OwlBot script for google-cloud-oracle_database-v1 + +# Remove a spurious link to a class in a different gem. +# See https://github.com/googleapis/gapic-generator-ruby/issues/824 +OwlBot.modifier path: "proto_docs/google/cloud/oracledatabase/v1/location_metadata.rb" do |content| + content.gsub "{::Google::Cloud::Location::Location Location}", + "`::Google::Cloud::Location::Location`" +end + +# Remove path tests due to +# https://github.com/googleapis/gapic-generator-ruby/issues/1115 +OwlBot.modifier path: %r{google/cloud/oracle_database/v1/\w+_paths_test\.rb$} do + nil +end + +OwlBot.move_files diff --git a/google-cloud-oracle_database-v1/.repo-metadata.json b/google-cloud-oracle_database-v1/.repo-metadata.json new file mode 100644 index 000000000000..d25b8ceec3d9 --- /dev/null +++ b/google-cloud-oracle_database-v1/.repo-metadata.json @@ -0,0 +1,17 @@ +{ + "api_id": "oracledatabase.googleapis.com", + "api_shortname": "oracledatabase", + "client_documentation": "https://cloud.google.com/ruby/docs/reference/google-cloud-oracle_database-v1/latest", + "distribution_name": "google-cloud-oracle_database-v1", + "is_cloud": true, + "language": "ruby", + "name": "oracledatabase", + "name_pretty": "Oracle Database@Google Cloud V1 API", + "product_documentation": "https://cloud.google.com/oracle/database/docs", + "release_level": "unreleased", + "repo": "googleapis/google-cloud-ruby", + "requires_billing": true, + "ruby-cloud-description": "The Oracle Database@Google Cloud API provides a set of APIs to manage Oracle database services, such as Exadata and Autonomous Databases. Note that google-cloud-oracle_database-v1 is a version-specific client library. For most uses, we recommend installing the main client library google-cloud-oracle_database instead. See the readme for more details.", + "ruby-cloud-product-url": "https://cloud.google.com/oracle/database/docs", + "library_type": "GAPIC_AUTO" +} diff --git a/google-cloud-oracle_database-v1/.rubocop.yml b/google-cloud-oracle_database-v1/.rubocop.yml new file mode 100644 index 000000000000..5d3a13a478ab --- /dev/null +++ b/google-cloud-oracle_database-v1/.rubocop.yml @@ -0,0 +1,33 @@ +inherit_gem: + google-style: google-style.yml + +AllCops: + Exclude: + - "google-cloud-oracle_database-v1.gemspec" + - "lib/**/*_pb.rb" + - "proto_docs/**/*" + - "test/**/*" + - "acceptance/**/*" + - "samples/acceptance/**/*" + - "Rakefile" + +Layout/LineLength: + Enabled: false +Metrics/AbcSize: + Enabled: false +Metrics/ClassLength: + Enabled: false +Metrics/CyclomaticComplexity: + Enabled: false +Metrics/MethodLength: + Enabled: false +Metrics/ModuleLength: + Enabled: false +Metrics/PerceivedComplexity: + Enabled: false +Naming/AccessorMethodName: + Exclude: + - "snippets/**/*.rb" +Naming/FileName: + Exclude: + - "lib/google-cloud-oracle_database-v1.rb" diff --git a/google-cloud-oracle_database-v1/.toys.rb b/google-cloud-oracle_database-v1/.toys.rb new file mode 100644 index 000000000000..23434bdd5d5b --- /dev/null +++ b/google-cloud-oracle_database-v1/.toys.rb @@ -0,0 +1,28 @@ +# frozen_string_literal: true + +# Copyright 2024 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# https://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Auto-generated by gapic-generator-ruby. DO NOT EDIT! + +toys_version! ">= 0.15.3" + +if ENV["RUBY_COMMON_TOOLS"] + common_tools_dir = File.expand_path ENV["RUBY_COMMON_TOOLS"] + load File.join(common_tools_dir, "toys", "gapic") +else + load_git remote: "https://github.com/googleapis/ruby-common-tools.git", + path: "toys/gapic", + update: true +end diff --git a/google-cloud-oracle_database-v1/.yardopts b/google-cloud-oracle_database-v1/.yardopts new file mode 100644 index 000000000000..665101124a1e --- /dev/null +++ b/google-cloud-oracle_database-v1/.yardopts @@ -0,0 +1,12 @@ +--no-private +--title="Oracle Database@Google Cloud V1 API" +--exclude _pb\.rb$ +--markup markdown +--markup-provider redcarpet + +./lib/**/*.rb +./proto_docs/**/*.rb +- +README.md +LICENSE.md +AUTHENTICATION.md diff --git a/google-cloud-oracle_database-v1/AUTHENTICATION.md b/google-cloud-oracle_database-v1/AUTHENTICATION.md new file mode 100644 index 000000000000..1900cf6f1f85 --- /dev/null +++ b/google-cloud-oracle_database-v1/AUTHENTICATION.md @@ -0,0 +1,122 @@ +# Authentication + +The recommended way to authenticate to the google-cloud-oracle_database-v1 library is to use +[Application Default Credentials (ADC)](https://cloud.google.com/docs/authentication/application-default-credentials). +To review all of your authentication options, see [Credentials lookup](#credential-lookup). + +## Quickstart + +The following example shows how to set up authentication for a local development +environment with your user credentials. + +**NOTE:** This method is _not_ recommended for running in production. User credentials +should be used only during development. + +1. [Download and install the Google Cloud CLI](https://cloud.google.com/sdk). +2. Set up a local ADC file with your user credentials: + +```sh +gcloud auth application-default login +``` + +3. Write code as if already authenticated. + +For more information about setting up authentication for a local development environment, see +[Set up Application Default Credentials](https://cloud.google.com/docs/authentication/provide-credentials-adc#local-dev). + +## Credential Lookup + +The google-cloud-oracle_database-v1 library provides several mechanisms to configure your system. +Generally, using Application Default Credentials to facilitate automatic +credentials discovery is the easist method. But if you need to explicitly specify +credentials, there are several methods available to you. + +Credentials are accepted in the following ways, in the following order or precedence: + +1. Credentials specified in method arguments +2. Credentials specified in configuration +3. Credentials pointed to or included in environment variables +4. Credentials found in local ADC file +5. Credentials returned by the metadata server for the attached service account (GCP) + +### Configuration + +You can configure a path to a JSON credentials file, either for an individual client object or +globally, for all client objects. The JSON file can contain credentials created for +[workload identity federation](https://cloud.google.com/iam/docs/workload-identity-federation), +[workforce identity federation](https://cloud.google.com/iam/docs/workforce-identity-federation), or a +[service account key](https://cloud.google.com/docs/authentication/provide-credentials-adc#local-key). + +Note: Service account keys are a security risk if not managed correctly. You should +[choose a more secure alternative to service account keys](https://cloud.google.com/docs/authentication#auth-decision-tree) +whenever possible. + +To configure a credentials file for an individual client initialization: + +```ruby +require "google/cloud/oracle_database/v1" + +client = ::Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::Client.new do |config| + config.credentials = "path/to/credentialfile.json" +end +``` + +To configure a credentials file globally for all clients: + +```ruby +require "google/cloud/oracle_database/v1" + +::Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::Client.configure do |config| + config.credentials = "path/to/credentialfile.json" +end + +client = ::Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::Client.new +``` + +### Environment Variables + +You can also use an environment variable to provide a JSON credentials file. +The environment variable can contain a path to the credentials file or, for +environments such as Docker containers where writing files is not encouraged, +you can include the credentials file itself. + +The JSON file can contain credentials created for +[workload identity federation](https://cloud.google.com/iam/docs/workload-identity-federation), +[workforce identity federation](https://cloud.google.com/iam/docs/workforce-identity-federation), or a +[service account key](https://cloud.google.com/docs/authentication/provide-credentials-adc#local-key). + +Note: Service account keys are a security risk if not managed correctly. You should +[choose a more secure alternative to service account keys](https://cloud.google.com/docs/authentication#auth-decision-tree) +whenever possible. + +The environment variables that google-cloud-oracle_database-v1 +checks for credentials are: + +* `GOOGLE_CLOUD_CREDENTIALS` - Path to JSON file, or JSON contents +* `GOOGLE_APPLICATION_CREDENTIALS` - Path to JSON file + +```ruby +require "google/cloud/oracle_database/v1" + +ENV["GOOGLE_APPLICATION_CREDENTIALS"] = "path/to/credentialfile.json" + +client = ::Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::Client.new +``` + +### Local ADC file + +You can set up a local ADC file with your user credentials for authentication during +development. If credentials are not provided in code or in environment variables, +then the local ADC credentials are discovered. + +Follow the steps in [Quickstart](#quickstart) to set up a local ADC file. + +### Google Cloud Platform environments + +When running on Google Cloud Platform (GCP), including Google Compute Engine +(GCE), Google Kubernetes Engine (GKE), Google App Engine (GAE), Google Cloud +Functions (GCF) and Cloud Run, credentials are retrieved from the attached +service account automatically. Code should be written as if already authenticated. + +For more information, see +[Set up ADC for Google Cloud services](https://cloud.google.com/docs/authentication/provide-credentials-adc#attached-sa). diff --git a/google-cloud-oracle_database-v1/CHANGELOG.md b/google-cloud-oracle_database-v1/CHANGELOG.md new file mode 100644 index 000000000000..f88957a62ba2 --- /dev/null +++ b/google-cloud-oracle_database-v1/CHANGELOG.md @@ -0,0 +1,2 @@ +# Release History + diff --git a/google-cloud-oracle_database-v1/Gemfile b/google-cloud-oracle_database-v1/Gemfile new file mode 100644 index 000000000000..95163a6d11f8 --- /dev/null +++ b/google-cloud-oracle_database-v1/Gemfile @@ -0,0 +1,11 @@ +source "https://rubygems.org" + +gemspec + +gem "google-style", "~> 1.27.1" +gem "minitest", "~> 5.22" +gem "minitest-focus", "~> 1.4" +gem "minitest-rg", "~> 5.3" +gem "rake", ">= 13.0" +gem "redcarpet", "~> 3.6" +gem "yard", "~> 0.9" diff --git a/google-cloud-oracle_database-v1/LICENSE.md b/google-cloud-oracle_database-v1/LICENSE.md new file mode 100644 index 000000000000..c261857ba6ad --- /dev/null +++ b/google-cloud-oracle_database-v1/LICENSE.md @@ -0,0 +1,201 @@ + Apache License + Version 2.0, January 2004 + http://www.apache.org/licenses/ + + TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION + + 1. Definitions. + + "License" shall mean the terms and conditions for use, reproduction, + and distribution as defined by Sections 1 through 9 of this document. + + "Licensor" shall mean the copyright owner or entity authorized by + the copyright owner that is granting the License. + + "Legal Entity" shall mean the union of the acting entity and all + other entities that control, are controlled by, or are under common + control with that entity. For the purposes of this definition, + "control" means (i) the power, direct or indirect, to cause the + direction or management of such entity, whether by contract or + otherwise, or (ii) ownership of fifty percent (50%) or more of the + outstanding shares, or (iii) beneficial ownership of such entity. + + "You" (or "Your") shall mean an individual or Legal Entity + exercising permissions granted by this License. + + "Source" form shall mean the preferred form for making modifications, + including but not limited to software source code, documentation + source, and configuration files. + + "Object" form shall mean any form resulting from mechanical + transformation or translation of a Source form, including but + not limited to compiled object code, generated documentation, + and conversions to other media types. + + "Work" shall mean the work of authorship, whether in Source or + Object form, made available under the License, as indicated by a + copyright notice that is included in or attached to the work + (an example is provided in the Appendix below). + + "Derivative Works" shall mean any work, whether in Source or Object + form, that is based on (or derived from) the Work and for which the + editorial revisions, annotations, elaborations, or other modifications + represent, as a whole, an original work of authorship. For the purposes + of this License, Derivative Works shall not include works that remain + separable from, or merely link (or bind by name) to the interfaces of, + the Work and Derivative Works thereof. + + "Contribution" shall mean any work of authorship, including + the original version of the Work and any modifications or additions + to that Work or Derivative Works thereof, that is intentionally + submitted to Licensor for inclusion in the Work by the copyright owner + or by an individual or Legal Entity authorized to submit on behalf of + the copyright owner. For the purposes of this definition, "submitted" + means any form of electronic, verbal, or written communication sent + to the Licensor or its representatives, including but not limited to + communication on electronic mailing lists, source code control systems, + and issue tracking systems that are managed by, or on behalf of, the + Licensor for the purpose of discussing and improving the Work, but + excluding communication that is conspicuously marked or otherwise + designated in writing by the copyright owner as "Not a Contribution." + + "Contributor" shall mean Licensor and any individual or Legal Entity + on behalf of whom a Contribution has been received by Licensor and + subsequently incorporated within the Work. + + 2. Grant of Copyright License. Subject to the terms and conditions of + this License, each Contributor hereby grants to You a perpetual, + worldwide, non-exclusive, no-charge, royalty-free, irrevocable + copyright license to reproduce, prepare Derivative Works of, + publicly display, publicly perform, sublicense, and distribute the + Work and such Derivative Works in Source or Object form. + + 3. Grant of Patent License. Subject to the terms and conditions of + this License, each Contributor hereby grants to You a perpetual, + worldwide, non-exclusive, no-charge, royalty-free, irrevocable + (except as stated in this section) patent license to make, have made, + use, offer to sell, sell, import, and otherwise transfer the Work, + where such license applies only to those patent claims licensable + by such Contributor that are necessarily infringed by their + Contribution(s) alone or by combination of their Contribution(s) + with the Work to which such Contribution(s) was submitted. If You + institute patent litigation against any entity (including a + cross-claim or counterclaim in a lawsuit) alleging that the Work + or a Contribution incorporated within the Work constitutes direct + or contributory patent infringement, then any patent licenses + granted to You under this License for that Work shall terminate + as of the date such litigation is filed. + + 4. Redistribution. You may reproduce and distribute copies of the + Work or Derivative Works thereof in any medium, with or without + modifications, and in Source or Object form, provided that You + meet the following conditions: + + (a) You must give any other recipients of the Work or + Derivative Works a copy of this License; and + + (b) You must cause any modified files to carry prominent notices + stating that You changed the files; and + + (c) You must retain, in the Source form of any Derivative Works + that You distribute, all copyright, patent, trademark, and + attribution notices from the Source form of the Work, + excluding those notices that do not pertain to any part of + the Derivative Works; and + + (d) If the Work includes a "NOTICE" text file as part of its + distribution, then any Derivative Works that You distribute must + include a readable copy of the attribution notices contained + within such NOTICE file, excluding those notices that do not + pertain to any part of the Derivative Works, in at least one + of the following places: within a NOTICE text file distributed + as part of the Derivative Works; within the Source form or + documentation, if provided along with the Derivative Works; or, + within a display generated by the Derivative Works, if and + wherever such third-party notices normally appear. The contents + of the NOTICE file are for informational purposes only and + do not modify the License. You may add Your own attribution + notices within Derivative Works that You distribute, alongside + or as an addendum to the NOTICE text from the Work, provided + that such additional attribution notices cannot be construed + as modifying the License. + + You may add Your own copyright statement to Your modifications and + may provide additional or different license terms and conditions + for use, reproduction, or distribution of Your modifications, or + for any such Derivative Works as a whole, provided Your use, + reproduction, and distribution of the Work otherwise complies with + the conditions stated in this License. + + 5. Submission of Contributions. Unless You explicitly state otherwise, + any Contribution intentionally submitted for inclusion in the Work + by You to the Licensor shall be under the terms and conditions of + this License, without any additional terms or conditions. + Notwithstanding the above, nothing herein shall supersede or modify + the terms of any separate license agreement you may have executed + with Licensor regarding such Contributions. + + 6. Trademarks. This License does not grant permission to use the trade + names, trademarks, service marks, or product names of the Licensor, + except as required for reasonable and customary use in describing the + origin of the Work and reproducing the content of the NOTICE file. + + 7. Disclaimer of Warranty. Unless required by applicable law or + agreed to in writing, Licensor provides the Work (and each + Contributor provides its Contributions) on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or + implied, including, without limitation, any warranties or conditions + of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A + PARTICULAR PURPOSE. You are solely responsible for determining the + appropriateness of using or redistributing the Work and assume any + risks associated with Your exercise of permissions under this License. + + 8. Limitation of Liability. In no event and under no legal theory, + whether in tort (including negligence), contract, or otherwise, + unless required by applicable law (such as deliberate and grossly + negligent acts) or agreed to in writing, shall any Contributor be + liable to You for damages, including any direct, indirect, special, + incidental, or consequential damages of any character arising as a + result of this License or out of the use or inability to use the + Work (including but not limited to damages for loss of goodwill, + work stoppage, computer failure or malfunction, or any and all + other commercial damages or losses), even if such Contributor + has been advised of the possibility of such damages. + + 9. Accepting Warranty or Additional Liability. While redistributing + the Work or Derivative Works thereof, You may choose to offer, + and charge a fee for, acceptance of support, warranty, indemnity, + or other liability obligations and/or rights consistent with this + License. However, in accepting such obligations, You may act only + on Your own behalf and on Your sole responsibility, not on behalf + of any other Contributor, and only if You agree to indemnify, + defend, and hold each Contributor harmless for any liability + incurred by, or claims asserted against, such Contributor by reason + of your accepting any such warranty or additional liability. + + END OF TERMS AND CONDITIONS + + APPENDIX: How to apply the Apache License to your work. + + To apply the Apache License to your work, attach the following + boilerplate notice, with the fields enclosed by brackets "[]" + replaced with your own identifying information. (Don't include + the brackets!) The text should be enclosed in the appropriate + comment syntax for the file format. We also recommend that a + file or class name and description of purpose be included on the + same "printed page" as the copyright notice for easier + identification within third-party archives. + + Copyright [yyyy] [name of copyright owner] + + Licensed under the Apache License, Version 2.0 (the "License"); + you may not use this file except in compliance with the License. + You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. diff --git a/google-cloud-oracle_database-v1/README.md b/google-cloud-oracle_database-v1/README.md new file mode 100644 index 000000000000..36ec52f378cc --- /dev/null +++ b/google-cloud-oracle_database-v1/README.md @@ -0,0 +1,118 @@ +# Ruby Client for the Oracle Database@Google Cloud V1 API + +The Oracle Database@Google Cloud API provides a set of APIs to manage Oracle database services, such as Exadata and Autonomous Databases. + +The Oracle Database@Google Cloud API provides a set of APIs to manage Oracle database services, such as Exadata and Autonomous Databases. + +https://github.com/googleapis/google-cloud-ruby + +This gem is a _versioned_ client. It provides basic client classes for a +specific version of the Oracle Database@Google Cloud V1 API. Most users should consider using +the main client gem, +[google-cloud-oracle_database](https://rubygems.org/gems/google-cloud-oracle_database). +See the section below titled *Which client should I use?* for more information. + +## Installation + +``` +$ gem install google-cloud-oracle_database-v1 +``` + +## Before You Begin + +In order to use this library, you first need to go through the following steps: + +1. [Select or create a Cloud Platform project.](https://console.cloud.google.com/project) +1. [Enable billing for your project.](https://cloud.google.com/billing/docs/how-to/modify-project#enable_billing_for_a_project) +1. [Enable the API.](https://console.cloud.google.com/apis/library/oracledatabase.googleapis.com) +1. [Set up authentication.](AUTHENTICATION.md) + +## Quick Start + +```ruby +require "google/cloud/oracle_database/v1" + +client = ::Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::Client.new +request = ::Google::Cloud::OracleDatabase::V1::ListCloudExadataInfrastructuresRequest.new # (request fields as keyword arguments...) +response = client.list_cloud_exadata_infrastructures request +``` + +View the [Client Library Documentation](https://cloud.google.com/ruby/docs/reference/google-cloud-oracle_database-v1/latest) +for class and method documentation. + +See also the [Product Documentation](https://cloud.google.com/oracle/database/docs) +for general usage information. + + +## Google Cloud Samples + +To browse ready to use code samples check [Google Cloud Samples](https://cloud.google.com/docs/samples). + +## Supported Ruby Versions + +This library is supported on Ruby 2.7+. + +Google provides official support for Ruby versions that are actively supported +by Ruby Core—that is, Ruby versions that are either in normal maintenance or +in security maintenance, and not end of life. Older versions of Ruby _may_ +still work, but are unsupported and not recommended. See +https://www.ruby-lang.org/en/downloads/branches/ for details about the Ruby +support schedule. + +## Which client should I use? + +Most modern Ruby client libraries for Google APIs come in two flavors: the main +client library with a name such as `google-cloud-oracle_database`, +and lower-level _versioned_ client libraries with names such as +`google-cloud-oracle_database-v1`. +_In most cases, you should install the main client._ + +### What's the difference between the main client and a versioned client? + +A _versioned client_ provides a basic set of data types and client classes for +a _single version_ of a specific service. (That is, for a service with multiple +versions, there might be a separate versioned client for each service version.) +Most versioned clients are written and maintained by a code generator. + +The _main client_ is designed to provide you with the _recommended_ client +interfaces for the service. There will be only one main client for any given +service, even a service with multiple versions. The main client includes +factory methods for constructing the client objects we recommend for most +users. In some cases, those will be classes provided by an underlying versioned +client; in other cases, they will be handwritten higher-level client objects +with additional capabilities, convenience methods, or best practices built in. +Generally, the main client will default to a recommended service version, +although in some cases you can override this if you need to talk to a specific +service version. + +### Why would I want to use the main client? + +We recommend that most users install the main client gem for a service. You can +identify this gem as the one _without_ a version in its name, e.g. +`google-cloud-oracle_database`. +The main client is recommended because it will embody the best practices for +accessing the service, and may also provide more convenient interfaces or +tighter integration into frameworks and third-party libraries. In addition, the +documentation and samples published by Google will generally demonstrate use of +the main client. + +### Why would I want to use a versioned client? + +You can use a versioned client if you are content with a possibly lower-level +class interface, you explicitly want to avoid features provided by the main +client, or you want to access a specific service version not be covered by the +main client. You can identify versioned client gems because the service version +is part of the name, e.g. `google-cloud-oracle_database-v1`. + +### What about the google-apis- clients? + +Client library gems with names that begin with `google-apis-` are based on an +older code generation technology. They talk to a REST/JSON backend (whereas +most modern clients talk to a [gRPC](https://grpc.io/) backend) and they may +not offer the same performance, features, and ease of use provided by more +modern clients. + +The `google-apis-` clients have wide coverage across Google services, so you +might need to use one if there is no modern client available for the service. +However, if a modern client is available, we generally recommend it over the +older `google-apis-` clients. diff --git a/google-cloud-oracle_database-v1/Rakefile b/google-cloud-oracle_database-v1/Rakefile new file mode 100644 index 000000000000..ec9b36904c2e --- /dev/null +++ b/google-cloud-oracle_database-v1/Rakefile @@ -0,0 +1,169 @@ +# frozen_string_literal: true + +# Copyright 2024 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# https://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Auto-generated by gapic-generator-ruby. DO NOT EDIT! + +require "bundler/setup" +require "bundler/gem_tasks" + +require "rubocop/rake_task" +RuboCop::RakeTask.new + +require "rake/testtask" +desc "Run tests." +Rake::TestTask.new do |t| + t.libs << "test" + t.test_files = FileList["test/**/*_test.rb"] + t.warning = false +end + +desc "Runs the smoke tests." +Rake::TestTask.new :smoke_test do |t| + t.test_files = FileList["acceptance/**/*smoke_test.rb"] + t.warning = false +end + +# Acceptance tests +desc "Run the google-cloud-oracle_database-v1 acceptance tests." +task :acceptance, :project, :keyfile do |t, args| + project = args[:project] + project ||= + ENV["GOOGLE_CLOUD_TEST_PROJECT"] || + ENV["GCLOUD_TEST_PROJECT"] + keyfile = args[:keyfile] + keyfile ||= + ENV["GOOGLE_CLOUD_TEST_KEYFILE"] || + ENV["GCLOUD_TEST_KEYFILE"] + if keyfile + keyfile = File.read keyfile + else + keyfile ||= + ENV["GOOGLE_CLOUD_TEST_KEYFILE_JSON"] || + ENV["GCLOUD_TEST_KEYFILE_JSON"] + end + if project.nil? || keyfile.nil? + fail "You must provide a project and keyfile. e.g. rake acceptance[test123, /path/to/keyfile.json] or GOOGLE_CLOUD_TEST_PROJECT=test123 GOOGLE_CLOUD_TEST_KEYFILE=/path/to/keyfile.json rake acceptance" + end + require "google/cloud/oracle_database/v1/oracle_database/credentials" + ::Google::Cloud::OracleDatabase::V1::OracleDatabase::Credentials.env_vars.each do |path| + ENV[path] = nil + end + ENV["GOOGLE_CLOUD_PROJECT"] = project + ENV["GOOGLE_CLOUD_TEST_PROJECT"] = project + ENV["GOOGLE_CLOUD_KEYFILE_JSON"] = keyfile + + Rake::Task["acceptance:run"].invoke +end + +namespace :acceptance do + task :run do + if File.directory? "acceptance" + Rake::Task[:smoke_test].invoke + else + puts "The google-cloud-oracle_database-v1 gem has no acceptance tests." + end + end + + desc "Run acceptance cleanup." + task :cleanup do + end +end + +task :samples do + Rake::Task["samples:latest"].invoke +end + +namespace :samples do + task :latest do + if File.directory? "samples" + Dir.chdir "samples" do + Bundler.with_clean_env do + ENV["GOOGLE_CLOUD_SAMPLES_TEST"] = "not_master" + sh "bundle update" + sh "bundle exec rake test" + end + end + else + puts "The google-cloud-oracle_database-v1 gem has no samples to test." + end + end + + task :master do + if File.directory? "samples" + Dir.chdir "samples" do + Bundler.with_clean_env do + ENV["GOOGLE_CLOUD_SAMPLES_TEST"] = "master" + sh "bundle update" + sh "bundle exec rake test" + end + end + else + puts "The google-cloud-oracle_database-v1 gem has no samples to test." + end + end +end + +require "yard" +require "yard/rake/yardoc_task" +YARD::Rake::YardocTask.new do |y| + y.options << "--fail-on-warning" +end + +desc "Run yard-doctest example tests." +task :doctest do + puts "The google-cloud-oracle_database-v1 gem does not have doctest tests." +end + +desc "Run the CI build" +task :ci do + header "BUILDING google-cloud-oracle_database-v1" + header "google-cloud-oracle_database-v1 rubocop", "*" + Rake::Task[:rubocop].invoke + header "google-cloud-oracle_database-v1 yard", "*" + Rake::Task[:yard].invoke + header "google-cloud-oracle_database-v1 test", "*" + Rake::Task[:test].invoke +end + +namespace :ci do + desc "Run the CI build, with smoke tests." + task :smoke_test do + Rake::Task[:ci].invoke + header "google-cloud-oracle_database-v1 smoke_test", "*" + Rake::Task[:smoke_test].invoke + end + desc "Run the CI build, with acceptance tests." + task :acceptance do + Rake::Task[:ci].invoke + header "google-cloud-oracle_database-v1 acceptance", "*" + Rake::Task[:acceptance].invoke + end + task :a do + # This is a handy shortcut to save typing + Rake::Task["ci:acceptance"].invoke + end +end + +task default: :test + +def header str, token = "#" + line_length = str.length + 8 + puts "" + puts token * line_length + puts "#{token * 3} #{str} #{token * 3}" + puts token * line_length + puts "" +end diff --git a/google-cloud-oracle_database-v1/gapic_metadata.json b/google-cloud-oracle_database-v1/gapic_metadata.json new file mode 100644 index 000000000000..f29009ec1d27 --- /dev/null +++ b/google-cloud-oracle_database-v1/gapic_metadata.json @@ -0,0 +1,128 @@ +{ + "schema": "1.0", + "comment": "This file maps proto services/RPCs to the corresponding library clients/methods", + "language": "ruby", + "protoPackage": "google.cloud.oracledatabase.v1", + "libraryPackage": "::Google::Cloud::OracleDatabase::V1", + "services": { + "OracleDatabase": { + "clients": { + "grpc": { + "libraryClient": "::Google::Cloud::OracleDatabase::V1::OracleDatabase::Client", + "rpcs": { + "ListCloudExadataInfrastructures": { + "methods": [ + "list_cloud_exadata_infrastructures" + ] + }, + "GetCloudExadataInfrastructure": { + "methods": [ + "get_cloud_exadata_infrastructure" + ] + }, + "CreateCloudExadataInfrastructure": { + "methods": [ + "create_cloud_exadata_infrastructure" + ] + }, + "DeleteCloudExadataInfrastructure": { + "methods": [ + "delete_cloud_exadata_infrastructure" + ] + }, + "ListCloudVmClusters": { + "methods": [ + "list_cloud_vm_clusters" + ] + }, + "GetCloudVmCluster": { + "methods": [ + "get_cloud_vm_cluster" + ] + }, + "CreateCloudVmCluster": { + "methods": [ + "create_cloud_vm_cluster" + ] + }, + "DeleteCloudVmCluster": { + "methods": [ + "delete_cloud_vm_cluster" + ] + }, + "ListEntitlements": { + "methods": [ + "list_entitlements" + ] + }, + "ListDbServers": { + "methods": [ + "list_db_servers" + ] + }, + "ListDbNodes": { + "methods": [ + "list_db_nodes" + ] + }, + "ListGiVersions": { + "methods": [ + "list_gi_versions" + ] + }, + "ListDbSystemShapes": { + "methods": [ + "list_db_system_shapes" + ] + }, + "ListAutonomousDatabases": { + "methods": [ + "list_autonomous_databases" + ] + }, + "GetAutonomousDatabase": { + "methods": [ + "get_autonomous_database" + ] + }, + "CreateAutonomousDatabase": { + "methods": [ + "create_autonomous_database" + ] + }, + "DeleteAutonomousDatabase": { + "methods": [ + "delete_autonomous_database" + ] + }, + "RestoreAutonomousDatabase": { + "methods": [ + "restore_autonomous_database" + ] + }, + "GenerateAutonomousDatabaseWallet": { + "methods": [ + "generate_autonomous_database_wallet" + ] + }, + "ListAutonomousDbVersions": { + "methods": [ + "list_autonomous_db_versions" + ] + }, + "ListAutonomousDatabaseCharacterSets": { + "methods": [ + "list_autonomous_database_character_sets" + ] + }, + "ListAutonomousDatabaseBackups": { + "methods": [ + "list_autonomous_database_backups" + ] + } + } + } + } + } + } +} diff --git a/google-cloud-oracle_database-v1/google-cloud-oracle_database-v1.gemspec b/google-cloud-oracle_database-v1/google-cloud-oracle_database-v1.gemspec new file mode 100644 index 000000000000..0b629723380a --- /dev/null +++ b/google-cloud-oracle_database-v1/google-cloud-oracle_database-v1.gemspec @@ -0,0 +1,29 @@ +# -*- ruby -*- +# encoding: utf-8 + +require File.expand_path("lib/google/cloud/oracle_database/v1/version", __dir__) + +Gem::Specification.new do |gem| + gem.name = "google-cloud-oracle_database-v1" + gem.version = Google::Cloud::OracleDatabase::V1::VERSION + + gem.authors = ["Google LLC"] + gem.email = "googleapis-packages@google.com" + gem.description = "The Oracle Database@Google Cloud API provides a set of APIs to manage Oracle database services, such as Exadata and Autonomous Databases. Note that google-cloud-oracle_database-v1 is a version-specific client library. For most uses, we recommend installing the main client library google-cloud-oracle_database instead. See the readme for more details." + gem.summary = "The Oracle Database@Google Cloud API provides a set of APIs to manage Oracle database services, such as Exadata and Autonomous Databases." + gem.homepage = "https://github.com/googleapis/google-cloud-ruby" + gem.license = "Apache-2.0" + + gem.platform = Gem::Platform::RUBY + + gem.files = `git ls-files -- lib/*`.split("\n") + + `git ls-files -- proto_docs/*`.split("\n") + + ["README.md", "LICENSE.md", "AUTHENTICATION.md", ".yardopts"] + gem.require_paths = ["lib"] + + gem.required_ruby_version = ">= 2.7" + + gem.add_dependency "gapic-common", ">= 0.21.1", "< 2.a" + gem.add_dependency "google-cloud-errors", "~> 1.0" + gem.add_dependency "google-cloud-location", ">= 0.7", "< 2.a" +end diff --git a/google-cloud-oracle_database-v1/lib/google-cloud-oracle_database-v1.rb b/google-cloud-oracle_database-v1/lib/google-cloud-oracle_database-v1.rb new file mode 100644 index 000000000000..0f9424ebc5e9 --- /dev/null +++ b/google-cloud-oracle_database-v1/lib/google-cloud-oracle_database-v1.rb @@ -0,0 +1,21 @@ +# frozen_string_literal: true + +# Copyright 2024 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# https://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Auto-generated by gapic-generator-ruby. DO NOT EDIT! + +# This gem does not autoload during Bundler.require. To load this gem, +# issue explicit require statements for the packages desired, e.g.: +# require "google/cloud/oracle_database/v1" diff --git a/google-cloud-oracle_database-v1/lib/google/cloud/oracle_database/v1.rb b/google-cloud-oracle_database-v1/lib/google/cloud/oracle_database/v1.rb new file mode 100644 index 000000000000..32cd18956d27 --- /dev/null +++ b/google-cloud-oracle_database-v1/lib/google/cloud/oracle_database/v1.rb @@ -0,0 +1,40 @@ +# frozen_string_literal: true + +# Copyright 2024 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# https://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Auto-generated by gapic-generator-ruby. DO NOT EDIT! + +require "google/cloud/oracle_database/v1/oracle_database" +require "google/cloud/oracle_database/v1/version" + +module Google + module Cloud + module OracleDatabase + ## + # API client module. + # + # @example Load this package, including all its services, and instantiate a REST client + # + # require "google/cloud/oracle_database/v1" + # client = ::Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::Client.new + # + module V1 + end + end + end +end + +helper_path = ::File.join __dir__, "v1", "_helpers.rb" +require "google/cloud/oracle_database/v1/_helpers" if ::File.file? helper_path diff --git a/google-cloud-oracle_database-v1/lib/google/cloud/oracle_database/v1/bindings_override.rb b/google-cloud-oracle_database-v1/lib/google/cloud/oracle_database/v1/bindings_override.rb new file mode 100644 index 000000000000..a793434ec72a --- /dev/null +++ b/google-cloud-oracle_database-v1/lib/google/cloud/oracle_database/v1/bindings_override.rb @@ -0,0 +1,102 @@ +# frozen_string_literal: true + +# Copyright 2024 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# https://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Auto-generated by gapic-generator-ruby. DO NOT EDIT! + +require "gapic/config" + +module Google + module Cloud + module OracleDatabase + ## + # @example Loading just the REST part of this package, including all its services, and instantiating a REST client + # + # require "google/cloud/oracle_database/v1/rest" + # client = ::Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::Client.new + # + module V1 + ## + # @private + # Initialize the mixin bindings configuration + # + def self.configure + @configure ||= begin + namespace = ["Google", "Cloud", "OracleDatabase"] + parent_config = while namespace.any? + parent_name = namespace.join "::" + parent_const = const_get parent_name + break parent_const.configure if parent_const.respond_to? :configure + namespace.pop + end + + default_config = Configuration.new parent_config + default_config.bindings_override["google.cloud.location.Locations.GetLocation"] = [ + Gapic::Rest::GrpcTranscoder::HttpBinding.create_with_validation( + uri_method: :get, + uri_template: "/v1/{name}", + matches: [ + ["name", %r{^projects/[^/]+/locations/[^/]+/?$}, false] + ], + body: nil + ) + ] + default_config.bindings_override["google.cloud.location.Locations.ListLocations"] = [ + + Gapic::Rest::GrpcTranscoder::HttpBinding.create_with_validation( + uri_method: :get, + uri_template: "/v1/{name}/locations", + matches: [ + ["name", %r{^projects/[^/]+/?$}, false] + ], + body: nil + ) + ] + default_config + end + yield @configure if block_given? + @configure + end + + ## + # @private + # Configuration class for the google.cloud.oracledatabase.v1 package. + # + # This class contains common configuration for all services + # of the google.cloud.oracledatabase.v1 package. + # + # This configuration is for internal use of the client library classes, + # and it is not intended that the end-users will read or change it. + # + class Configuration + extend ::Gapic::Config + + # @private + # Overrides for http bindings for the RPC of the mixins for this package. + # Services in this package should use these when creating clients for the mixin services. + # @return [::Hash{::Symbol=>::Array<::Gapic::Rest::GrpcTranscoder::HttpBinding>}] + config_attr :bindings_override, {}, ::Hash, nil + + # @private + def initialize parent_config = nil + @parent_config = parent_config unless parent_config.nil? + + yield self if block_given? + end + end + end + end + end +end diff --git a/google-cloud-oracle_database-v1/lib/google/cloud/oracle_database/v1/oracle_database.rb b/google-cloud-oracle_database-v1/lib/google/cloud/oracle_database/v1/oracle_database.rb new file mode 100644 index 000000000000..6f77a77da4fd --- /dev/null +++ b/google-cloud-oracle_database-v1/lib/google/cloud/oracle_database/v1/oracle_database.rb @@ -0,0 +1,48 @@ +# frozen_string_literal: true + +# Copyright 2024 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# https://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Auto-generated by gapic-generator-ruby. DO NOT EDIT! + +require "gapic/config" +require "gapic/config/method" + +require "google/cloud/oracle_database/v1/version" + +require "google/cloud/oracle_database/v1/oracle_database/credentials" +require "google/cloud/oracle_database/v1/oracle_database/paths" +require "google/cloud/oracle_database/v1/oracle_database/rest" + +module Google + module Cloud + module OracleDatabase + module V1 + ## + # Service describing handlers for resources + # + # @example Load this service and instantiate a REST client + # + # require "google/cloud/oracle_database/v1/oracle_database/rest" + # client = ::Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::Client.new + # + module OracleDatabase + end + end + end + end +end + +helper_path = ::File.join __dir__, "oracle_database", "helpers.rb" +require "google/cloud/oracle_database/v1/oracle_database/helpers" if ::File.file? helper_path diff --git a/google-cloud-oracle_database-v1/lib/google/cloud/oracle_database/v1/oracle_database/credentials.rb b/google-cloud-oracle_database-v1/lib/google/cloud/oracle_database/v1/oracle_database/credentials.rb new file mode 100644 index 000000000000..e71e27ad4b81 --- /dev/null +++ b/google-cloud-oracle_database-v1/lib/google/cloud/oracle_database/v1/oracle_database/credentials.rb @@ -0,0 +1,47 @@ +# frozen_string_literal: true + +# Copyright 2024 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# https://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Auto-generated by gapic-generator-ruby. DO NOT EDIT! + +require "googleauth" + +module Google + module Cloud + module OracleDatabase + module V1 + module OracleDatabase + # Credentials for the OracleDatabase API. + class Credentials < ::Google::Auth::Credentials + self.scope = [ + "https://www.googleapis.com/auth/cloud-platform" + ] + self.env_vars = [ + "GOOGLE_CLOUD_CREDENTIALS", + "GOOGLE_CLOUD_KEYFILE", + "GCLOUD_KEYFILE", + "GOOGLE_CLOUD_CREDENTIALS_JSON", + "GOOGLE_CLOUD_KEYFILE_JSON", + "GCLOUD_KEYFILE_JSON" + ] + self.paths = [ + "~/.config/google_cloud/application_default_credentials.json" + ] + end + end + end + end + end +end diff --git a/google-cloud-oracle_database-v1/lib/google/cloud/oracle_database/v1/oracle_database/paths.rb b/google-cloud-oracle_database-v1/lib/google/cloud/oracle_database/v1/oracle_database/paths.rb new file mode 100644 index 000000000000..c9785768247a --- /dev/null +++ b/google-cloud-oracle_database-v1/lib/google/cloud/oracle_database/v1/oracle_database/paths.rb @@ -0,0 +1,124 @@ +# frozen_string_literal: true + +# Copyright 2024 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# https://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Auto-generated by gapic-generator-ruby. DO NOT EDIT! + + +module Google + module Cloud + module OracleDatabase + module V1 + module OracleDatabase + # Path helper methods for the OracleDatabase API. + module Paths + ## + # Create a fully-qualified AutonomousDatabase resource string. + # + # The resource will be in the following format: + # + # `projects/{project}/locations/{location}/autonomousDatabases/{autonomous_database}` + # + # @param project [String] + # @param location [String] + # @param autonomous_database [String] + # + # @return [::String] + def autonomous_database_path project:, location:, autonomous_database: + raise ::ArgumentError, "project cannot contain /" if project.to_s.include? "/" + raise ::ArgumentError, "location cannot contain /" if location.to_s.include? "/" + + "projects/#{project}/locations/#{location}/autonomousDatabases/#{autonomous_database}" + end + + ## + # Create a fully-qualified CloudExadataInfrastructure resource string. + # + # The resource will be in the following format: + # + # `projects/{project}/locations/{location}/cloudExadataInfrastructures/{cloud_exadata_infrastructure}` + # + # @param project [String] + # @param location [String] + # @param cloud_exadata_infrastructure [String] + # + # @return [::String] + def cloud_exadata_infrastructure_path project:, location:, cloud_exadata_infrastructure: + raise ::ArgumentError, "project cannot contain /" if project.to_s.include? "/" + raise ::ArgumentError, "location cannot contain /" if location.to_s.include? "/" + + "projects/#{project}/locations/#{location}/cloudExadataInfrastructures/#{cloud_exadata_infrastructure}" + end + + ## + # Create a fully-qualified CloudVmCluster resource string. + # + # The resource will be in the following format: + # + # `projects/{project}/locations/{location}/cloudVmClusters/{cloud_vm_cluster}` + # + # @param project [String] + # @param location [String] + # @param cloud_vm_cluster [String] + # + # @return [::String] + def cloud_vm_cluster_path project:, location:, cloud_vm_cluster: + raise ::ArgumentError, "project cannot contain /" if project.to_s.include? "/" + raise ::ArgumentError, "location cannot contain /" if location.to_s.include? "/" + + "projects/#{project}/locations/#{location}/cloudVmClusters/#{cloud_vm_cluster}" + end + + ## + # Create a fully-qualified Location resource string. + # + # The resource will be in the following format: + # + # `projects/{project}/locations/{location}` + # + # @param project [String] + # @param location [String] + # + # @return [::String] + def location_path project:, location: + raise ::ArgumentError, "project cannot contain /" if project.to_s.include? "/" + + "projects/#{project}/locations/#{location}" + end + + ## + # Create a fully-qualified Network resource string. + # + # The resource will be in the following format: + # + # `projects/{project}/global/networks/{network}` + # + # @param project [String] + # @param network [String] + # + # @return [::String] + def network_path project:, network: + raise ::ArgumentError, "project cannot contain /" if project.to_s.include? "/" + + "projects/#{project}/global/networks/#{network}" + end + + extend self + end + end + end + end + end +end diff --git a/google-cloud-oracle_database-v1/lib/google/cloud/oracle_database/v1/oracle_database/rest.rb b/google-cloud-oracle_database-v1/lib/google/cloud/oracle_database/v1/oracle_database/rest.rb new file mode 100644 index 000000000000..cc5ed785f64a --- /dev/null +++ b/google-cloud-oracle_database-v1/lib/google/cloud/oracle_database/v1/oracle_database/rest.rb @@ -0,0 +1,54 @@ +# frozen_string_literal: true + +# Copyright 2024 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# https://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Auto-generated by gapic-generator-ruby. DO NOT EDIT! + +require "gapic/rest" +require "gapic/config" +require "gapic/config/method" + +require "google/cloud/oracle_database/v1/version" +require "google/cloud/oracle_database/v1/bindings_override" + +require "google/cloud/oracle_database/v1/oracle_database/credentials" +require "google/cloud/oracle_database/v1/oracle_database/paths" +require "google/cloud/oracle_database/v1/oracle_database/rest/operations" +require "google/cloud/oracle_database/v1/oracle_database/rest/client" + +module Google + module Cloud + module OracleDatabase + module V1 + ## + # Service describing handlers for resources + # + # To load this service and instantiate a REST client: + # + # require "google/cloud/oracle_database/v1/oracle_database/rest" + # client = ::Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::Client.new + # + module OracleDatabase + # Client for the REST transport + module Rest + end + end + end + end + end +end + +helper_path = ::File.join __dir__, "rest", "helpers.rb" +require "google/cloud/oracle_database/v1/oracle_database/rest/helpers" if ::File.file? helper_path diff --git a/google-cloud-oracle_database-v1/lib/google/cloud/oracle_database/v1/oracle_database/rest/client.rb b/google-cloud-oracle_database-v1/lib/google/cloud/oracle_database/v1/oracle_database/rest/client.rb new file mode 100644 index 000000000000..ecd120e8522c --- /dev/null +++ b/google-cloud-oracle_database-v1/lib/google/cloud/oracle_database/v1/oracle_database/rest/client.rb @@ -0,0 +1,2624 @@ +# frozen_string_literal: true + +# Copyright 2024 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# https://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Auto-generated by gapic-generator-ruby. DO NOT EDIT! + +require "google/cloud/errors" +require "google/cloud/oracledatabase/v1/oracledatabase_pb" +require "google/cloud/oracle_database/v1/oracle_database/rest/service_stub" +require "google/cloud/location/rest" + +module Google + module Cloud + module OracleDatabase + module V1 + module OracleDatabase + module Rest + ## + # REST client for the OracleDatabase service. + # + # Service describing handlers for resources + # + class Client + # @private + API_VERSION = "" + + # @private + DEFAULT_ENDPOINT_TEMPLATE = "oracledatabase.$UNIVERSE_DOMAIN$" + + include Paths + + # @private + attr_reader :oracle_database_stub + + ## + # Configure the OracleDatabase Client class. + # + # See {::Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::Client::Configuration} + # for a description of the configuration fields. + # + # @example + # + # # Modify the configuration for all OracleDatabase clients + # ::Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::Client.configure do |config| + # config.timeout = 10.0 + # end + # + # @yield [config] Configure the Client client. + # @yieldparam config [Client::Configuration] + # + # @return [Client::Configuration] + # + def self.configure + @configure ||= begin + namespace = ["Google", "Cloud", "OracleDatabase", "V1"] + parent_config = while namespace.any? + parent_name = namespace.join "::" + parent_const = const_get parent_name + break parent_const.configure if parent_const.respond_to? :configure + namespace.pop + end + default_config = Client::Configuration.new parent_config + + default_config.timeout = 60.0 + + default_config.rpcs.list_cloud_exadata_infrastructures.timeout = 60.0 + default_config.rpcs.list_cloud_exadata_infrastructures.retry_policy = { + initial_delay: 1.0, max_delay: 10.0, multiplier: 1.3, retry_codes: [8, 14, 13, 4] + } + + default_config.rpcs.get_cloud_exadata_infrastructure.timeout = 60.0 + default_config.rpcs.get_cloud_exadata_infrastructure.retry_policy = { + initial_delay: 1.0, max_delay: 10.0, multiplier: 1.3, retry_codes: [8, 14, 13, 4] + } + + default_config.rpcs.list_cloud_vm_clusters.timeout = 60.0 + default_config.rpcs.list_cloud_vm_clusters.retry_policy = { + initial_delay: 1.0, max_delay: 10.0, multiplier: 1.3, retry_codes: [8, 14, 13, 4] + } + + default_config.rpcs.get_cloud_vm_cluster.timeout = 60.0 + default_config.rpcs.get_cloud_vm_cluster.retry_policy = { + initial_delay: 1.0, max_delay: 10.0, multiplier: 1.3, retry_codes: [8, 14, 13, 4] + } + + default_config.rpcs.list_entitlements.timeout = 60.0 + default_config.rpcs.list_entitlements.retry_policy = { + initial_delay: 1.0, max_delay: 10.0, multiplier: 1.3, retry_codes: [8, 14, 13, 4] + } + + default_config.rpcs.list_db_servers.timeout = 60.0 + default_config.rpcs.list_db_servers.retry_policy = { + initial_delay: 1.0, max_delay: 10.0, multiplier: 1.3, retry_codes: [8, 14, 13, 4] + } + + default_config.rpcs.list_db_nodes.timeout = 60.0 + default_config.rpcs.list_db_nodes.retry_policy = { + initial_delay: 1.0, max_delay: 10.0, multiplier: 1.3, retry_codes: [8, 14, 13, 4] + } + + default_config.rpcs.list_gi_versions.timeout = 60.0 + default_config.rpcs.list_gi_versions.retry_policy = { + initial_delay: 1.0, max_delay: 10.0, multiplier: 1.3, retry_codes: [8, 14, 13, 4] + } + + default_config.rpcs.list_db_system_shapes.timeout = 60.0 + default_config.rpcs.list_db_system_shapes.retry_policy = { + initial_delay: 1.0, max_delay: 10.0, multiplier: 1.3, retry_codes: [8, 14, 13, 4] + } + + default_config.rpcs.list_autonomous_databases.timeout = 60.0 + default_config.rpcs.list_autonomous_databases.retry_policy = { + initial_delay: 1.0, max_delay: 10.0, multiplier: 1.3, retry_codes: [8, 14, 13, 4] + } + + default_config.rpcs.get_autonomous_database.timeout = 60.0 + default_config.rpcs.get_autonomous_database.retry_policy = { + initial_delay: 1.0, max_delay: 10.0, multiplier: 1.3, retry_codes: [8, 14, 13, 4] + } + + default_config.rpcs.list_autonomous_db_versions.timeout = 60.0 + default_config.rpcs.list_autonomous_db_versions.retry_policy = { + initial_delay: 1.0, max_delay: 10.0, multiplier: 1.3, retry_codes: [8, 14, 13, 4] + } + + default_config.rpcs.list_autonomous_database_character_sets.timeout = 60.0 + default_config.rpcs.list_autonomous_database_character_sets.retry_policy = { + initial_delay: 1.0, max_delay: 10.0, multiplier: 1.3, retry_codes: [8, 14, 13, 4] + } + + default_config.rpcs.list_autonomous_database_backups.timeout = 60.0 + default_config.rpcs.list_autonomous_database_backups.retry_policy = { + initial_delay: 1.0, max_delay: 10.0, multiplier: 1.3, retry_codes: [8, 14, 13, 4] + } + + default_config + end + yield @configure if block_given? + @configure + end + + ## + # Configure the OracleDatabase Client instance. + # + # The configuration is set to the derived mode, meaning that values can be changed, + # but structural changes (adding new fields, etc.) are not allowed. Structural changes + # should be made on {Client.configure}. + # + # See {::Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::Client::Configuration} + # for a description of the configuration fields. + # + # @yield [config] Configure the Client client. + # @yieldparam config [Client::Configuration] + # + # @return [Client::Configuration] + # + def configure + yield @config if block_given? + @config + end + + ## + # The effective universe domain + # + # @return [String] + # + def universe_domain + @oracle_database_stub.universe_domain + end + + ## + # Create a new OracleDatabase REST client object. + # + # @example + # + # # Create a client using the default configuration + # client = ::Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::Client.new + # + # # Create a client using a custom configuration + # client = ::Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::Client.new do |config| + # config.timeout = 10.0 + # end + # + # @yield [config] Configure the OracleDatabase client. + # @yieldparam config [Client::Configuration] + # + def initialize + # Create the configuration object + @config = Configuration.new Client.configure + + # Yield the configuration if needed + yield @config if block_given? + + # Create credentials + credentials = @config.credentials + # Use self-signed JWT if the endpoint is unchanged from default, + # but only if the default endpoint does not have a region prefix. + enable_self_signed_jwt = @config.endpoint.nil? || + (@config.endpoint == Configuration::DEFAULT_ENDPOINT && + !@config.endpoint.split(".").first.include?("-")) + credentials ||= Credentials.default scope: @config.scope, + enable_self_signed_jwt: enable_self_signed_jwt + if credentials.is_a?(::String) || credentials.is_a?(::Hash) + credentials = Credentials.new credentials, scope: @config.scope + end + + @quota_project_id = @config.quota_project + @quota_project_id ||= credentials.quota_project_id if credentials.respond_to? :quota_project_id + + @operations_client = ::Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::Operations.new do |config| + config.credentials = credentials + config.quota_project = @quota_project_id + config.endpoint = @config.endpoint + config.universe_domain = @config.universe_domain + end + + @oracle_database_stub = ::Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::ServiceStub.new( + endpoint: @config.endpoint, + endpoint_template: DEFAULT_ENDPOINT_TEMPLATE, + universe_domain: @config.universe_domain, + credentials: credentials + ) + + @location_client = Google::Cloud::Location::Locations::Rest::Client.new do |config| + config.credentials = credentials + config.quota_project = @quota_project_id + config.endpoint = @oracle_database_stub.endpoint + config.universe_domain = @oracle_database_stub.universe_domain + config.bindings_override = @config.bindings_override + end + end + + ## + # Get the associated client for long-running operations. + # + # @return [::Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::Operations] + # + attr_reader :operations_client + + ## + # Get the associated client for mix-in of the Locations. + # + # @return [Google::Cloud::Location::Locations::Rest::Client] + # + attr_reader :location_client + + # Service calls + + ## + # Lists Exadata Infrastructures in a given project and location. + # + # @overload list_cloud_exadata_infrastructures(request, options = nil) + # Pass arguments to `list_cloud_exadata_infrastructures` via a request object, either of type + # {::Google::Cloud::OracleDatabase::V1::ListCloudExadataInfrastructuresRequest} or an equivalent Hash. + # + # @param request [::Google::Cloud::OracleDatabase::V1::ListCloudExadataInfrastructuresRequest, ::Hash] + # A request object representing the call parameters. Required. To specify no + # parameters, or to keep all the default parameter values, pass an empty Hash. + # @param options [::Gapic::CallOptions, ::Hash] + # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. + # + # @overload list_cloud_exadata_infrastructures(parent: nil, page_size: nil, page_token: nil) + # Pass arguments to `list_cloud_exadata_infrastructures` via keyword arguments. Note that at + # least one keyword argument is required. To specify no parameters, or to keep all + # the default parameter values, pass an empty Hash as a request object (see above). + # + # @param parent [::String] + # Required. The parent value for CloudExadataInfrastructure in the following + # format: projects/\\{project}/locations/\\{location}. + # @param page_size [::Integer] + # Optional. The maximum number of items to return. + # If unspecified, at most 50 Exadata infrastructures will be returned. + # The maximum value is 1000; values above 1000 will be coerced to 1000. + # @param page_token [::String] + # Optional. A token identifying a page of results the server should return. + # @yield [result, operation] Access the result along with the TransportOperation object + # @yieldparam result [::Gapic::Rest::PagedEnumerable<::Google::Cloud::OracleDatabase::V1::CloudExadataInfrastructure>] + # @yieldparam operation [::Gapic::Rest::TransportOperation] + # + # @return [::Gapic::Rest::PagedEnumerable<::Google::Cloud::OracleDatabase::V1::CloudExadataInfrastructure>] + # + # @raise [::Google::Cloud::Error] if the REST call is aborted. + # + # @example Basic example + # require "google/cloud/oracle_database/v1" + # + # # Create a client object. The client can be reused for multiple calls. + # client = Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::Client.new + # + # # Create a request. To set request fields, pass in keyword arguments. + # request = Google::Cloud::OracleDatabase::V1::ListCloudExadataInfrastructuresRequest.new + # + # # Call the list_cloud_exadata_infrastructures method. + # result = client.list_cloud_exadata_infrastructures request + # + # # The returned object is of type Gapic::PagedEnumerable. You can iterate + # # over elements, and API calls will be issued to fetch pages as needed. + # result.each do |item| + # # Each element is of type ::Google::Cloud::OracleDatabase::V1::CloudExadataInfrastructure. + # p item + # end + # + def list_cloud_exadata_infrastructures request, options = nil + raise ::ArgumentError, "request must be provided" if request.nil? + + request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::OracleDatabase::V1::ListCloudExadataInfrastructuresRequest + + # Converts hash and nil to an options object + options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h + + # Customize the options with defaults + call_metadata = @config.rpcs.list_cloud_exadata_infrastructures.metadata.to_h + + # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers + call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ + lib_name: @config.lib_name, lib_version: @config.lib_version, + gapic_version: ::Google::Cloud::OracleDatabase::V1::VERSION, + transports_version_send: [:rest] + + call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? + call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id + + options.apply_defaults timeout: @config.rpcs.list_cloud_exadata_infrastructures.timeout, + metadata: call_metadata, + retry_policy: @config.rpcs.list_cloud_exadata_infrastructures.retry_policy + + options.apply_defaults timeout: @config.timeout, + metadata: @config.metadata, + retry_policy: @config.retry_policy + + @oracle_database_stub.list_cloud_exadata_infrastructures request, options do |result, operation| + result = ::Gapic::Rest::PagedEnumerable.new @oracle_database_stub, :list_cloud_exadata_infrastructures, "cloud_exadata_infrastructures", request, result, options + yield result, operation if block_given? + return result + end + rescue ::Gapic::Rest::Error => e + raise ::Google::Cloud::Error.from_error(e) + end + + ## + # Gets details of a single Exadata Infrastructure. + # + # @overload get_cloud_exadata_infrastructure(request, options = nil) + # Pass arguments to `get_cloud_exadata_infrastructure` via a request object, either of type + # {::Google::Cloud::OracleDatabase::V1::GetCloudExadataInfrastructureRequest} or an equivalent Hash. + # + # @param request [::Google::Cloud::OracleDatabase::V1::GetCloudExadataInfrastructureRequest, ::Hash] + # A request object representing the call parameters. Required. To specify no + # parameters, or to keep all the default parameter values, pass an empty Hash. + # @param options [::Gapic::CallOptions, ::Hash] + # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. + # + # @overload get_cloud_exadata_infrastructure(name: nil) + # Pass arguments to `get_cloud_exadata_infrastructure` via keyword arguments. Note that at + # least one keyword argument is required. To specify no parameters, or to keep all + # the default parameter values, pass an empty Hash as a request object (see above). + # + # @param name [::String] + # Required. The name of the Cloud Exadata Infrastructure in the following + # format: + # projects/\\{project}/locations/\\{location}/cloudExadataInfrastructures/\\{cloud_exadata_infrastructure}. + # @yield [result, operation] Access the result along with the TransportOperation object + # @yieldparam result [::Google::Cloud::OracleDatabase::V1::CloudExadataInfrastructure] + # @yieldparam operation [::Gapic::Rest::TransportOperation] + # + # @return [::Google::Cloud::OracleDatabase::V1::CloudExadataInfrastructure] + # + # @raise [::Google::Cloud::Error] if the REST call is aborted. + # + # @example Basic example + # require "google/cloud/oracle_database/v1" + # + # # Create a client object. The client can be reused for multiple calls. + # client = Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::Client.new + # + # # Create a request. To set request fields, pass in keyword arguments. + # request = Google::Cloud::OracleDatabase::V1::GetCloudExadataInfrastructureRequest.new + # + # # Call the get_cloud_exadata_infrastructure method. + # result = client.get_cloud_exadata_infrastructure request + # + # # The returned object is of type Google::Cloud::OracleDatabase::V1::CloudExadataInfrastructure. + # p result + # + def get_cloud_exadata_infrastructure request, options = nil + raise ::ArgumentError, "request must be provided" if request.nil? + + request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::OracleDatabase::V1::GetCloudExadataInfrastructureRequest + + # Converts hash and nil to an options object + options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h + + # Customize the options with defaults + call_metadata = @config.rpcs.get_cloud_exadata_infrastructure.metadata.to_h + + # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers + call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ + lib_name: @config.lib_name, lib_version: @config.lib_version, + gapic_version: ::Google::Cloud::OracleDatabase::V1::VERSION, + transports_version_send: [:rest] + + call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? + call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id + + options.apply_defaults timeout: @config.rpcs.get_cloud_exadata_infrastructure.timeout, + metadata: call_metadata, + retry_policy: @config.rpcs.get_cloud_exadata_infrastructure.retry_policy + + options.apply_defaults timeout: @config.timeout, + metadata: @config.metadata, + retry_policy: @config.retry_policy + + @oracle_database_stub.get_cloud_exadata_infrastructure request, options do |result, operation| + yield result, operation if block_given? + return result + end + rescue ::Gapic::Rest::Error => e + raise ::Google::Cloud::Error.from_error(e) + end + + ## + # Creates a new Exadata Infrastructure in a given project and location. + # + # @overload create_cloud_exadata_infrastructure(request, options = nil) + # Pass arguments to `create_cloud_exadata_infrastructure` via a request object, either of type + # {::Google::Cloud::OracleDatabase::V1::CreateCloudExadataInfrastructureRequest} or an equivalent Hash. + # + # @param request [::Google::Cloud::OracleDatabase::V1::CreateCloudExadataInfrastructureRequest, ::Hash] + # A request object representing the call parameters. Required. To specify no + # parameters, or to keep all the default parameter values, pass an empty Hash. + # @param options [::Gapic::CallOptions, ::Hash] + # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. + # + # @overload create_cloud_exadata_infrastructure(parent: nil, cloud_exadata_infrastructure_id: nil, cloud_exadata_infrastructure: nil, request_id: nil) + # Pass arguments to `create_cloud_exadata_infrastructure` via keyword arguments. Note that at + # least one keyword argument is required. To specify no parameters, or to keep all + # the default parameter values, pass an empty Hash as a request object (see above). + # + # @param parent [::String] + # Required. The parent value for CloudExadataInfrastructure in the following + # format: projects/\\{project}/locations/\\{location}. + # @param cloud_exadata_infrastructure_id [::String] + # Required. The ID of the Exadata Infrastructure to create. This value is + # restricted to (^[a-z]([a-z0-9-]\\{0,61}[a-z0-9])?$) and must be a maximum of + # 63 characters in length. The value must start with a letter and end with a + # letter or a number. + # @param cloud_exadata_infrastructure [::Google::Cloud::OracleDatabase::V1::CloudExadataInfrastructure, ::Hash] + # Required. Details of the Exadata Infrastructure instance to create. + # @param request_id [::String] + # Optional. An optional ID to identify the request. This value is used to + # identify duplicate requests. If you make a request with the same request ID + # and the original request is still in progress or completed, the server + # ignores the second request. This prevents clients from + # accidentally creating duplicate commitments. + # + # The request ID must be a valid UUID with the exception that zero UUID is + # not supported (00000000-0000-0000-0000-000000000000). + # @yield [result, operation] Access the result along with the TransportOperation object + # @yieldparam result [::Gapic::Operation] + # @yieldparam operation [::Gapic::Rest::TransportOperation] + # + # @return [::Gapic::Operation] + # + # @raise [::Google::Cloud::Error] if the REST call is aborted. + # + # @example Basic example + # require "google/cloud/oracle_database/v1" + # + # # Create a client object. The client can be reused for multiple calls. + # client = Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::Client.new + # + # # Create a request. To set request fields, pass in keyword arguments. + # request = Google::Cloud::OracleDatabase::V1::CreateCloudExadataInfrastructureRequest.new + # + # # Call the create_cloud_exadata_infrastructure method. + # result = client.create_cloud_exadata_infrastructure request + # + # # The returned object is of type Gapic::Operation. You can use it to + # # check the status of an operation, cancel it, or wait for results. + # # Here is how to wait for a response. + # result.wait_until_done! timeout: 60 + # if result.response? + # p result.response + # else + # puts "No response received." + # end + # + def create_cloud_exadata_infrastructure request, options = nil + raise ::ArgumentError, "request must be provided" if request.nil? + + request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::OracleDatabase::V1::CreateCloudExadataInfrastructureRequest + + # Converts hash and nil to an options object + options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h + + # Customize the options with defaults + call_metadata = @config.rpcs.create_cloud_exadata_infrastructure.metadata.to_h + + # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers + call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ + lib_name: @config.lib_name, lib_version: @config.lib_version, + gapic_version: ::Google::Cloud::OracleDatabase::V1::VERSION, + transports_version_send: [:rest] + + call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? + call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id + + options.apply_defaults timeout: @config.rpcs.create_cloud_exadata_infrastructure.timeout, + metadata: call_metadata, + retry_policy: @config.rpcs.create_cloud_exadata_infrastructure.retry_policy + + options.apply_defaults timeout: @config.timeout, + metadata: @config.metadata, + retry_policy: @config.retry_policy + + @oracle_database_stub.create_cloud_exadata_infrastructure request, options do |result, operation| + result = ::Gapic::Operation.new result, @operations_client, options: options + yield result, operation if block_given? + return result + end + rescue ::Gapic::Rest::Error => e + raise ::Google::Cloud::Error.from_error(e) + end + + ## + # Deletes a single Exadata Infrastructure. + # + # @overload delete_cloud_exadata_infrastructure(request, options = nil) + # Pass arguments to `delete_cloud_exadata_infrastructure` via a request object, either of type + # {::Google::Cloud::OracleDatabase::V1::DeleteCloudExadataInfrastructureRequest} or an equivalent Hash. + # + # @param request [::Google::Cloud::OracleDatabase::V1::DeleteCloudExadataInfrastructureRequest, ::Hash] + # A request object representing the call parameters. Required. To specify no + # parameters, or to keep all the default parameter values, pass an empty Hash. + # @param options [::Gapic::CallOptions, ::Hash] + # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. + # + # @overload delete_cloud_exadata_infrastructure(name: nil, request_id: nil, force: nil) + # Pass arguments to `delete_cloud_exadata_infrastructure` via keyword arguments. Note that at + # least one keyword argument is required. To specify no parameters, or to keep all + # the default parameter values, pass an empty Hash as a request object (see above). + # + # @param name [::String] + # Required. The name of the Cloud Exadata Infrastructure in the following + # format: + # projects/\\{project}/locations/\\{location}/cloudExadataInfrastructures/\\{cloud_exadata_infrastructure}. + # @param request_id [::String] + # Optional. An optional ID to identify the request. This value is used to + # identify duplicate requests. If you make a request with the same request ID + # and the original request is still in progress or completed, the server + # ignores the second request. This prevents clients from + # accidentally creating duplicate commitments. + # + # The request ID must be a valid UUID with the exception that zero UUID is + # not supported (00000000-0000-0000-0000-000000000000). + # @param force [::Boolean] + # Optional. If set to true, all VM clusters for this Exadata Infrastructure + # will be deleted. An Exadata Infrastructure can only be deleted once all its + # VM clusters have been deleted. + # @yield [result, operation] Access the result along with the TransportOperation object + # @yieldparam result [::Gapic::Operation] + # @yieldparam operation [::Gapic::Rest::TransportOperation] + # + # @return [::Gapic::Operation] + # + # @raise [::Google::Cloud::Error] if the REST call is aborted. + # + # @example Basic example + # require "google/cloud/oracle_database/v1" + # + # # Create a client object. The client can be reused for multiple calls. + # client = Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::Client.new + # + # # Create a request. To set request fields, pass in keyword arguments. + # request = Google::Cloud::OracleDatabase::V1::DeleteCloudExadataInfrastructureRequest.new + # + # # Call the delete_cloud_exadata_infrastructure method. + # result = client.delete_cloud_exadata_infrastructure request + # + # # The returned object is of type Gapic::Operation. You can use it to + # # check the status of an operation, cancel it, or wait for results. + # # Here is how to wait for a response. + # result.wait_until_done! timeout: 60 + # if result.response? + # p result.response + # else + # puts "No response received." + # end + # + def delete_cloud_exadata_infrastructure request, options = nil + raise ::ArgumentError, "request must be provided" if request.nil? + + request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::OracleDatabase::V1::DeleteCloudExadataInfrastructureRequest + + # Converts hash and nil to an options object + options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h + + # Customize the options with defaults + call_metadata = @config.rpcs.delete_cloud_exadata_infrastructure.metadata.to_h + + # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers + call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ + lib_name: @config.lib_name, lib_version: @config.lib_version, + gapic_version: ::Google::Cloud::OracleDatabase::V1::VERSION, + transports_version_send: [:rest] + + call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? + call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id + + options.apply_defaults timeout: @config.rpcs.delete_cloud_exadata_infrastructure.timeout, + metadata: call_metadata, + retry_policy: @config.rpcs.delete_cloud_exadata_infrastructure.retry_policy + + options.apply_defaults timeout: @config.timeout, + metadata: @config.metadata, + retry_policy: @config.retry_policy + + @oracle_database_stub.delete_cloud_exadata_infrastructure request, options do |result, operation| + result = ::Gapic::Operation.new result, @operations_client, options: options + yield result, operation if block_given? + return result + end + rescue ::Gapic::Rest::Error => e + raise ::Google::Cloud::Error.from_error(e) + end + + ## + # Lists the VM Clusters in a given project and location. + # + # @overload list_cloud_vm_clusters(request, options = nil) + # Pass arguments to `list_cloud_vm_clusters` via a request object, either of type + # {::Google::Cloud::OracleDatabase::V1::ListCloudVmClustersRequest} or an equivalent Hash. + # + # @param request [::Google::Cloud::OracleDatabase::V1::ListCloudVmClustersRequest, ::Hash] + # A request object representing the call parameters. Required. To specify no + # parameters, or to keep all the default parameter values, pass an empty Hash. + # @param options [::Gapic::CallOptions, ::Hash] + # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. + # + # @overload list_cloud_vm_clusters(parent: nil, page_size: nil, page_token: nil, filter: nil) + # Pass arguments to `list_cloud_vm_clusters` via keyword arguments. Note that at + # least one keyword argument is required. To specify no parameters, or to keep all + # the default parameter values, pass an empty Hash as a request object (see above). + # + # @param parent [::String] + # Required. The name of the parent in the following format: + # projects/\\{project}/locations/\\{location}. + # @param page_size [::Integer] + # Optional. The number of VM clusters to return. + # If unspecified, at most 50 VM clusters will be returned. + # The maximum value is 1,000. + # @param page_token [::String] + # Optional. A token identifying the page of results the server returns. + # @param filter [::String] + # Optional. An expression for filtering the results of the request. + # @yield [result, operation] Access the result along with the TransportOperation object + # @yieldparam result [::Gapic::Rest::PagedEnumerable<::Google::Cloud::OracleDatabase::V1::CloudVmCluster>] + # @yieldparam operation [::Gapic::Rest::TransportOperation] + # + # @return [::Gapic::Rest::PagedEnumerable<::Google::Cloud::OracleDatabase::V1::CloudVmCluster>] + # + # @raise [::Google::Cloud::Error] if the REST call is aborted. + # + # @example Basic example + # require "google/cloud/oracle_database/v1" + # + # # Create a client object. The client can be reused for multiple calls. + # client = Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::Client.new + # + # # Create a request. To set request fields, pass in keyword arguments. + # request = Google::Cloud::OracleDatabase::V1::ListCloudVmClustersRequest.new + # + # # Call the list_cloud_vm_clusters method. + # result = client.list_cloud_vm_clusters request + # + # # The returned object is of type Gapic::PagedEnumerable. You can iterate + # # over elements, and API calls will be issued to fetch pages as needed. + # result.each do |item| + # # Each element is of type ::Google::Cloud::OracleDatabase::V1::CloudVmCluster. + # p item + # end + # + def list_cloud_vm_clusters request, options = nil + raise ::ArgumentError, "request must be provided" if request.nil? + + request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::OracleDatabase::V1::ListCloudVmClustersRequest + + # Converts hash and nil to an options object + options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h + + # Customize the options with defaults + call_metadata = @config.rpcs.list_cloud_vm_clusters.metadata.to_h + + # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers + call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ + lib_name: @config.lib_name, lib_version: @config.lib_version, + gapic_version: ::Google::Cloud::OracleDatabase::V1::VERSION, + transports_version_send: [:rest] + + call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? + call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id + + options.apply_defaults timeout: @config.rpcs.list_cloud_vm_clusters.timeout, + metadata: call_metadata, + retry_policy: @config.rpcs.list_cloud_vm_clusters.retry_policy + + options.apply_defaults timeout: @config.timeout, + metadata: @config.metadata, + retry_policy: @config.retry_policy + + @oracle_database_stub.list_cloud_vm_clusters request, options do |result, operation| + result = ::Gapic::Rest::PagedEnumerable.new @oracle_database_stub, :list_cloud_vm_clusters, "cloud_vm_clusters", request, result, options + yield result, operation if block_given? + return result + end + rescue ::Gapic::Rest::Error => e + raise ::Google::Cloud::Error.from_error(e) + end + + ## + # Gets details of a single VM Cluster. + # + # @overload get_cloud_vm_cluster(request, options = nil) + # Pass arguments to `get_cloud_vm_cluster` via a request object, either of type + # {::Google::Cloud::OracleDatabase::V1::GetCloudVmClusterRequest} or an equivalent Hash. + # + # @param request [::Google::Cloud::OracleDatabase::V1::GetCloudVmClusterRequest, ::Hash] + # A request object representing the call parameters. Required. To specify no + # parameters, or to keep all the default parameter values, pass an empty Hash. + # @param options [::Gapic::CallOptions, ::Hash] + # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. + # + # @overload get_cloud_vm_cluster(name: nil) + # Pass arguments to `get_cloud_vm_cluster` via keyword arguments. Note that at + # least one keyword argument is required. To specify no parameters, or to keep all + # the default parameter values, pass an empty Hash as a request object (see above). + # + # @param name [::String] + # Required. The name of the Cloud VM Cluster in the following format: + # projects/\\{project}/locations/\\{location}/cloudVmClusters/\\{cloud_vm_cluster}. + # @yield [result, operation] Access the result along with the TransportOperation object + # @yieldparam result [::Google::Cloud::OracleDatabase::V1::CloudVmCluster] + # @yieldparam operation [::Gapic::Rest::TransportOperation] + # + # @return [::Google::Cloud::OracleDatabase::V1::CloudVmCluster] + # + # @raise [::Google::Cloud::Error] if the REST call is aborted. + # + # @example Basic example + # require "google/cloud/oracle_database/v1" + # + # # Create a client object. The client can be reused for multiple calls. + # client = Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::Client.new + # + # # Create a request. To set request fields, pass in keyword arguments. + # request = Google::Cloud::OracleDatabase::V1::GetCloudVmClusterRequest.new + # + # # Call the get_cloud_vm_cluster method. + # result = client.get_cloud_vm_cluster request + # + # # The returned object is of type Google::Cloud::OracleDatabase::V1::CloudVmCluster. + # p result + # + def get_cloud_vm_cluster request, options = nil + raise ::ArgumentError, "request must be provided" if request.nil? + + request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::OracleDatabase::V1::GetCloudVmClusterRequest + + # Converts hash and nil to an options object + options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h + + # Customize the options with defaults + call_metadata = @config.rpcs.get_cloud_vm_cluster.metadata.to_h + + # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers + call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ + lib_name: @config.lib_name, lib_version: @config.lib_version, + gapic_version: ::Google::Cloud::OracleDatabase::V1::VERSION, + transports_version_send: [:rest] + + call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? + call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id + + options.apply_defaults timeout: @config.rpcs.get_cloud_vm_cluster.timeout, + metadata: call_metadata, + retry_policy: @config.rpcs.get_cloud_vm_cluster.retry_policy + + options.apply_defaults timeout: @config.timeout, + metadata: @config.metadata, + retry_policy: @config.retry_policy + + @oracle_database_stub.get_cloud_vm_cluster request, options do |result, operation| + yield result, operation if block_given? + return result + end + rescue ::Gapic::Rest::Error => e + raise ::Google::Cloud::Error.from_error(e) + end + + ## + # Creates a new VM Cluster in a given project and location. + # + # @overload create_cloud_vm_cluster(request, options = nil) + # Pass arguments to `create_cloud_vm_cluster` via a request object, either of type + # {::Google::Cloud::OracleDatabase::V1::CreateCloudVmClusterRequest} or an equivalent Hash. + # + # @param request [::Google::Cloud::OracleDatabase::V1::CreateCloudVmClusterRequest, ::Hash] + # A request object representing the call parameters. Required. To specify no + # parameters, or to keep all the default parameter values, pass an empty Hash. + # @param options [::Gapic::CallOptions, ::Hash] + # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. + # + # @overload create_cloud_vm_cluster(parent: nil, cloud_vm_cluster_id: nil, cloud_vm_cluster: nil, request_id: nil) + # Pass arguments to `create_cloud_vm_cluster` via keyword arguments. Note that at + # least one keyword argument is required. To specify no parameters, or to keep all + # the default parameter values, pass an empty Hash as a request object (see above). + # + # @param parent [::String] + # Required. The name of the parent in the following format: + # projects/\\{project}/locations/\\{location}. + # @param cloud_vm_cluster_id [::String] + # Required. The ID of the VM Cluster to create. This value is restricted + # to (^[a-z]([a-z0-9-]\\{0,61}[a-z0-9])?$) and must be a maximum of 63 + # characters in length. The value must start with a letter and end with + # a letter or a number. + # @param cloud_vm_cluster [::Google::Cloud::OracleDatabase::V1::CloudVmCluster, ::Hash] + # Required. The resource being created + # @param request_id [::String] + # Optional. An optional ID to identify the request. This value is used to + # identify duplicate requests. If you make a request with the same request ID + # and the original request is still in progress or completed, the server + # ignores the second request. This prevents clients from + # accidentally creating duplicate commitments. + # + # The request ID must be a valid UUID with the exception that zero UUID is + # not supported (00000000-0000-0000-0000-000000000000). + # @yield [result, operation] Access the result along with the TransportOperation object + # @yieldparam result [::Gapic::Operation] + # @yieldparam operation [::Gapic::Rest::TransportOperation] + # + # @return [::Gapic::Operation] + # + # @raise [::Google::Cloud::Error] if the REST call is aborted. + # + # @example Basic example + # require "google/cloud/oracle_database/v1" + # + # # Create a client object. The client can be reused for multiple calls. + # client = Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::Client.new + # + # # Create a request. To set request fields, pass in keyword arguments. + # request = Google::Cloud::OracleDatabase::V1::CreateCloudVmClusterRequest.new + # + # # Call the create_cloud_vm_cluster method. + # result = client.create_cloud_vm_cluster request + # + # # The returned object is of type Gapic::Operation. You can use it to + # # check the status of an operation, cancel it, or wait for results. + # # Here is how to wait for a response. + # result.wait_until_done! timeout: 60 + # if result.response? + # p result.response + # else + # puts "No response received." + # end + # + def create_cloud_vm_cluster request, options = nil + raise ::ArgumentError, "request must be provided" if request.nil? + + request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::OracleDatabase::V1::CreateCloudVmClusterRequest + + # Converts hash and nil to an options object + options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h + + # Customize the options with defaults + call_metadata = @config.rpcs.create_cloud_vm_cluster.metadata.to_h + + # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers + call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ + lib_name: @config.lib_name, lib_version: @config.lib_version, + gapic_version: ::Google::Cloud::OracleDatabase::V1::VERSION, + transports_version_send: [:rest] + + call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? + call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id + + options.apply_defaults timeout: @config.rpcs.create_cloud_vm_cluster.timeout, + metadata: call_metadata, + retry_policy: @config.rpcs.create_cloud_vm_cluster.retry_policy + + options.apply_defaults timeout: @config.timeout, + metadata: @config.metadata, + retry_policy: @config.retry_policy + + @oracle_database_stub.create_cloud_vm_cluster request, options do |result, operation| + result = ::Gapic::Operation.new result, @operations_client, options: options + yield result, operation if block_given? + return result + end + rescue ::Gapic::Rest::Error => e + raise ::Google::Cloud::Error.from_error(e) + end + + ## + # Deletes a single VM Cluster. + # + # @overload delete_cloud_vm_cluster(request, options = nil) + # Pass arguments to `delete_cloud_vm_cluster` via a request object, either of type + # {::Google::Cloud::OracleDatabase::V1::DeleteCloudVmClusterRequest} or an equivalent Hash. + # + # @param request [::Google::Cloud::OracleDatabase::V1::DeleteCloudVmClusterRequest, ::Hash] + # A request object representing the call parameters. Required. To specify no + # parameters, or to keep all the default parameter values, pass an empty Hash. + # @param options [::Gapic::CallOptions, ::Hash] + # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. + # + # @overload delete_cloud_vm_cluster(name: nil, request_id: nil, force: nil) + # Pass arguments to `delete_cloud_vm_cluster` via keyword arguments. Note that at + # least one keyword argument is required. To specify no parameters, or to keep all + # the default parameter values, pass an empty Hash as a request object (see above). + # + # @param name [::String] + # Required. The name of the Cloud VM Cluster in the following format: + # projects/\\{project}/locations/\\{location}/cloudVmClusters/\\{cloud_vm_cluster}. + # @param request_id [::String] + # Optional. An optional ID to identify the request. This value is used to + # identify duplicate requests. If you make a request with the same request ID + # and the original request is still in progress or completed, the server + # ignores the second request. This prevents clients from + # accidentally creating duplicate commitments. + # + # The request ID must be a valid UUID with the exception that zero UUID is + # not supported (00000000-0000-0000-0000-000000000000). + # @param force [::Boolean] + # Optional. If set to true, all child resources for the VM Cluster will be + # deleted. A VM Cluster can only be deleted once all its child resources have + # been deleted. + # @yield [result, operation] Access the result along with the TransportOperation object + # @yieldparam result [::Gapic::Operation] + # @yieldparam operation [::Gapic::Rest::TransportOperation] + # + # @return [::Gapic::Operation] + # + # @raise [::Google::Cloud::Error] if the REST call is aborted. + # + # @example Basic example + # require "google/cloud/oracle_database/v1" + # + # # Create a client object. The client can be reused for multiple calls. + # client = Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::Client.new + # + # # Create a request. To set request fields, pass in keyword arguments. + # request = Google::Cloud::OracleDatabase::V1::DeleteCloudVmClusterRequest.new + # + # # Call the delete_cloud_vm_cluster method. + # result = client.delete_cloud_vm_cluster request + # + # # The returned object is of type Gapic::Operation. You can use it to + # # check the status of an operation, cancel it, or wait for results. + # # Here is how to wait for a response. + # result.wait_until_done! timeout: 60 + # if result.response? + # p result.response + # else + # puts "No response received." + # end + # + def delete_cloud_vm_cluster request, options = nil + raise ::ArgumentError, "request must be provided" if request.nil? + + request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::OracleDatabase::V1::DeleteCloudVmClusterRequest + + # Converts hash and nil to an options object + options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h + + # Customize the options with defaults + call_metadata = @config.rpcs.delete_cloud_vm_cluster.metadata.to_h + + # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers + call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ + lib_name: @config.lib_name, lib_version: @config.lib_version, + gapic_version: ::Google::Cloud::OracleDatabase::V1::VERSION, + transports_version_send: [:rest] + + call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? + call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id + + options.apply_defaults timeout: @config.rpcs.delete_cloud_vm_cluster.timeout, + metadata: call_metadata, + retry_policy: @config.rpcs.delete_cloud_vm_cluster.retry_policy + + options.apply_defaults timeout: @config.timeout, + metadata: @config.metadata, + retry_policy: @config.retry_policy + + @oracle_database_stub.delete_cloud_vm_cluster request, options do |result, operation| + result = ::Gapic::Operation.new result, @operations_client, options: options + yield result, operation if block_given? + return result + end + rescue ::Gapic::Rest::Error => e + raise ::Google::Cloud::Error.from_error(e) + end + + ## + # Lists the entitlements in a given project. + # + # @overload list_entitlements(request, options = nil) + # Pass arguments to `list_entitlements` via a request object, either of type + # {::Google::Cloud::OracleDatabase::V1::ListEntitlementsRequest} or an equivalent Hash. + # + # @param request [::Google::Cloud::OracleDatabase::V1::ListEntitlementsRequest, ::Hash] + # A request object representing the call parameters. Required. To specify no + # parameters, or to keep all the default parameter values, pass an empty Hash. + # @param options [::Gapic::CallOptions, ::Hash] + # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. + # + # @overload list_entitlements(parent: nil, page_size: nil, page_token: nil) + # Pass arguments to `list_entitlements` via keyword arguments. Note that at + # least one keyword argument is required. To specify no parameters, or to keep all + # the default parameter values, pass an empty Hash as a request object (see above). + # + # @param parent [::String] + # Required. The parent value for the entitlement in the following format: + # projects/\\{project}/locations/\\{location}. + # @param page_size [::Integer] + # Optional. The maximum number of items to return. + # If unspecified, a maximum of 50 entitlements will be returned. + # The maximum value is 1000. + # @param page_token [::String] + # Optional. A token identifying a page of results the server should return. + # @yield [result, operation] Access the result along with the TransportOperation object + # @yieldparam result [::Gapic::Rest::PagedEnumerable<::Google::Cloud::OracleDatabase::V1::Entitlement>] + # @yieldparam operation [::Gapic::Rest::TransportOperation] + # + # @return [::Gapic::Rest::PagedEnumerable<::Google::Cloud::OracleDatabase::V1::Entitlement>] + # + # @raise [::Google::Cloud::Error] if the REST call is aborted. + # + # @example Basic example + # require "google/cloud/oracle_database/v1" + # + # # Create a client object. The client can be reused for multiple calls. + # client = Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::Client.new + # + # # Create a request. To set request fields, pass in keyword arguments. + # request = Google::Cloud::OracleDatabase::V1::ListEntitlementsRequest.new + # + # # Call the list_entitlements method. + # result = client.list_entitlements request + # + # # The returned object is of type Gapic::PagedEnumerable. You can iterate + # # over elements, and API calls will be issued to fetch pages as needed. + # result.each do |item| + # # Each element is of type ::Google::Cloud::OracleDatabase::V1::Entitlement. + # p item + # end + # + def list_entitlements request, options = nil + raise ::ArgumentError, "request must be provided" if request.nil? + + request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::OracleDatabase::V1::ListEntitlementsRequest + + # Converts hash and nil to an options object + options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h + + # Customize the options with defaults + call_metadata = @config.rpcs.list_entitlements.metadata.to_h + + # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers + call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ + lib_name: @config.lib_name, lib_version: @config.lib_version, + gapic_version: ::Google::Cloud::OracleDatabase::V1::VERSION, + transports_version_send: [:rest] + + call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? + call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id + + options.apply_defaults timeout: @config.rpcs.list_entitlements.timeout, + metadata: call_metadata, + retry_policy: @config.rpcs.list_entitlements.retry_policy + + options.apply_defaults timeout: @config.timeout, + metadata: @config.metadata, + retry_policy: @config.retry_policy + + @oracle_database_stub.list_entitlements request, options do |result, operation| + result = ::Gapic::Rest::PagedEnumerable.new @oracle_database_stub, :list_entitlements, "entitlements", request, result, options + yield result, operation if block_given? + return result + end + rescue ::Gapic::Rest::Error => e + raise ::Google::Cloud::Error.from_error(e) + end + + ## + # Lists the database servers of an Exadata Infrastructure instance. + # + # @overload list_db_servers(request, options = nil) + # Pass arguments to `list_db_servers` via a request object, either of type + # {::Google::Cloud::OracleDatabase::V1::ListDbServersRequest} or an equivalent Hash. + # + # @param request [::Google::Cloud::OracleDatabase::V1::ListDbServersRequest, ::Hash] + # A request object representing the call parameters. Required. To specify no + # parameters, or to keep all the default parameter values, pass an empty Hash. + # @param options [::Gapic::CallOptions, ::Hash] + # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. + # + # @overload list_db_servers(parent: nil, page_size: nil, page_token: nil) + # Pass arguments to `list_db_servers` via keyword arguments. Note that at + # least one keyword argument is required. To specify no parameters, or to keep all + # the default parameter values, pass an empty Hash as a request object (see above). + # + # @param parent [::String] + # Required. The parent value for database server in the following format: + # projects/\\{project}/locations/\\{location}/cloudExadataInfrastructures/\\{cloudExadataInfrastructure}. + # @param page_size [::Integer] + # Optional. The maximum number of items to return. + # If unspecified, a maximum of 50 db servers will be returned. + # The maximum value is 1000; values above 1000 will be reset to 1000. + # @param page_token [::String] + # Optional. A token identifying a page of results the server should return. + # @yield [result, operation] Access the result along with the TransportOperation object + # @yieldparam result [::Gapic::Rest::PagedEnumerable<::Google::Cloud::OracleDatabase::V1::DbServer>] + # @yieldparam operation [::Gapic::Rest::TransportOperation] + # + # @return [::Gapic::Rest::PagedEnumerable<::Google::Cloud::OracleDatabase::V1::DbServer>] + # + # @raise [::Google::Cloud::Error] if the REST call is aborted. + # + # @example Basic example + # require "google/cloud/oracle_database/v1" + # + # # Create a client object. The client can be reused for multiple calls. + # client = Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::Client.new + # + # # Create a request. To set request fields, pass in keyword arguments. + # request = Google::Cloud::OracleDatabase::V1::ListDbServersRequest.new + # + # # Call the list_db_servers method. + # result = client.list_db_servers request + # + # # The returned object is of type Gapic::PagedEnumerable. You can iterate + # # over elements, and API calls will be issued to fetch pages as needed. + # result.each do |item| + # # Each element is of type ::Google::Cloud::OracleDatabase::V1::DbServer. + # p item + # end + # + def list_db_servers request, options = nil + raise ::ArgumentError, "request must be provided" if request.nil? + + request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::OracleDatabase::V1::ListDbServersRequest + + # Converts hash and nil to an options object + options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h + + # Customize the options with defaults + call_metadata = @config.rpcs.list_db_servers.metadata.to_h + + # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers + call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ + lib_name: @config.lib_name, lib_version: @config.lib_version, + gapic_version: ::Google::Cloud::OracleDatabase::V1::VERSION, + transports_version_send: [:rest] + + call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? + call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id + + options.apply_defaults timeout: @config.rpcs.list_db_servers.timeout, + metadata: call_metadata, + retry_policy: @config.rpcs.list_db_servers.retry_policy + + options.apply_defaults timeout: @config.timeout, + metadata: @config.metadata, + retry_policy: @config.retry_policy + + @oracle_database_stub.list_db_servers request, options do |result, operation| + result = ::Gapic::Rest::PagedEnumerable.new @oracle_database_stub, :list_db_servers, "db_servers", request, result, options + yield result, operation if block_given? + return result + end + rescue ::Gapic::Rest::Error => e + raise ::Google::Cloud::Error.from_error(e) + end + + ## + # Lists the database nodes of a VM Cluster. + # + # @overload list_db_nodes(request, options = nil) + # Pass arguments to `list_db_nodes` via a request object, either of type + # {::Google::Cloud::OracleDatabase::V1::ListDbNodesRequest} or an equivalent Hash. + # + # @param request [::Google::Cloud::OracleDatabase::V1::ListDbNodesRequest, ::Hash] + # A request object representing the call parameters. Required. To specify no + # parameters, or to keep all the default parameter values, pass an empty Hash. + # @param options [::Gapic::CallOptions, ::Hash] + # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. + # + # @overload list_db_nodes(parent: nil, page_size: nil, page_token: nil) + # Pass arguments to `list_db_nodes` via keyword arguments. Note that at + # least one keyword argument is required. To specify no parameters, or to keep all + # the default parameter values, pass an empty Hash as a request object (see above). + # + # @param parent [::String] + # Required. The parent value for database node in the following format: + # projects/\\{project}/locations/\\{location}/cloudVmClusters/\\{cloudVmCluster}. + # @param page_size [::Integer] + # Optional. The maximum number of items to return. + # If unspecified, at most 50 db nodes will be returned. + # The maximum value is 1000; values above 1000 will be coerced to 1000. + # @param page_token [::String] + # Optional. A token identifying a page of results the node should return. + # @yield [result, operation] Access the result along with the TransportOperation object + # @yieldparam result [::Gapic::Rest::PagedEnumerable<::Google::Cloud::OracleDatabase::V1::DbNode>] + # @yieldparam operation [::Gapic::Rest::TransportOperation] + # + # @return [::Gapic::Rest::PagedEnumerable<::Google::Cloud::OracleDatabase::V1::DbNode>] + # + # @raise [::Google::Cloud::Error] if the REST call is aborted. + # + # @example Basic example + # require "google/cloud/oracle_database/v1" + # + # # Create a client object. The client can be reused for multiple calls. + # client = Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::Client.new + # + # # Create a request. To set request fields, pass in keyword arguments. + # request = Google::Cloud::OracleDatabase::V1::ListDbNodesRequest.new + # + # # Call the list_db_nodes method. + # result = client.list_db_nodes request + # + # # The returned object is of type Gapic::PagedEnumerable. You can iterate + # # over elements, and API calls will be issued to fetch pages as needed. + # result.each do |item| + # # Each element is of type ::Google::Cloud::OracleDatabase::V1::DbNode. + # p item + # end + # + def list_db_nodes request, options = nil + raise ::ArgumentError, "request must be provided" if request.nil? + + request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::OracleDatabase::V1::ListDbNodesRequest + + # Converts hash and nil to an options object + options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h + + # Customize the options with defaults + call_metadata = @config.rpcs.list_db_nodes.metadata.to_h + + # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers + call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ + lib_name: @config.lib_name, lib_version: @config.lib_version, + gapic_version: ::Google::Cloud::OracleDatabase::V1::VERSION, + transports_version_send: [:rest] + + call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? + call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id + + options.apply_defaults timeout: @config.rpcs.list_db_nodes.timeout, + metadata: call_metadata, + retry_policy: @config.rpcs.list_db_nodes.retry_policy + + options.apply_defaults timeout: @config.timeout, + metadata: @config.metadata, + retry_policy: @config.retry_policy + + @oracle_database_stub.list_db_nodes request, options do |result, operation| + result = ::Gapic::Rest::PagedEnumerable.new @oracle_database_stub, :list_db_nodes, "db_nodes", request, result, options + yield result, operation if block_given? + return result + end + rescue ::Gapic::Rest::Error => e + raise ::Google::Cloud::Error.from_error(e) + end + + ## + # Lists all the valid Oracle Grid Infrastructure (GI) versions for the given + # project and location. + # + # @overload list_gi_versions(request, options = nil) + # Pass arguments to `list_gi_versions` via a request object, either of type + # {::Google::Cloud::OracleDatabase::V1::ListGiVersionsRequest} or an equivalent Hash. + # + # @param request [::Google::Cloud::OracleDatabase::V1::ListGiVersionsRequest, ::Hash] + # A request object representing the call parameters. Required. To specify no + # parameters, or to keep all the default parameter values, pass an empty Hash. + # @param options [::Gapic::CallOptions, ::Hash] + # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. + # + # @overload list_gi_versions(parent: nil, page_size: nil, page_token: nil) + # Pass arguments to `list_gi_versions` via keyword arguments. Note that at + # least one keyword argument is required. To specify no parameters, or to keep all + # the default parameter values, pass an empty Hash as a request object (see above). + # + # @param parent [::String] + # Required. The parent value for Grid Infrastructure Version in the following + # format: Format: projects/\\{project}/locations/\\{location}. + # @param page_size [::Integer] + # Optional. The maximum number of items to return. + # If unspecified, a maximum of 50 Oracle Grid Infrastructure (GI) versions + # will be returned. The maximum value is 1000; values above 1000 will be + # reset to 1000. + # @param page_token [::String] + # Optional. A token identifying a page of results the server should return. + # @yield [result, operation] Access the result along with the TransportOperation object + # @yieldparam result [::Gapic::Rest::PagedEnumerable<::Google::Cloud::OracleDatabase::V1::GiVersion>] + # @yieldparam operation [::Gapic::Rest::TransportOperation] + # + # @return [::Gapic::Rest::PagedEnumerable<::Google::Cloud::OracleDatabase::V1::GiVersion>] + # + # @raise [::Google::Cloud::Error] if the REST call is aborted. + # + # @example Basic example + # require "google/cloud/oracle_database/v1" + # + # # Create a client object. The client can be reused for multiple calls. + # client = Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::Client.new + # + # # Create a request. To set request fields, pass in keyword arguments. + # request = Google::Cloud::OracleDatabase::V1::ListGiVersionsRequest.new + # + # # Call the list_gi_versions method. + # result = client.list_gi_versions request + # + # # The returned object is of type Gapic::PagedEnumerable. You can iterate + # # over elements, and API calls will be issued to fetch pages as needed. + # result.each do |item| + # # Each element is of type ::Google::Cloud::OracleDatabase::V1::GiVersion. + # p item + # end + # + def list_gi_versions request, options = nil + raise ::ArgumentError, "request must be provided" if request.nil? + + request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::OracleDatabase::V1::ListGiVersionsRequest + + # Converts hash and nil to an options object + options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h + + # Customize the options with defaults + call_metadata = @config.rpcs.list_gi_versions.metadata.to_h + + # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers + call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ + lib_name: @config.lib_name, lib_version: @config.lib_version, + gapic_version: ::Google::Cloud::OracleDatabase::V1::VERSION, + transports_version_send: [:rest] + + call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? + call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id + + options.apply_defaults timeout: @config.rpcs.list_gi_versions.timeout, + metadata: call_metadata, + retry_policy: @config.rpcs.list_gi_versions.retry_policy + + options.apply_defaults timeout: @config.timeout, + metadata: @config.metadata, + retry_policy: @config.retry_policy + + @oracle_database_stub.list_gi_versions request, options do |result, operation| + result = ::Gapic::Rest::PagedEnumerable.new @oracle_database_stub, :list_gi_versions, "gi_versions", request, result, options + yield result, operation if block_given? + return result + end + rescue ::Gapic::Rest::Error => e + raise ::Google::Cloud::Error.from_error(e) + end + + ## + # Lists the database system shapes available for the project and location. + # + # @overload list_db_system_shapes(request, options = nil) + # Pass arguments to `list_db_system_shapes` via a request object, either of type + # {::Google::Cloud::OracleDatabase::V1::ListDbSystemShapesRequest} or an equivalent Hash. + # + # @param request [::Google::Cloud::OracleDatabase::V1::ListDbSystemShapesRequest, ::Hash] + # A request object representing the call parameters. Required. To specify no + # parameters, or to keep all the default parameter values, pass an empty Hash. + # @param options [::Gapic::CallOptions, ::Hash] + # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. + # + # @overload list_db_system_shapes(parent: nil, page_size: nil, page_token: nil) + # Pass arguments to `list_db_system_shapes` via keyword arguments. Note that at + # least one keyword argument is required. To specify no parameters, or to keep all + # the default parameter values, pass an empty Hash as a request object (see above). + # + # @param parent [::String] + # Required. The parent value for Database System Shapes in the following + # format: projects/\\{project}/locations/\\{location}. + # @param page_size [::Integer] + # Optional. The maximum number of items to return. + # If unspecified, at most 50 database system shapes will be returned. + # The maximum value is 1000; values above 1000 will be coerced to 1000. + # @param page_token [::String] + # Optional. A token identifying a page of results the server should return. + # @yield [result, operation] Access the result along with the TransportOperation object + # @yieldparam result [::Gapic::Rest::PagedEnumerable<::Google::Cloud::OracleDatabase::V1::DbSystemShape>] + # @yieldparam operation [::Gapic::Rest::TransportOperation] + # + # @return [::Gapic::Rest::PagedEnumerable<::Google::Cloud::OracleDatabase::V1::DbSystemShape>] + # + # @raise [::Google::Cloud::Error] if the REST call is aborted. + # + # @example Basic example + # require "google/cloud/oracle_database/v1" + # + # # Create a client object. The client can be reused for multiple calls. + # client = Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::Client.new + # + # # Create a request. To set request fields, pass in keyword arguments. + # request = Google::Cloud::OracleDatabase::V1::ListDbSystemShapesRequest.new + # + # # Call the list_db_system_shapes method. + # result = client.list_db_system_shapes request + # + # # The returned object is of type Gapic::PagedEnumerable. You can iterate + # # over elements, and API calls will be issued to fetch pages as needed. + # result.each do |item| + # # Each element is of type ::Google::Cloud::OracleDatabase::V1::DbSystemShape. + # p item + # end + # + def list_db_system_shapes request, options = nil + raise ::ArgumentError, "request must be provided" if request.nil? + + request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::OracleDatabase::V1::ListDbSystemShapesRequest + + # Converts hash and nil to an options object + options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h + + # Customize the options with defaults + call_metadata = @config.rpcs.list_db_system_shapes.metadata.to_h + + # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers + call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ + lib_name: @config.lib_name, lib_version: @config.lib_version, + gapic_version: ::Google::Cloud::OracleDatabase::V1::VERSION, + transports_version_send: [:rest] + + call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? + call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id + + options.apply_defaults timeout: @config.rpcs.list_db_system_shapes.timeout, + metadata: call_metadata, + retry_policy: @config.rpcs.list_db_system_shapes.retry_policy + + options.apply_defaults timeout: @config.timeout, + metadata: @config.metadata, + retry_policy: @config.retry_policy + + @oracle_database_stub.list_db_system_shapes request, options do |result, operation| + result = ::Gapic::Rest::PagedEnumerable.new @oracle_database_stub, :list_db_system_shapes, "db_system_shapes", request, result, options + yield result, operation if block_given? + return result + end + rescue ::Gapic::Rest::Error => e + raise ::Google::Cloud::Error.from_error(e) + end + + ## + # Lists the Autonomous Databases in a given project and location. + # + # @overload list_autonomous_databases(request, options = nil) + # Pass arguments to `list_autonomous_databases` via a request object, either of type + # {::Google::Cloud::OracleDatabase::V1::ListAutonomousDatabasesRequest} or an equivalent Hash. + # + # @param request [::Google::Cloud::OracleDatabase::V1::ListAutonomousDatabasesRequest, ::Hash] + # A request object representing the call parameters. Required. To specify no + # parameters, or to keep all the default parameter values, pass an empty Hash. + # @param options [::Gapic::CallOptions, ::Hash] + # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. + # + # @overload list_autonomous_databases(parent: nil, page_size: nil, page_token: nil, filter: nil, order_by: nil) + # Pass arguments to `list_autonomous_databases` via keyword arguments. Note that at + # least one keyword argument is required. To specify no parameters, or to keep all + # the default parameter values, pass an empty Hash as a request object (see above). + # + # @param parent [::String] + # Required. The parent value for the Autonomous Database in the following + # format: projects/\\{project}/locations/\\{location}. + # @param page_size [::Integer] + # Optional. The maximum number of items to return. + # If unspecified, at most 50 Autonomous Database will be returned. + # The maximum value is 1000; values above 1000 will be coerced to 1000. + # @param page_token [::String] + # Optional. A token identifying a page of results the server should return. + # @param filter [::String] + # Optional. An expression for filtering the results of the request. + # @param order_by [::String] + # Optional. An expression for ordering the results of the request. + # @yield [result, operation] Access the result along with the TransportOperation object + # @yieldparam result [::Gapic::Rest::PagedEnumerable<::Google::Cloud::OracleDatabase::V1::AutonomousDatabase>] + # @yieldparam operation [::Gapic::Rest::TransportOperation] + # + # @return [::Gapic::Rest::PagedEnumerable<::Google::Cloud::OracleDatabase::V1::AutonomousDatabase>] + # + # @raise [::Google::Cloud::Error] if the REST call is aborted. + # + # @example Basic example + # require "google/cloud/oracle_database/v1" + # + # # Create a client object. The client can be reused for multiple calls. + # client = Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::Client.new + # + # # Create a request. To set request fields, pass in keyword arguments. + # request = Google::Cloud::OracleDatabase::V1::ListAutonomousDatabasesRequest.new + # + # # Call the list_autonomous_databases method. + # result = client.list_autonomous_databases request + # + # # The returned object is of type Gapic::PagedEnumerable. You can iterate + # # over elements, and API calls will be issued to fetch pages as needed. + # result.each do |item| + # # Each element is of type ::Google::Cloud::OracleDatabase::V1::AutonomousDatabase. + # p item + # end + # + def list_autonomous_databases request, options = nil + raise ::ArgumentError, "request must be provided" if request.nil? + + request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::OracleDatabase::V1::ListAutonomousDatabasesRequest + + # Converts hash and nil to an options object + options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h + + # Customize the options with defaults + call_metadata = @config.rpcs.list_autonomous_databases.metadata.to_h + + # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers + call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ + lib_name: @config.lib_name, lib_version: @config.lib_version, + gapic_version: ::Google::Cloud::OracleDatabase::V1::VERSION, + transports_version_send: [:rest] + + call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? + call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id + + options.apply_defaults timeout: @config.rpcs.list_autonomous_databases.timeout, + metadata: call_metadata, + retry_policy: @config.rpcs.list_autonomous_databases.retry_policy + + options.apply_defaults timeout: @config.timeout, + metadata: @config.metadata, + retry_policy: @config.retry_policy + + @oracle_database_stub.list_autonomous_databases request, options do |result, operation| + result = ::Gapic::Rest::PagedEnumerable.new @oracle_database_stub, :list_autonomous_databases, "autonomous_databases", request, result, options + yield result, operation if block_given? + return result + end + rescue ::Gapic::Rest::Error => e + raise ::Google::Cloud::Error.from_error(e) + end + + ## + # Gets the details of a single Autonomous Database. + # + # @overload get_autonomous_database(request, options = nil) + # Pass arguments to `get_autonomous_database` via a request object, either of type + # {::Google::Cloud::OracleDatabase::V1::GetAutonomousDatabaseRequest} or an equivalent Hash. + # + # @param request [::Google::Cloud::OracleDatabase::V1::GetAutonomousDatabaseRequest, ::Hash] + # A request object representing the call parameters. Required. To specify no + # parameters, or to keep all the default parameter values, pass an empty Hash. + # @param options [::Gapic::CallOptions, ::Hash] + # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. + # + # @overload get_autonomous_database(name: nil) + # Pass arguments to `get_autonomous_database` via keyword arguments. Note that at + # least one keyword argument is required. To specify no parameters, or to keep all + # the default parameter values, pass an empty Hash as a request object (see above). + # + # @param name [::String] + # Required. The name of the Autonomous Database in the following format: + # projects/\\{project}/locations/\\{location}/autonomousDatabases/\\{autonomous_database}. + # @yield [result, operation] Access the result along with the TransportOperation object + # @yieldparam result [::Google::Cloud::OracleDatabase::V1::AutonomousDatabase] + # @yieldparam operation [::Gapic::Rest::TransportOperation] + # + # @return [::Google::Cloud::OracleDatabase::V1::AutonomousDatabase] + # + # @raise [::Google::Cloud::Error] if the REST call is aborted. + # + # @example Basic example + # require "google/cloud/oracle_database/v1" + # + # # Create a client object. The client can be reused for multiple calls. + # client = Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::Client.new + # + # # Create a request. To set request fields, pass in keyword arguments. + # request = Google::Cloud::OracleDatabase::V1::GetAutonomousDatabaseRequest.new + # + # # Call the get_autonomous_database method. + # result = client.get_autonomous_database request + # + # # The returned object is of type Google::Cloud::OracleDatabase::V1::AutonomousDatabase. + # p result + # + def get_autonomous_database request, options = nil + raise ::ArgumentError, "request must be provided" if request.nil? + + request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::OracleDatabase::V1::GetAutonomousDatabaseRequest + + # Converts hash and nil to an options object + options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h + + # Customize the options with defaults + call_metadata = @config.rpcs.get_autonomous_database.metadata.to_h + + # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers + call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ + lib_name: @config.lib_name, lib_version: @config.lib_version, + gapic_version: ::Google::Cloud::OracleDatabase::V1::VERSION, + transports_version_send: [:rest] + + call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? + call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id + + options.apply_defaults timeout: @config.rpcs.get_autonomous_database.timeout, + metadata: call_metadata, + retry_policy: @config.rpcs.get_autonomous_database.retry_policy + + options.apply_defaults timeout: @config.timeout, + metadata: @config.metadata, + retry_policy: @config.retry_policy + + @oracle_database_stub.get_autonomous_database request, options do |result, operation| + yield result, operation if block_given? + return result + end + rescue ::Gapic::Rest::Error => e + raise ::Google::Cloud::Error.from_error(e) + end + + ## + # Creates a new Autonomous Database in a given project and location. + # + # @overload create_autonomous_database(request, options = nil) + # Pass arguments to `create_autonomous_database` via a request object, either of type + # {::Google::Cloud::OracleDatabase::V1::CreateAutonomousDatabaseRequest} or an equivalent Hash. + # + # @param request [::Google::Cloud::OracleDatabase::V1::CreateAutonomousDatabaseRequest, ::Hash] + # A request object representing the call parameters. Required. To specify no + # parameters, or to keep all the default parameter values, pass an empty Hash. + # @param options [::Gapic::CallOptions, ::Hash] + # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. + # + # @overload create_autonomous_database(parent: nil, autonomous_database_id: nil, autonomous_database: nil, request_id: nil) + # Pass arguments to `create_autonomous_database` via keyword arguments. Note that at + # least one keyword argument is required. To specify no parameters, or to keep all + # the default parameter values, pass an empty Hash as a request object (see above). + # + # @param parent [::String] + # Required. The name of the parent in the following format: + # projects/\\{project}/locations/\\{location}. + # @param autonomous_database_id [::String] + # Required. The ID of the Autonomous Database to create. This value is + # restricted to (^[a-z]([a-z0-9-]\\{0,61}[a-z0-9])?$) and must be a maximum of + # 63 characters in length. The value must start with a letter and end with a + # letter or a number. + # @param autonomous_database [::Google::Cloud::OracleDatabase::V1::AutonomousDatabase, ::Hash] + # Required. The Autonomous Database being created. + # @param request_id [::String] + # Optional. An optional ID to identify the request. This value is used to + # identify duplicate requests. If you make a request with the same request ID + # and the original request is still in progress or completed, the server + # ignores the second request. This prevents clients from + # accidentally creating duplicate commitments. + # + # The request ID must be a valid UUID with the exception that zero UUID is + # not supported (00000000-0000-0000-0000-000000000000). + # @yield [result, operation] Access the result along with the TransportOperation object + # @yieldparam result [::Gapic::Operation] + # @yieldparam operation [::Gapic::Rest::TransportOperation] + # + # @return [::Gapic::Operation] + # + # @raise [::Google::Cloud::Error] if the REST call is aborted. + # + # @example Basic example + # require "google/cloud/oracle_database/v1" + # + # # Create a client object. The client can be reused for multiple calls. + # client = Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::Client.new + # + # # Create a request. To set request fields, pass in keyword arguments. + # request = Google::Cloud::OracleDatabase::V1::CreateAutonomousDatabaseRequest.new + # + # # Call the create_autonomous_database method. + # result = client.create_autonomous_database request + # + # # The returned object is of type Gapic::Operation. You can use it to + # # check the status of an operation, cancel it, or wait for results. + # # Here is how to wait for a response. + # result.wait_until_done! timeout: 60 + # if result.response? + # p result.response + # else + # puts "No response received." + # end + # + def create_autonomous_database request, options = nil + raise ::ArgumentError, "request must be provided" if request.nil? + + request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::OracleDatabase::V1::CreateAutonomousDatabaseRequest + + # Converts hash and nil to an options object + options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h + + # Customize the options with defaults + call_metadata = @config.rpcs.create_autonomous_database.metadata.to_h + + # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers + call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ + lib_name: @config.lib_name, lib_version: @config.lib_version, + gapic_version: ::Google::Cloud::OracleDatabase::V1::VERSION, + transports_version_send: [:rest] + + call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? + call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id + + options.apply_defaults timeout: @config.rpcs.create_autonomous_database.timeout, + metadata: call_metadata, + retry_policy: @config.rpcs.create_autonomous_database.retry_policy + + options.apply_defaults timeout: @config.timeout, + metadata: @config.metadata, + retry_policy: @config.retry_policy + + @oracle_database_stub.create_autonomous_database request, options do |result, operation| + result = ::Gapic::Operation.new result, @operations_client, options: options + yield result, operation if block_given? + return result + end + rescue ::Gapic::Rest::Error => e + raise ::Google::Cloud::Error.from_error(e) + end + + ## + # Deletes a single Autonomous Database. + # + # @overload delete_autonomous_database(request, options = nil) + # Pass arguments to `delete_autonomous_database` via a request object, either of type + # {::Google::Cloud::OracleDatabase::V1::DeleteAutonomousDatabaseRequest} or an equivalent Hash. + # + # @param request [::Google::Cloud::OracleDatabase::V1::DeleteAutonomousDatabaseRequest, ::Hash] + # A request object representing the call parameters. Required. To specify no + # parameters, or to keep all the default parameter values, pass an empty Hash. + # @param options [::Gapic::CallOptions, ::Hash] + # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. + # + # @overload delete_autonomous_database(name: nil, request_id: nil) + # Pass arguments to `delete_autonomous_database` via keyword arguments. Note that at + # least one keyword argument is required. To specify no parameters, or to keep all + # the default parameter values, pass an empty Hash as a request object (see above). + # + # @param name [::String] + # Required. The name of the resource in the following format: + # projects/\\{project}/locations/\\{location}/autonomousDatabases/\\{autonomous_database}. + # @param request_id [::String] + # Optional. An optional ID to identify the request. This value is used to + # identify duplicate requests. If you make a request with the same request ID + # and the original request is still in progress or completed, the server + # ignores the second request. This prevents clients from + # accidentally creating duplicate commitments. + # + # The request ID must be a valid UUID with the exception that zero UUID is + # not supported (00000000-0000-0000-0000-000000000000). + # @yield [result, operation] Access the result along with the TransportOperation object + # @yieldparam result [::Gapic::Operation] + # @yieldparam operation [::Gapic::Rest::TransportOperation] + # + # @return [::Gapic::Operation] + # + # @raise [::Google::Cloud::Error] if the REST call is aborted. + # + # @example Basic example + # require "google/cloud/oracle_database/v1" + # + # # Create a client object. The client can be reused for multiple calls. + # client = Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::Client.new + # + # # Create a request. To set request fields, pass in keyword arguments. + # request = Google::Cloud::OracleDatabase::V1::DeleteAutonomousDatabaseRequest.new + # + # # Call the delete_autonomous_database method. + # result = client.delete_autonomous_database request + # + # # The returned object is of type Gapic::Operation. You can use it to + # # check the status of an operation, cancel it, or wait for results. + # # Here is how to wait for a response. + # result.wait_until_done! timeout: 60 + # if result.response? + # p result.response + # else + # puts "No response received." + # end + # + def delete_autonomous_database request, options = nil + raise ::ArgumentError, "request must be provided" if request.nil? + + request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::OracleDatabase::V1::DeleteAutonomousDatabaseRequest + + # Converts hash and nil to an options object + options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h + + # Customize the options with defaults + call_metadata = @config.rpcs.delete_autonomous_database.metadata.to_h + + # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers + call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ + lib_name: @config.lib_name, lib_version: @config.lib_version, + gapic_version: ::Google::Cloud::OracleDatabase::V1::VERSION, + transports_version_send: [:rest] + + call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? + call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id + + options.apply_defaults timeout: @config.rpcs.delete_autonomous_database.timeout, + metadata: call_metadata, + retry_policy: @config.rpcs.delete_autonomous_database.retry_policy + + options.apply_defaults timeout: @config.timeout, + metadata: @config.metadata, + retry_policy: @config.retry_policy + + @oracle_database_stub.delete_autonomous_database request, options do |result, operation| + result = ::Gapic::Operation.new result, @operations_client, options: options + yield result, operation if block_given? + return result + end + rescue ::Gapic::Rest::Error => e + raise ::Google::Cloud::Error.from_error(e) + end + + ## + # Restores a single Autonomous Database. + # + # @overload restore_autonomous_database(request, options = nil) + # Pass arguments to `restore_autonomous_database` via a request object, either of type + # {::Google::Cloud::OracleDatabase::V1::RestoreAutonomousDatabaseRequest} or an equivalent Hash. + # + # @param request [::Google::Cloud::OracleDatabase::V1::RestoreAutonomousDatabaseRequest, ::Hash] + # A request object representing the call parameters. Required. To specify no + # parameters, or to keep all the default parameter values, pass an empty Hash. + # @param options [::Gapic::CallOptions, ::Hash] + # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. + # + # @overload restore_autonomous_database(name: nil, restore_time: nil) + # Pass arguments to `restore_autonomous_database` via keyword arguments. Note that at + # least one keyword argument is required. To specify no parameters, or to keep all + # the default parameter values, pass an empty Hash as a request object (see above). + # + # @param name [::String] + # Required. The name of the Autonomous Database in the following format: + # projects/\\{project}/locations/\\{location}/autonomousDatabases/\\{autonomous_database}. + # @param restore_time [::Google::Protobuf::Timestamp, ::Hash] + # Required. The time and date to restore the database to. + # @yield [result, operation] Access the result along with the TransportOperation object + # @yieldparam result [::Gapic::Operation] + # @yieldparam operation [::Gapic::Rest::TransportOperation] + # + # @return [::Gapic::Operation] + # + # @raise [::Google::Cloud::Error] if the REST call is aborted. + # + # @example Basic example + # require "google/cloud/oracle_database/v1" + # + # # Create a client object. The client can be reused for multiple calls. + # client = Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::Client.new + # + # # Create a request. To set request fields, pass in keyword arguments. + # request = Google::Cloud::OracleDatabase::V1::RestoreAutonomousDatabaseRequest.new + # + # # Call the restore_autonomous_database method. + # result = client.restore_autonomous_database request + # + # # The returned object is of type Gapic::Operation. You can use it to + # # check the status of an operation, cancel it, or wait for results. + # # Here is how to wait for a response. + # result.wait_until_done! timeout: 60 + # if result.response? + # p result.response + # else + # puts "No response received." + # end + # + def restore_autonomous_database request, options = nil + raise ::ArgumentError, "request must be provided" if request.nil? + + request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::OracleDatabase::V1::RestoreAutonomousDatabaseRequest + + # Converts hash and nil to an options object + options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h + + # Customize the options with defaults + call_metadata = @config.rpcs.restore_autonomous_database.metadata.to_h + + # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers + call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ + lib_name: @config.lib_name, lib_version: @config.lib_version, + gapic_version: ::Google::Cloud::OracleDatabase::V1::VERSION, + transports_version_send: [:rest] + + call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? + call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id + + options.apply_defaults timeout: @config.rpcs.restore_autonomous_database.timeout, + metadata: call_metadata, + retry_policy: @config.rpcs.restore_autonomous_database.retry_policy + + options.apply_defaults timeout: @config.timeout, + metadata: @config.metadata, + retry_policy: @config.retry_policy + + @oracle_database_stub.restore_autonomous_database request, options do |result, operation| + result = ::Gapic::Operation.new result, @operations_client, options: options + yield result, operation if block_given? + return result + end + rescue ::Gapic::Rest::Error => e + raise ::Google::Cloud::Error.from_error(e) + end + + ## + # Generates a wallet for an Autonomous Database. + # + # @overload generate_autonomous_database_wallet(request, options = nil) + # Pass arguments to `generate_autonomous_database_wallet` via a request object, either of type + # {::Google::Cloud::OracleDatabase::V1::GenerateAutonomousDatabaseWalletRequest} or an equivalent Hash. + # + # @param request [::Google::Cloud::OracleDatabase::V1::GenerateAutonomousDatabaseWalletRequest, ::Hash] + # A request object representing the call parameters. Required. To specify no + # parameters, or to keep all the default parameter values, pass an empty Hash. + # @param options [::Gapic::CallOptions, ::Hash] + # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. + # + # @overload generate_autonomous_database_wallet(name: nil, type: nil, is_regional: nil, password: nil) + # Pass arguments to `generate_autonomous_database_wallet` via keyword arguments. Note that at + # least one keyword argument is required. To specify no parameters, or to keep all + # the default parameter values, pass an empty Hash as a request object (see above). + # + # @param name [::String] + # Required. The name of the Autonomous Database in the following format: + # projects/\\{project}/locations/\\{location}/autonomousDatabases/\\{autonomous_database}. + # @param type [::Google::Cloud::OracleDatabase::V1::GenerateType] + # Optional. The type of wallet generation for the Autonomous Database. The + # default value is SINGLE. + # @param is_regional [::Boolean] + # Optional. True when requesting regional connection strings in PDB connect + # info, applicable to cross-region Data Guard only. + # @param password [::String] + # Required. The password used to encrypt the keys inside the wallet. The + # password must be a minimum of 8 characters. + # @yield [result, operation] Access the result along with the TransportOperation object + # @yieldparam result [::Google::Cloud::OracleDatabase::V1::GenerateAutonomousDatabaseWalletResponse] + # @yieldparam operation [::Gapic::Rest::TransportOperation] + # + # @return [::Google::Cloud::OracleDatabase::V1::GenerateAutonomousDatabaseWalletResponse] + # + # @raise [::Google::Cloud::Error] if the REST call is aborted. + # + # @example Basic example + # require "google/cloud/oracle_database/v1" + # + # # Create a client object. The client can be reused for multiple calls. + # client = Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::Client.new + # + # # Create a request. To set request fields, pass in keyword arguments. + # request = Google::Cloud::OracleDatabase::V1::GenerateAutonomousDatabaseWalletRequest.new + # + # # Call the generate_autonomous_database_wallet method. + # result = client.generate_autonomous_database_wallet request + # + # # The returned object is of type Google::Cloud::OracleDatabase::V1::GenerateAutonomousDatabaseWalletResponse. + # p result + # + def generate_autonomous_database_wallet request, options = nil + raise ::ArgumentError, "request must be provided" if request.nil? + + request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::OracleDatabase::V1::GenerateAutonomousDatabaseWalletRequest + + # Converts hash and nil to an options object + options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h + + # Customize the options with defaults + call_metadata = @config.rpcs.generate_autonomous_database_wallet.metadata.to_h + + # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers + call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ + lib_name: @config.lib_name, lib_version: @config.lib_version, + gapic_version: ::Google::Cloud::OracleDatabase::V1::VERSION, + transports_version_send: [:rest] + + call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? + call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id + + options.apply_defaults timeout: @config.rpcs.generate_autonomous_database_wallet.timeout, + metadata: call_metadata, + retry_policy: @config.rpcs.generate_autonomous_database_wallet.retry_policy + + options.apply_defaults timeout: @config.timeout, + metadata: @config.metadata, + retry_policy: @config.retry_policy + + @oracle_database_stub.generate_autonomous_database_wallet request, options do |result, operation| + yield result, operation if block_given? + return result + end + rescue ::Gapic::Rest::Error => e + raise ::Google::Cloud::Error.from_error(e) + end + + ## + # Lists all the available Autonomous Database versions for a project and + # location. + # + # @overload list_autonomous_db_versions(request, options = nil) + # Pass arguments to `list_autonomous_db_versions` via a request object, either of type + # {::Google::Cloud::OracleDatabase::V1::ListAutonomousDbVersionsRequest} or an equivalent Hash. + # + # @param request [::Google::Cloud::OracleDatabase::V1::ListAutonomousDbVersionsRequest, ::Hash] + # A request object representing the call parameters. Required. To specify no + # parameters, or to keep all the default parameter values, pass an empty Hash. + # @param options [::Gapic::CallOptions, ::Hash] + # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. + # + # @overload list_autonomous_db_versions(parent: nil, page_size: nil, page_token: nil) + # Pass arguments to `list_autonomous_db_versions` via keyword arguments. Note that at + # least one keyword argument is required. To specify no parameters, or to keep all + # the default parameter values, pass an empty Hash as a request object (see above). + # + # @param parent [::String] + # Required. The parent value for the Autonomous Database in the following + # format: projects/\\{project}/locations/\\{location}. + # @param page_size [::Integer] + # Optional. The maximum number of items to return. + # If unspecified, at most 50 Autonomous DB Versions will be returned. + # The maximum value is 1000; values above 1000 will be coerced to 1000. + # @param page_token [::String] + # Optional. A token identifying a page of results the server should return. + # @yield [result, operation] Access the result along with the TransportOperation object + # @yieldparam result [::Gapic::Rest::PagedEnumerable<::Google::Cloud::OracleDatabase::V1::AutonomousDbVersion>] + # @yieldparam operation [::Gapic::Rest::TransportOperation] + # + # @return [::Gapic::Rest::PagedEnumerable<::Google::Cloud::OracleDatabase::V1::AutonomousDbVersion>] + # + # @raise [::Google::Cloud::Error] if the REST call is aborted. + # + # @example Basic example + # require "google/cloud/oracle_database/v1" + # + # # Create a client object. The client can be reused for multiple calls. + # client = Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::Client.new + # + # # Create a request. To set request fields, pass in keyword arguments. + # request = Google::Cloud::OracleDatabase::V1::ListAutonomousDbVersionsRequest.new + # + # # Call the list_autonomous_db_versions method. + # result = client.list_autonomous_db_versions request + # + # # The returned object is of type Gapic::PagedEnumerable. You can iterate + # # over elements, and API calls will be issued to fetch pages as needed. + # result.each do |item| + # # Each element is of type ::Google::Cloud::OracleDatabase::V1::AutonomousDbVersion. + # p item + # end + # + def list_autonomous_db_versions request, options = nil + raise ::ArgumentError, "request must be provided" if request.nil? + + request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::OracleDatabase::V1::ListAutonomousDbVersionsRequest + + # Converts hash and nil to an options object + options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h + + # Customize the options with defaults + call_metadata = @config.rpcs.list_autonomous_db_versions.metadata.to_h + + # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers + call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ + lib_name: @config.lib_name, lib_version: @config.lib_version, + gapic_version: ::Google::Cloud::OracleDatabase::V1::VERSION, + transports_version_send: [:rest] + + call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? + call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id + + options.apply_defaults timeout: @config.rpcs.list_autonomous_db_versions.timeout, + metadata: call_metadata, + retry_policy: @config.rpcs.list_autonomous_db_versions.retry_policy + + options.apply_defaults timeout: @config.timeout, + metadata: @config.metadata, + retry_policy: @config.retry_policy + + @oracle_database_stub.list_autonomous_db_versions request, options do |result, operation| + result = ::Gapic::Rest::PagedEnumerable.new @oracle_database_stub, :list_autonomous_db_versions, "autonomous_db_versions", request, result, options + yield result, operation if block_given? + return result + end + rescue ::Gapic::Rest::Error => e + raise ::Google::Cloud::Error.from_error(e) + end + + ## + # Lists Autonomous Database Character Sets in a given project and location. + # + # @overload list_autonomous_database_character_sets(request, options = nil) + # Pass arguments to `list_autonomous_database_character_sets` via a request object, either of type + # {::Google::Cloud::OracleDatabase::V1::ListAutonomousDatabaseCharacterSetsRequest} or an equivalent Hash. + # + # @param request [::Google::Cloud::OracleDatabase::V1::ListAutonomousDatabaseCharacterSetsRequest, ::Hash] + # A request object representing the call parameters. Required. To specify no + # parameters, or to keep all the default parameter values, pass an empty Hash. + # @param options [::Gapic::CallOptions, ::Hash] + # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. + # + # @overload list_autonomous_database_character_sets(parent: nil, page_size: nil, page_token: nil, filter: nil) + # Pass arguments to `list_autonomous_database_character_sets` via keyword arguments. Note that at + # least one keyword argument is required. To specify no parameters, or to keep all + # the default parameter values, pass an empty Hash as a request object (see above). + # + # @param parent [::String] + # Required. The parent value for the Autonomous Database in the following + # format: projects/\\{project}/locations/\\{location}. + # @param page_size [::Integer] + # Optional. The maximum number of items to return. + # If unspecified, at most 50 Autonomous DB Character Sets will be returned. + # The maximum value is 1000; values above 1000 will be coerced to 1000. + # @param page_token [::String] + # Optional. A token identifying a page of results the server should return. + # @param filter [::String] + # Optional. An expression for filtering the results of the request. Only the + # **character_set_type** field is supported in the following format: + # `character_set_type="{characterSetType}"`. Accepted values include + # `DATABASE` and `NATIONAL`. + # @yield [result, operation] Access the result along with the TransportOperation object + # @yieldparam result [::Gapic::Rest::PagedEnumerable<::Google::Cloud::OracleDatabase::V1::AutonomousDatabaseCharacterSet>] + # @yieldparam operation [::Gapic::Rest::TransportOperation] + # + # @return [::Gapic::Rest::PagedEnumerable<::Google::Cloud::OracleDatabase::V1::AutonomousDatabaseCharacterSet>] + # + # @raise [::Google::Cloud::Error] if the REST call is aborted. + # + # @example Basic example + # require "google/cloud/oracle_database/v1" + # + # # Create a client object. The client can be reused for multiple calls. + # client = Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::Client.new + # + # # Create a request. To set request fields, pass in keyword arguments. + # request = Google::Cloud::OracleDatabase::V1::ListAutonomousDatabaseCharacterSetsRequest.new + # + # # Call the list_autonomous_database_character_sets method. + # result = client.list_autonomous_database_character_sets request + # + # # The returned object is of type Gapic::PagedEnumerable. You can iterate + # # over elements, and API calls will be issued to fetch pages as needed. + # result.each do |item| + # # Each element is of type ::Google::Cloud::OracleDatabase::V1::AutonomousDatabaseCharacterSet. + # p item + # end + # + def list_autonomous_database_character_sets request, options = nil + raise ::ArgumentError, "request must be provided" if request.nil? + + request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::OracleDatabase::V1::ListAutonomousDatabaseCharacterSetsRequest + + # Converts hash and nil to an options object + options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h + + # Customize the options with defaults + call_metadata = @config.rpcs.list_autonomous_database_character_sets.metadata.to_h + + # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers + call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ + lib_name: @config.lib_name, lib_version: @config.lib_version, + gapic_version: ::Google::Cloud::OracleDatabase::V1::VERSION, + transports_version_send: [:rest] + + call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? + call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id + + options.apply_defaults timeout: @config.rpcs.list_autonomous_database_character_sets.timeout, + metadata: call_metadata, + retry_policy: @config.rpcs.list_autonomous_database_character_sets.retry_policy + + options.apply_defaults timeout: @config.timeout, + metadata: @config.metadata, + retry_policy: @config.retry_policy + + @oracle_database_stub.list_autonomous_database_character_sets request, options do |result, operation| + result = ::Gapic::Rest::PagedEnumerable.new @oracle_database_stub, :list_autonomous_database_character_sets, "autonomous_database_character_sets", request, result, options + yield result, operation if block_given? + return result + end + rescue ::Gapic::Rest::Error => e + raise ::Google::Cloud::Error.from_error(e) + end + + ## + # Lists the long-term and automatic backups of an Autonomous Database. + # + # @overload list_autonomous_database_backups(request, options = nil) + # Pass arguments to `list_autonomous_database_backups` via a request object, either of type + # {::Google::Cloud::OracleDatabase::V1::ListAutonomousDatabaseBackupsRequest} or an equivalent Hash. + # + # @param request [::Google::Cloud::OracleDatabase::V1::ListAutonomousDatabaseBackupsRequest, ::Hash] + # A request object representing the call parameters. Required. To specify no + # parameters, or to keep all the default parameter values, pass an empty Hash. + # @param options [::Gapic::CallOptions, ::Hash] + # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. + # + # @overload list_autonomous_database_backups(parent: nil, filter: nil, page_size: nil, page_token: nil) + # Pass arguments to `list_autonomous_database_backups` via keyword arguments. Note that at + # least one keyword argument is required. To specify no parameters, or to keep all + # the default parameter values, pass an empty Hash as a request object (see above). + # + # @param parent [::String] + # Required. The parent value for ListAutonomousDatabaseBackups in the + # following format: projects/\\{project}/locations/\\{location}. + # @param filter [::String] + # Optional. An expression for filtering the results of the request. Only the + # **autonomous_database_id** field is supported in the following format: + # `autonomous_database_id="{autonomous_database_id}"`. The accepted values + # must be a valid Autonomous Database ID, limited to the naming + # restrictions of the ID: ^[a-z]([a-z0-9-]\\{0,61}[a-z0-9])?$). + # The ID must start with a letter, end with a letter or a number, and be + # a maximum of 63 characters. + # @param page_size [::Integer] + # Optional. The maximum number of items to return. + # If unspecified, at most 50 Autonomous DB Backups will be returned. + # The maximum value is 1000; values above 1000 will be coerced to 1000. + # @param page_token [::String] + # Optional. A token identifying a page of results the server should return. + # @yield [result, operation] Access the result along with the TransportOperation object + # @yieldparam result [::Gapic::Rest::PagedEnumerable<::Google::Cloud::OracleDatabase::V1::AutonomousDatabaseBackup>] + # @yieldparam operation [::Gapic::Rest::TransportOperation] + # + # @return [::Gapic::Rest::PagedEnumerable<::Google::Cloud::OracleDatabase::V1::AutonomousDatabaseBackup>] + # + # @raise [::Google::Cloud::Error] if the REST call is aborted. + # + # @example Basic example + # require "google/cloud/oracle_database/v1" + # + # # Create a client object. The client can be reused for multiple calls. + # client = Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::Client.new + # + # # Create a request. To set request fields, pass in keyword arguments. + # request = Google::Cloud::OracleDatabase::V1::ListAutonomousDatabaseBackupsRequest.new + # + # # Call the list_autonomous_database_backups method. + # result = client.list_autonomous_database_backups request + # + # # The returned object is of type Gapic::PagedEnumerable. You can iterate + # # over elements, and API calls will be issued to fetch pages as needed. + # result.each do |item| + # # Each element is of type ::Google::Cloud::OracleDatabase::V1::AutonomousDatabaseBackup. + # p item + # end + # + def list_autonomous_database_backups request, options = nil + raise ::ArgumentError, "request must be provided" if request.nil? + + request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::OracleDatabase::V1::ListAutonomousDatabaseBackupsRequest + + # Converts hash and nil to an options object + options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h + + # Customize the options with defaults + call_metadata = @config.rpcs.list_autonomous_database_backups.metadata.to_h + + # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers + call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ + lib_name: @config.lib_name, lib_version: @config.lib_version, + gapic_version: ::Google::Cloud::OracleDatabase::V1::VERSION, + transports_version_send: [:rest] + + call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? + call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id + + options.apply_defaults timeout: @config.rpcs.list_autonomous_database_backups.timeout, + metadata: call_metadata, + retry_policy: @config.rpcs.list_autonomous_database_backups.retry_policy + + options.apply_defaults timeout: @config.timeout, + metadata: @config.metadata, + retry_policy: @config.retry_policy + + @oracle_database_stub.list_autonomous_database_backups request, options do |result, operation| + result = ::Gapic::Rest::PagedEnumerable.new @oracle_database_stub, :list_autonomous_database_backups, "autonomous_database_backups", request, result, options + yield result, operation if block_given? + return result + end + rescue ::Gapic::Rest::Error => e + raise ::Google::Cloud::Error.from_error(e) + end + + ## + # Configuration class for the OracleDatabase REST API. + # + # This class represents the configuration for OracleDatabase REST, + # providing control over timeouts, retry behavior, logging, transport + # parameters, and other low-level controls. Certain parameters can also be + # applied individually to specific RPCs. See + # {::Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::Client::Configuration::Rpcs} + # for a list of RPCs that can be configured independently. + # + # Configuration can be applied globally to all clients, or to a single client + # on construction. + # + # @example + # + # # Modify the global config, setting the timeout for + # # list_cloud_exadata_infrastructures to 20 seconds, + # # and all remaining timeouts to 10 seconds. + # ::Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::Client.configure do |config| + # config.timeout = 10.0 + # config.rpcs.list_cloud_exadata_infrastructures.timeout = 20.0 + # end + # + # # Apply the above configuration only to a new client. + # client = ::Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::Client.new do |config| + # config.timeout = 10.0 + # config.rpcs.list_cloud_exadata_infrastructures.timeout = 20.0 + # end + # + # @!attribute [rw] endpoint + # A custom service endpoint, as a hostname or hostname:port. The default is + # nil, indicating to use the default endpoint in the current universe domain. + # @return [::String,nil] + # @!attribute [rw] credentials + # Credentials to send with calls. You may provide any of the following types: + # * (`String`) The path to a service account key file in JSON format + # * (`Hash`) A service account key as a Hash + # * (`Google::Auth::Credentials`) A googleauth credentials object + # (see the [googleauth docs](https://rubydoc.info/gems/googleauth/Google/Auth/Credentials)) + # * (`Signet::OAuth2::Client`) A signet oauth2 client object + # (see the [signet docs](https://rubydoc.info/gems/signet/Signet/OAuth2/Client)) + # * (`nil`) indicating no credentials + # @return [::Object] + # @!attribute [rw] scope + # The OAuth scopes + # @return [::Array<::String>] + # @!attribute [rw] lib_name + # The library name as recorded in instrumentation and logging + # @return [::String] + # @!attribute [rw] lib_version + # The library version as recorded in instrumentation and logging + # @return [::String] + # @!attribute [rw] timeout + # The call timeout in seconds. + # @return [::Numeric] + # @!attribute [rw] metadata + # Additional headers to be sent with the call. + # @return [::Hash{::Symbol=>::String}] + # @!attribute [rw] retry_policy + # The retry policy. The value is a hash with the following keys: + # * `:initial_delay` (*type:* `Numeric`) - The initial delay in seconds. + # * `:max_delay` (*type:* `Numeric`) - The max delay in seconds. + # * `:multiplier` (*type:* `Numeric`) - The incremental backoff multiplier. + # * `:retry_codes` (*type:* `Array`) - The error codes that should + # trigger a retry. + # @return [::Hash] + # @!attribute [rw] quota_project + # A separate project against which to charge quota. + # @return [::String] + # @!attribute [rw] universe_domain + # The universe domain within which to make requests. This determines the + # default endpoint URL. The default value of nil uses the environment + # universe (usually the default "googleapis.com" universe). + # @return [::String,nil] + # + class Configuration + extend ::Gapic::Config + + # @private + # The endpoint specific to the default "googleapis.com" universe. Deprecated. + DEFAULT_ENDPOINT = "oracledatabase.googleapis.com" + + config_attr :endpoint, nil, ::String, nil + config_attr :credentials, nil do |value| + allowed = [::String, ::Hash, ::Proc, ::Symbol, ::Google::Auth::Credentials, ::Signet::OAuth2::Client, nil] + allowed.any? { |klass| klass === value } + end + config_attr :scope, nil, ::String, ::Array, nil + config_attr :lib_name, nil, ::String, nil + config_attr :lib_version, nil, ::String, nil + config_attr :timeout, nil, ::Numeric, nil + config_attr :metadata, nil, ::Hash, nil + config_attr :retry_policy, nil, ::Hash, ::Proc, nil + config_attr :quota_project, nil, ::String, nil + config_attr :universe_domain, nil, ::String, nil + + # @private + # Overrides for http bindings for the RPCs of this service + # are only used when this service is used as mixin, and only + # by the host service. + # @return [::Hash{::Symbol=>::Array<::Gapic::Rest::GrpcTranscoder::HttpBinding>}] + config_attr :bindings_override, {}, ::Hash, nil + + # @private + def initialize parent_config = nil + @parent_config = parent_config unless parent_config.nil? + + yield self if block_given? + end + + ## + # Configurations for individual RPCs + # @return [Rpcs] + # + def rpcs + @rpcs ||= begin + parent_rpcs = nil + parent_rpcs = @parent_config.rpcs if defined?(@parent_config) && @parent_config.respond_to?(:rpcs) + Rpcs.new parent_rpcs + end + end + + ## + # Configuration RPC class for the OracleDatabase API. + # + # Includes fields providing the configuration for each RPC in this service. + # Each configuration object is of type `Gapic::Config::Method` and includes + # the following configuration fields: + # + # * `timeout` (*type:* `Numeric`) - The call timeout in seconds + # * `metadata` (*type:* `Hash{Symbol=>String}`) - Additional headers + # * `retry_policy (*type:* `Hash`) - The retry policy. The policy fields + # include the following keys: + # * `:initial_delay` (*type:* `Numeric`) - The initial delay in seconds. + # * `:max_delay` (*type:* `Numeric`) - The max delay in seconds. + # * `:multiplier` (*type:* `Numeric`) - The incremental backoff multiplier. + # * `:retry_codes` (*type:* `Array`) - The error codes that should + # trigger a retry. + # + class Rpcs + ## + # RPC-specific configuration for `list_cloud_exadata_infrastructures` + # @return [::Gapic::Config::Method] + # + attr_reader :list_cloud_exadata_infrastructures + ## + # RPC-specific configuration for `get_cloud_exadata_infrastructure` + # @return [::Gapic::Config::Method] + # + attr_reader :get_cloud_exadata_infrastructure + ## + # RPC-specific configuration for `create_cloud_exadata_infrastructure` + # @return [::Gapic::Config::Method] + # + attr_reader :create_cloud_exadata_infrastructure + ## + # RPC-specific configuration for `delete_cloud_exadata_infrastructure` + # @return [::Gapic::Config::Method] + # + attr_reader :delete_cloud_exadata_infrastructure + ## + # RPC-specific configuration for `list_cloud_vm_clusters` + # @return [::Gapic::Config::Method] + # + attr_reader :list_cloud_vm_clusters + ## + # RPC-specific configuration for `get_cloud_vm_cluster` + # @return [::Gapic::Config::Method] + # + attr_reader :get_cloud_vm_cluster + ## + # RPC-specific configuration for `create_cloud_vm_cluster` + # @return [::Gapic::Config::Method] + # + attr_reader :create_cloud_vm_cluster + ## + # RPC-specific configuration for `delete_cloud_vm_cluster` + # @return [::Gapic::Config::Method] + # + attr_reader :delete_cloud_vm_cluster + ## + # RPC-specific configuration for `list_entitlements` + # @return [::Gapic::Config::Method] + # + attr_reader :list_entitlements + ## + # RPC-specific configuration for `list_db_servers` + # @return [::Gapic::Config::Method] + # + attr_reader :list_db_servers + ## + # RPC-specific configuration for `list_db_nodes` + # @return [::Gapic::Config::Method] + # + attr_reader :list_db_nodes + ## + # RPC-specific configuration for `list_gi_versions` + # @return [::Gapic::Config::Method] + # + attr_reader :list_gi_versions + ## + # RPC-specific configuration for `list_db_system_shapes` + # @return [::Gapic::Config::Method] + # + attr_reader :list_db_system_shapes + ## + # RPC-specific configuration for `list_autonomous_databases` + # @return [::Gapic::Config::Method] + # + attr_reader :list_autonomous_databases + ## + # RPC-specific configuration for `get_autonomous_database` + # @return [::Gapic::Config::Method] + # + attr_reader :get_autonomous_database + ## + # RPC-specific configuration for `create_autonomous_database` + # @return [::Gapic::Config::Method] + # + attr_reader :create_autonomous_database + ## + # RPC-specific configuration for `delete_autonomous_database` + # @return [::Gapic::Config::Method] + # + attr_reader :delete_autonomous_database + ## + # RPC-specific configuration for `restore_autonomous_database` + # @return [::Gapic::Config::Method] + # + attr_reader :restore_autonomous_database + ## + # RPC-specific configuration for `generate_autonomous_database_wallet` + # @return [::Gapic::Config::Method] + # + attr_reader :generate_autonomous_database_wallet + ## + # RPC-specific configuration for `list_autonomous_db_versions` + # @return [::Gapic::Config::Method] + # + attr_reader :list_autonomous_db_versions + ## + # RPC-specific configuration for `list_autonomous_database_character_sets` + # @return [::Gapic::Config::Method] + # + attr_reader :list_autonomous_database_character_sets + ## + # RPC-specific configuration for `list_autonomous_database_backups` + # @return [::Gapic::Config::Method] + # + attr_reader :list_autonomous_database_backups + + # @private + def initialize parent_rpcs = nil + list_cloud_exadata_infrastructures_config = parent_rpcs.list_cloud_exadata_infrastructures if parent_rpcs.respond_to? :list_cloud_exadata_infrastructures + @list_cloud_exadata_infrastructures = ::Gapic::Config::Method.new list_cloud_exadata_infrastructures_config + get_cloud_exadata_infrastructure_config = parent_rpcs.get_cloud_exadata_infrastructure if parent_rpcs.respond_to? :get_cloud_exadata_infrastructure + @get_cloud_exadata_infrastructure = ::Gapic::Config::Method.new get_cloud_exadata_infrastructure_config + create_cloud_exadata_infrastructure_config = parent_rpcs.create_cloud_exadata_infrastructure if parent_rpcs.respond_to? :create_cloud_exadata_infrastructure + @create_cloud_exadata_infrastructure = ::Gapic::Config::Method.new create_cloud_exadata_infrastructure_config + delete_cloud_exadata_infrastructure_config = parent_rpcs.delete_cloud_exadata_infrastructure if parent_rpcs.respond_to? :delete_cloud_exadata_infrastructure + @delete_cloud_exadata_infrastructure = ::Gapic::Config::Method.new delete_cloud_exadata_infrastructure_config + list_cloud_vm_clusters_config = parent_rpcs.list_cloud_vm_clusters if parent_rpcs.respond_to? :list_cloud_vm_clusters + @list_cloud_vm_clusters = ::Gapic::Config::Method.new list_cloud_vm_clusters_config + get_cloud_vm_cluster_config = parent_rpcs.get_cloud_vm_cluster if parent_rpcs.respond_to? :get_cloud_vm_cluster + @get_cloud_vm_cluster = ::Gapic::Config::Method.new get_cloud_vm_cluster_config + create_cloud_vm_cluster_config = parent_rpcs.create_cloud_vm_cluster if parent_rpcs.respond_to? :create_cloud_vm_cluster + @create_cloud_vm_cluster = ::Gapic::Config::Method.new create_cloud_vm_cluster_config + delete_cloud_vm_cluster_config = parent_rpcs.delete_cloud_vm_cluster if parent_rpcs.respond_to? :delete_cloud_vm_cluster + @delete_cloud_vm_cluster = ::Gapic::Config::Method.new delete_cloud_vm_cluster_config + list_entitlements_config = parent_rpcs.list_entitlements if parent_rpcs.respond_to? :list_entitlements + @list_entitlements = ::Gapic::Config::Method.new list_entitlements_config + list_db_servers_config = parent_rpcs.list_db_servers if parent_rpcs.respond_to? :list_db_servers + @list_db_servers = ::Gapic::Config::Method.new list_db_servers_config + list_db_nodes_config = parent_rpcs.list_db_nodes if parent_rpcs.respond_to? :list_db_nodes + @list_db_nodes = ::Gapic::Config::Method.new list_db_nodes_config + list_gi_versions_config = parent_rpcs.list_gi_versions if parent_rpcs.respond_to? :list_gi_versions + @list_gi_versions = ::Gapic::Config::Method.new list_gi_versions_config + list_db_system_shapes_config = parent_rpcs.list_db_system_shapes if parent_rpcs.respond_to? :list_db_system_shapes + @list_db_system_shapes = ::Gapic::Config::Method.new list_db_system_shapes_config + list_autonomous_databases_config = parent_rpcs.list_autonomous_databases if parent_rpcs.respond_to? :list_autonomous_databases + @list_autonomous_databases = ::Gapic::Config::Method.new list_autonomous_databases_config + get_autonomous_database_config = parent_rpcs.get_autonomous_database if parent_rpcs.respond_to? :get_autonomous_database + @get_autonomous_database = ::Gapic::Config::Method.new get_autonomous_database_config + create_autonomous_database_config = parent_rpcs.create_autonomous_database if parent_rpcs.respond_to? :create_autonomous_database + @create_autonomous_database = ::Gapic::Config::Method.new create_autonomous_database_config + delete_autonomous_database_config = parent_rpcs.delete_autonomous_database if parent_rpcs.respond_to? :delete_autonomous_database + @delete_autonomous_database = ::Gapic::Config::Method.new delete_autonomous_database_config + restore_autonomous_database_config = parent_rpcs.restore_autonomous_database if parent_rpcs.respond_to? :restore_autonomous_database + @restore_autonomous_database = ::Gapic::Config::Method.new restore_autonomous_database_config + generate_autonomous_database_wallet_config = parent_rpcs.generate_autonomous_database_wallet if parent_rpcs.respond_to? :generate_autonomous_database_wallet + @generate_autonomous_database_wallet = ::Gapic::Config::Method.new generate_autonomous_database_wallet_config + list_autonomous_db_versions_config = parent_rpcs.list_autonomous_db_versions if parent_rpcs.respond_to? :list_autonomous_db_versions + @list_autonomous_db_versions = ::Gapic::Config::Method.new list_autonomous_db_versions_config + list_autonomous_database_character_sets_config = parent_rpcs.list_autonomous_database_character_sets if parent_rpcs.respond_to? :list_autonomous_database_character_sets + @list_autonomous_database_character_sets = ::Gapic::Config::Method.new list_autonomous_database_character_sets_config + list_autonomous_database_backups_config = parent_rpcs.list_autonomous_database_backups if parent_rpcs.respond_to? :list_autonomous_database_backups + @list_autonomous_database_backups = ::Gapic::Config::Method.new list_autonomous_database_backups_config + + yield self if block_given? + end + end + end + end + end + end + end + end + end +end diff --git a/google-cloud-oracle_database-v1/lib/google/cloud/oracle_database/v1/oracle_database/rest/operations.rb b/google-cloud-oracle_database-v1/lib/google/cloud/oracle_database/v1/oracle_database/rest/operations.rb new file mode 100644 index 000000000000..5efd1435bd78 --- /dev/null +++ b/google-cloud-oracle_database-v1/lib/google/cloud/oracle_database/v1/oracle_database/rest/operations.rb @@ -0,0 +1,902 @@ +# frozen_string_literal: true + +# Copyright 2024 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# https://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Auto-generated by gapic-generator-ruby. DO NOT EDIT! + +require "gapic/operation" + +module Google + module Cloud + module OracleDatabase + module V1 + module OracleDatabase + module Rest + # Service that implements Longrunning Operations API. + class Operations + # @private + API_VERSION = "" + + # @private + DEFAULT_ENDPOINT_TEMPLATE = "oracledatabase.$UNIVERSE_DOMAIN$" + + # @private + attr_reader :operations_stub + + ## + # Configuration for the OracleDatabase Operations API. + # + # @yield [config] Configure the Operations client. + # @yieldparam config [Operations::Configuration] + # + # @return [Operations::Configuration] + # + def self.configure + @configure ||= Operations::Configuration.new + yield @configure if block_given? + @configure + end + + ## + # Configure the OracleDatabase Operations instance. + # + # The configuration is set to the derived mode, meaning that values can be changed, + # but structural changes (adding new fields, etc.) are not allowed. Structural changes + # should be made on {Operations.configure}. + # + # @yield [config] Configure the Operations client. + # @yieldparam config [Operations::Configuration] + # + # @return [Operations::Configuration] + # + def configure + yield @config if block_given? + @config + end + + ## + # The effective universe domain + # + # @return [String] + # + def universe_domain + @operations_stub.universe_domain + end + + ## + # Create a new Operations client object. + # + # @yield [config] Configure the Client client. + # @yieldparam config [Operations::Configuration] + # + def initialize + # Create the configuration object + @config = Configuration.new Operations.configure + + # Yield the configuration if needed + yield @config if block_given? + + # Create credentials + credentials = @config.credentials + credentials ||= Credentials.default scope: @config.scope + if credentials.is_a?(::String) || credentials.is_a?(::Hash) + credentials = Credentials.new credentials, scope: @config.scope + end + + @quota_project_id = @config.quota_project + @quota_project_id ||= credentials.quota_project_id if credentials.respond_to? :quota_project_id + + @operations_stub = OperationsServiceStub.new( + endpoint: @config.endpoint, + endpoint_template: DEFAULT_ENDPOINT_TEMPLATE, + universe_domain: @config.universe_domain, + credentials: credentials + ) + + # Used by an LRO wrapper for some methods of this service + @operations_client = self + end + + # Service calls + + ## + # Lists operations that match the specified filter in the request. If the + # server doesn't support this method, it returns `UNIMPLEMENTED`. + # + # NOTE: the `name` binding allows API services to override the binding + # to use different resource name schemes, such as `users/*/operations`. To + # override the binding, API services can add a binding such as + # `"/v1/{name=users/*}/operations"` to their service configuration. + # For backwards compatibility, the default name includes the operations + # collection id, however overriding users must ensure the name binding + # is the parent resource, without the operations collection id. + # + # @overload list_operations(request, options = nil) + # Pass arguments to `list_operations` via a request object, either of type + # {::Google::Longrunning::ListOperationsRequest} or an equivalent Hash. + # + # @param request [::Google::Longrunning::ListOperationsRequest, ::Hash] + # A request object representing the call parameters. Required. To specify no + # parameters, or to keep all the default parameter values, pass an empty Hash. + # @param options [::Gapic::CallOptions, ::Hash] + # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. + # + # @overload list_operations(name: nil, filter: nil, page_size: nil, page_token: nil) + # Pass arguments to `list_operations` via keyword arguments. Note that at + # least one keyword argument is required. To specify no parameters, or to keep all + # the default parameter values, pass an empty Hash as a request object (see above). + # + # @param name [::String] + # The name of the operation's parent resource. + # @param filter [::String] + # The standard list filter. + # @param page_size [::Integer] + # The standard list page size. + # @param page_token [::String] + # The standard list page token. + # @yield [result, operation] Access the result along with the TransportOperation object + # @yieldparam result [::Gapic::Operation] + # @yieldparam operation [::Gapic::Rest::TransportOperation] + # + # @return [::Gapic::Operation] + # + # @raise [::Google::Cloud::Error] if the REST call is aborted. + # + # @example Basic example + # require "google/longrunning" + # + # # Create a client object. The client can be reused for multiple calls. + # client = Google::Longrunning::Operations::Rest::Client.new + # + # # Create a request. To set request fields, pass in keyword arguments. + # request = Google::Longrunning::ListOperationsRequest.new + # + # # Call the list_operations method. + # result = client.list_operations request + # + # # The returned object is of type Gapic::PagedEnumerable. You can iterate + # # over elements, and API calls will be issued to fetch pages as needed. + # result.each do |item| + # # Each element is of type ::Google::Longrunning::Operation. + # p item + # end + # + def list_operations request, options = nil + raise ::ArgumentError, "request must be provided" if request.nil? + + request = ::Gapic::Protobuf.coerce request, to: ::Google::Longrunning::ListOperationsRequest + + # Converts hash and nil to an options object + options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h + + # Customize the options with defaults + call_metadata = @config.rpcs.list_operations.metadata.to_h + + # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers + call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ + lib_name: @config.lib_name, lib_version: @config.lib_version, + gapic_version: ::Google::Cloud::OracleDatabase::V1::VERSION, + transports_version_send: [:rest] + + call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? + call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id + + options.apply_defaults timeout: @config.rpcs.list_operations.timeout, + metadata: call_metadata, + retry_policy: @config.rpcs.list_operations.retry_policy + + options.apply_defaults timeout: @config.timeout, + metadata: @config.metadata, + retry_policy: @config.retry_policy + + @operations_stub.list_operations request, options do |result, operation| + result = ::Gapic::Rest::PagedEnumerable.new @operations_stub, :list_operations, "operations", request, result, options + yield result, operation if block_given? + return result + end + rescue ::Gapic::Rest::Error => e + raise ::Google::Cloud::Error.from_error(e) + end + + ## + # Gets the latest state of a long-running operation. Clients can use this + # method to poll the operation result at intervals as recommended by the API + # service. + # + # @overload get_operation(request, options = nil) + # Pass arguments to `get_operation` via a request object, either of type + # {::Google::Longrunning::GetOperationRequest} or an equivalent Hash. + # + # @param request [::Google::Longrunning::GetOperationRequest, ::Hash] + # A request object representing the call parameters. Required. To specify no + # parameters, or to keep all the default parameter values, pass an empty Hash. + # @param options [::Gapic::CallOptions, ::Hash] + # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. + # + # @overload get_operation(name: nil) + # Pass arguments to `get_operation` via keyword arguments. Note that at + # least one keyword argument is required. To specify no parameters, or to keep all + # the default parameter values, pass an empty Hash as a request object (see above). + # + # @param name [::String] + # The name of the operation resource. + # @yield [result, operation] Access the result along with the TransportOperation object + # @yieldparam result [::Gapic::Operation] + # @yieldparam operation [::Gapic::Rest::TransportOperation] + # + # @return [::Gapic::Operation] + # + # @raise [::Google::Cloud::Error] if the REST call is aborted. + # + # @example Basic example + # require "google/longrunning" + # + # # Create a client object. The client can be reused for multiple calls. + # client = Google::Longrunning::Operations::Rest::Client.new + # + # # Create a request. To set request fields, pass in keyword arguments. + # request = Google::Longrunning::GetOperationRequest.new + # + # # Call the get_operation method. + # result = client.get_operation request + # + # # The returned object is of type Gapic::Operation. You can use it to + # # check the status of an operation, cancel it, or wait for results. + # # Here is how to wait for a response. + # result.wait_until_done! timeout: 60 + # if result.response? + # p result.response + # else + # puts "No response received." + # end + # + def get_operation request, options = nil + raise ::ArgumentError, "request must be provided" if request.nil? + + request = ::Gapic::Protobuf.coerce request, to: ::Google::Longrunning::GetOperationRequest + + # Converts hash and nil to an options object + options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h + + # Customize the options with defaults + call_metadata = @config.rpcs.get_operation.metadata.to_h + + # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers + call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ + lib_name: @config.lib_name, lib_version: @config.lib_version, + gapic_version: ::Google::Cloud::OracleDatabase::V1::VERSION, + transports_version_send: [:rest] + + call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? + call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id + + options.apply_defaults timeout: @config.rpcs.get_operation.timeout, + metadata: call_metadata, + retry_policy: @config.rpcs.get_operation.retry_policy + + options.apply_defaults timeout: @config.timeout, + metadata: @config.metadata, + retry_policy: @config.retry_policy + + @operations_stub.get_operation request, options do |result, operation| + result = ::Gapic::Operation.new result, @operations_client, options: options + yield result, operation if block_given? + return result + end + rescue ::Gapic::Rest::Error => e + raise ::Google::Cloud::Error.from_error(e) + end + + ## + # Deletes a long-running operation. This method indicates that the client is + # no longer interested in the operation result. It does not cancel the + # operation. If the server doesn't support this method, it returns + # `google.rpc.Code.UNIMPLEMENTED`. + # + # @overload delete_operation(request, options = nil) + # Pass arguments to `delete_operation` via a request object, either of type + # {::Google::Longrunning::DeleteOperationRequest} or an equivalent Hash. + # + # @param request [::Google::Longrunning::DeleteOperationRequest, ::Hash] + # A request object representing the call parameters. Required. To specify no + # parameters, or to keep all the default parameter values, pass an empty Hash. + # @param options [::Gapic::CallOptions, ::Hash] + # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. + # + # @overload delete_operation(name: nil) + # Pass arguments to `delete_operation` via keyword arguments. Note that at + # least one keyword argument is required. To specify no parameters, or to keep all + # the default parameter values, pass an empty Hash as a request object (see above). + # + # @param name [::String] + # The name of the operation resource to be deleted. + # @yield [result, operation] Access the result along with the TransportOperation object + # @yieldparam result [::Google::Protobuf::Empty] + # @yieldparam operation [::Gapic::Rest::TransportOperation] + # + # @return [::Google::Protobuf::Empty] + # + # @raise [::Google::Cloud::Error] if the REST call is aborted. + # + # @example Basic example + # require "google/longrunning" + # + # # Create a client object. The client can be reused for multiple calls. + # client = Google::Longrunning::Operations::Rest::Client.new + # + # # Create a request. To set request fields, pass in keyword arguments. + # request = Google::Longrunning::DeleteOperationRequest.new + # + # # Call the delete_operation method. + # result = client.delete_operation request + # + # # The returned object is of type Google::Protobuf::Empty. + # p result + # + def delete_operation request, options = nil + raise ::ArgumentError, "request must be provided" if request.nil? + + request = ::Gapic::Protobuf.coerce request, to: ::Google::Longrunning::DeleteOperationRequest + + # Converts hash and nil to an options object + options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h + + # Customize the options with defaults + call_metadata = @config.rpcs.delete_operation.metadata.to_h + + # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers + call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ + lib_name: @config.lib_name, lib_version: @config.lib_version, + gapic_version: ::Google::Cloud::OracleDatabase::V1::VERSION, + transports_version_send: [:rest] + + call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? + call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id + + options.apply_defaults timeout: @config.rpcs.delete_operation.timeout, + metadata: call_metadata, + retry_policy: @config.rpcs.delete_operation.retry_policy + + options.apply_defaults timeout: @config.timeout, + metadata: @config.metadata, + retry_policy: @config.retry_policy + + @operations_stub.delete_operation request, options do |result, operation| + yield result, operation if block_given? + return result + end + rescue ::Gapic::Rest::Error => e + raise ::Google::Cloud::Error.from_error(e) + end + + ## + # Starts asynchronous cancellation on a long-running operation. The server + # makes a best effort to cancel the operation, but success is not + # guaranteed. If the server doesn't support this method, it returns + # `google.rpc.Code.UNIMPLEMENTED`. Clients can use + # Operations.GetOperation or + # other methods to check whether the cancellation succeeded or whether the + # operation completed despite cancellation. On successful cancellation, + # the operation is not deleted; instead, it becomes an operation with + # an {::Google::Longrunning::Operation#error Operation.error} value with a {::Google::Rpc::Status#code google.rpc.Status.code} of 1, + # corresponding to `Code.CANCELLED`. + # + # @overload cancel_operation(request, options = nil) + # Pass arguments to `cancel_operation` via a request object, either of type + # {::Google::Longrunning::CancelOperationRequest} or an equivalent Hash. + # + # @param request [::Google::Longrunning::CancelOperationRequest, ::Hash] + # A request object representing the call parameters. Required. To specify no + # parameters, or to keep all the default parameter values, pass an empty Hash. + # @param options [::Gapic::CallOptions, ::Hash] + # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. + # + # @overload cancel_operation(name: nil) + # Pass arguments to `cancel_operation` via keyword arguments. Note that at + # least one keyword argument is required. To specify no parameters, or to keep all + # the default parameter values, pass an empty Hash as a request object (see above). + # + # @param name [::String] + # The name of the operation resource to be cancelled. + # @yield [result, operation] Access the result along with the TransportOperation object + # @yieldparam result [::Google::Protobuf::Empty] + # @yieldparam operation [::Gapic::Rest::TransportOperation] + # + # @return [::Google::Protobuf::Empty] + # + # @raise [::Google::Cloud::Error] if the REST call is aborted. + # + # @example Basic example + # require "google/longrunning" + # + # # Create a client object. The client can be reused for multiple calls. + # client = Google::Longrunning::Operations::Rest::Client.new + # + # # Create a request. To set request fields, pass in keyword arguments. + # request = Google::Longrunning::CancelOperationRequest.new + # + # # Call the cancel_operation method. + # result = client.cancel_operation request + # + # # The returned object is of type Google::Protobuf::Empty. + # p result + # + def cancel_operation request, options = nil + raise ::ArgumentError, "request must be provided" if request.nil? + + request = ::Gapic::Protobuf.coerce request, to: ::Google::Longrunning::CancelOperationRequest + + # Converts hash and nil to an options object + options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h + + # Customize the options with defaults + call_metadata = @config.rpcs.cancel_operation.metadata.to_h + + # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers + call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ + lib_name: @config.lib_name, lib_version: @config.lib_version, + gapic_version: ::Google::Cloud::OracleDatabase::V1::VERSION, + transports_version_send: [:rest] + + call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty? + call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id + + options.apply_defaults timeout: @config.rpcs.cancel_operation.timeout, + metadata: call_metadata, + retry_policy: @config.rpcs.cancel_operation.retry_policy + + options.apply_defaults timeout: @config.timeout, + metadata: @config.metadata, + retry_policy: @config.retry_policy + + @operations_stub.cancel_operation request, options do |result, operation| + yield result, operation if block_given? + return result + end + rescue ::Gapic::Rest::Error => e + raise ::Google::Cloud::Error.from_error(e) + end + + ## + # Configuration class for the Operations REST API. + # + # This class represents the configuration for Operations REST, + # providing control over timeouts, retry behavior, logging, transport + # parameters, and other low-level controls. Certain parameters can also be + # applied individually to specific RPCs. See + # {::Google::Longrunning::Operations::Rest::Client::Configuration::Rpcs} + # for a list of RPCs that can be configured independently. + # + # Configuration can be applied globally to all clients, or to a single client + # on construction. + # + # @example + # + # # Modify the global config, setting the timeout for + # # list_operations to 20 seconds, + # # and all remaining timeouts to 10 seconds. + # ::Google::Longrunning::Operations::Rest::Client.configure do |config| + # config.timeout = 10.0 + # config.rpcs.list_operations.timeout = 20.0 + # end + # + # # Apply the above configuration only to a new client. + # client = ::Google::Longrunning::Operations::Rest::Client.new do |config| + # config.timeout = 10.0 + # config.rpcs.list_operations.timeout = 20.0 + # end + # + # @!attribute [rw] endpoint + # A custom service endpoint, as a hostname or hostname:port. The default is + # nil, indicating to use the default endpoint in the current universe domain. + # @return [::String,nil] + # @!attribute [rw] credentials + # Credentials to send with calls. You may provide any of the following types: + # * (`String`) The path to a service account key file in JSON format + # * (`Hash`) A service account key as a Hash + # * (`Google::Auth::Credentials`) A googleauth credentials object + # (see the [googleauth docs](https://rubydoc.info/gems/googleauth/Google/Auth/Credentials)) + # * (`Signet::OAuth2::Client`) A signet oauth2 client object + # (see the [signet docs](https://rubydoc.info/gems/signet/Signet/OAuth2/Client)) + # * (`nil`) indicating no credentials + # @return [::Object] + # @!attribute [rw] scope + # The OAuth scopes + # @return [::Array<::String>] + # @!attribute [rw] lib_name + # The library name as recorded in instrumentation and logging + # @return [::String] + # @!attribute [rw] lib_version + # The library version as recorded in instrumentation and logging + # @return [::String] + # @!attribute [rw] timeout + # The call timeout in seconds. + # @return [::Numeric] + # @!attribute [rw] metadata + # Additional headers to be sent with the call. + # @return [::Hash{::Symbol=>::String}] + # @!attribute [rw] retry_policy + # The retry policy. The value is a hash with the following keys: + # * `:initial_delay` (*type:* `Numeric`) - The initial delay in seconds. + # * `:max_delay` (*type:* `Numeric`) - The max delay in seconds. + # * `:multiplier` (*type:* `Numeric`) - The incremental backoff multiplier. + # * `:retry_codes` (*type:* `Array`) - The error codes that should + # trigger a retry. + # @return [::Hash] + # @!attribute [rw] quota_project + # A separate project against which to charge quota. + # @return [::String] + # @!attribute [rw] universe_domain + # The universe domain within which to make requests. This determines the + # default endpoint URL. The default value of nil uses the environment + # universe (usually the default "googleapis.com" universe). + # @return [::String,nil] + # + class Configuration + extend ::Gapic::Config + + # @private + # The endpoint specific to the default "googleapis.com" universe. Deprecated. + DEFAULT_ENDPOINT = "oracledatabase.googleapis.com" + + config_attr :endpoint, nil, ::String, nil + config_attr :credentials, nil do |value| + allowed = [::String, ::Hash, ::Proc, ::Symbol, ::Google::Auth::Credentials, ::Signet::OAuth2::Client, nil] + allowed.any? { |klass| klass === value } + end + config_attr :scope, nil, ::String, ::Array, nil + config_attr :lib_name, nil, ::String, nil + config_attr :lib_version, nil, ::String, nil + config_attr :timeout, nil, ::Numeric, nil + config_attr :metadata, nil, ::Hash, nil + config_attr :retry_policy, nil, ::Hash, ::Proc, nil + config_attr :quota_project, nil, ::String, nil + config_attr :universe_domain, nil, ::String, nil + + # @private + def initialize parent_config = nil + @parent_config = parent_config unless parent_config.nil? + + yield self if block_given? + end + + ## + # Configurations for individual RPCs + # @return [Rpcs] + # + def rpcs + @rpcs ||= begin + parent_rpcs = nil + parent_rpcs = @parent_config.rpcs if defined?(@parent_config) && @parent_config.respond_to?(:rpcs) + Rpcs.new parent_rpcs + end + end + + ## + # Configuration RPC class for the Operations API. + # + # Includes fields providing the configuration for each RPC in this service. + # Each configuration object is of type `Gapic::Config::Method` and includes + # the following configuration fields: + # + # * `timeout` (*type:* `Numeric`) - The call timeout in seconds + # * `metadata` (*type:* `Hash{Symbol=>String}`) - Additional headers + # * `retry_policy (*type:* `Hash`) - The retry policy. The policy fields + # include the following keys: + # * `:initial_delay` (*type:* `Numeric`) - The initial delay in seconds. + # * `:max_delay` (*type:* `Numeric`) - The max delay in seconds. + # * `:multiplier` (*type:* `Numeric`) - The incremental backoff multiplier. + # * `:retry_codes` (*type:* `Array`) - The error codes that should + # trigger a retry. + # + class Rpcs + ## + # RPC-specific configuration for `list_operations` + # @return [::Gapic::Config::Method] + # + attr_reader :list_operations + ## + # RPC-specific configuration for `get_operation` + # @return [::Gapic::Config::Method] + # + attr_reader :get_operation + ## + # RPC-specific configuration for `delete_operation` + # @return [::Gapic::Config::Method] + # + attr_reader :delete_operation + ## + # RPC-specific configuration for `cancel_operation` + # @return [::Gapic::Config::Method] + # + attr_reader :cancel_operation + + # @private + def initialize parent_rpcs = nil + list_operations_config = parent_rpcs.list_operations if parent_rpcs.respond_to? :list_operations + @list_operations = ::Gapic::Config::Method.new list_operations_config + get_operation_config = parent_rpcs.get_operation if parent_rpcs.respond_to? :get_operation + @get_operation = ::Gapic::Config::Method.new get_operation_config + delete_operation_config = parent_rpcs.delete_operation if parent_rpcs.respond_to? :delete_operation + @delete_operation = ::Gapic::Config::Method.new delete_operation_config + cancel_operation_config = parent_rpcs.cancel_operation if parent_rpcs.respond_to? :cancel_operation + @cancel_operation = ::Gapic::Config::Method.new cancel_operation_config + + yield self if block_given? + end + end + end + end + + ## + # @private + # REST service stub for the Longrunning Operations API. + # Service stub contains baseline method implementations + # including transcoding, making the REST call, and deserialing the response. + class OperationsServiceStub + def initialize endpoint:, endpoint_template:, universe_domain:, credentials: + # These require statements are intentionally placed here to initialize + # the REST modules only when it's required. + require "gapic/rest" + + @client_stub = ::Gapic::Rest::ClientStub.new endpoint: endpoint, + endpoint_template: endpoint_template, + universe_domain: universe_domain, + credentials: credentials + end + + ## + # Baseline implementation for the list_operations REST call + # + # @param request_pb [::Google::Longrunning::ListOperationsRequest] + # A request object representing the call parameters. Required. + # @param options [::Gapic::CallOptions] + # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. + # + # @yield [result, operation] Access the result along with the TransportOperation object + # @yieldparam result [::Google::Longrunning::ListOperationsResponse] + # @yieldparam operation [::Gapic::Rest::TransportOperation] + # + # @return [::Google::Longrunning::ListOperationsResponse] + # A result object deserialized from the server's reply + def list_operations request_pb, options = nil + raise ::ArgumentError, "request must be provided" if request_pb.nil? + + verb, uri, query_string_params, body = OperationsServiceStub.transcode_list_operations_request request_pb + query_string_params = if query_string_params.any? + query_string_params.to_h { |p| p.split "=", 2 } + else + {} + end + + response = @client_stub.make_http_request( + verb, + uri: uri, + body: body || "", + params: query_string_params, + options: options + ) + operation = ::Gapic::Rest::TransportOperation.new response + result = ::Google::Longrunning::ListOperationsResponse.decode_json response.body, ignore_unknown_fields: true + + yield result, operation if block_given? + result + end + + ## + # Baseline implementation for the get_operation REST call + # + # @param request_pb [::Google::Longrunning::GetOperationRequest] + # A request object representing the call parameters. Required. + # @param options [::Gapic::CallOptions] + # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. + # + # @yield [result, operation] Access the result along with the TransportOperation object + # @yieldparam result [::Google::Longrunning::Operation] + # @yieldparam operation [::Gapic::Rest::TransportOperation] + # + # @return [::Google::Longrunning::Operation] + # A result object deserialized from the server's reply + def get_operation request_pb, options = nil + raise ::ArgumentError, "request must be provided" if request_pb.nil? + + verb, uri, query_string_params, body = OperationsServiceStub.transcode_get_operation_request request_pb + query_string_params = if query_string_params.any? + query_string_params.to_h { |p| p.split "=", 2 } + else + {} + end + + response = @client_stub.make_http_request( + verb, + uri: uri, + body: body || "", + params: query_string_params, + options: options + ) + operation = ::Gapic::Rest::TransportOperation.new response + result = ::Google::Longrunning::Operation.decode_json response.body, ignore_unknown_fields: true + + yield result, operation if block_given? + result + end + + ## + # Baseline implementation for the delete_operation REST call + # + # @param request_pb [::Google::Longrunning::DeleteOperationRequest] + # A request object representing the call parameters. Required. + # @param options [::Gapic::CallOptions] + # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. + # + # @yield [result, operation] Access the result along with the TransportOperation object + # @yieldparam result [::Google::Protobuf::Empty] + # @yieldparam operation [::Gapic::Rest::TransportOperation] + # + # @return [::Google::Protobuf::Empty] + # A result object deserialized from the server's reply + def delete_operation request_pb, options = nil + raise ::ArgumentError, "request must be provided" if request_pb.nil? + + verb, uri, query_string_params, body = OperationsServiceStub.transcode_delete_operation_request request_pb + query_string_params = if query_string_params.any? + query_string_params.to_h { |p| p.split "=", 2 } + else + {} + end + + response = @client_stub.make_http_request( + verb, + uri: uri, + body: body || "", + params: query_string_params, + options: options + ) + operation = ::Gapic::Rest::TransportOperation.new response + result = ::Google::Protobuf::Empty.decode_json response.body, ignore_unknown_fields: true + + yield result, operation if block_given? + result + end + + ## + # Baseline implementation for the cancel_operation REST call + # + # @param request_pb [::Google::Longrunning::CancelOperationRequest] + # A request object representing the call parameters. Required. + # @param options [::Gapic::CallOptions] + # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. + # + # @yield [result, operation] Access the result along with the TransportOperation object + # @yieldparam result [::Google::Protobuf::Empty] + # @yieldparam operation [::Gapic::Rest::TransportOperation] + # + # @return [::Google::Protobuf::Empty] + # A result object deserialized from the server's reply + def cancel_operation request_pb, options = nil + raise ::ArgumentError, "request must be provided" if request_pb.nil? + + verb, uri, query_string_params, body = OperationsServiceStub.transcode_cancel_operation_request request_pb + query_string_params = if query_string_params.any? + query_string_params.to_h { |p| p.split "=", 2 } + else + {} + end + + response = @client_stub.make_http_request( + verb, + uri: uri, + body: body || "", + params: query_string_params, + options: options + ) + operation = ::Gapic::Rest::TransportOperation.new response + result = ::Google::Protobuf::Empty.decode_json response.body, ignore_unknown_fields: true + + yield result, operation if block_given? + result + end + + ## + # @private + # + # GRPC transcoding helper method for the list_operations REST call + # + # @param request_pb [::Google::Longrunning::ListOperationsRequest] + # A request object representing the call parameters. Required. + # @return [Array(String, [String, nil], Hash{String => String})] + # Uri, Body, Query string parameters + def self.transcode_list_operations_request request_pb + transcoder = Gapic::Rest::GrpcTranscoder.new + .with_bindings( + uri_method: :get, + uri_template: "/v1/{name}/operations", + matches: [ + ["name", %r{^projects/[^/]+/locations/[^/]+/?$}, false] + ] + ) + transcoder.transcode request_pb + end + + ## + # @private + # + # GRPC transcoding helper method for the get_operation REST call + # + # @param request_pb [::Google::Longrunning::GetOperationRequest] + # A request object representing the call parameters. Required. + # @return [Array(String, [String, nil], Hash{String => String})] + # Uri, Body, Query string parameters + def self.transcode_get_operation_request request_pb + transcoder = Gapic::Rest::GrpcTranscoder.new + .with_bindings( + uri_method: :get, + uri_template: "/v1/{name}", + matches: [ + ["name", %r{^projects/[^/]+/locations/[^/]+/operations/[^/]+/?$}, false] + ] + ) + transcoder.transcode request_pb + end + + ## + # @private + # + # GRPC transcoding helper method for the delete_operation REST call + # + # @param request_pb [::Google::Longrunning::DeleteOperationRequest] + # A request object representing the call parameters. Required. + # @return [Array(String, [String, nil], Hash{String => String})] + # Uri, Body, Query string parameters + def self.transcode_delete_operation_request request_pb + transcoder = Gapic::Rest::GrpcTranscoder.new + .with_bindings( + uri_method: :delete, + uri_template: "/v1/{name}", + matches: [ + ["name", %r{^projects/[^/]+/locations/[^/]+/operations/[^/]+/?$}, false] + ] + ) + transcoder.transcode request_pb + end + + ## + # @private + # + # GRPC transcoding helper method for the cancel_operation REST call + # + # @param request_pb [::Google::Longrunning::CancelOperationRequest] + # A request object representing the call parameters. Required. + # @return [Array(String, [String, nil], Hash{String => String})] + # Uri, Body, Query string parameters + def self.transcode_cancel_operation_request request_pb + transcoder = Gapic::Rest::GrpcTranscoder.new + .with_bindings( + uri_method: :post, + uri_template: "/v1/{name}:cancel", + body: "*", + matches: [ + ["name", %r{^projects/[^/]+/locations/[^/]+/operations/[^/]+/?$}, false] + ] + ) + transcoder.transcode request_pb + end + end + end + end + end + end + end +end diff --git a/google-cloud-oracle_database-v1/lib/google/cloud/oracle_database/v1/oracle_database/rest/service_stub.rb b/google-cloud-oracle_database-v1/lib/google/cloud/oracle_database/v1/oracle_database/rest/service_stub.rb new file mode 100644 index 000000000000..d0ca34ef35fb --- /dev/null +++ b/google-cloud-oracle_database-v1/lib/google/cloud/oracle_database/v1/oracle_database/rest/service_stub.rb @@ -0,0 +1,1372 @@ +# frozen_string_literal: true + +# Copyright 2024 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# https://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Auto-generated by gapic-generator-ruby. DO NOT EDIT! + +require "google/cloud/oracledatabase/v1/oracledatabase_pb" + +module Google + module Cloud + module OracleDatabase + module V1 + module OracleDatabase + module Rest + ## + # REST service stub for the OracleDatabase service. + # Service stub contains baseline method implementations + # including transcoding, making the REST call, and deserialing the response. + # + class ServiceStub + def initialize endpoint:, endpoint_template:, universe_domain:, credentials: + # These require statements are intentionally placed here to initialize + # the REST modules only when it's required. + require "gapic/rest" + + @client_stub = ::Gapic::Rest::ClientStub.new endpoint: endpoint, + endpoint_template: endpoint_template, + universe_domain: universe_domain, + credentials: credentials, + numeric_enums: true, + raise_faraday_errors: false + end + + ## + # The effective universe domain + # + # @return [String] + # + def universe_domain + @client_stub.universe_domain + end + + ## + # The effective endpoint + # + # @return [String] + # + def endpoint + @client_stub.endpoint + end + + ## + # Baseline implementation for the list_cloud_exadata_infrastructures REST call + # + # @param request_pb [::Google::Cloud::OracleDatabase::V1::ListCloudExadataInfrastructuresRequest] + # A request object representing the call parameters. Required. + # @param options [::Gapic::CallOptions] + # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. + # + # @yield [result, operation] Access the result along with the TransportOperation object + # @yieldparam result [::Google::Cloud::OracleDatabase::V1::ListCloudExadataInfrastructuresResponse] + # @yieldparam operation [::Gapic::Rest::TransportOperation] + # + # @return [::Google::Cloud::OracleDatabase::V1::ListCloudExadataInfrastructuresResponse] + # A result object deserialized from the server's reply + def list_cloud_exadata_infrastructures request_pb, options = nil + raise ::ArgumentError, "request must be provided" if request_pb.nil? + + verb, uri, query_string_params, body = ServiceStub.transcode_list_cloud_exadata_infrastructures_request request_pb + query_string_params = if query_string_params.any? + query_string_params.to_h { |p| p.split "=", 2 } + else + {} + end + + response = @client_stub.make_http_request( + verb, + uri: uri, + body: body || "", + params: query_string_params, + options: options + ) + operation = ::Gapic::Rest::TransportOperation.new response + result = ::Google::Cloud::OracleDatabase::V1::ListCloudExadataInfrastructuresResponse.decode_json response.body, ignore_unknown_fields: true + + yield result, operation if block_given? + result + end + + ## + # Baseline implementation for the get_cloud_exadata_infrastructure REST call + # + # @param request_pb [::Google::Cloud::OracleDatabase::V1::GetCloudExadataInfrastructureRequest] + # A request object representing the call parameters. Required. + # @param options [::Gapic::CallOptions] + # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. + # + # @yield [result, operation] Access the result along with the TransportOperation object + # @yieldparam result [::Google::Cloud::OracleDatabase::V1::CloudExadataInfrastructure] + # @yieldparam operation [::Gapic::Rest::TransportOperation] + # + # @return [::Google::Cloud::OracleDatabase::V1::CloudExadataInfrastructure] + # A result object deserialized from the server's reply + def get_cloud_exadata_infrastructure request_pb, options = nil + raise ::ArgumentError, "request must be provided" if request_pb.nil? + + verb, uri, query_string_params, body = ServiceStub.transcode_get_cloud_exadata_infrastructure_request request_pb + query_string_params = if query_string_params.any? + query_string_params.to_h { |p| p.split "=", 2 } + else + {} + end + + response = @client_stub.make_http_request( + verb, + uri: uri, + body: body || "", + params: query_string_params, + options: options + ) + operation = ::Gapic::Rest::TransportOperation.new response + result = ::Google::Cloud::OracleDatabase::V1::CloudExadataInfrastructure.decode_json response.body, ignore_unknown_fields: true + + yield result, operation if block_given? + result + end + + ## + # Baseline implementation for the create_cloud_exadata_infrastructure REST call + # + # @param request_pb [::Google::Cloud::OracleDatabase::V1::CreateCloudExadataInfrastructureRequest] + # A request object representing the call parameters. Required. + # @param options [::Gapic::CallOptions] + # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. + # + # @yield [result, operation] Access the result along with the TransportOperation object + # @yieldparam result [::Google::Longrunning::Operation] + # @yieldparam operation [::Gapic::Rest::TransportOperation] + # + # @return [::Google::Longrunning::Operation] + # A result object deserialized from the server's reply + def create_cloud_exadata_infrastructure request_pb, options = nil + raise ::ArgumentError, "request must be provided" if request_pb.nil? + + verb, uri, query_string_params, body = ServiceStub.transcode_create_cloud_exadata_infrastructure_request request_pb + query_string_params = if query_string_params.any? + query_string_params.to_h { |p| p.split "=", 2 } + else + {} + end + + response = @client_stub.make_http_request( + verb, + uri: uri, + body: body || "", + params: query_string_params, + options: options + ) + operation = ::Gapic::Rest::TransportOperation.new response + result = ::Google::Longrunning::Operation.decode_json response.body, ignore_unknown_fields: true + + yield result, operation if block_given? + result + end + + ## + # Baseline implementation for the delete_cloud_exadata_infrastructure REST call + # + # @param request_pb [::Google::Cloud::OracleDatabase::V1::DeleteCloudExadataInfrastructureRequest] + # A request object representing the call parameters. Required. + # @param options [::Gapic::CallOptions] + # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. + # + # @yield [result, operation] Access the result along with the TransportOperation object + # @yieldparam result [::Google::Longrunning::Operation] + # @yieldparam operation [::Gapic::Rest::TransportOperation] + # + # @return [::Google::Longrunning::Operation] + # A result object deserialized from the server's reply + def delete_cloud_exadata_infrastructure request_pb, options = nil + raise ::ArgumentError, "request must be provided" if request_pb.nil? + + verb, uri, query_string_params, body = ServiceStub.transcode_delete_cloud_exadata_infrastructure_request request_pb + query_string_params = if query_string_params.any? + query_string_params.to_h { |p| p.split "=", 2 } + else + {} + end + + response = @client_stub.make_http_request( + verb, + uri: uri, + body: body || "", + params: query_string_params, + options: options + ) + operation = ::Gapic::Rest::TransportOperation.new response + result = ::Google::Longrunning::Operation.decode_json response.body, ignore_unknown_fields: true + + yield result, operation if block_given? + result + end + + ## + # Baseline implementation for the list_cloud_vm_clusters REST call + # + # @param request_pb [::Google::Cloud::OracleDatabase::V1::ListCloudVmClustersRequest] + # A request object representing the call parameters. Required. + # @param options [::Gapic::CallOptions] + # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. + # + # @yield [result, operation] Access the result along with the TransportOperation object + # @yieldparam result [::Google::Cloud::OracleDatabase::V1::ListCloudVmClustersResponse] + # @yieldparam operation [::Gapic::Rest::TransportOperation] + # + # @return [::Google::Cloud::OracleDatabase::V1::ListCloudVmClustersResponse] + # A result object deserialized from the server's reply + def list_cloud_vm_clusters request_pb, options = nil + raise ::ArgumentError, "request must be provided" if request_pb.nil? + + verb, uri, query_string_params, body = ServiceStub.transcode_list_cloud_vm_clusters_request request_pb + query_string_params = if query_string_params.any? + query_string_params.to_h { |p| p.split "=", 2 } + else + {} + end + + response = @client_stub.make_http_request( + verb, + uri: uri, + body: body || "", + params: query_string_params, + options: options + ) + operation = ::Gapic::Rest::TransportOperation.new response + result = ::Google::Cloud::OracleDatabase::V1::ListCloudVmClustersResponse.decode_json response.body, ignore_unknown_fields: true + + yield result, operation if block_given? + result + end + + ## + # Baseline implementation for the get_cloud_vm_cluster REST call + # + # @param request_pb [::Google::Cloud::OracleDatabase::V1::GetCloudVmClusterRequest] + # A request object representing the call parameters. Required. + # @param options [::Gapic::CallOptions] + # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. + # + # @yield [result, operation] Access the result along with the TransportOperation object + # @yieldparam result [::Google::Cloud::OracleDatabase::V1::CloudVmCluster] + # @yieldparam operation [::Gapic::Rest::TransportOperation] + # + # @return [::Google::Cloud::OracleDatabase::V1::CloudVmCluster] + # A result object deserialized from the server's reply + def get_cloud_vm_cluster request_pb, options = nil + raise ::ArgumentError, "request must be provided" if request_pb.nil? + + verb, uri, query_string_params, body = ServiceStub.transcode_get_cloud_vm_cluster_request request_pb + query_string_params = if query_string_params.any? + query_string_params.to_h { |p| p.split "=", 2 } + else + {} + end + + response = @client_stub.make_http_request( + verb, + uri: uri, + body: body || "", + params: query_string_params, + options: options + ) + operation = ::Gapic::Rest::TransportOperation.new response + result = ::Google::Cloud::OracleDatabase::V1::CloudVmCluster.decode_json response.body, ignore_unknown_fields: true + + yield result, operation if block_given? + result + end + + ## + # Baseline implementation for the create_cloud_vm_cluster REST call + # + # @param request_pb [::Google::Cloud::OracleDatabase::V1::CreateCloudVmClusterRequest] + # A request object representing the call parameters. Required. + # @param options [::Gapic::CallOptions] + # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. + # + # @yield [result, operation] Access the result along with the TransportOperation object + # @yieldparam result [::Google::Longrunning::Operation] + # @yieldparam operation [::Gapic::Rest::TransportOperation] + # + # @return [::Google::Longrunning::Operation] + # A result object deserialized from the server's reply + def create_cloud_vm_cluster request_pb, options = nil + raise ::ArgumentError, "request must be provided" if request_pb.nil? + + verb, uri, query_string_params, body = ServiceStub.transcode_create_cloud_vm_cluster_request request_pb + query_string_params = if query_string_params.any? + query_string_params.to_h { |p| p.split "=", 2 } + else + {} + end + + response = @client_stub.make_http_request( + verb, + uri: uri, + body: body || "", + params: query_string_params, + options: options + ) + operation = ::Gapic::Rest::TransportOperation.new response + result = ::Google::Longrunning::Operation.decode_json response.body, ignore_unknown_fields: true + + yield result, operation if block_given? + result + end + + ## + # Baseline implementation for the delete_cloud_vm_cluster REST call + # + # @param request_pb [::Google::Cloud::OracleDatabase::V1::DeleteCloudVmClusterRequest] + # A request object representing the call parameters. Required. + # @param options [::Gapic::CallOptions] + # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. + # + # @yield [result, operation] Access the result along with the TransportOperation object + # @yieldparam result [::Google::Longrunning::Operation] + # @yieldparam operation [::Gapic::Rest::TransportOperation] + # + # @return [::Google::Longrunning::Operation] + # A result object deserialized from the server's reply + def delete_cloud_vm_cluster request_pb, options = nil + raise ::ArgumentError, "request must be provided" if request_pb.nil? + + verb, uri, query_string_params, body = ServiceStub.transcode_delete_cloud_vm_cluster_request request_pb + query_string_params = if query_string_params.any? + query_string_params.to_h { |p| p.split "=", 2 } + else + {} + end + + response = @client_stub.make_http_request( + verb, + uri: uri, + body: body || "", + params: query_string_params, + options: options + ) + operation = ::Gapic::Rest::TransportOperation.new response + result = ::Google::Longrunning::Operation.decode_json response.body, ignore_unknown_fields: true + + yield result, operation if block_given? + result + end + + ## + # Baseline implementation for the list_entitlements REST call + # + # @param request_pb [::Google::Cloud::OracleDatabase::V1::ListEntitlementsRequest] + # A request object representing the call parameters. Required. + # @param options [::Gapic::CallOptions] + # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. + # + # @yield [result, operation] Access the result along with the TransportOperation object + # @yieldparam result [::Google::Cloud::OracleDatabase::V1::ListEntitlementsResponse] + # @yieldparam operation [::Gapic::Rest::TransportOperation] + # + # @return [::Google::Cloud::OracleDatabase::V1::ListEntitlementsResponse] + # A result object deserialized from the server's reply + def list_entitlements request_pb, options = nil + raise ::ArgumentError, "request must be provided" if request_pb.nil? + + verb, uri, query_string_params, body = ServiceStub.transcode_list_entitlements_request request_pb + query_string_params = if query_string_params.any? + query_string_params.to_h { |p| p.split "=", 2 } + else + {} + end + + response = @client_stub.make_http_request( + verb, + uri: uri, + body: body || "", + params: query_string_params, + options: options + ) + operation = ::Gapic::Rest::TransportOperation.new response + result = ::Google::Cloud::OracleDatabase::V1::ListEntitlementsResponse.decode_json response.body, ignore_unknown_fields: true + + yield result, operation if block_given? + result + end + + ## + # Baseline implementation for the list_db_servers REST call + # + # @param request_pb [::Google::Cloud::OracleDatabase::V1::ListDbServersRequest] + # A request object representing the call parameters. Required. + # @param options [::Gapic::CallOptions] + # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. + # + # @yield [result, operation] Access the result along with the TransportOperation object + # @yieldparam result [::Google::Cloud::OracleDatabase::V1::ListDbServersResponse] + # @yieldparam operation [::Gapic::Rest::TransportOperation] + # + # @return [::Google::Cloud::OracleDatabase::V1::ListDbServersResponse] + # A result object deserialized from the server's reply + def list_db_servers request_pb, options = nil + raise ::ArgumentError, "request must be provided" if request_pb.nil? + + verb, uri, query_string_params, body = ServiceStub.transcode_list_db_servers_request request_pb + query_string_params = if query_string_params.any? + query_string_params.to_h { |p| p.split "=", 2 } + else + {} + end + + response = @client_stub.make_http_request( + verb, + uri: uri, + body: body || "", + params: query_string_params, + options: options + ) + operation = ::Gapic::Rest::TransportOperation.new response + result = ::Google::Cloud::OracleDatabase::V1::ListDbServersResponse.decode_json response.body, ignore_unknown_fields: true + + yield result, operation if block_given? + result + end + + ## + # Baseline implementation for the list_db_nodes REST call + # + # @param request_pb [::Google::Cloud::OracleDatabase::V1::ListDbNodesRequest] + # A request object representing the call parameters. Required. + # @param options [::Gapic::CallOptions] + # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. + # + # @yield [result, operation] Access the result along with the TransportOperation object + # @yieldparam result [::Google::Cloud::OracleDatabase::V1::ListDbNodesResponse] + # @yieldparam operation [::Gapic::Rest::TransportOperation] + # + # @return [::Google::Cloud::OracleDatabase::V1::ListDbNodesResponse] + # A result object deserialized from the server's reply + def list_db_nodes request_pb, options = nil + raise ::ArgumentError, "request must be provided" if request_pb.nil? + + verb, uri, query_string_params, body = ServiceStub.transcode_list_db_nodes_request request_pb + query_string_params = if query_string_params.any? + query_string_params.to_h { |p| p.split "=", 2 } + else + {} + end + + response = @client_stub.make_http_request( + verb, + uri: uri, + body: body || "", + params: query_string_params, + options: options + ) + operation = ::Gapic::Rest::TransportOperation.new response + result = ::Google::Cloud::OracleDatabase::V1::ListDbNodesResponse.decode_json response.body, ignore_unknown_fields: true + + yield result, operation if block_given? + result + end + + ## + # Baseline implementation for the list_gi_versions REST call + # + # @param request_pb [::Google::Cloud::OracleDatabase::V1::ListGiVersionsRequest] + # A request object representing the call parameters. Required. + # @param options [::Gapic::CallOptions] + # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. + # + # @yield [result, operation] Access the result along with the TransportOperation object + # @yieldparam result [::Google::Cloud::OracleDatabase::V1::ListGiVersionsResponse] + # @yieldparam operation [::Gapic::Rest::TransportOperation] + # + # @return [::Google::Cloud::OracleDatabase::V1::ListGiVersionsResponse] + # A result object deserialized from the server's reply + def list_gi_versions request_pb, options = nil + raise ::ArgumentError, "request must be provided" if request_pb.nil? + + verb, uri, query_string_params, body = ServiceStub.transcode_list_gi_versions_request request_pb + query_string_params = if query_string_params.any? + query_string_params.to_h { |p| p.split "=", 2 } + else + {} + end + + response = @client_stub.make_http_request( + verb, + uri: uri, + body: body || "", + params: query_string_params, + options: options + ) + operation = ::Gapic::Rest::TransportOperation.new response + result = ::Google::Cloud::OracleDatabase::V1::ListGiVersionsResponse.decode_json response.body, ignore_unknown_fields: true + + yield result, operation if block_given? + result + end + + ## + # Baseline implementation for the list_db_system_shapes REST call + # + # @param request_pb [::Google::Cloud::OracleDatabase::V1::ListDbSystemShapesRequest] + # A request object representing the call parameters. Required. + # @param options [::Gapic::CallOptions] + # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. + # + # @yield [result, operation] Access the result along with the TransportOperation object + # @yieldparam result [::Google::Cloud::OracleDatabase::V1::ListDbSystemShapesResponse] + # @yieldparam operation [::Gapic::Rest::TransportOperation] + # + # @return [::Google::Cloud::OracleDatabase::V1::ListDbSystemShapesResponse] + # A result object deserialized from the server's reply + def list_db_system_shapes request_pb, options = nil + raise ::ArgumentError, "request must be provided" if request_pb.nil? + + verb, uri, query_string_params, body = ServiceStub.transcode_list_db_system_shapes_request request_pb + query_string_params = if query_string_params.any? + query_string_params.to_h { |p| p.split "=", 2 } + else + {} + end + + response = @client_stub.make_http_request( + verb, + uri: uri, + body: body || "", + params: query_string_params, + options: options + ) + operation = ::Gapic::Rest::TransportOperation.new response + result = ::Google::Cloud::OracleDatabase::V1::ListDbSystemShapesResponse.decode_json response.body, ignore_unknown_fields: true + + yield result, operation if block_given? + result + end + + ## + # Baseline implementation for the list_autonomous_databases REST call + # + # @param request_pb [::Google::Cloud::OracleDatabase::V1::ListAutonomousDatabasesRequest] + # A request object representing the call parameters. Required. + # @param options [::Gapic::CallOptions] + # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. + # + # @yield [result, operation] Access the result along with the TransportOperation object + # @yieldparam result [::Google::Cloud::OracleDatabase::V1::ListAutonomousDatabasesResponse] + # @yieldparam operation [::Gapic::Rest::TransportOperation] + # + # @return [::Google::Cloud::OracleDatabase::V1::ListAutonomousDatabasesResponse] + # A result object deserialized from the server's reply + def list_autonomous_databases request_pb, options = nil + raise ::ArgumentError, "request must be provided" if request_pb.nil? + + verb, uri, query_string_params, body = ServiceStub.transcode_list_autonomous_databases_request request_pb + query_string_params = if query_string_params.any? + query_string_params.to_h { |p| p.split "=", 2 } + else + {} + end + + response = @client_stub.make_http_request( + verb, + uri: uri, + body: body || "", + params: query_string_params, + options: options + ) + operation = ::Gapic::Rest::TransportOperation.new response + result = ::Google::Cloud::OracleDatabase::V1::ListAutonomousDatabasesResponse.decode_json response.body, ignore_unknown_fields: true + + yield result, operation if block_given? + result + end + + ## + # Baseline implementation for the get_autonomous_database REST call + # + # @param request_pb [::Google::Cloud::OracleDatabase::V1::GetAutonomousDatabaseRequest] + # A request object representing the call parameters. Required. + # @param options [::Gapic::CallOptions] + # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. + # + # @yield [result, operation] Access the result along with the TransportOperation object + # @yieldparam result [::Google::Cloud::OracleDatabase::V1::AutonomousDatabase] + # @yieldparam operation [::Gapic::Rest::TransportOperation] + # + # @return [::Google::Cloud::OracleDatabase::V1::AutonomousDatabase] + # A result object deserialized from the server's reply + def get_autonomous_database request_pb, options = nil + raise ::ArgumentError, "request must be provided" if request_pb.nil? + + verb, uri, query_string_params, body = ServiceStub.transcode_get_autonomous_database_request request_pb + query_string_params = if query_string_params.any? + query_string_params.to_h { |p| p.split "=", 2 } + else + {} + end + + response = @client_stub.make_http_request( + verb, + uri: uri, + body: body || "", + params: query_string_params, + options: options + ) + operation = ::Gapic::Rest::TransportOperation.new response + result = ::Google::Cloud::OracleDatabase::V1::AutonomousDatabase.decode_json response.body, ignore_unknown_fields: true + + yield result, operation if block_given? + result + end + + ## + # Baseline implementation for the create_autonomous_database REST call + # + # @param request_pb [::Google::Cloud::OracleDatabase::V1::CreateAutonomousDatabaseRequest] + # A request object representing the call parameters. Required. + # @param options [::Gapic::CallOptions] + # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. + # + # @yield [result, operation] Access the result along with the TransportOperation object + # @yieldparam result [::Google::Longrunning::Operation] + # @yieldparam operation [::Gapic::Rest::TransportOperation] + # + # @return [::Google::Longrunning::Operation] + # A result object deserialized from the server's reply + def create_autonomous_database request_pb, options = nil + raise ::ArgumentError, "request must be provided" if request_pb.nil? + + verb, uri, query_string_params, body = ServiceStub.transcode_create_autonomous_database_request request_pb + query_string_params = if query_string_params.any? + query_string_params.to_h { |p| p.split "=", 2 } + else + {} + end + + response = @client_stub.make_http_request( + verb, + uri: uri, + body: body || "", + params: query_string_params, + options: options + ) + operation = ::Gapic::Rest::TransportOperation.new response + result = ::Google::Longrunning::Operation.decode_json response.body, ignore_unknown_fields: true + + yield result, operation if block_given? + result + end + + ## + # Baseline implementation for the delete_autonomous_database REST call + # + # @param request_pb [::Google::Cloud::OracleDatabase::V1::DeleteAutonomousDatabaseRequest] + # A request object representing the call parameters. Required. + # @param options [::Gapic::CallOptions] + # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. + # + # @yield [result, operation] Access the result along with the TransportOperation object + # @yieldparam result [::Google::Longrunning::Operation] + # @yieldparam operation [::Gapic::Rest::TransportOperation] + # + # @return [::Google::Longrunning::Operation] + # A result object deserialized from the server's reply + def delete_autonomous_database request_pb, options = nil + raise ::ArgumentError, "request must be provided" if request_pb.nil? + + verb, uri, query_string_params, body = ServiceStub.transcode_delete_autonomous_database_request request_pb + query_string_params = if query_string_params.any? + query_string_params.to_h { |p| p.split "=", 2 } + else + {} + end + + response = @client_stub.make_http_request( + verb, + uri: uri, + body: body || "", + params: query_string_params, + options: options + ) + operation = ::Gapic::Rest::TransportOperation.new response + result = ::Google::Longrunning::Operation.decode_json response.body, ignore_unknown_fields: true + + yield result, operation if block_given? + result + end + + ## + # Baseline implementation for the restore_autonomous_database REST call + # + # @param request_pb [::Google::Cloud::OracleDatabase::V1::RestoreAutonomousDatabaseRequest] + # A request object representing the call parameters. Required. + # @param options [::Gapic::CallOptions] + # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. + # + # @yield [result, operation] Access the result along with the TransportOperation object + # @yieldparam result [::Google::Longrunning::Operation] + # @yieldparam operation [::Gapic::Rest::TransportOperation] + # + # @return [::Google::Longrunning::Operation] + # A result object deserialized from the server's reply + def restore_autonomous_database request_pb, options = nil + raise ::ArgumentError, "request must be provided" if request_pb.nil? + + verb, uri, query_string_params, body = ServiceStub.transcode_restore_autonomous_database_request request_pb + query_string_params = if query_string_params.any? + query_string_params.to_h { |p| p.split "=", 2 } + else + {} + end + + response = @client_stub.make_http_request( + verb, + uri: uri, + body: body || "", + params: query_string_params, + options: options + ) + operation = ::Gapic::Rest::TransportOperation.new response + result = ::Google::Longrunning::Operation.decode_json response.body, ignore_unknown_fields: true + + yield result, operation if block_given? + result + end + + ## + # Baseline implementation for the generate_autonomous_database_wallet REST call + # + # @param request_pb [::Google::Cloud::OracleDatabase::V1::GenerateAutonomousDatabaseWalletRequest] + # A request object representing the call parameters. Required. + # @param options [::Gapic::CallOptions] + # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. + # + # @yield [result, operation] Access the result along with the TransportOperation object + # @yieldparam result [::Google::Cloud::OracleDatabase::V1::GenerateAutonomousDatabaseWalletResponse] + # @yieldparam operation [::Gapic::Rest::TransportOperation] + # + # @return [::Google::Cloud::OracleDatabase::V1::GenerateAutonomousDatabaseWalletResponse] + # A result object deserialized from the server's reply + def generate_autonomous_database_wallet request_pb, options = nil + raise ::ArgumentError, "request must be provided" if request_pb.nil? + + verb, uri, query_string_params, body = ServiceStub.transcode_generate_autonomous_database_wallet_request request_pb + query_string_params = if query_string_params.any? + query_string_params.to_h { |p| p.split "=", 2 } + else + {} + end + + response = @client_stub.make_http_request( + verb, + uri: uri, + body: body || "", + params: query_string_params, + options: options + ) + operation = ::Gapic::Rest::TransportOperation.new response + result = ::Google::Cloud::OracleDatabase::V1::GenerateAutonomousDatabaseWalletResponse.decode_json response.body, ignore_unknown_fields: true + + yield result, operation if block_given? + result + end + + ## + # Baseline implementation for the list_autonomous_db_versions REST call + # + # @param request_pb [::Google::Cloud::OracleDatabase::V1::ListAutonomousDbVersionsRequest] + # A request object representing the call parameters. Required. + # @param options [::Gapic::CallOptions] + # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. + # + # @yield [result, operation] Access the result along with the TransportOperation object + # @yieldparam result [::Google::Cloud::OracleDatabase::V1::ListAutonomousDbVersionsResponse] + # @yieldparam operation [::Gapic::Rest::TransportOperation] + # + # @return [::Google::Cloud::OracleDatabase::V1::ListAutonomousDbVersionsResponse] + # A result object deserialized from the server's reply + def list_autonomous_db_versions request_pb, options = nil + raise ::ArgumentError, "request must be provided" if request_pb.nil? + + verb, uri, query_string_params, body = ServiceStub.transcode_list_autonomous_db_versions_request request_pb + query_string_params = if query_string_params.any? + query_string_params.to_h { |p| p.split "=", 2 } + else + {} + end + + response = @client_stub.make_http_request( + verb, + uri: uri, + body: body || "", + params: query_string_params, + options: options + ) + operation = ::Gapic::Rest::TransportOperation.new response + result = ::Google::Cloud::OracleDatabase::V1::ListAutonomousDbVersionsResponse.decode_json response.body, ignore_unknown_fields: true + + yield result, operation if block_given? + result + end + + ## + # Baseline implementation for the list_autonomous_database_character_sets REST call + # + # @param request_pb [::Google::Cloud::OracleDatabase::V1::ListAutonomousDatabaseCharacterSetsRequest] + # A request object representing the call parameters. Required. + # @param options [::Gapic::CallOptions] + # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. + # + # @yield [result, operation] Access the result along with the TransportOperation object + # @yieldparam result [::Google::Cloud::OracleDatabase::V1::ListAutonomousDatabaseCharacterSetsResponse] + # @yieldparam operation [::Gapic::Rest::TransportOperation] + # + # @return [::Google::Cloud::OracleDatabase::V1::ListAutonomousDatabaseCharacterSetsResponse] + # A result object deserialized from the server's reply + def list_autonomous_database_character_sets request_pb, options = nil + raise ::ArgumentError, "request must be provided" if request_pb.nil? + + verb, uri, query_string_params, body = ServiceStub.transcode_list_autonomous_database_character_sets_request request_pb + query_string_params = if query_string_params.any? + query_string_params.to_h { |p| p.split "=", 2 } + else + {} + end + + response = @client_stub.make_http_request( + verb, + uri: uri, + body: body || "", + params: query_string_params, + options: options + ) + operation = ::Gapic::Rest::TransportOperation.new response + result = ::Google::Cloud::OracleDatabase::V1::ListAutonomousDatabaseCharacterSetsResponse.decode_json response.body, ignore_unknown_fields: true + + yield result, operation if block_given? + result + end + + ## + # Baseline implementation for the list_autonomous_database_backups REST call + # + # @param request_pb [::Google::Cloud::OracleDatabase::V1::ListAutonomousDatabaseBackupsRequest] + # A request object representing the call parameters. Required. + # @param options [::Gapic::CallOptions] + # Overrides the default settings for this call, e.g, timeout, retries etc. Optional. + # + # @yield [result, operation] Access the result along with the TransportOperation object + # @yieldparam result [::Google::Cloud::OracleDatabase::V1::ListAutonomousDatabaseBackupsResponse] + # @yieldparam operation [::Gapic::Rest::TransportOperation] + # + # @return [::Google::Cloud::OracleDatabase::V1::ListAutonomousDatabaseBackupsResponse] + # A result object deserialized from the server's reply + def list_autonomous_database_backups request_pb, options = nil + raise ::ArgumentError, "request must be provided" if request_pb.nil? + + verb, uri, query_string_params, body = ServiceStub.transcode_list_autonomous_database_backups_request request_pb + query_string_params = if query_string_params.any? + query_string_params.to_h { |p| p.split "=", 2 } + else + {} + end + + response = @client_stub.make_http_request( + verb, + uri: uri, + body: body || "", + params: query_string_params, + options: options + ) + operation = ::Gapic::Rest::TransportOperation.new response + result = ::Google::Cloud::OracleDatabase::V1::ListAutonomousDatabaseBackupsResponse.decode_json response.body, ignore_unknown_fields: true + + yield result, operation if block_given? + result + end + + ## + # @private + # + # GRPC transcoding helper method for the list_cloud_exadata_infrastructures REST call + # + # @param request_pb [::Google::Cloud::OracleDatabase::V1::ListCloudExadataInfrastructuresRequest] + # A request object representing the call parameters. Required. + # @return [Array(String, [String, nil], Hash{String => String})] + # Uri, Body, Query string parameters + def self.transcode_list_cloud_exadata_infrastructures_request request_pb + transcoder = Gapic::Rest::GrpcTranscoder.new + .with_bindings( + uri_method: :get, + uri_template: "/v1/{parent}/cloudExadataInfrastructures", + matches: [ + ["parent", %r{^projects/[^/]+/locations/[^/]+/?$}, false] + ] + ) + transcoder.transcode request_pb + end + + ## + # @private + # + # GRPC transcoding helper method for the get_cloud_exadata_infrastructure REST call + # + # @param request_pb [::Google::Cloud::OracleDatabase::V1::GetCloudExadataInfrastructureRequest] + # A request object representing the call parameters. Required. + # @return [Array(String, [String, nil], Hash{String => String})] + # Uri, Body, Query string parameters + def self.transcode_get_cloud_exadata_infrastructure_request request_pb + transcoder = Gapic::Rest::GrpcTranscoder.new + .with_bindings( + uri_method: :get, + uri_template: "/v1/{name}", + matches: [ + ["name", %r{^projects/[^/]+/locations/[^/]+/cloudExadataInfrastructures/[^/]+/?$}, false] + ] + ) + transcoder.transcode request_pb + end + + ## + # @private + # + # GRPC transcoding helper method for the create_cloud_exadata_infrastructure REST call + # + # @param request_pb [::Google::Cloud::OracleDatabase::V1::CreateCloudExadataInfrastructureRequest] + # A request object representing the call parameters. Required. + # @return [Array(String, [String, nil], Hash{String => String})] + # Uri, Body, Query string parameters + def self.transcode_create_cloud_exadata_infrastructure_request request_pb + transcoder = Gapic::Rest::GrpcTranscoder.new + .with_bindings( + uri_method: :post, + uri_template: "/v1/{parent}/cloudExadataInfrastructures", + body: "cloud_exadata_infrastructure", + matches: [ + ["parent", %r{^projects/[^/]+/locations/[^/]+/?$}, false] + ] + ) + transcoder.transcode request_pb + end + + ## + # @private + # + # GRPC transcoding helper method for the delete_cloud_exadata_infrastructure REST call + # + # @param request_pb [::Google::Cloud::OracleDatabase::V1::DeleteCloudExadataInfrastructureRequest] + # A request object representing the call parameters. Required. + # @return [Array(String, [String, nil], Hash{String => String})] + # Uri, Body, Query string parameters + def self.transcode_delete_cloud_exadata_infrastructure_request request_pb + transcoder = Gapic::Rest::GrpcTranscoder.new + .with_bindings( + uri_method: :delete, + uri_template: "/v1/{name}", + matches: [ + ["name", %r{^projects/[^/]+/locations/[^/]+/cloudExadataInfrastructures/[^/]+/?$}, false] + ] + ) + transcoder.transcode request_pb + end + + ## + # @private + # + # GRPC transcoding helper method for the list_cloud_vm_clusters REST call + # + # @param request_pb [::Google::Cloud::OracleDatabase::V1::ListCloudVmClustersRequest] + # A request object representing the call parameters. Required. + # @return [Array(String, [String, nil], Hash{String => String})] + # Uri, Body, Query string parameters + def self.transcode_list_cloud_vm_clusters_request request_pb + transcoder = Gapic::Rest::GrpcTranscoder.new + .with_bindings( + uri_method: :get, + uri_template: "/v1/{parent}/cloudVmClusters", + matches: [ + ["parent", %r{^projects/[^/]+/locations/[^/]+/?$}, false] + ] + ) + transcoder.transcode request_pb + end + + ## + # @private + # + # GRPC transcoding helper method for the get_cloud_vm_cluster REST call + # + # @param request_pb [::Google::Cloud::OracleDatabase::V1::GetCloudVmClusterRequest] + # A request object representing the call parameters. Required. + # @return [Array(String, [String, nil], Hash{String => String})] + # Uri, Body, Query string parameters + def self.transcode_get_cloud_vm_cluster_request request_pb + transcoder = Gapic::Rest::GrpcTranscoder.new + .with_bindings( + uri_method: :get, + uri_template: "/v1/{name}", + matches: [ + ["name", %r{^projects/[^/]+/locations/[^/]+/cloudVmClusters/[^/]+/?$}, false] + ] + ) + transcoder.transcode request_pb + end + + ## + # @private + # + # GRPC transcoding helper method for the create_cloud_vm_cluster REST call + # + # @param request_pb [::Google::Cloud::OracleDatabase::V1::CreateCloudVmClusterRequest] + # A request object representing the call parameters. Required. + # @return [Array(String, [String, nil], Hash{String => String})] + # Uri, Body, Query string parameters + def self.transcode_create_cloud_vm_cluster_request request_pb + transcoder = Gapic::Rest::GrpcTranscoder.new + .with_bindings( + uri_method: :post, + uri_template: "/v1/{parent}/cloudVmClusters", + body: "cloud_vm_cluster", + matches: [ + ["parent", %r{^projects/[^/]+/locations/[^/]+/?$}, false] + ] + ) + transcoder.transcode request_pb + end + + ## + # @private + # + # GRPC transcoding helper method for the delete_cloud_vm_cluster REST call + # + # @param request_pb [::Google::Cloud::OracleDatabase::V1::DeleteCloudVmClusterRequest] + # A request object representing the call parameters. Required. + # @return [Array(String, [String, nil], Hash{String => String})] + # Uri, Body, Query string parameters + def self.transcode_delete_cloud_vm_cluster_request request_pb + transcoder = Gapic::Rest::GrpcTranscoder.new + .with_bindings( + uri_method: :delete, + uri_template: "/v1/{name}", + matches: [ + ["name", %r{^projects/[^/]+/locations/[^/]+/cloudVmClusters/[^/]+/?$}, false] + ] + ) + transcoder.transcode request_pb + end + + ## + # @private + # + # GRPC transcoding helper method for the list_entitlements REST call + # + # @param request_pb [::Google::Cloud::OracleDatabase::V1::ListEntitlementsRequest] + # A request object representing the call parameters. Required. + # @return [Array(String, [String, nil], Hash{String => String})] + # Uri, Body, Query string parameters + def self.transcode_list_entitlements_request request_pb + transcoder = Gapic::Rest::GrpcTranscoder.new + .with_bindings( + uri_method: :get, + uri_template: "/v1/{parent}/entitlements", + matches: [ + ["parent", %r{^projects/[^/]+/locations/[^/]+/?$}, false] + ] + ) + transcoder.transcode request_pb + end + + ## + # @private + # + # GRPC transcoding helper method for the list_db_servers REST call + # + # @param request_pb [::Google::Cloud::OracleDatabase::V1::ListDbServersRequest] + # A request object representing the call parameters. Required. + # @return [Array(String, [String, nil], Hash{String => String})] + # Uri, Body, Query string parameters + def self.transcode_list_db_servers_request request_pb + transcoder = Gapic::Rest::GrpcTranscoder.new + .with_bindings( + uri_method: :get, + uri_template: "/v1/{parent}/dbServers", + matches: [ + ["parent", %r{^projects/[^/]+/locations/[^/]+/cloudExadataInfrastructures/[^/]+/?$}, false] + ] + ) + transcoder.transcode request_pb + end + + ## + # @private + # + # GRPC transcoding helper method for the list_db_nodes REST call + # + # @param request_pb [::Google::Cloud::OracleDatabase::V1::ListDbNodesRequest] + # A request object representing the call parameters. Required. + # @return [Array(String, [String, nil], Hash{String => String})] + # Uri, Body, Query string parameters + def self.transcode_list_db_nodes_request request_pb + transcoder = Gapic::Rest::GrpcTranscoder.new + .with_bindings( + uri_method: :get, + uri_template: "/v1/{parent}/dbNodes", + matches: [ + ["parent", %r{^projects/[^/]+/locations/[^/]+/cloudVmClusters/[^/]+/?$}, false] + ] + ) + transcoder.transcode request_pb + end + + ## + # @private + # + # GRPC transcoding helper method for the list_gi_versions REST call + # + # @param request_pb [::Google::Cloud::OracleDatabase::V1::ListGiVersionsRequest] + # A request object representing the call parameters. Required. + # @return [Array(String, [String, nil], Hash{String => String})] + # Uri, Body, Query string parameters + def self.transcode_list_gi_versions_request request_pb + transcoder = Gapic::Rest::GrpcTranscoder.new + .with_bindings( + uri_method: :get, + uri_template: "/v1/{parent}/giVersions", + matches: [ + ["parent", %r{^projects/[^/]+/locations/[^/]+/?$}, false] + ] + ) + transcoder.transcode request_pb + end + + ## + # @private + # + # GRPC transcoding helper method for the list_db_system_shapes REST call + # + # @param request_pb [::Google::Cloud::OracleDatabase::V1::ListDbSystemShapesRequest] + # A request object representing the call parameters. Required. + # @return [Array(String, [String, nil], Hash{String => String})] + # Uri, Body, Query string parameters + def self.transcode_list_db_system_shapes_request request_pb + transcoder = Gapic::Rest::GrpcTranscoder.new + .with_bindings( + uri_method: :get, + uri_template: "/v1/{parent}/dbSystemShapes", + matches: [ + ["parent", %r{^projects/[^/]+/locations/[^/]+/?$}, false] + ] + ) + transcoder.transcode request_pb + end + + ## + # @private + # + # GRPC transcoding helper method for the list_autonomous_databases REST call + # + # @param request_pb [::Google::Cloud::OracleDatabase::V1::ListAutonomousDatabasesRequest] + # A request object representing the call parameters. Required. + # @return [Array(String, [String, nil], Hash{String => String})] + # Uri, Body, Query string parameters + def self.transcode_list_autonomous_databases_request request_pb + transcoder = Gapic::Rest::GrpcTranscoder.new + .with_bindings( + uri_method: :get, + uri_template: "/v1/{parent}/autonomousDatabases", + matches: [ + ["parent", %r{^projects/[^/]+/locations/[^/]+/?$}, false] + ] + ) + transcoder.transcode request_pb + end + + ## + # @private + # + # GRPC transcoding helper method for the get_autonomous_database REST call + # + # @param request_pb [::Google::Cloud::OracleDatabase::V1::GetAutonomousDatabaseRequest] + # A request object representing the call parameters. Required. + # @return [Array(String, [String, nil], Hash{String => String})] + # Uri, Body, Query string parameters + def self.transcode_get_autonomous_database_request request_pb + transcoder = Gapic::Rest::GrpcTranscoder.new + .with_bindings( + uri_method: :get, + uri_template: "/v1/{name}", + matches: [ + ["name", %r{^projects/[^/]+/locations/[^/]+/autonomousDatabases/[^/]+/?$}, false] + ] + ) + transcoder.transcode request_pb + end + + ## + # @private + # + # GRPC transcoding helper method for the create_autonomous_database REST call + # + # @param request_pb [::Google::Cloud::OracleDatabase::V1::CreateAutonomousDatabaseRequest] + # A request object representing the call parameters. Required. + # @return [Array(String, [String, nil], Hash{String => String})] + # Uri, Body, Query string parameters + def self.transcode_create_autonomous_database_request request_pb + transcoder = Gapic::Rest::GrpcTranscoder.new + .with_bindings( + uri_method: :post, + uri_template: "/v1/{parent}/autonomousDatabases", + body: "autonomous_database", + matches: [ + ["parent", %r{^projects/[^/]+/locations/[^/]+/?$}, false] + ] + ) + transcoder.transcode request_pb + end + + ## + # @private + # + # GRPC transcoding helper method for the delete_autonomous_database REST call + # + # @param request_pb [::Google::Cloud::OracleDatabase::V1::DeleteAutonomousDatabaseRequest] + # A request object representing the call parameters. Required. + # @return [Array(String, [String, nil], Hash{String => String})] + # Uri, Body, Query string parameters + def self.transcode_delete_autonomous_database_request request_pb + transcoder = Gapic::Rest::GrpcTranscoder.new + .with_bindings( + uri_method: :delete, + uri_template: "/v1/{name}", + matches: [ + ["name", %r{^projects/[^/]+/locations/[^/]+/autonomousDatabases/[^/]+/?$}, false] + ] + ) + transcoder.transcode request_pb + end + + ## + # @private + # + # GRPC transcoding helper method for the restore_autonomous_database REST call + # + # @param request_pb [::Google::Cloud::OracleDatabase::V1::RestoreAutonomousDatabaseRequest] + # A request object representing the call parameters. Required. + # @return [Array(String, [String, nil], Hash{String => String})] + # Uri, Body, Query string parameters + def self.transcode_restore_autonomous_database_request request_pb + transcoder = Gapic::Rest::GrpcTranscoder.new + .with_bindings( + uri_method: :post, + uri_template: "/v1/{name}:restore", + body: "*", + matches: [ + ["name", %r{^projects/[^/]+/locations/[^/]+/autonomousDatabases/[^/]+/?$}, false] + ] + ) + transcoder.transcode request_pb + end + + ## + # @private + # + # GRPC transcoding helper method for the generate_autonomous_database_wallet REST call + # + # @param request_pb [::Google::Cloud::OracleDatabase::V1::GenerateAutonomousDatabaseWalletRequest] + # A request object representing the call parameters. Required. + # @return [Array(String, [String, nil], Hash{String => String})] + # Uri, Body, Query string parameters + def self.transcode_generate_autonomous_database_wallet_request request_pb + transcoder = Gapic::Rest::GrpcTranscoder.new + .with_bindings( + uri_method: :post, + uri_template: "/v1/{name}:generateWallet", + body: "*", + matches: [ + ["name", %r{^projects/[^/]+/locations/[^/]+/autonomousDatabases/[^/]+/?$}, false] + ] + ) + transcoder.transcode request_pb + end + + ## + # @private + # + # GRPC transcoding helper method for the list_autonomous_db_versions REST call + # + # @param request_pb [::Google::Cloud::OracleDatabase::V1::ListAutonomousDbVersionsRequest] + # A request object representing the call parameters. Required. + # @return [Array(String, [String, nil], Hash{String => String})] + # Uri, Body, Query string parameters + def self.transcode_list_autonomous_db_versions_request request_pb + transcoder = Gapic::Rest::GrpcTranscoder.new + .with_bindings( + uri_method: :get, + uri_template: "/v1/{parent}/autonomousDbVersions", + matches: [ + ["parent", %r{^projects/[^/]+/locations/[^/]+/?$}, false] + ] + ) + transcoder.transcode request_pb + end + + ## + # @private + # + # GRPC transcoding helper method for the list_autonomous_database_character_sets REST call + # + # @param request_pb [::Google::Cloud::OracleDatabase::V1::ListAutonomousDatabaseCharacterSetsRequest] + # A request object representing the call parameters. Required. + # @return [Array(String, [String, nil], Hash{String => String})] + # Uri, Body, Query string parameters + def self.transcode_list_autonomous_database_character_sets_request request_pb + transcoder = Gapic::Rest::GrpcTranscoder.new + .with_bindings( + uri_method: :get, + uri_template: "/v1/{parent}/autonomousDatabaseCharacterSets", + matches: [ + ["parent", %r{^projects/[^/]+/locations/[^/]+/?$}, false] + ] + ) + transcoder.transcode request_pb + end + + ## + # @private + # + # GRPC transcoding helper method for the list_autonomous_database_backups REST call + # + # @param request_pb [::Google::Cloud::OracleDatabase::V1::ListAutonomousDatabaseBackupsRequest] + # A request object representing the call parameters. Required. + # @return [Array(String, [String, nil], Hash{String => String})] + # Uri, Body, Query string parameters + def self.transcode_list_autonomous_database_backups_request request_pb + transcoder = Gapic::Rest::GrpcTranscoder.new + .with_bindings( + uri_method: :get, + uri_template: "/v1/{parent}/autonomousDatabaseBackups", + matches: [ + ["parent", %r{^projects/[^/]+/locations/[^/]+/?$}, false] + ] + ) + transcoder.transcode request_pb + end + end + end + end + end + end + end +end diff --git a/google-cloud-oracle_database-v1/lib/google/cloud/oracle_database/v1/rest.rb b/google-cloud-oracle_database-v1/lib/google/cloud/oracle_database/v1/rest.rb new file mode 100644 index 000000000000..dfb415755816 --- /dev/null +++ b/google-cloud-oracle_database-v1/lib/google/cloud/oracle_database/v1/rest.rb @@ -0,0 +1,38 @@ +# frozen_string_literal: true + +# Copyright 2024 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# https://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Auto-generated by gapic-generator-ruby. DO NOT EDIT! + +require "google/cloud/oracle_database/v1/oracle_database/rest" +require "google/cloud/oracle_database/v1/bindings_override" +require "google/cloud/oracle_database/v1/version" + +module Google + module Cloud + module OracleDatabase + ## + # To load just the REST part of this package, including all its services, and instantiate a REST client: + # + # @example + # + # require "google/cloud/oracle_database/v1/rest" + # client = ::Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::Client.new + # + module V1 + end + end + end +end diff --git a/google-cloud-oracle_database-v1/lib/google/cloud/oracle_database/v1/version.rb b/google-cloud-oracle_database-v1/lib/google/cloud/oracle_database/v1/version.rb new file mode 100644 index 000000000000..d6a85d15fd55 --- /dev/null +++ b/google-cloud-oracle_database-v1/lib/google/cloud/oracle_database/v1/version.rb @@ -0,0 +1,28 @@ +# frozen_string_literal: true + +# Copyright 2024 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# https://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Auto-generated by gapic-generator-ruby. DO NOT EDIT! + + +module Google + module Cloud + module OracleDatabase + module V1 + VERSION = "0.0.1" + end + end + end +end diff --git a/google-cloud-oracle_database-v1/lib/google/cloud/oracledatabase/v1/autonomous_database_character_set_pb.rb b/google-cloud-oracle_database-v1/lib/google/cloud/oracledatabase/v1/autonomous_database_character_set_pb.rb new file mode 100644 index 000000000000..366f67852570 --- /dev/null +++ b/google-cloud-oracle_database-v1/lib/google/cloud/oracledatabase/v1/autonomous_database_character_set_pb.rb @@ -0,0 +1,46 @@ +# frozen_string_literal: true +# Generated by the protocol buffer compiler. DO NOT EDIT! +# source: google/cloud/oracledatabase/v1/autonomous_database_character_set.proto + +require 'google/protobuf' + +require 'google/api/field_behavior_pb' +require 'google/api/resource_pb' + + +descriptor_data = "\nFgoogle/cloud/oracledatabase/v1/autonomous_database_character_set.proto\x12\x1egoogle.cloud.oracledatabase.v1\x1a\x1fgoogle/api/field_behavior.proto\x1a\x19google/api/resource.proto\"\x88\x04\n\x1e\x41utonomousDatabaseCharacterSet\x12\x11\n\x04name\x18\x01 \x01(\tB\x03\xe0\x41\x08\x12p\n\x12\x63haracter_set_type\x18\x02 \x01(\x0e\x32O.google.cloud.oracledatabase.v1.AutonomousDatabaseCharacterSet.CharacterSetTypeB\x03\xe0\x41\x03\x12\x1a\n\rcharacter_set\x18\x03 \x01(\tB\x03\xe0\x41\x03\"R\n\x10\x43haracterSetType\x12\"\n\x1e\x43HARACTER_SET_TYPE_UNSPECIFIED\x10\x00\x12\x0c\n\x08\x44\x41TABASE\x10\x01\x12\x0c\n\x08NATIONAL\x10\x02:\xf0\x01\xea\x41\xec\x01\n.google.cloud.oracledatabase.v1.AutonomousDatabase.LabelsEntryB\x03\xe0\x41\x01\x12\x37\n\x07network\x18\t \x01(\tB&\xe0\x41\x02\xfa\x41 \n\x1e\x63ompute.googleapis.com/Network\x12\x11\n\x04\x63idr\x18\n \x01(\tB\x03\xe0\x41\x02\x12\x34\n\x0b\x63reate_time\x18\r \x01(\x0b\x32\x1a.google.protobuf.TimestampB\x03\xe0\x41\x03\x1a-\n\x0bLabelsEntry\x12\x0b\n\x03key\x18\x01 \x01(\t\x12\r\n\x05value\x18\x02 \x01(\t:\x02\x38\x01:\xb2\x01\xea\x41\xae\x01\n0oracledatabase.googleapis.com/AutonomousDatabase\x12Qprojects/{project}/locations/{location}/autonomousDatabases/{autonomous_database}*\x13\x61utonomousDatabases2\x12\x61utonomousDatabase\"\xb7$\n\x1c\x41utonomousDatabaseProperties\x12\x11\n\x04ocid\x18\x01 \x01(\tB\x03\xe0\x41\x03\x12\x1a\n\rcompute_count\x18\x02 \x01(\x02\x42\x03\xe0\x41\x01\x12\x1b\n\x0e\x63pu_core_count\x18\x03 \x01(\x05\x42\x03\xe0\x41\x01\x12!\n\x14\x64\x61ta_storage_size_tb\x18\x04 \x01(\x05\x42\x03\xe0\x41\x01\x12!\n\x14\x64\x61ta_storage_size_gb\x18? \x01(\x05\x42\x03\xe0\x41\x01\x12\x44\n\x0b\x64\x62_workload\x18\x05 \x01(\x0e\x32*.google.cloud.oracledatabase.v1.DBWorkloadB\x03\xe0\x41\x02\x12\x65\n\ndb_edition\x18\x06 \x01(\x0e\x32L.google.cloud.oracledatabase.v1.AutonomousDatabaseProperties.DatabaseEditionB\x03\xe0\x41\x01\x12\x1a\n\rcharacter_set\x18\x08 \x01(\tB\x03\xe0\x41\x01\x12\x1c\n\x0fn_character_set\x18\t \x01(\tB\x03\xe0\x41\x01\x12 \n\x13private_endpoint_ip\x18\n \x01(\tB\x03\xe0\x41\x01\x12#\n\x16private_endpoint_label\x18\x0b \x01(\tB\x03\xe0\x41\x01\x12\x17\n\ndb_version\x18\x0c \x01(\tB\x03\xe0\x41\x01\x12$\n\x17is_auto_scaling_enabled\x18\x0e \x01(\x08\x42\x03\xe0\x41\x01\x12,\n\x1fis_storage_auto_scaling_enabled\x18\x0f \x01(\x08\x42\x03\xe0\x41\x01\x12\x63\n\x0clicense_type\x18\x10 \x01(\x0e\x32H.google.cloud.oracledatabase.v1.AutonomousDatabaseProperties.LicenseTypeB\x03\xe0\x41\x02\x12O\n\x11\x63ustomer_contacts\x18\x11 \x03(\x0b\x32/.google.cloud.oracledatabase.v1.CustomerContactB\x03\xe0\x41\x01\x12\x16\n\tsecret_id\x18\x12 \x01(\tB\x03\xe0\x41\x01\x12\x15\n\x08vault_id\x18\x13 \x01(\tB\x03\xe0\x41\x01\x12|\n\x19maintenance_schedule_type\x18\x14 \x01(\x0e\x32T.google.cloud.oracledatabase.v1.AutonomousDatabaseProperties.MaintenanceScheduleTypeB\x03\xe0\x41\x01\x12%\n\x18mtls_connection_required\x18\" \x01(\x08\x42\x03\xe0\x41\x01\x12)\n\x1c\x62\x61\x63kup_retention_period_days\x18\x39 \x01(\x05\x42\x03\xe0\x41\x01\x12-\n actual_used_data_storage_size_tb\x18\x15 \x01(\x01\x42\x03\xe0\x41\x03\x12&\n\x19\x61llocated_storage_size_tb\x18\x16 \x01(\x01\x42\x03\xe0\x41\x03\x12Q\n\x0c\x61pex_details\x18\x17 \x01(\x0b\x32\x36.google.cloud.oracledatabase.v1.AutonomousDatabaseApexB\x03\xe0\x41\x03\x12\x32\n are_primary_allowlisted_ips_used\x18\x18 \x01(\x08\x42\x03\xe0\x41\x03H\x00\x88\x01\x01\x12\x1e\n\x11lifecycle_details\x18\x19 \x01(\tB\x03\xe0\x41\x03\x12\x39\n\x05state\x18\x1a \x01(\x0e\x32%.google.cloud.oracledatabase.v1.StateB\x03\xe0\x41\x03\x12-\n autonomous_container_database_id\x18\x1b \x01(\tB\x03\xe0\x41\x03\x12\'\n\x1a\x61vailable_upgrade_versions\x18\x1c \x03(\tB\x03\xe0\x41\x03\x12\x64\n\x12\x63onnection_strings\x18\x1d \x01(\x0b\x32\x43.google.cloud.oracledatabase.v1.AutonomousDatabaseConnectionStringsB\x03\xe0\x41\x03\x12^\n\x0f\x63onnection_urls\x18\x1e \x01(\x0b\x32@.google.cloud.oracledatabase.v1.AutonomousDatabaseConnectionUrlsB\x03\xe0\x41\x03\x12\x45\n\x1d\x66\x61iled_data_recovery_duration\x18\x1f \x01(\x0b\x32\x19.google.protobuf.DurationB\x03\xe0\x41\x03\x12\x1d\n\x10memory_table_gbs\x18 \x01(\x05\x42\x03\xe0\x41\x03\x12(\n\x1bis_local_data_guard_enabled\x18! \x01(\x08\x42\x03\xe0\x41\x03\x12\x38\n+local_adg_auto_failover_max_data_loss_limit\x18# \x01(\x05\x42\x03\xe0\x41\x03\x12_\n\x10local_standby_db\x18$ \x01(\x0b\x32@.google.cloud.oracledatabase.v1.AutonomousDatabaseStandbySummaryB\x03\xe0\x41\x03\x12/\n\"memory_per_oracle_compute_unit_gbs\x18% \x01(\x05\x42\x03\xe0\x41\x03\x12\x81\x01\n\x1clocal_disaster_recovery_type\x18& \x01(\x0e\x32V.google.cloud.oracledatabase.v1.AutonomousDatabaseProperties.LocalDisasterRecoveryTypeB\x03\xe0\x41\x03\x12h\n\x0f\x64\x61ta_safe_state\x18\' \x01(\x0e\x32J.google.cloud.oracledatabase.v1.AutonomousDatabaseProperties.DataSafeStateB\x03\xe0\x41\x03\x12|\n\x19\x64\x61tabase_management_state\x18( \x01(\x0e\x32T.google.cloud.oracledatabase.v1.AutonomousDatabaseProperties.DatabaseManagementStateB\x03\xe0\x41\x03\x12]\n\topen_mode\x18) \x01(\x0e\x32\x45.google.cloud.oracledatabase.v1.AutonomousDatabaseProperties.OpenModeB\x03\xe0\x41\x03\x12_\n\x19operations_insights_state\x18* \x01(\x0e\x32\x37.google.cloud.oracledatabase.v1.OperationsInsightsStateB\x03\xe0\x41\x03\x12\x18\n\x0bpeer_db_ids\x18+ \x03(\tB\x03\xe0\x41\x03\x12k\n\x10permission_level\x18, \x01(\x0e\x32L.google.cloud.oracledatabase.v1.AutonomousDatabaseProperties.PermissionLevelB\x03\xe0\x41\x03\x12\x1d\n\x10private_endpoint\x18- \x01(\tB\x03\xe0\x41\x03\x12k\n\x10refreshable_mode\x18. \x01(\x0e\x32L.google.cloud.oracledatabase.v1.AutonomousDatabaseProperties.RefreshableModeB\x03\xe0\x41\x03\x12m\n\x11refreshable_state\x18/ \x01(\x0e\x32M.google.cloud.oracledatabase.v1.AutonomousDatabaseProperties.RefreshableStateB\x03\xe0\x41\x03\x12T\n\x04role\x18\x30 \x01(\x0e\x32\x41.google.cloud.oracledatabase.v1.AutonomousDatabaseProperties.RoleB\x03\xe0\x41\x03\x12\x63\n\x1bscheduled_operation_details\x18@ \x03(\x0b\x32\x39.google.cloud.oracledatabase.v1.ScheduledOperationDetailsB\x03\xe0\x41\x03\x12\"\n\x15sql_web_developer_url\x18\x32 \x01(\tB\x03\xe0\x41\x03\x12$\n\x17supported_clone_regions\x18\x33 \x03(\tB\x03\xe0\x41\x03\x12\'\n\x1aused_data_storage_size_tbs\x18\x35 \x01(\x05\x42\x03\xe0\x41\x03\x12\x14\n\x07oci_url\x18\x36 \x01(\tB\x03\xe0\x41\x03\x12/\n\"total_auto_backup_storage_size_gbs\x18; \x01(\x02\x42\x03\xe0\x41\x03\x12\x43\n\x1anext_long_term_backup_time\x18< \x01(\x0b\x32\x1a.google.protobuf.TimestampB\x03\xe0\x41\x03\x12?\n\x16maintenance_begin_time\x18\x41 \x01(\x0b\x32\x1a.google.protobuf.TimestampB\x03\xe0\x41\x03\x12=\n\x14maintenance_end_time\x18\x42 \x01(\x0b\x32\x1a.google.protobuf.TimestampB\x03\xe0\x41\x03\"a\n\x0f\x44\x61tabaseEdition\x12 \n\x1c\x44\x41TABASE_EDITION_UNSPECIFIED\x10\x00\x12\x14\n\x10STANDARD_EDITION\x10\x01\x12\x16\n\x12\x45NTERPRISE_EDITION\x10\x02\"]\n\x0bLicenseType\x12\x1c\n\x18LICENSE_TYPE_UNSPECIFIED\x10\x00\x12\x14\n\x10LICENSE_INCLUDED\x10\x01\x12\x1a\n\x16\x42RING_YOUR_OWN_LICENSE\x10\x02\"\\\n\x17MaintenanceScheduleType\x12)\n%MAINTENANCE_SCHEDULE_TYPE_UNSPECIFIED\x10\x00\x12\t\n\x05\x45\x41RLY\x10\x01\x12\x0b\n\x07REGULAR\x10\x02\"d\n\x19LocalDisasterRecoveryType\x12,\n(LOCAL_DISASTER_RECOVERY_TYPE_UNSPECIFIED\x10\x00\x12\x07\n\x03\x41\x44G\x10\x01\x12\x10\n\x0c\x42\x41\x43KUP_BASED\x10\x02\"\x84\x01\n\rDataSafeState\x12\x1f\n\x1b\x44\x41TA_SAFE_STATE_UNSPECIFIED\x10\x00\x12\x0f\n\x0bREGISTERING\x10\x01\x12\x0e\n\nREGISTERED\x10\x02\x12\x11\n\rDEREGISTERING\x10\x03\x12\x12\n\x0eNOT_REGISTERED\x10\x04\x12\n\n\x06\x46\x41ILED\x10\x05\"\xaa\x01\n\x17\x44\x61tabaseManagementState\x12)\n%DATABASE_MANAGEMENT_STATE_UNSPECIFIED\x10\x00\x12\x0c\n\x08\x45NABLING\x10\x01\x12\x0b\n\x07\x45NABLED\x10\x02\x12\r\n\tDISABLING\x10\x03\x12\x0f\n\x0bNOT_ENABLED\x10\x04\x12\x13\n\x0f\x46\x41ILED_ENABLING\x10\x05\x12\x14\n\x10\x46\x41ILED_DISABLING\x10\x06\"D\n\x08OpenMode\x12\x19\n\x15OPEN_MODE_UNSPECIFIED\x10\x00\x12\r\n\tREAD_ONLY\x10\x01\x12\x0e\n\nREAD_WRITE\x10\x02\"U\n\x0fPermissionLevel\x12 \n\x1cPERMISSION_LEVEL_UNSPECIFIED\x10\x00\x12\x0e\n\nRESTRICTED\x10\x01\x12\x10\n\x0cUNRESTRICTED\x10\x02\"N\n\x0fRefreshableMode\x12 \n\x1cREFRESHABLE_MODE_UNSPECIFIED\x10\x00\x12\r\n\tAUTOMATIC\x10\x01\x12\n\n\x06MANUAL\x10\x02\"Y\n\x10RefreshableState\x12!\n\x1dREFRESHABLE_STATE_UNSPECIFIED\x10\x00\x12\x0e\n\nREFRESHING\x10\x01\x12\x12\n\x0eNOT_REFRESHING\x10\x02\"s\n\x04Role\x12\x14\n\x10ROLE_UNSPECIFIED\x10\x00\x12\x0b\n\x07PRIMARY\x10\x01\x12\x0b\n\x07STANDBY\x10\x02\x12\x14\n\x10\x44ISABLED_STANDBY\x10\x03\x12\x0f\n\x0b\x42\x41\x43KUP_COPY\x10\x04\x12\x14\n\x10SNAPSHOT_STANDBY\x10\x05\x42#\n!_are_primary_allowlisted_ips_used\"N\n\x16\x41utonomousDatabaseApex\x12\x19\n\x0c\x61pex_version\x18\x01 \x01(\tB\x03\xe0\x41\x03\x12\x19\n\x0cords_version\x18\x02 \x01(\tB\x03\xe0\x41\x03\"\xaa\x02\n#AutonomousDatabaseConnectionStrings\x12Y\n\x16\x61ll_connection_strings\x18\x01 \x01(\x0b\x32\x34.google.cloud.oracledatabase.v1.AllConnectionStringsB\x03\xe0\x41\x03\x12\x16\n\tdedicated\x18\x02 \x01(\tB\x03\xe0\x41\x03\x12\x11\n\x04high\x18\x03 \x01(\tB\x03\xe0\x41\x03\x12\x10\n\x03low\x18\x04 \x01(\tB\x03\xe0\x41\x03\x12\x13\n\x06medium\x18\x05 \x01(\tB\x03\xe0\x41\x03\x12V\n\x08profiles\x18\x06 \x03(\x0b\x32?.google.cloud.oracledatabase.v1.DatabaseConnectionStringProfileB\x03\xe0\x41\x03\"\xb2\t\n\x1f\x44\x61tabaseConnectionStringProfile\x12j\n\x0e\x63onsumer_group\x18\x01 \x01(\x0e\x32M.google.cloud.oracledatabase.v1.DatabaseConnectionStringProfile.ConsumerGroupB\x03\xe0\x41\x03\x12\x19\n\x0c\x64isplay_name\x18\x02 \x01(\tB\x03\xe0\x41\x03\x12\x64\n\x0bhost_format\x18\x03 \x01(\x0e\x32J.google.cloud.oracledatabase.v1.DatabaseConnectionStringProfile.HostFormatB\x03\xe0\x41\x03\x12\x18\n\x0bis_regional\x18\x04 \x01(\x08\x42\x03\xe0\x41\x03\x12_\n\x08protocol\x18\x05 \x01(\x0e\x32H.google.cloud.oracledatabase.v1.DatabaseConnectionStringProfile.ProtocolB\x03\xe0\x41\x03\x12\x66\n\x0csession_mode\x18\x06 \x01(\x0e\x32K.google.cloud.oracledatabase.v1.DatabaseConnectionStringProfile.SessionModeB\x03\xe0\x41\x03\x12h\n\rsyntax_format\x18\x07 \x01(\x0e\x32L.google.cloud.oracledatabase.v1.DatabaseConnectionStringProfile.SyntaxFormatB\x03\xe0\x41\x03\x12r\n\x12tls_authentication\x18\x08 \x01(\x0e\x32Q.google.cloud.oracledatabase.v1.DatabaseConnectionStringProfile.TLSAuthenticationB\x03\xe0\x41\x03\x12\x12\n\x05value\x18\t \x01(\tB\x03\xe0\x41\x03\"d\n\rConsumerGroup\x12\x1e\n\x1a\x43ONSUMER_GROUP_UNSPECIFIED\x10\x00\x12\x08\n\x04HIGH\x10\x01\x12\n\n\x06MEDIUM\x10\x02\x12\x07\n\x03LOW\x10\x03\x12\x06\n\x02TP\x10\x04\x12\x0c\n\x08TPURGENT\x10\x05\";\n\nHostFormat\x12\x1b\n\x17HOST_FORMAT_UNSPECIFIED\x10\x00\x12\x08\n\x04\x46QDN\x10\x01\x12\x06\n\x02IP\x10\x02\"7\n\x08Protocol\x12\x18\n\x14PROTOCOL_UNSPECIFIED\x10\x00\x12\x07\n\x03TCP\x10\x01\x12\x08\n\x04TCPS\x10\x02\"E\n\x0bSessionMode\x12\x1c\n\x18SESSION_MODE_UNSPECIFIED\x10\x00\x12\n\n\x06\x44IRECT\x10\x01\x12\x0c\n\x08INDIRECT\x10\x02\"Y\n\x0cSyntaxFormat\x12\x1d\n\x19SYNTAX_FORMAT_UNSPECIFIED\x10\x00\x12\x08\n\x04LONG\x10\x01\x12\r\n\tEZCONNECT\x10\x02\x12\x11\n\rEZCONNECTPLUS\x10\x03\"O\n\x11TLSAuthentication\x12\"\n\x1eTLS_AUTHENTICATION_UNSPECIFIED\x10\x00\x12\n\n\x06SERVER\x10\x01\x12\n\n\x06MUTUAL\x10\x02\"P\n\x14\x41llConnectionStrings\x12\x11\n\x04high\x18\x01 \x01(\tB\x03\xe0\x41\x03\x12\x10\n\x03low\x18\x02 \x01(\tB\x03\xe0\x41\x03\x12\x13\n\x06medium\x18\x03 \x01(\tB\x03\xe0\x41\x03\"\xad\x02\n AutonomousDatabaseConnectionUrls\x12\x15\n\x08\x61pex_uri\x18\x01 \x01(\tB\x03\xe0\x41\x03\x12$\n\x17\x64\x61tabase_transforms_uri\x18\x02 \x01(\tB\x03\xe0\x41\x03\x12\x1d\n\x10graph_studio_uri\x18\x03 \x01(\tB\x03\xe0\x41\x03\x12*\n\x1dmachine_learning_notebook_uri\x18\x04 \x01(\tB\x03\xe0\x41\x03\x12\x31\n$machine_learning_user_management_uri\x18\x05 \x01(\tB\x03\xe0\x41\x03\x12\x19\n\x0cmongo_db_uri\x18\x06 \x01(\tB\x03\xe0\x41\x03\x12\x15\n\x08ords_uri\x18\x07 \x01(\tB\x03\xe0\x41\x03\x12\x1c\n\x0fsql_dev_web_uri\x18\x08 \x01(\tB\x03\xe0\x41\x03\"\xcd\x02\n AutonomousDatabaseStandbySummary\x12\x39\n\x11lag_time_duration\x18\x01 \x01(\x0b\x32\x19.google.protobuf.DurationB\x03\xe0\x41\x03\x12\x1e\n\x11lifecycle_details\x18\x02 \x01(\tB\x03\xe0\x41\x03\x12\x39\n\x05state\x18\x03 \x01(\x0e\x32%.google.cloud.oracledatabase.v1.StateB\x03\xe0\x41\x03\x12\x45\n\x1c\x64\x61ta_guard_role_changed_time\x18\x04 \x01(\x0b\x32\x1a.google.protobuf.TimestampB\x03\xe0\x41\x03\x12L\n#disaster_recovery_role_changed_time\x18\x05 \x01(\x0b\x32\x1a.google.protobuf.TimestampB\x03\xe0\x41\x03\"\xae\x01\n\x19ScheduledOperationDetails\x12\x30\n\x0b\x64\x61y_of_week\x18\x01 \x01(\x0e\x32\x16.google.type.DayOfWeekB\x03\xe0\x41\x03\x12/\n\nstart_time\x18\x04 \x01(\x0b\x32\x16.google.type.TimeOfDayB\x03\xe0\x41\x03\x12.\n\tstop_time\x18\x05 \x01(\x0b\x32\x16.google.type.TimeOfDayB\x03\xe0\x41\x03*B\n\x0cGenerateType\x12\x1d\n\x19GENERATE_TYPE_UNSPECIFIED\x10\x00\x12\x07\n\x03\x41LL\x10\x01\x12\n\n\x06SINGLE\x10\x02*\xab\x03\n\x05State\x12\x15\n\x11STATE_UNSPECIFIED\x10\x00\x12\x10\n\x0cPROVISIONING\x10\x01\x12\r\n\tAVAILABLE\x10\x02\x12\x0c\n\x08STOPPING\x10\x03\x12\x0b\n\x07STOPPED\x10\x04\x12\x0c\n\x08STARTING\x10\x05\x12\x0f\n\x0bTERMINATING\x10\x06\x12\x0e\n\nTERMINATED\x10\x07\x12\x0f\n\x0bUNAVAILABLE\x10\x08\x12\x17\n\x13RESTORE_IN_PROGRESS\x10\t\x12\x12\n\x0eRESTORE_FAILED\x10\n\x12\x16\n\x12\x42\x41\x43KUP_IN_PROGRESS\x10\x0b\x12\x15\n\x11SCALE_IN_PROGRESS\x10\x0c\x12\x1d\n\x19\x41VAILABLE_NEEDS_ATTENTION\x10\r\x12\x0c\n\x08UPDATING\x10\x0e\x12\x1b\n\x17MAINTENANCE_IN_PROGRESS\x10\x0f\x12\x0e\n\nRESTARTING\x10\x10\x12\x0e\n\nRECREATING\x10\x11\x12\x1b\n\x17ROLE_CHANGE_IN_PROGRESS\x10\x12\x12\r\n\tUPGRADING\x10\x13\x12\x10\n\x0cINACCESSIBLE\x10\x14\x12\x0b\n\x07STANDBY\x10\x15*\xaa\x01\n\x17OperationsInsightsState\x12)\n%OPERATIONS_INSIGHTS_STATE_UNSPECIFIED\x10\x00\x12\x0c\n\x08\x45NABLING\x10\x01\x12\x0b\n\x07\x45NABLED\x10\x02\x12\r\n\tDISABLING\x10\x03\x12\x0f\n\x0bNOT_ENABLED\x10\x04\x12\x13\n\x0f\x46\x41ILED_ENABLING\x10\x05\x12\x14\n\x10\x46\x41ILED_DISABLING\x10\x06*N\n\nDBWorkload\x12\x1b\n\x17\x44\x42_WORKLOAD_UNSPECIFIED\x10\x00\x12\x08\n\x04OLTP\x10\x01\x12\x06\n\x02\x44W\x10\x02\x12\x07\n\x03\x41JD\x10\x03\x12\x08\n\x04\x41PEX\x10\x04\x42\xf1\x01\n\"com.google.cloud.oracledatabase.v1B\x17\x41utonomousDatabaseProtoP\x01ZJcloud.google.com/go/oracledatabase/apiv1/oracledatabasepb;oracledatabasepb\xaa\x02\x1eGoogle.Cloud.OracleDatabase.V1\xca\x02\x1eGoogle\\Cloud\\OracleDatabase\\V1\xea\x02!Google::Cloud::OracleDatabase::V1b\x06proto3" + +pool = Google::Protobuf::DescriptorPool.generated_pool + +begin + pool.add_serialized_file(descriptor_data) +rescue TypeError + # Compatibility code: will be removed in the next major version. + require 'google/protobuf/descriptor_pb' + parsed = Google::Protobuf::FileDescriptorProto.decode(descriptor_data) + parsed.clear_dependency + serialized = parsed.class.encode(parsed) + file = pool.add_serialized_file(serialized) + warn "Warning: Protobuf detected an import path issue while loading generated file #{__FILE__}" + imports = [ + ["google.protobuf.Timestamp", "google/protobuf/timestamp.proto"], + ["google.cloud.oracledatabase.v1.CustomerContact", "google/cloud/oracledatabase/v1/common.proto"], + ["google.protobuf.Duration", "google/protobuf/duration.proto"], + ["google.type.TimeOfDay", "google/type/timeofday.proto"], + ] + imports.each do |type_name, expected_filename| + import_file = pool.lookup(type_name).file_descriptor + if import_file.name != expected_filename + warn "- #{file.name} imports #{expected_filename}, but that import was loaded as #{import_file.name}" + end + end + warn "Each proto file must use a consistent fully-qualified name." + warn "This will become an error in the next major version." +end + +module Google + module Cloud + module OracleDatabase + module V1 + AutonomousDatabase = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.oracledatabase.v1.AutonomousDatabase").msgclass + AutonomousDatabaseProperties = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.oracledatabase.v1.AutonomousDatabaseProperties").msgclass + AutonomousDatabaseProperties::DatabaseEdition = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.oracledatabase.v1.AutonomousDatabaseProperties.DatabaseEdition").enummodule + AutonomousDatabaseProperties::LicenseType = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.oracledatabase.v1.AutonomousDatabaseProperties.LicenseType").enummodule + AutonomousDatabaseProperties::MaintenanceScheduleType = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.oracledatabase.v1.AutonomousDatabaseProperties.MaintenanceScheduleType").enummodule + AutonomousDatabaseProperties::LocalDisasterRecoveryType = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.oracledatabase.v1.AutonomousDatabaseProperties.LocalDisasterRecoveryType").enummodule + AutonomousDatabaseProperties::DataSafeState = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.oracledatabase.v1.AutonomousDatabaseProperties.DataSafeState").enummodule + AutonomousDatabaseProperties::DatabaseManagementState = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.oracledatabase.v1.AutonomousDatabaseProperties.DatabaseManagementState").enummodule + AutonomousDatabaseProperties::OpenMode = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.oracledatabase.v1.AutonomousDatabaseProperties.OpenMode").enummodule + AutonomousDatabaseProperties::PermissionLevel = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.oracledatabase.v1.AutonomousDatabaseProperties.PermissionLevel").enummodule + AutonomousDatabaseProperties::RefreshableMode = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.oracledatabase.v1.AutonomousDatabaseProperties.RefreshableMode").enummodule + AutonomousDatabaseProperties::RefreshableState = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.oracledatabase.v1.AutonomousDatabaseProperties.RefreshableState").enummodule + AutonomousDatabaseProperties::Role = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.oracledatabase.v1.AutonomousDatabaseProperties.Role").enummodule + AutonomousDatabaseApex = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.oracledatabase.v1.AutonomousDatabaseApex").msgclass + AutonomousDatabaseConnectionStrings = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.oracledatabase.v1.AutonomousDatabaseConnectionStrings").msgclass + DatabaseConnectionStringProfile = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.oracledatabase.v1.DatabaseConnectionStringProfile").msgclass + DatabaseConnectionStringProfile::ConsumerGroup = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.oracledatabase.v1.DatabaseConnectionStringProfile.ConsumerGroup").enummodule + DatabaseConnectionStringProfile::HostFormat = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.oracledatabase.v1.DatabaseConnectionStringProfile.HostFormat").enummodule + DatabaseConnectionStringProfile::Protocol = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.oracledatabase.v1.DatabaseConnectionStringProfile.Protocol").enummodule + DatabaseConnectionStringProfile::SessionMode = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.oracledatabase.v1.DatabaseConnectionStringProfile.SessionMode").enummodule + DatabaseConnectionStringProfile::SyntaxFormat = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.oracledatabase.v1.DatabaseConnectionStringProfile.SyntaxFormat").enummodule + DatabaseConnectionStringProfile::TLSAuthentication = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.oracledatabase.v1.DatabaseConnectionStringProfile.TLSAuthentication").enummodule + AllConnectionStrings = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.oracledatabase.v1.AllConnectionStrings").msgclass + AutonomousDatabaseConnectionUrls = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.oracledatabase.v1.AutonomousDatabaseConnectionUrls").msgclass + AutonomousDatabaseStandbySummary = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.oracledatabase.v1.AutonomousDatabaseStandbySummary").msgclass + ScheduledOperationDetails = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.oracledatabase.v1.ScheduledOperationDetails").msgclass + GenerateType = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.oracledatabase.v1.GenerateType").enummodule + State = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.oracledatabase.v1.State").enummodule + OperationsInsightsState = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.oracledatabase.v1.OperationsInsightsState").enummodule + DBWorkload = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.oracledatabase.v1.DBWorkload").enummodule + end + end + end +end diff --git a/google-cloud-oracle_database-v1/lib/google/cloud/oracledatabase/v1/autonomous_db_backup_pb.rb b/google-cloud-oracle_database-v1/lib/google/cloud/oracledatabase/v1/autonomous_db_backup_pb.rb new file mode 100644 index 000000000000..9ba48e29a35a --- /dev/null +++ b/google-cloud-oracle_database-v1/lib/google/cloud/oracledatabase/v1/autonomous_db_backup_pb.rb @@ -0,0 +1,50 @@ +# frozen_string_literal: true +# Generated by the protocol buffer compiler. DO NOT EDIT! +# source: google/cloud/oracledatabase/v1/autonomous_db_backup.proto + +require 'google/protobuf' + +require 'google/api/field_behavior_pb' +require 'google/api/resource_pb' +require 'google/protobuf/timestamp_pb' + + +descriptor_data = "\n9google/cloud/oracledatabase/v1/autonomous_db_backup.proto\x12\x1egoogle.cloud.oracledatabase.v1\x1a\x1fgoogle/api/field_behavior.proto\x1a\x19google/api/resource.proto\x1a\x1fgoogle/protobuf/timestamp.proto\"\xda\x04\n\x18\x41utonomousDatabaseBackup\x12\x11\n\x04name\x18\x01 \x01(\tB\x03\xe0\x41\x08\x12U\n\x13\x61utonomous_database\x18\x02 \x01(\tB8\xe0\x41\x02\xfa\x41\x32\n0oracledatabase.googleapis.com/AutonomousDatabase\x12\x19\n\x0c\x64isplay_name\x18\x03 \x01(\tB\x03\xe0\x41\x01\x12[\n\nproperties\x18\x04 \x01(\x0b\x32\x42.google.cloud.oracledatabase.v1.AutonomousDatabaseBackupPropertiesB\x03\xe0\x41\x01\x12Y\n\x06labels\x18\x05 \x03(\x0b\x32\x44.google.cloud.oracledatabase.v1.AutonomousDatabaseBackup.LabelsEntryB\x03\xe0\x41\x01\x1a-\n\x0bLabelsEntry\x12\x0b\n\x03key\x18\x01 \x01(\t\x12\r\n\x05value\x18\x02 \x01(\t:\x02\x38\x01:\xd1\x01\xea\x41\xcd\x01\n6oracledatabase.googleapis.com/AutonomousDatabaseBackup\x12^projects/{project}/locations/{location}/autonomousDatabaseBackups/{autonomous_database_backup}*\x19\x61utonomousDatabaseBackups2\x18\x61utonomousDatabaseBackup\"\xf2\x07\n\"AutonomousDatabaseBackupProperties\x12\x11\n\x04ocid\x18\x01 \x01(\tB\x03\xe0\x41\x03\x12\"\n\x15retention_period_days\x18\x02 \x01(\x05\x42\x03\xe0\x41\x01\x12\x1b\n\x0e\x63ompartment_id\x18\x03 \x01(\tB\x03\xe0\x41\x03\x12\x1d\n\x10\x64\x61tabase_size_tb\x18\x04 \x01(\x02\x42\x03\xe0\x41\x03\x12\x17\n\ndb_version\x18\x05 \x01(\tB\x03\xe0\x41\x03\x12 \n\x13is_long_term_backup\x18\x06 \x01(\x08\x42\x03\xe0\x41\x03\x12 \n\x13is_automatic_backup\x18\x07 \x01(\x08\x42\x03\xe0\x41\x03\x12\x1a\n\ris_restorable\x18\x08 \x01(\x08\x42\x03\xe0\x41\x03\x12\x19\n\x0ckey_store_id\x18\t \x01(\tB\x03\xe0\x41\x01\x12\x1d\n\x10key_store_wallet\x18\n \x01(\tB\x03\xe0\x41\x01\x12\x17\n\nkms_key_id\x18\x0b \x01(\tB\x03\xe0\x41\x01\x12\x1f\n\x12kms_key_version_id\x18\x0c \x01(\tB\x03\xe0\x41\x01\x12\x1e\n\x11lifecycle_details\x18\r \x01(\tB\x03\xe0\x41\x03\x12\x66\n\x0flifecycle_state\x18\x0e \x01(\x0e\x32H.google.cloud.oracledatabase.v1.AutonomousDatabaseBackupProperties.StateB\x03\xe0\x41\x03\x12\x14\n\x07size_tb\x18\x0f \x01(\x02\x42\x03\xe0\x41\x03\x12<\n\x13\x61vailable_till_time\x18\x10 \x01(\x0b\x32\x1a.google.protobuf.TimestampB\x03\xe0\x41\x03\x12\x31\n\x08\x65nd_time\x18\x11 \x01(\x0b\x32\x1a.google.protobuf.TimestampB\x03\xe0\x41\x03\x12\x33\n\nstart_time\x18\x12 \x01(\x0b\x32\x1a.google.protobuf.TimestampB\x03\xe0\x41\x03\x12Z\n\x04type\x18\x13 \x01(\x0e\x32G.google.cloud.oracledatabase.v1.AutonomousDatabaseBackupProperties.TypeB\x03\xe0\x41\x03\x12\x15\n\x08vault_id\x18\x14 \x01(\tB\x03\xe0\x41\x01\"m\n\x05State\x12\x15\n\x11STATE_UNSPECIFIED\x10\x00\x12\x0c\n\x08\x43REATING\x10\x01\x12\n\n\x06\x41\x43TIVE\x10\x02\x12\x0c\n\x08\x44\x45LETING\x10\x03\x12\x0b\n\x07\x44\x45LETED\x10\x04\x12\n\n\x06\x46\x41ILED\x10\x06\x12\x0c\n\x08UPDATING\x10\x07\"F\n\x04Type\x12\x14\n\x10TYPE_UNSPECIFIED\x10\x00\x12\x0f\n\x0bINCREMENTAL\x10\x01\x12\x08\n\x04\x46ULL\x10\x02\x12\r\n\tLONG_TERM\x10\x03\x42\xf1\x01\n\"com.google.cloud.oracledatabase.v1B\x17\x41utonomousDbBackupProtoP\x01ZJcloud.google.com/go/oracledatabase/apiv1/oracledatabasepb;oracledatabasepb\xaa\x02\x1eGoogle.Cloud.OracleDatabase.V1\xca\x02\x1eGoogle\\Cloud\\OracleDatabase\\V1\xea\x02!Google::Cloud::OracleDatabase::V1b\x06proto3" + +pool = Google::Protobuf::DescriptorPool.generated_pool + +begin + pool.add_serialized_file(descriptor_data) +rescue TypeError + # Compatibility code: will be removed in the next major version. + require 'google/protobuf/descriptor_pb' + parsed = Google::Protobuf::FileDescriptorProto.decode(descriptor_data) + parsed.clear_dependency + serialized = parsed.class.encode(parsed) + file = pool.add_serialized_file(serialized) + warn "Warning: Protobuf detected an import path issue while loading generated file #{__FILE__}" + imports = [ + ["google.protobuf.Timestamp", "google/protobuf/timestamp.proto"], + ] + imports.each do |type_name, expected_filename| + import_file = pool.lookup(type_name).file_descriptor + if import_file.name != expected_filename + warn "- #{file.name} imports #{expected_filename}, but that import was loaded as #{import_file.name}" + end + end + warn "Each proto file must use a consistent fully-qualified name." + warn "This will become an error in the next major version." +end + +module Google + module Cloud + module OracleDatabase + module V1 + AutonomousDatabaseBackup = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.oracledatabase.v1.AutonomousDatabaseBackup").msgclass + AutonomousDatabaseBackupProperties = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.oracledatabase.v1.AutonomousDatabaseBackupProperties").msgclass + AutonomousDatabaseBackupProperties::State = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.oracledatabase.v1.AutonomousDatabaseBackupProperties.State").enummodule + AutonomousDatabaseBackupProperties::Type = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.oracledatabase.v1.AutonomousDatabaseBackupProperties.Type").enummodule + end + end + end +end diff --git a/google-cloud-oracle_database-v1/lib/google/cloud/oracledatabase/v1/autonomous_db_version_pb.rb b/google-cloud-oracle_database-v1/lib/google/cloud/oracledatabase/v1/autonomous_db_version_pb.rb new file mode 100644 index 000000000000..2c56c7e3ce4a --- /dev/null +++ b/google-cloud-oracle_database-v1/lib/google/cloud/oracledatabase/v1/autonomous_db_version_pb.rb @@ -0,0 +1,46 @@ +# frozen_string_literal: true +# Generated by the protocol buffer compiler. DO NOT EDIT! +# source: google/cloud/oracledatabase/v1/autonomous_db_version.proto + +require 'google/protobuf' + +require 'google/api/field_behavior_pb' +require 'google/api/resource_pb' +require 'google/cloud/oracledatabase/v1/autonomous_database_pb' + + +descriptor_data = "\n:google/cloud/oracledatabase/v1/autonomous_db_version.proto\x12\x1egoogle.cloud.oracledatabase.v1\x1a\x1fgoogle/api/field_behavior.proto\x1a\x19google/api/resource.proto\x1a\x38google/cloud/oracledatabase/v1/autonomous_database.proto\"\xda\x02\n\x13\x41utonomousDbVersion\x12\x11\n\x04name\x18\x01 \x01(\tB\x03\xe0\x41\x08\x12\x14\n\x07version\x18\x02 \x01(\tB\x03\xe0\x41\x03\x12\x44\n\x0b\x64\x62_workload\x18\x04 \x01(\x0e\x32*.google.cloud.oracledatabase.v1.DBWorkloadB\x03\xe0\x41\x03\x12\x19\n\x0cworkload_uri\x18\x05 \x01(\tB\x03\xe0\x41\x03:\xb8\x01\xea\x41\xb4\x01\n1oracledatabase.googleapis.com/AutonomousDbVersion\x12Tprojects/{project}/locations/{location}/autonomousDbVersions/{autonomous_db_version}*\x14\x61utonomousDbVersions2\x13\x61utonomousDbVersionB\xf2\x01\n\"com.google.cloud.oracledatabase.v1B\x18\x41utonomousDbVersionProtoP\x01ZJcloud.google.com/go/oracledatabase/apiv1/oracledatabasepb;oracledatabasepb\xaa\x02\x1eGoogle.Cloud.OracleDatabase.V1\xca\x02\x1eGoogle\\Cloud\\OracleDatabase\\V1\xea\x02!Google::Cloud::OracleDatabase::V1b\x06proto3" + +pool = Google::Protobuf::DescriptorPool.generated_pool + +begin + pool.add_serialized_file(descriptor_data) +rescue TypeError + # Compatibility code: will be removed in the next major version. + require 'google/protobuf/descriptor_pb' + parsed = Google::Protobuf::FileDescriptorProto.decode(descriptor_data) + parsed.clear_dependency + serialized = parsed.class.encode(parsed) + file = pool.add_serialized_file(serialized) + warn "Warning: Protobuf detected an import path issue while loading generated file #{__FILE__}" + imports = [ + ] + imports.each do |type_name, expected_filename| + import_file = pool.lookup(type_name).file_descriptor + if import_file.name != expected_filename + warn "- #{file.name} imports #{expected_filename}, but that import was loaded as #{import_file.name}" + end + end + warn "Each proto file must use a consistent fully-qualified name." + warn "This will become an error in the next major version." +end + +module Google + module Cloud + module OracleDatabase + module V1 + AutonomousDbVersion = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.oracledatabase.v1.AutonomousDbVersion").msgclass + end + end + end +end diff --git a/google-cloud-oracle_database-v1/lib/google/cloud/oracledatabase/v1/common_pb.rb b/google-cloud-oracle_database-v1/lib/google/cloud/oracledatabase/v1/common_pb.rb new file mode 100644 index 000000000000..69ec5f1f9ad4 --- /dev/null +++ b/google-cloud-oracle_database-v1/lib/google/cloud/oracledatabase/v1/common_pb.rb @@ -0,0 +1,44 @@ +# frozen_string_literal: true +# Generated by the protocol buffer compiler. DO NOT EDIT! +# source: google/cloud/oracledatabase/v1/common.proto + +require 'google/protobuf' + +require 'google/api/field_behavior_pb' + + +descriptor_data = "\n+google/cloud/oracledatabase/v1/common.proto\x12\x1egoogle.cloud.oracledatabase.v1\x1a\x1fgoogle/api/field_behavior.proto\"%\n\x0f\x43ustomerContact\x12\x12\n\x05\x65mail\x18\x01 \x01(\tB\x03\xe0\x41\x02\x42\xe5\x01\n\"com.google.cloud.oracledatabase.v1B\x0b\x43ommonProtoP\x01ZJcloud.google.com/go/oracledatabase/apiv1/oracledatabasepb;oracledatabasepb\xaa\x02\x1eGoogle.Cloud.OracleDatabase.V1\xca\x02\x1eGoogle\\Cloud\\OracleDatabase\\V1\xea\x02!Google::Cloud::OracleDatabase::V1b\x06proto3" + +pool = Google::Protobuf::DescriptorPool.generated_pool + +begin + pool.add_serialized_file(descriptor_data) +rescue TypeError + # Compatibility code: will be removed in the next major version. + require 'google/protobuf/descriptor_pb' + parsed = Google::Protobuf::FileDescriptorProto.decode(descriptor_data) + parsed.clear_dependency + serialized = parsed.class.encode(parsed) + file = pool.add_serialized_file(serialized) + warn "Warning: Protobuf detected an import path issue while loading generated file #{__FILE__}" + imports = [ + ] + imports.each do |type_name, expected_filename| + import_file = pool.lookup(type_name).file_descriptor + if import_file.name != expected_filename + warn "- #{file.name} imports #{expected_filename}, but that import was loaded as #{import_file.name}" + end + end + warn "Each proto file must use a consistent fully-qualified name." + warn "This will become an error in the next major version." +end + +module Google + module Cloud + module OracleDatabase + module V1 + CustomerContact = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.oracledatabase.v1.CustomerContact").msgclass + end + end + end +end diff --git a/google-cloud-oracle_database-v1/lib/google/cloud/oracledatabase/v1/db_node_pb.rb b/google-cloud-oracle_database-v1/lib/google/cloud/oracledatabase/v1/db_node_pb.rb new file mode 100644 index 000000000000..a6b90bcd7374 --- /dev/null +++ b/google-cloud-oracle_database-v1/lib/google/cloud/oracledatabase/v1/db_node_pb.rb @@ -0,0 +1,47 @@ +# frozen_string_literal: true +# Generated by the protocol buffer compiler. DO NOT EDIT! +# source: google/cloud/oracledatabase/v1/db_node.proto + +require 'google/protobuf' + +require 'google/api/field_behavior_pb' +require 'google/api/resource_pb' + + +descriptor_data = "\n,google/cloud/oracledatabase/v1/db_node.proto\x12\x1egoogle.cloud.oracledatabase.v1\x1a\x1fgoogle/api/field_behavior.proto\x1a\x19google/api/resource.proto\"\x82\x02\n\x06\x44\x62Node\x12\x11\n\x04name\x18\x01 \x01(\tB\x03\xe0\x41\x08\x12I\n\nproperties\x18\x03 \x01(\x0b\x32\x30.google.cloud.oracledatabase.v1.DbNodePropertiesB\x03\xe0\x41\x01:\x99\x01\xea\x41\x95\x01\n$oracledatabase.googleapis.com/DbNode\x12\\projects/{project}/locations/{location}/cloudVmClusters/{cloud_vm_cluster}/dbNodes/{db_node}*\x07\x64\x62Nodes2\x06\x64\x62Node\"\xc0\x03\n\x10\x44\x62NodeProperties\x12\x11\n\x04ocid\x18\x01 \x01(\tB\x03\xe0\x41\x03\x12\x17\n\nocpu_count\x18\x02 \x01(\x05\x42\x03\xe0\x41\x01\x12\x16\n\x0ememory_size_gb\x18\x03 \x01(\x05\x12$\n\x17\x64\x62_node_storage_size_gb\x18\x04 \x01(\x05\x42\x03\xe0\x41\x01\x12\x1b\n\x0e\x64\x62_server_ocid\x18\x05 \x01(\tB\x03\xe0\x41\x01\x12\x15\n\x08hostname\x18\x08 \x01(\tB\x03\xe0\x41\x01\x12J\n\x05state\x18\t \x01(\x0e\x32\x36.google.cloud.oracledatabase.v1.DbNodeProperties.StateB\x03\xe0\x41\x03\x12\x1c\n\x14total_cpu_core_count\x18\n \x01(\x05\"\xa3\x01\n\x05State\x12\x15\n\x11STATE_UNSPECIFIED\x10\x00\x12\x10\n\x0cPROVISIONING\x10\x01\x12\r\n\tAVAILABLE\x10\x02\x12\x0c\n\x08UPDATING\x10\x03\x12\x0c\n\x08STOPPING\x10\x04\x12\x0b\n\x07STOPPED\x10\x05\x12\x0c\n\x08STARTING\x10\x06\x12\x0f\n\x0bTERMINATING\x10\x07\x12\x0e\n\nTERMINATED\x10\x08\x12\n\n\x06\x46\x41ILED\x10\tB\xe5\x01\n\"com.google.cloud.oracledatabase.v1B\x0b\x44\x62NodeProtoP\x01ZJcloud.google.com/go/oracledatabase/apiv1/oracledatabasepb;oracledatabasepb\xaa\x02\x1eGoogle.Cloud.OracleDatabase.V1\xca\x02\x1eGoogle\\Cloud\\OracleDatabase\\V1\xea\x02!Google::Cloud::OracleDatabase::V1b\x06proto3" + +pool = Google::Protobuf::DescriptorPool.generated_pool + +begin + pool.add_serialized_file(descriptor_data) +rescue TypeError + # Compatibility code: will be removed in the next major version. + require 'google/protobuf/descriptor_pb' + parsed = Google::Protobuf::FileDescriptorProto.decode(descriptor_data) + parsed.clear_dependency + serialized = parsed.class.encode(parsed) + file = pool.add_serialized_file(serialized) + warn "Warning: Protobuf detected an import path issue while loading generated file #{__FILE__}" + imports = [ + ] + imports.each do |type_name, expected_filename| + import_file = pool.lookup(type_name).file_descriptor + if import_file.name != expected_filename + warn "- #{file.name} imports #{expected_filename}, but that import was loaded as #{import_file.name}" + end + end + warn "Each proto file must use a consistent fully-qualified name." + warn "This will become an error in the next major version." +end + +module Google + module Cloud + module OracleDatabase + module V1 + DbNode = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.oracledatabase.v1.DbNode").msgclass + DbNodeProperties = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.oracledatabase.v1.DbNodeProperties").msgclass + DbNodeProperties::State = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.oracledatabase.v1.DbNodeProperties.State").enummodule + end + end + end +end diff --git a/google-cloud-oracle_database-v1/lib/google/cloud/oracledatabase/v1/db_server_pb.rb b/google-cloud-oracle_database-v1/lib/google/cloud/oracledatabase/v1/db_server_pb.rb new file mode 100644 index 000000000000..e7e0866591f5 --- /dev/null +++ b/google-cloud-oracle_database-v1/lib/google/cloud/oracledatabase/v1/db_server_pb.rb @@ -0,0 +1,47 @@ +# frozen_string_literal: true +# Generated by the protocol buffer compiler. DO NOT EDIT! +# source: google/cloud/oracledatabase/v1/db_server.proto + +require 'google/protobuf' + +require 'google/api/field_behavior_pb' +require 'google/api/resource_pb' + + +descriptor_data = "\n.google/cloud/oracledatabase/v1/db_server.proto\x12\x1egoogle.cloud.oracledatabase.v1\x1a\x1fgoogle/api/field_behavior.proto\x1a\x19google/api/resource.proto\"\xc3\x02\n\x08\x44\x62Server\x12\x11\n\x04name\x18\x01 \x01(\tB\x03\xe0\x41\x08\x12\x19\n\x0c\x64isplay_name\x18\x02 \x01(\tB\x03\xe0\x41\x01\x12K\n\nproperties\x18\x03 \x01(\x0b\x32\x32.google.cloud.oracledatabase.v1.DbServerPropertiesB\x03\xe0\x41\x01:\xbb\x01\xea\x41\xb7\x01\n&oracledatabase.googleapis.com/DbServer\x12xprojects/{project}/locations/{location}/cloudExadataInfrastructures/{cloud_exadata_infrastructure}/dbServers/{db_server}*\tdbServers2\x08\x64\x62Server\"\xd3\x03\n\x12\x44\x62ServerProperties\x12\x11\n\x04ocid\x18\x01 \x01(\tB\x03\xe0\x41\x03\x12\x17\n\nocpu_count\x18\x02 \x01(\x05\x42\x03\xe0\x41\x01\x12\x1b\n\x0emax_ocpu_count\x18\x03 \x01(\x05\x42\x03\xe0\x41\x01\x12\x1b\n\x0ememory_size_gb\x18\x04 \x01(\x05\x42\x03\xe0\x41\x01\x12\x1f\n\x12max_memory_size_gb\x18\x05 \x01(\x05\x42\x03\xe0\x41\x01\x12$\n\x17\x64\x62_node_storage_size_gb\x18\x06 \x01(\x05\x42\x03\xe0\x41\x01\x12(\n\x1bmax_db_node_storage_size_gb\x18\x07 \x01(\x05\x42\x03\xe0\x41\x01\x12\x15\n\x08vm_count\x18\x08 \x01(\x05\x42\x03\xe0\x41\x01\x12L\n\x05state\x18\t \x01(\x0e\x32\x38.google.cloud.oracledatabase.v1.DbServerProperties.StateB\x03\xe0\x41\x03\x12\x18\n\x0b\x64\x62_node_ids\x18\n \x03(\tB\x03\xe0\x41\x03\"g\n\x05State\x12\x15\n\x11STATE_UNSPECIFIED\x10\x00\x12\x0c\n\x08\x43REATING\x10\x01\x12\r\n\tAVAILABLE\x10\x02\x12\x0f\n\x0bUNAVAILABLE\x10\x03\x12\x0c\n\x08\x44\x45LETING\x10\x04\x12\x0b\n\x07\x44\x45LETED\x10\x05\x42\xe7\x01\n\"com.google.cloud.oracledatabase.v1B\rDbServerProtoP\x01ZJcloud.google.com/go/oracledatabase/apiv1/oracledatabasepb;oracledatabasepb\xaa\x02\x1eGoogle.Cloud.OracleDatabase.V1\xca\x02\x1eGoogle\\Cloud\\OracleDatabase\\V1\xea\x02!Google::Cloud::OracleDatabase::V1b\x06proto3" + +pool = Google::Protobuf::DescriptorPool.generated_pool + +begin + pool.add_serialized_file(descriptor_data) +rescue TypeError + # Compatibility code: will be removed in the next major version. + require 'google/protobuf/descriptor_pb' + parsed = Google::Protobuf::FileDescriptorProto.decode(descriptor_data) + parsed.clear_dependency + serialized = parsed.class.encode(parsed) + file = pool.add_serialized_file(serialized) + warn "Warning: Protobuf detected an import path issue while loading generated file #{__FILE__}" + imports = [ + ] + imports.each do |type_name, expected_filename| + import_file = pool.lookup(type_name).file_descriptor + if import_file.name != expected_filename + warn "- #{file.name} imports #{expected_filename}, but that import was loaded as #{import_file.name}" + end + end + warn "Each proto file must use a consistent fully-qualified name." + warn "This will become an error in the next major version." +end + +module Google + module Cloud + module OracleDatabase + module V1 + DbServer = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.oracledatabase.v1.DbServer").msgclass + DbServerProperties = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.oracledatabase.v1.DbServerProperties").msgclass + DbServerProperties::State = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.oracledatabase.v1.DbServerProperties.State").enummodule + end + end + end +end diff --git a/google-cloud-oracle_database-v1/lib/google/cloud/oracledatabase/v1/db_system_shape_pb.rb b/google-cloud-oracle_database-v1/lib/google/cloud/oracledatabase/v1/db_system_shape_pb.rb new file mode 100644 index 000000000000..635c7f1f4f33 --- /dev/null +++ b/google-cloud-oracle_database-v1/lib/google/cloud/oracledatabase/v1/db_system_shape_pb.rb @@ -0,0 +1,45 @@ +# frozen_string_literal: true +# Generated by the protocol buffer compiler. DO NOT EDIT! +# source: google/cloud/oracledatabase/v1/db_system_shape.proto + +require 'google/protobuf' + +require 'google/api/field_behavior_pb' +require 'google/api/resource_pb' + + +descriptor_data = "\n4google/cloud/oracledatabase/v1/db_system_shape.proto\x12\x1egoogle.cloud.oracledatabase.v1\x1a\x1fgoogle/api/field_behavior.proto\x1a\x19google/api/resource.proto\"\xc5\x04\n\rDbSystemShape\x12\x11\n\x04name\x18\x01 \x01(\tB\x03\xe0\x41\x08\x12\x12\n\x05shape\x18\x02 \x01(\tB\x03\xe0\x41\x01\x12\x1b\n\x0emin_node_count\x18\x03 \x01(\x05\x42\x03\xe0\x41\x01\x12\x1b\n\x0emax_node_count\x18\x04 \x01(\x05\x42\x03\xe0\x41\x01\x12\x1e\n\x11min_storage_count\x18\x05 \x01(\x05\x42\x03\xe0\x41\x01\x12\x1e\n\x11max_storage_count\x18\x06 \x01(\x05\x42\x03\xe0\x41\x01\x12*\n\x1d\x61vailable_core_count_per_node\x18\x07 \x01(\x05\x42\x03\xe0\x41\x01\x12)\n\x1c\x61vailable_memory_per_node_gb\x18\x08 \x01(\x05\x42\x03\xe0\x41\x01\x12&\n\x19\x61vailable_data_storage_tb\x18\t \x01(\x05\x42\x03\xe0\x41\x01\x12$\n\x17min_core_count_per_node\x18\n \x01(\x05\x42\x03\xe0\x41\x01\x12#\n\x16min_memory_per_node_gb\x18\x0b \x01(\x05\x42\x03\xe0\x41\x01\x12,\n\x1fmin_db_node_storage_per_node_gb\x18\x0c \x01(\x05\x42\x03\xe0\x41\x01:\x9a\x01\xea\x41\x96\x01\n+oracledatabase.googleapis.com/DbSystemShape\x12Hprojects/{project}/locations/{location}/dbSystemShapes/{db_system_shape}*\x0e\x64\x62SystemShapes2\rdbSystemShapeB\xec\x01\n\"com.google.cloud.oracledatabase.v1B\x12\x44\x62SystemShapeProtoP\x01ZJcloud.google.com/go/oracledatabase/apiv1/oracledatabasepb;oracledatabasepb\xaa\x02\x1eGoogle.Cloud.OracleDatabase.V1\xca\x02\x1eGoogle\\Cloud\\OracleDatabase\\V1\xea\x02!Google::Cloud::OracleDatabase::V1b\x06proto3" + +pool = Google::Protobuf::DescriptorPool.generated_pool + +begin + pool.add_serialized_file(descriptor_data) +rescue TypeError + # Compatibility code: will be removed in the next major version. + require 'google/protobuf/descriptor_pb' + parsed = Google::Protobuf::FileDescriptorProto.decode(descriptor_data) + parsed.clear_dependency + serialized = parsed.class.encode(parsed) + file = pool.add_serialized_file(serialized) + warn "Warning: Protobuf detected an import path issue while loading generated file #{__FILE__}" + imports = [ + ] + imports.each do |type_name, expected_filename| + import_file = pool.lookup(type_name).file_descriptor + if import_file.name != expected_filename + warn "- #{file.name} imports #{expected_filename}, but that import was loaded as #{import_file.name}" + end + end + warn "Each proto file must use a consistent fully-qualified name." + warn "This will become an error in the next major version." +end + +module Google + module Cloud + module OracleDatabase + module V1 + DbSystemShape = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.oracledatabase.v1.DbSystemShape").msgclass + end + end + end +end diff --git a/google-cloud-oracle_database-v1/lib/google/cloud/oracledatabase/v1/entitlement_pb.rb b/google-cloud-oracle_database-v1/lib/google/cloud/oracledatabase/v1/entitlement_pb.rb new file mode 100644 index 000000000000..6a9e8ee55d97 --- /dev/null +++ b/google-cloud-oracle_database-v1/lib/google/cloud/oracledatabase/v1/entitlement_pb.rb @@ -0,0 +1,47 @@ +# frozen_string_literal: true +# Generated by the protocol buffer compiler. DO NOT EDIT! +# source: google/cloud/oracledatabase/v1/entitlement.proto + +require 'google/protobuf' + +require 'google/api/field_behavior_pb' +require 'google/api/resource_pb' + + +descriptor_data = "\n0google/cloud/oracledatabase/v1/entitlement.proto\x12\x1egoogle.cloud.oracledatabase.v1\x1a\x1fgoogle/api/field_behavior.proto\x1a\x19google/api/resource.proto\"\xc5\x03\n\x0b\x45ntitlement\x12\x11\n\x04name\x18\x01 \x01(\tB\x03\xe0\x41\x08\x12R\n\x15\x63loud_account_details\x18\x02 \x01(\x0b\x32\x33.google.cloud.oracledatabase.v1.CloudAccountDetails\x12\x1b\n\x0e\x65ntitlement_id\x18\x03 \x01(\tB\x03\xe0\x41\x03\x12\x45\n\x05state\x18\x04 \x01(\x0e\x32\x31.google.cloud.oracledatabase.v1.Entitlement.StateB\x03\xe0\x41\x03\"Z\n\x05State\x12\x15\n\x11STATE_UNSPECIFIED\x10\x00\x12\x16\n\x12\x41\x43\x43OUNT_NOT_LINKED\x10\x01\x12\x16\n\x12\x41\x43\x43OUNT_NOT_ACTIVE\x10\x02\x12\n\n\x06\x41\x43TIVE\x10\x03:\x8e\x01\xea\x41\x8a\x01\n)oracledatabase.googleapis.com/Entitlement\x12\x42projects/{project}/locations/{location}/entitlements/{entitlement}*\x0c\x65ntitlements2\x0b\x65ntitlement\"\xe5\x01\n\x13\x43loudAccountDetails\x12\x1a\n\rcloud_account\x18\x01 \x01(\tB\x03\xe0\x41\x03\x12&\n\x19\x63loud_account_home_region\x18\x02 \x01(\tB\x03\xe0\x41\x03\x12+\n\x19link_existing_account_uri\x18\x03 \x01(\tB\x03\xe0\x41\x03H\x00\x88\x01\x01\x12&\n\x14\x61\x63\x63ount_creation_uri\x18\x04 \x01(\tB\x03\xe0\x41\x03H\x01\x88\x01\x01\x42\x1c\n\x1a_link_existing_account_uriB\x17\n\x15_account_creation_uriB\xea\x01\n\"com.google.cloud.oracledatabase.v1B\x10\x45ntitlementProtoP\x01ZJcloud.google.com/go/oracledatabase/apiv1/oracledatabasepb;oracledatabasepb\xaa\x02\x1eGoogle.Cloud.OracleDatabase.V1\xca\x02\x1eGoogle\\Cloud\\OracleDatabase\\V1\xea\x02!Google::Cloud::OracleDatabase::V1b\x06proto3" + +pool = Google::Protobuf::DescriptorPool.generated_pool + +begin + pool.add_serialized_file(descriptor_data) +rescue TypeError + # Compatibility code: will be removed in the next major version. + require 'google/protobuf/descriptor_pb' + parsed = Google::Protobuf::FileDescriptorProto.decode(descriptor_data) + parsed.clear_dependency + serialized = parsed.class.encode(parsed) + file = pool.add_serialized_file(serialized) + warn "Warning: Protobuf detected an import path issue while loading generated file #{__FILE__}" + imports = [ + ] + imports.each do |type_name, expected_filename| + import_file = pool.lookup(type_name).file_descriptor + if import_file.name != expected_filename + warn "- #{file.name} imports #{expected_filename}, but that import was loaded as #{import_file.name}" + end + end + warn "Each proto file must use a consistent fully-qualified name." + warn "This will become an error in the next major version." +end + +module Google + module Cloud + module OracleDatabase + module V1 + Entitlement = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.oracledatabase.v1.Entitlement").msgclass + Entitlement::State = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.oracledatabase.v1.Entitlement.State").enummodule + CloudAccountDetails = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.oracledatabase.v1.CloudAccountDetails").msgclass + end + end + end +end diff --git a/google-cloud-oracle_database-v1/lib/google/cloud/oracledatabase/v1/exadata_infra_pb.rb b/google-cloud-oracle_database-v1/lib/google/cloud/oracledatabase/v1/exadata_infra_pb.rb new file mode 100644 index 000000000000..d9607938ff04 --- /dev/null +++ b/google-cloud-oracle_database-v1/lib/google/cloud/oracledatabase/v1/exadata_infra_pb.rb @@ -0,0 +1,56 @@ +# frozen_string_literal: true +# Generated by the protocol buffer compiler. DO NOT EDIT! +# source: google/cloud/oracledatabase/v1/exadata_infra.proto + +require 'google/protobuf' + +require 'google/api/field_behavior_pb' +require 'google/api/resource_pb' +require 'google/cloud/oracledatabase/v1/common_pb' +require 'google/protobuf/timestamp_pb' +require 'google/type/dayofweek_pb' +require 'google/type/month_pb' + + +descriptor_data = "\n2google/cloud/oracledatabase/v1/exadata_infra.proto\x12\x1egoogle.cloud.oracledatabase.v1\x1a\x1fgoogle/api/field_behavior.proto\x1a\x19google/api/resource.proto\x1a+google/cloud/oracledatabase/v1/common.proto\x1a\x1fgoogle/protobuf/timestamp.proto\x1a\x1bgoogle/type/dayofweek.proto\x1a\x17google/type/month.proto\"\x84\x05\n\x1a\x43loudExadataInfrastructure\x12\x11\n\x04name\x18\x01 \x01(\tB\x03\xe0\x41\x08\x12\x19\n\x0c\x64isplay_name\x18\x02 \x01(\tB\x03\xe0\x41\x01\x12\x1c\n\x0fgcp_oracle_zone\x18\x08 \x01(\tB\x03\xe0\x41\x01\x12\x1b\n\x0e\x65ntitlement_id\x18\x04 \x01(\tB\x03\xe0\x41\x03\x12]\n\nproperties\x18\x05 \x01(\x0b\x32\x44.google.cloud.oracledatabase.v1.CloudExadataInfrastructurePropertiesB\x03\xe0\x41\x01\x12[\n\x06labels\x18\x06 \x03(\x0b\x32\x46.google.cloud.oracledatabase.v1.CloudExadataInfrastructure.LabelsEntryB\x03\xe0\x41\x01\x12\x34\n\x0b\x63reate_time\x18\x07 \x01(\x0b\x32\x1a.google.protobuf.TimestampB\x03\xe0\x41\x03\x1a-\n\x0bLabelsEntry\x12\x0b\n\x03key\x18\x01 \x01(\t\x12\r\n\x05value\x18\x02 \x01(\t:\x02\x38\x01:\xdb\x01\xea\x41\xd7\x01\n8oracledatabase.googleapis.com/CloudExadataInfrastructure\x12\x62projects/{project}/locations/{location}/cloudExadataInfrastructures/{cloud_exadata_infrastructure}*\x1b\x63loudExadataInfrastructures2\x1a\x63loudExadataInfrastructure\"\xa6\n\n$CloudExadataInfrastructureProperties\x12\x11\n\x04ocid\x18\x01 \x01(\tB\x03\xe0\x41\x03\x12\x1a\n\rcompute_count\x18\x02 \x01(\x05\x42\x03\xe0\x41\x01\x12\x1a\n\rstorage_count\x18\x03 \x01(\x05\x42\x03\xe0\x41\x01\x12\"\n\x15total_storage_size_gb\x18\x04 \x01(\x05\x42\x03\xe0\x41\x01\x12&\n\x19\x61vailable_storage_size_gb\x18\x05 \x01(\x05\x42\x03\xe0\x41\x03\x12R\n\x12maintenance_window\x18\x06 \x01(\x0b\x32\x31.google.cloud.oracledatabase.v1.MaintenanceWindowB\x03\xe0\x41\x01\x12^\n\x05state\x18\x07 \x01(\x0e\x32J.google.cloud.oracledatabase.v1.CloudExadataInfrastructureProperties.StateB\x03\xe0\x41\x03\x12\x12\n\x05shape\x18\x08 \x01(\tB\x03\xe0\x41\x02\x12\x14\n\x07oci_url\x18\t \x01(\tB\x03\xe0\x41\x03\x12\x16\n\tcpu_count\x18\n \x01(\x05\x42\x03\xe0\x41\x01\x12\x1a\n\rmax_cpu_count\x18\x0b \x01(\x05\x42\x03\xe0\x41\x03\x12\x1b\n\x0ememory_size_gb\x18\x0c \x01(\x05\x42\x03\xe0\x41\x01\x12\x1a\n\rmax_memory_gb\x18\r \x01(\x05\x42\x03\xe0\x41\x03\x12$\n\x17\x64\x62_node_storage_size_gb\x18\x0e \x01(\x05\x42\x03\xe0\x41\x01\x12(\n\x1bmax_db_node_storage_size_gb\x18\x0f \x01(\x05\x42\x03\xe0\x41\x03\x12!\n\x14\x64\x61ta_storage_size_tb\x18\x10 \x01(\x01\x42\x03\xe0\x41\x03\x12 \n\x13max_data_storage_tb\x18\x11 \x01(\x01\x42\x03\xe0\x41\x03\x12$\n\x17\x61\x63tivated_storage_count\x18\x12 \x01(\x05\x42\x03\xe0\x41\x03\x12%\n\x18\x61\x64\x64itional_storage_count\x18\x13 \x01(\x05\x42\x03\xe0\x41\x03\x12\x1e\n\x11\x64\x62_server_version\x18\x14 \x01(\tB\x03\xe0\x41\x03\x12#\n\x16storage_server_version\x18\x15 \x01(\tB\x03\xe0\x41\x03\x12$\n\x17next_maintenance_run_id\x18\x16 \x01(\tB\x03\xe0\x41\x03\x12\x42\n\x19next_maintenance_run_time\x18\x17 \x01(\x0b\x32\x1a.google.protobuf.TimestampB\x03\xe0\x41\x03\x12K\n\"next_security_maintenance_run_time\x18\x18 \x01(\x0b\x32\x1a.google.protobuf.TimestampB\x03\xe0\x41\x03\x12O\n\x11\x63ustomer_contacts\x18\x19 \x03(\x0b\x32/.google.cloud.oracledatabase.v1.CustomerContactB\x03\xe0\x41\x01\x12+\n\x1emonthly_storage_server_version\x18\x1a \x01(\tB\x03\xe0\x41\x03\x12&\n\x19monthly_db_server_version\x18\x1b \x01(\tB\x03\xe0\x41\x03\"\x97\x01\n\x05State\x12\x15\n\x11STATE_UNSPECIFIED\x10\x00\x12\x10\n\x0cPROVISIONING\x10\x01\x12\r\n\tAVAILABLE\x10\x02\x12\x0c\n\x08UPDATING\x10\x03\x12\x0f\n\x0bTERMINATING\x10\x04\x12\x0e\n\nTERMINATED\x10\x05\x12\n\n\x06\x46\x41ILED\x10\x06\x12\x1b\n\x17MAINTENANCE_IN_PROGRESS\x10\x07\"\xa5\x05\n\x11MaintenanceWindow\x12\x66\n\npreference\x18\x01 \x01(\x0e\x32M.google.cloud.oracledatabase.v1.MaintenanceWindow.MaintenanceWindowPreferenceB\x03\xe0\x41\x01\x12\'\n\x06months\x18\x02 \x03(\x0e\x32\x12.google.type.MonthB\x03\xe0\x41\x01\x12\x1b\n\x0eweeks_of_month\x18\x03 \x03(\x05\x42\x03\xe0\x41\x01\x12\x31\n\x0c\x64\x61ys_of_week\x18\x04 \x03(\x0e\x32\x16.google.type.DayOfWeekB\x03\xe0\x41\x01\x12\x19\n\x0chours_of_day\x18\x05 \x03(\x05\x42\x03\xe0\x41\x01\x12\x1b\n\x0elead_time_week\x18\x06 \x01(\x05\x42\x03\xe0\x41\x01\x12Z\n\rpatching_mode\x18\x07 \x01(\x0e\x32>.google.cloud.oracledatabase.v1.MaintenanceWindow.PatchingModeB\x03\xe0\x41\x01\x12\'\n\x1a\x63ustom_action_timeout_mins\x18\x08 \x01(\x05\x42\x03\xe0\x41\x01\x12-\n is_custom_action_timeout_enabled\x18\t \x01(\x08\x42\x03\xe0\x41\x01\"v\n\x1bMaintenanceWindowPreference\x12-\n)MAINTENANCE_WINDOW_PREFERENCE_UNSPECIFIED\x10\x00\x12\x15\n\x11\x43USTOM_PREFERENCE\x10\x01\x12\x11\n\rNO_PREFERENCE\x10\x02\"K\n\x0cPatchingMode\x12\x1d\n\x19PATCHING_MODE_UNSPECIFIED\x10\x00\x12\x0b\n\x07ROLLING\x10\x01\x12\x0f\n\x0bNON_ROLLING\x10\x02\x42\xf9\x01\n\"com.google.cloud.oracledatabase.v1B\x1f\x43loudExadataInfrastructureProtoP\x01ZJcloud.google.com/go/oracledatabase/apiv1/oracledatabasepb;oracledatabasepb\xaa\x02\x1eGoogle.Cloud.OracleDatabase.V1\xca\x02\x1eGoogle\\Cloud\\OracleDatabase\\V1\xea\x02!Google::Cloud::OracleDatabase::V1b\x06proto3" + +pool = Google::Protobuf::DescriptorPool.generated_pool + +begin + pool.add_serialized_file(descriptor_data) +rescue TypeError + # Compatibility code: will be removed in the next major version. + require 'google/protobuf/descriptor_pb' + parsed = Google::Protobuf::FileDescriptorProto.decode(descriptor_data) + parsed.clear_dependency + serialized = parsed.class.encode(parsed) + file = pool.add_serialized_file(serialized) + warn "Warning: Protobuf detected an import path issue while loading generated file #{__FILE__}" + imports = [ + ["google.protobuf.Timestamp", "google/protobuf/timestamp.proto"], + ["google.cloud.oracledatabase.v1.CustomerContact", "google/cloud/oracledatabase/v1/common.proto"], + ] + imports.each do |type_name, expected_filename| + import_file = pool.lookup(type_name).file_descriptor + if import_file.name != expected_filename + warn "- #{file.name} imports #{expected_filename}, but that import was loaded as #{import_file.name}" + end + end + warn "Each proto file must use a consistent fully-qualified name." + warn "This will become an error in the next major version." +end + +module Google + module Cloud + module OracleDatabase + module V1 + CloudExadataInfrastructure = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.oracledatabase.v1.CloudExadataInfrastructure").msgclass + CloudExadataInfrastructureProperties = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.oracledatabase.v1.CloudExadataInfrastructureProperties").msgclass + CloudExadataInfrastructureProperties::State = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.oracledatabase.v1.CloudExadataInfrastructureProperties.State").enummodule + MaintenanceWindow = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.oracledatabase.v1.MaintenanceWindow").msgclass + MaintenanceWindow::MaintenanceWindowPreference = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.oracledatabase.v1.MaintenanceWindow.MaintenanceWindowPreference").enummodule + MaintenanceWindow::PatchingMode = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.oracledatabase.v1.MaintenanceWindow.PatchingMode").enummodule + end + end + end +end diff --git a/google-cloud-oracle_database-v1/lib/google/cloud/oracledatabase/v1/gi_version_pb.rb b/google-cloud-oracle_database-v1/lib/google/cloud/oracledatabase/v1/gi_version_pb.rb new file mode 100644 index 000000000000..940f3587c682 --- /dev/null +++ b/google-cloud-oracle_database-v1/lib/google/cloud/oracledatabase/v1/gi_version_pb.rb @@ -0,0 +1,45 @@ +# frozen_string_literal: true +# Generated by the protocol buffer compiler. DO NOT EDIT! +# source: google/cloud/oracledatabase/v1/gi_version.proto + +require 'google/protobuf' + +require 'google/api/field_behavior_pb' +require 'google/api/resource_pb' + + +descriptor_data = "\n/google/cloud/oracledatabase/v1/gi_version.proto\x12\x1egoogle.cloud.oracledatabase.v1\x1a\x1fgoogle/api/field_behavior.proto\x1a\x19google/api/resource.proto\"\xbc\x01\n\tGiVersion\x12\x11\n\x04name\x18\x01 \x01(\tB\x03\xe0\x41\x08\x12\x14\n\x07version\x18\x02 \x01(\tB\x03\xe0\x41\x01:\x85\x01\xea\x41\x81\x01\n\'oracledatabase.googleapis.com/GiVersion\x12?projects/{project}/locations/{location}/giVersions/{gi_version}*\ngiVersions2\tgiVersionB\xe8\x01\n\"com.google.cloud.oracledatabase.v1B\x0eGiVersionProtoP\x01ZJcloud.google.com/go/oracledatabase/apiv1/oracledatabasepb;oracledatabasepb\xaa\x02\x1eGoogle.Cloud.OracleDatabase.V1\xca\x02\x1eGoogle\\Cloud\\OracleDatabase\\V1\xea\x02!Google::Cloud::OracleDatabase::V1b\x06proto3" + +pool = Google::Protobuf::DescriptorPool.generated_pool + +begin + pool.add_serialized_file(descriptor_data) +rescue TypeError + # Compatibility code: will be removed in the next major version. + require 'google/protobuf/descriptor_pb' + parsed = Google::Protobuf::FileDescriptorProto.decode(descriptor_data) + parsed.clear_dependency + serialized = parsed.class.encode(parsed) + file = pool.add_serialized_file(serialized) + warn "Warning: Protobuf detected an import path issue while loading generated file #{__FILE__}" + imports = [ + ] + imports.each do |type_name, expected_filename| + import_file = pool.lookup(type_name).file_descriptor + if import_file.name != expected_filename + warn "- #{file.name} imports #{expected_filename}, but that import was loaded as #{import_file.name}" + end + end + warn "Each proto file must use a consistent fully-qualified name." + warn "This will become an error in the next major version." +end + +module Google + module Cloud + module OracleDatabase + module V1 + GiVersion = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.oracledatabase.v1.GiVersion").msgclass + end + end + end +end diff --git a/google-cloud-oracle_database-v1/lib/google/cloud/oracledatabase/v1/location_metadata_pb.rb b/google-cloud-oracle_database-v1/lib/google/cloud/oracledatabase/v1/location_metadata_pb.rb new file mode 100644 index 000000000000..0f8d3d843689 --- /dev/null +++ b/google-cloud-oracle_database-v1/lib/google/cloud/oracledatabase/v1/location_metadata_pb.rb @@ -0,0 +1,44 @@ +# frozen_string_literal: true +# Generated by the protocol buffer compiler. DO NOT EDIT! +# source: google/cloud/oracledatabase/v1/location_metadata.proto + +require 'google/protobuf' + +require 'google/api/field_behavior_pb' + + +descriptor_data = "\n6google/cloud/oracledatabase/v1/location_metadata.proto\x12\x1egoogle.cloud.oracledatabase.v1\x1a\x1fgoogle/api/field_behavior.proto\"1\n\x10LocationMetadata\x12\x1d\n\x10gcp_oracle_zones\x18\x02 \x03(\tB\x03\xe0\x41\x03\x42\xef\x01\n\"com.google.cloud.oracledatabase.v1B\x15LocationMetadataProtoP\x01ZJcloud.google.com/go/oracledatabase/apiv1/oracledatabasepb;oracledatabasepb\xaa\x02\x1eGoogle.Cloud.OracleDatabase.V1\xca\x02\x1eGoogle\\Cloud\\OracleDatabase\\V1\xea\x02!Google::Cloud::OracleDatabase::V1b\x06proto3" + +pool = Google::Protobuf::DescriptorPool.generated_pool + +begin + pool.add_serialized_file(descriptor_data) +rescue TypeError + # Compatibility code: will be removed in the next major version. + require 'google/protobuf/descriptor_pb' + parsed = Google::Protobuf::FileDescriptorProto.decode(descriptor_data) + parsed.clear_dependency + serialized = parsed.class.encode(parsed) + file = pool.add_serialized_file(serialized) + warn "Warning: Protobuf detected an import path issue while loading generated file #{__FILE__}" + imports = [ + ] + imports.each do |type_name, expected_filename| + import_file = pool.lookup(type_name).file_descriptor + if import_file.name != expected_filename + warn "- #{file.name} imports #{expected_filename}, but that import was loaded as #{import_file.name}" + end + end + warn "Each proto file must use a consistent fully-qualified name." + warn "This will become an error in the next major version." +end + +module Google + module Cloud + module OracleDatabase + module V1 + LocationMetadata = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.oracledatabase.v1.LocationMetadata").msgclass + end + end + end +end diff --git a/google-cloud-oracle_database-v1/lib/google/cloud/oracledatabase/v1/oracledatabase_pb.rb b/google-cloud-oracle_database-v1/lib/google/cloud/oracledatabase/v1/oracledatabase_pb.rb new file mode 100644 index 000000000000..4812b2d32f42 --- /dev/null +++ b/google-cloud-oracle_database-v1/lib/google/cloud/oracledatabase/v1/oracledatabase_pb.rb @@ -0,0 +1,108 @@ +# frozen_string_literal: true +# Generated by the protocol buffer compiler. DO NOT EDIT! +# source: google/cloud/oracledatabase/v1/oracledatabase.proto + +require 'google/protobuf' + +require 'google/api/annotations_pb' +require 'google/api/client_pb' +require 'google/api/field_behavior_pb' +require 'google/api/field_info_pb' +require 'google/api/resource_pb' +require 'google/cloud/oracledatabase/v1/autonomous_database_pb' +require 'google/cloud/oracledatabase/v1/autonomous_database_character_set_pb' +require 'google/cloud/oracledatabase/v1/autonomous_db_backup_pb' +require 'google/cloud/oracledatabase/v1/autonomous_db_version_pb' +require 'google/cloud/oracledatabase/v1/db_node_pb' +require 'google/cloud/oracledatabase/v1/db_server_pb' +require 'google/cloud/oracledatabase/v1/db_system_shape_pb' +require 'google/cloud/oracledatabase/v1/entitlement_pb' +require 'google/cloud/oracledatabase/v1/exadata_infra_pb' +require 'google/cloud/oracledatabase/v1/gi_version_pb' +require 'google/cloud/oracledatabase/v1/vm_cluster_pb' +require 'google/longrunning/operations_pb' +require 'google/protobuf/empty_pb' +require 'google/protobuf/timestamp_pb' + + +descriptor_data = "\n3google/cloud/oracledatabase/v1/oracledatabase.proto\x12\x1egoogle.cloud.oracledatabase.v1\x1a\x1cgoogle/api/annotations.proto\x1a\x17google/api/client.proto\x1a\x1fgoogle/api/field_behavior.proto\x1a\x1bgoogle/api/field_info.proto\x1a\x19google/api/resource.proto\x1a\x38google/cloud/oracledatabase/v1/autonomous_database.proto\x1a\x46google/cloud/oracledatabase/v1/autonomous_database_character_set.proto\x1a\x39google/cloud/oracledatabase/v1/autonomous_db_backup.proto\x1a:google/cloud/oracledatabase/v1/autonomous_db_version.proto\x1a,google/cloud/oracledatabase/v1/db_node.proto\x1a.google/cloud/oracledatabase/v1/db_server.proto\x1a\x34google/cloud/oracledatabase/v1/db_system_shape.proto\x1a\x30google/cloud/oracledatabase/v1/entitlement.proto\x1a\x32google/cloud/oracledatabase/v1/exadata_infra.proto\x1a/google/cloud/oracledatabase/v1/gi_version.proto\x1a/google/cloud/oracledatabase/v1/vm_cluster.proto\x1a#google/longrunning/operations.proto\x1a\x1bgoogle/protobuf/empty.proto\x1a\x1fgoogle/protobuf/timestamp.proto\"\xab\x01\n&ListCloudExadataInfrastructuresRequest\x12P\n\x06parent\x18\x01 \x01(\tB@\xe0\x41\x02\xfa\x41:\x12\x38oracledatabase.googleapis.com/CloudExadataInfrastructure\x12\x16\n\tpage_size\x18\x02 \x01(\x05\x42\x03\xe0\x41\x01\x12\x17\n\npage_token\x18\x03 \x01(\tB\x03\xe0\x41\x01\"\xa5\x01\n\'ListCloudExadataInfrastructuresResponse\x12\x61\n\x1d\x63loud_exadata_infrastructures\x18\x01 \x03(\x0b\x32:.google.cloud.oracledatabase.v1.CloudExadataInfrastructure\x12\x17\n\x0fnext_page_token\x18\x02 \x01(\t\"v\n$GetCloudExadataInfrastructureRequest\x12N\n\x04name\x18\x01 \x01(\tB@\xe0\x41\x02\xfa\x41:\n8oracledatabase.googleapis.com/CloudExadataInfrastructure\"\xb1\x02\n\'CreateCloudExadataInfrastructureRequest\x12P\n\x06parent\x18\x01 \x01(\tB@\xe0\x41\x02\xfa\x41:\x12\x38oracledatabase.googleapis.com/CloudExadataInfrastructure\x12,\n\x1f\x63loud_exadata_infrastructure_id\x18\x02 \x01(\tB\x03\xe0\x41\x02\x12\x65\n\x1c\x63loud_exadata_infrastructure\x18\x03 \x01(\x0b\x32:.google.cloud.oracledatabase.v1.CloudExadataInfrastructureB\x03\xe0\x41\x02\x12\x1f\n\nrequest_id\x18\x04 \x01(\tB\x0b\xe0\x41\x01\xe2\x8c\xcf\xd7\x08\x02\x08\x01\"\xae\x01\n\'DeleteCloudExadataInfrastructureRequest\x12N\n\x04name\x18\x01 \x01(\tB@\xe0\x41\x02\xfa\x41:\n8oracledatabase.googleapis.com/CloudExadataInfrastructure\x12\x1f\n\nrequest_id\x18\x02 \x01(\tB\x0b\xe0\x41\x01\xe2\x8c\xcf\xd7\x08\x02\x08\x01\x12\x12\n\x05\x66orce\x18\x03 \x01(\x08\x42\x03\xe0\x41\x01\"\xa8\x01\n\x1aListCloudVmClustersRequest\x12\x44\n\x06parent\x18\x01 \x01(\tB4\xe0\x41\x02\xfa\x41.\x12,oracledatabase.googleapis.com/CloudVmCluster\x12\x16\n\tpage_size\x18\x02 \x01(\x05\x42\x03\xe0\x41\x01\x12\x17\n\npage_token\x18\x03 \x01(\tB\x03\xe0\x41\x01\x12\x13\n\x06\x66ilter\x18\x04 \x01(\tB\x03\xe0\x41\x01\"\x81\x01\n\x1bListCloudVmClustersResponse\x12I\n\x11\x63loud_vm_clusters\x18\x01 \x03(\x0b\x32..google.cloud.oracledatabase.v1.CloudVmCluster\x12\x17\n\x0fnext_page_token\x18\x02 \x01(\t\"^\n\x18GetCloudVmClusterRequest\x12\x42\n\x04name\x18\x01 \x01(\tB4\xe0\x41\x02\xfa\x41.\n,oracledatabase.googleapis.com/CloudVmCluster\"\xf5\x01\n\x1b\x43reateCloudVmClusterRequest\x12\x44\n\x06parent\x18\x01 \x01(\tB4\xe0\x41\x02\xfa\x41.\x12,oracledatabase.googleapis.com/CloudVmCluster\x12 \n\x13\x63loud_vm_cluster_id\x18\x02 \x01(\tB\x03\xe0\x41\x02\x12M\n\x10\x63loud_vm_cluster\x18\x03 \x01(\x0b\x32..google.cloud.oracledatabase.v1.CloudVmClusterB\x03\xe0\x41\x02\x12\x1f\n\nrequest_id\x18\x04 \x01(\tB\x0b\xe0\x41\x01\xe2\x8c\xcf\xd7\x08\x02\x08\x01\"\x96\x01\n\x1b\x44\x65leteCloudVmClusterRequest\x12\x42\n\x04name\x18\x01 \x01(\tB4\xe0\x41\x02\xfa\x41.\n,oracledatabase.googleapis.com/CloudVmCluster\x12\x1f\n\nrequest_id\x18\x02 \x01(\tB\x0b\xe0\x41\x01\xe2\x8c\xcf\xd7\x08\x02\x08\x01\x12\x12\n\x05\x66orce\x18\x03 \x01(\x08\x42\x03\xe0\x41\x01\"\x8d\x01\n\x17ListEntitlementsRequest\x12\x41\n\x06parent\x18\x01 \x01(\tB1\xe0\x41\x02\xfa\x41+\x12)oracledatabase.googleapis.com/Entitlement\x12\x16\n\tpage_size\x18\x02 \x01(\x05\x42\x03\xe0\x41\x01\x12\x17\n\npage_token\x18\x03 \x01(\tB\x03\xe0\x41\x01\"v\n\x18ListEntitlementsResponse\x12\x41\n\x0c\x65ntitlements\x18\x01 \x03(\x0b\x32+.google.cloud.oracledatabase.v1.Entitlement\x12\x17\n\x0fnext_page_token\x18\x02 \x01(\t\"\x87\x01\n\x14ListDbServersRequest\x12>\n\x06parent\x18\x01 \x01(\tB.\xe0\x41\x02\xfa\x41(\x12&oracledatabase.googleapis.com/DbServer\x12\x16\n\tpage_size\x18\x02 \x01(\x05\x42\x03\xe0\x41\x01\x12\x17\n\npage_token\x18\x03 \x01(\tB\x03\xe0\x41\x01\"n\n\x15ListDbServersResponse\x12<\n\ndb_servers\x18\x01 \x03(\x0b\x32(.google.cloud.oracledatabase.v1.DbServer\x12\x17\n\x0fnext_page_token\x18\x02 \x01(\t\"\x83\x01\n\x12ListDbNodesRequest\x12<\n\x06parent\x18\x01 \x01(\tB,\xe0\x41\x02\xfa\x41&\x12$oracledatabase.googleapis.com/DbNode\x12\x16\n\tpage_size\x18\x02 \x01(\x05\x42\x03\xe0\x41\x01\x12\x17\n\npage_token\x18\x03 \x01(\tB\x03\xe0\x41\x01\"h\n\x13ListDbNodesResponse\x12\x38\n\x08\x64\x62_nodes\x18\x01 \x03(\x0b\x32&.google.cloud.oracledatabase.v1.DbNode\x12\x17\n\x0fnext_page_token\x18\x02 \x01(\t\"\x89\x01\n\x15ListGiVersionsRequest\x12?\n\x06parent\x18\x01 \x01(\tB/\xe0\x41\x02\xfa\x41)\x12\'oracledatabase.googleapis.com/GiVersion\x12\x16\n\tpage_size\x18\x02 \x01(\x05\x42\x03\xe0\x41\x01\x12\x17\n\npage_token\x18\x03 \x01(\tB\x03\xe0\x41\x01\"q\n\x16ListGiVersionsResponse\x12>\n\x0bgi_versions\x18\x01 \x03(\x0b\x32).google.cloud.oracledatabase.v1.GiVersion\x12\x17\n\x0fnext_page_token\x18\x02 \x01(\t\"\x91\x01\n\x19ListDbSystemShapesRequest\x12\x43\n\x06parent\x18\x01 \x01(\tB3\xe0\x41\x02\xfa\x41-\x12+oracledatabase.googleapis.com/DbSystemShape\x12\x16\n\tpage_size\x18\x02 \x01(\x05\x42\x03\xe0\x41\x01\x12\x17\n\npage_token\x18\x03 \x01(\tB\x03\xe0\x41\x01\"~\n\x1aListDbSystemShapesResponse\x12G\n\x10\x64\x62_system_shapes\x18\x01 \x03(\x0b\x32-.google.cloud.oracledatabase.v1.DbSystemShape\x12\x17\n\x0fnext_page_token\x18\x02 \x01(\t\"\x9f\x02\n\x11OperationMetadata\x12\x34\n\x0b\x63reate_time\x18\x01 \x01(\x0b\x32\x1a.google.protobuf.TimestampB\x03\xe0\x41\x03\x12\x31\n\x08\x65nd_time\x18\x02 \x01(\x0b\x32\x1a.google.protobuf.TimestampB\x03\xe0\x41\x03\x12\x13\n\x06target\x18\x03 \x01(\tB\x03\xe0\x41\x03\x12\x11\n\x04verb\x18\x04 \x01(\tB\x03\xe0\x41\x03\x12\x1b\n\x0estatus_message\x18\x05 \x01(\tB\x03\xe0\x41\x03\x12#\n\x16requested_cancellation\x18\x06 \x01(\x08\x42\x03\xe0\x41\x03\x12\x18\n\x0b\x61pi_version\x18\x07 \x01(\tB\x03\xe0\x41\x03\x12\x1d\n\x10percent_complete\x18\x08 \x01(\x01\x42\x03\xe0\x41\x03\"\xc7\x01\n\x1eListAutonomousDatabasesRequest\x12H\n\x06parent\x18\x01 \x01(\tB8\xe0\x41\x02\xfa\x41\x32\x12\x30oracledatabase.googleapis.com/AutonomousDatabase\x12\x16\n\tpage_size\x18\x02 \x01(\x05\x42\x03\xe0\x41\x01\x12\x17\n\npage_token\x18\x03 \x01(\tB\x03\xe0\x41\x01\x12\x13\n\x06\x66ilter\x18\x04 \x01(\tB\x03\xe0\x41\x01\x12\x15\n\x08order_by\x18\x05 \x01(\tB\x03\xe0\x41\x01\"\x8c\x01\n\x1fListAutonomousDatabasesResponse\x12P\n\x14\x61utonomous_databases\x18\x01 \x03(\x0b\x32\x32.google.cloud.oracledatabase.v1.AutonomousDatabase\x12\x17\n\x0fnext_page_token\x18\x02 \x01(\t\"f\n\x1cGetAutonomousDatabaseRequest\x12\x46\n\x04name\x18\x01 \x01(\tB8\xe0\x41\x02\xfa\x41\x32\n0oracledatabase.googleapis.com/AutonomousDatabase\"\x87\x02\n\x1f\x43reateAutonomousDatabaseRequest\x12H\n\x06parent\x18\x01 \x01(\tB8\xe0\x41\x02\xfa\x41\x32\x12\x30oracledatabase.googleapis.com/AutonomousDatabase\x12#\n\x16\x61utonomous_database_id\x18\x02 \x01(\tB\x03\xe0\x41\x02\x12T\n\x13\x61utonomous_database\x18\x03 \x01(\x0b\x32\x32.google.cloud.oracledatabase.v1.AutonomousDatabaseB\x03\xe0\x41\x02\x12\x1f\n\nrequest_id\x18\x04 \x01(\tB\x0b\xe0\x41\x01\xe2\x8c\xcf\xd7\x08\x02\x08\x01\"\x8a\x01\n\x1f\x44\x65leteAutonomousDatabaseRequest\x12\x46\n\x04name\x18\x01 \x01(\tB8\xe0\x41\x02\xfa\x41\x32\n0oracledatabase.googleapis.com/AutonomousDatabase\x12\x1f\n\nrequest_id\x18\x02 \x01(\tB\x0b\xe0\x41\x01\xe2\x8c\xcf\xd7\x08\x02\x08\x01\"\xa1\x01\n RestoreAutonomousDatabaseRequest\x12\x46\n\x04name\x18\x01 \x01(\tB8\xe0\x41\x02\xfa\x41\x32\n0oracledatabase.googleapis.com/AutonomousDatabase\x12\x35\n\x0crestore_time\x18\x02 \x01(\x0b\x32\x1a.google.protobuf.TimestampB\x03\xe0\x41\x02\"\xe3\x01\n\'GenerateAutonomousDatabaseWalletRequest\x12\x46\n\x04name\x18\x01 \x01(\tB8\xe0\x41\x02\xfa\x41\x32\n0oracledatabase.googleapis.com/AutonomousDatabase\x12?\n\x04type\x18\x02 \x01(\x0e\x32,.google.cloud.oracledatabase.v1.GenerateTypeB\x03\xe0\x41\x01\x12\x18\n\x0bis_regional\x18\x03 \x01(\x08\x42\x03\xe0\x41\x01\x12\x15\n\x08password\x18\x04 \x01(\tB\x03\xe0\x41\x02\"H\n(GenerateAutonomousDatabaseWalletResponse\x12\x1c\n\x0f\x61rchive_content\x18\x01 \x01(\x0c\x42\x03\xe0\x41\x03\"\x9d\x01\n\x1fListAutonomousDbVersionsRequest\x12I\n\x06parent\x18\x01 \x01(\tB9\xe0\x41\x02\xfa\x41\x33\x12\x31oracledatabase.googleapis.com/AutonomousDbVersion\x12\x16\n\tpage_size\x18\x02 \x01(\x05\x42\x03\xe0\x41\x01\x12\x17\n\npage_token\x18\x03 \x01(\tB\x03\xe0\x41\x01\"\x90\x01\n ListAutonomousDbVersionsResponse\x12S\n\x16\x61utonomous_db_versions\x18\x01 \x03(\x0b\x32\x33.google.cloud.oracledatabase.v1.AutonomousDbVersion\x12\x17\n\x0fnext_page_token\x18\x02 \x01(\t\"\xc8\x01\n*ListAutonomousDatabaseCharacterSetsRequest\x12T\n\x06parent\x18\x01 \x01(\tBD\xe0\x41\x02\xfa\x41>\x12.google.cloud.oracledatabase.v1.AutonomousDatabaseCharacterSet\x12\x17\n\x0fnext_page_token\x18\x02 \x01(\t\"\xbc\x01\n$ListAutonomousDatabaseBackupsRequest\x12N\n\x06parent\x18\x01 \x01(\tB>\xe0\x41\x02\xfa\x41\x38\x12\x36oracledatabase.googleapis.com/AutonomousDatabaseBackup\x12\x13\n\x06\x66ilter\x18\x05 \x01(\tB\x03\xe0\x41\x01\x12\x16\n\tpage_size\x18\x03 \x01(\x05\x42\x03\xe0\x41\x01\x12\x17\n\npage_token\x18\x04 \x01(\tB\x03\xe0\x41\x01\"\x9f\x01\n%ListAutonomousDatabaseBackupsResponse\x12]\n\x1b\x61utonomous_database_backups\x18\x01 \x03(\x0b\x32\x38.google.cloud.oracledatabase.v1.AutonomousDatabaseBackup\x12\x17\n\x0fnext_page_token\x18\x02 \x01(\t2\x8c+\n\x0eOracleDatabase\x12\x84\x02\n\x1fListCloudExadataInfrastructures\x12\x46.google.cloud.oracledatabase.v1.ListCloudExadataInfrastructuresRequest\x1aG.google.cloud.oracledatabase.v1.ListCloudExadataInfrastructuresResponse\"P\xda\x41\x06parent\x82\xd3\xe4\x93\x02\x41\x12?/v1/{parent=projects/*/locations/*}/cloudExadataInfrastructures\x12\xf1\x01\n\x1dGetCloudExadataInfrastructure\x12\x44.google.cloud.oracledatabase.v1.GetCloudExadataInfrastructureRequest\x1a:.google.cloud.oracledatabase.v1.CloudExadataInfrastructure\"N\xda\x41\x04name\x82\xd3\xe4\x93\x02\x41\x12?/v1/{name=projects/*/locations/*/cloudExadataInfrastructures/*}\x12\xea\x02\n CreateCloudExadataInfrastructure\x12G.google.cloud.oracledatabase.v1.CreateCloudExadataInfrastructureRequest\x1a\x1d.google.longrunning.Operation\"\xdd\x01\xca\x41/\n\x1a\x43loudExadataInfrastructure\x12\x11OperationMetadata\xda\x41\x43parent,cloud_exadata_infrastructure,cloud_exadata_infrastructure_id\x82\xd3\xe4\x93\x02_\"?/v1/{parent=projects/*/locations/*}/cloudExadataInfrastructures:\x1c\x63loud_exadata_infrastructure\x12\x87\x02\n DeleteCloudExadataInfrastructure\x12G.google.cloud.oracledatabase.v1.DeleteCloudExadataInfrastructureRequest\x1a\x1d.google.longrunning.Operation\"{\xca\x41*\n\x15google.protobuf.Empty\x12\x11OperationMetadata\xda\x41\x04name\x82\xd3\xe4\x93\x02\x41*?/v1/{name=projects/*/locations/*/cloudExadataInfrastructures/*}\x12\xd4\x01\n\x13ListCloudVmClusters\x12:.google.cloud.oracledatabase.v1.ListCloudVmClustersRequest\x1a;.google.cloud.oracledatabase.v1.ListCloudVmClustersResponse\"D\xda\x41\x06parent\x82\xd3\xe4\x93\x02\x35\x12\x33/v1/{parent=projects/*/locations/*}/cloudVmClusters\x12\xc1\x01\n\x11GetCloudVmCluster\x12\x38.google.cloud.oracledatabase.v1.GetCloudVmClusterRequest\x1a..google.cloud.oracledatabase.v1.CloudVmCluster\"B\xda\x41\x04name\x82\xd3\xe4\x93\x02\x35\x12\x33/v1/{name=projects/*/locations/*/cloudVmClusters/*}\x12\x96\x02\n\x14\x43reateCloudVmCluster\x12;.google.cloud.oracledatabase.v1.CreateCloudVmClusterRequest\x1a\x1d.google.longrunning.Operation\"\xa1\x01\xca\x41#\n\x0e\x43loudVmCluster\x12\x11OperationMetadata\xda\x41+parent,cloud_vm_cluster,cloud_vm_cluster_id\x82\xd3\xe4\x93\x02G\"3/v1/{parent=projects/*/locations/*}/cloudVmClusters:\x10\x63loud_vm_cluster\x12\xe3\x01\n\x14\x44\x65leteCloudVmCluster\x12;.google.cloud.oracledatabase.v1.DeleteCloudVmClusterRequest\x1a\x1d.google.longrunning.Operation\"o\xca\x41*\n\x15google.protobuf.Empty\x12\x11OperationMetadata\xda\x41\x04name\x82\xd3\xe4\x93\x02\x35*3/v1/{name=projects/*/locations/*/cloudVmClusters/*}\x12\xc8\x01\n\x10ListEntitlements\x12\x37.google.cloud.oracledatabase.v1.ListEntitlementsRequest\x1a\x38.google.cloud.oracledatabase.v1.ListEntitlementsResponse\"A\xda\x41\x06parent\x82\xd3\xe4\x93\x02\x32\x12\x30/v1/{parent=projects/*/locations/*}/entitlements\x12\xda\x01\n\rListDbServers\x12\x34.google.cloud.oracledatabase.v1.ListDbServersRequest\x1a\x35.google.cloud.oracledatabase.v1.ListDbServersResponse\"\\\xda\x41\x06parent\x82\xd3\xe4\x93\x02M\x12K/v1/{parent=projects/*/locations/*/cloudExadataInfrastructures/*}/dbServers\x12\xc6\x01\n\x0bListDbNodes\x12\x32.google.cloud.oracledatabase.v1.ListDbNodesRequest\x1a\x33.google.cloud.oracledatabase.v1.ListDbNodesResponse\"N\xda\x41\x06parent\x82\xd3\xe4\x93\x02?\x12=/v1/{parent=projects/*/locations/*/cloudVmClusters/*}/dbNodes\x12\xc0\x01\n\x0eListGiVersions\x12\x35.google.cloud.oracledatabase.v1.ListGiVersionsRequest\x1a\x36.google.cloud.oracledatabase.v1.ListGiVersionsResponse\"?\xda\x41\x06parent\x82\xd3\xe4\x93\x02\x30\x12./v1/{parent=projects/*/locations/*}/giVersions\x12\xd0\x01\n\x12ListDbSystemShapes\x12\x39.google.cloud.oracledatabase.v1.ListDbSystemShapesRequest\x1a:.google.cloud.oracledatabase.v1.ListDbSystemShapesResponse\"C\xda\x41\x06parent\x82\xd3\xe4\x93\x02\x34\x12\x32/v1/{parent=projects/*/locations/*}/dbSystemShapes\x12\xe4\x01\n\x17ListAutonomousDatabases\x12>.google.cloud.oracledatabase.v1.ListAutonomousDatabasesRequest\x1a?.google.cloud.oracledatabase.v1.ListAutonomousDatabasesResponse\"H\xda\x41\x06parent\x82\xd3\xe4\x93\x02\x39\x12\x37/v1/{parent=projects/*/locations/*}/autonomousDatabases\x12\xd1\x01\n\x15GetAutonomousDatabase\x12<.google.cloud.oracledatabase.v1.GetAutonomousDatabaseRequest\x1a\x32.google.cloud.oracledatabase.v1.AutonomousDatabase\"F\xda\x41\x04name\x82\xd3\xe4\x93\x02\x39\x12\x37/v1/{name=projects/*/locations/*/autonomousDatabases/*}\x12\xaf\x02\n\x18\x43reateAutonomousDatabase\x12?.google.cloud.oracledatabase.v1.CreateAutonomousDatabaseRequest\x1a\x1d.google.longrunning.Operation\"\xb2\x01\xca\x41\'\n\x12\x41utonomousDatabase\x12\x11OperationMetadata\xda\x41\x31parent,autonomous_database,autonomous_database_id\x82\xd3\xe4\x93\x02N\"7/v1/{parent=projects/*/locations/*}/autonomousDatabases:\x13\x61utonomous_database\x12\xef\x01\n\x18\x44\x65leteAutonomousDatabase\x12?.google.cloud.oracledatabase.v1.DeleteAutonomousDatabaseRequest\x1a\x1d.google.longrunning.Operation\"s\xca\x41*\n\x15google.protobuf.Empty\x12\x11OperationMetadata\xda\x41\x04name\x82\xd3\xe4\x93\x02\x39*7/v1/{name=projects/*/locations/*/autonomousDatabases/*}\x12\x87\x02\n\x19RestoreAutonomousDatabase\x12@.google.cloud.oracledatabase.v1.RestoreAutonomousDatabaseRequest\x1a\x1d.google.longrunning.Operation\"\x88\x01\xca\x41\'\n\x12\x41utonomousDatabase\x12\x11OperationMetadata\xda\x41\x11name,restore_time\x82\xd3\xe4\x93\x02\x44\"?/v1/{name=projects/*/locations/*/autonomousDatabases/*}:restore:\x01*\x12\xa9\x02\n GenerateAutonomousDatabaseWallet\x12G.google.cloud.oracledatabase.v1.GenerateAutonomousDatabaseWalletRequest\x1aH.google.cloud.oracledatabase.v1.GenerateAutonomousDatabaseWalletResponse\"r\xda\x41\x1ename,type,is_regional,password\x82\xd3\xe4\x93\x02K\"F/v1/{name=projects/*/locations/*/autonomousDatabases/*}:generateWallet:\x01*\x12\xe8\x01\n\x18ListAutonomousDbVersions\x12?.google.cloud.oracledatabase.v1.ListAutonomousDbVersionsRequest\x1a@.google.cloud.oracledatabase.v1.ListAutonomousDbVersionsResponse\"I\xda\x41\x06parent\x82\xd3\xe4\x93\x02:\x12\x38/v1/{parent=projects/*/locations/*}/autonomousDbVersions\x12\x94\x02\n#ListAutonomousDatabaseCharacterSets\x12J.google.cloud.oracledatabase.v1.ListAutonomousDatabaseCharacterSetsRequest\x1aK.google.cloud.oracledatabase.v1.ListAutonomousDatabaseCharacterSetsResponse\"T\xda\x41\x06parent\x82\xd3\xe4\x93\x02\x45\x12\x43/v1/{parent=projects/*/locations/*}/autonomousDatabaseCharacterSets\x12\xfc\x01\n\x1dListAutonomousDatabaseBackups\x12\x44.google.cloud.oracledatabase.v1.ListAutonomousDatabaseBackupsRequest\x1a\x45.google.cloud.oracledatabase.v1.ListAutonomousDatabaseBackupsResponse\"N\xda\x41\x06parent\x82\xd3\xe4\x93\x02?\x12=/v1/{parent=projects/*/locations/*}/autonomousDatabaseBackups\x1aQ\xca\x41\x1doracledatabase.googleapis.com\xd2\x41.https://www.googleapis.com/auth/cloud-platformB\xb6\x02\n\"com.google.cloud.oracledatabase.v1B\x0bV1mainProtoP\x01ZJcloud.google.com/go/oracledatabase/apiv1/oracledatabasepb;oracledatabasepb\xaa\x02\x1eGoogle.Cloud.OracleDatabase.V1\xca\x02\x1eGoogle\\Cloud\\OracleDatabase\\V1\xea\x02!Google::Cloud::OracleDatabase::V1\xea\x41N\n\x1e\x63ompute.googleapis.com/Network\x12,projects/{project}/global/networks/{network}b\x06proto3" + +pool = Google::Protobuf::DescriptorPool.generated_pool + +begin + pool.add_serialized_file(descriptor_data) +rescue TypeError + # Compatibility code: will be removed in the next major version. + require 'google/protobuf/descriptor_pb' + parsed = Google::Protobuf::FileDescriptorProto.decode(descriptor_data) + parsed.clear_dependency + serialized = parsed.class.encode(parsed) + file = pool.add_serialized_file(serialized) + warn "Warning: Protobuf detected an import path issue while loading generated file #{__FILE__}" + imports = [ + ["google.cloud.oracledatabase.v1.CloudExadataInfrastructure", "google/cloud/oracledatabase/v1/exadata_infra.proto"], + ["google.cloud.oracledatabase.v1.CloudVmCluster", "google/cloud/oracledatabase/v1/vm_cluster.proto"], + ["google.cloud.oracledatabase.v1.Entitlement", "google/cloud/oracledatabase/v1/entitlement.proto"], + ["google.cloud.oracledatabase.v1.DbServer", "google/cloud/oracledatabase/v1/db_server.proto"], + ["google.cloud.oracledatabase.v1.DbNode", "google/cloud/oracledatabase/v1/db_node.proto"], + ["google.cloud.oracledatabase.v1.GiVersion", "google/cloud/oracledatabase/v1/gi_version.proto"], + ["google.cloud.oracledatabase.v1.DbSystemShape", "google/cloud/oracledatabase/v1/db_system_shape.proto"], + ["google.protobuf.Timestamp", "google/protobuf/timestamp.proto"], + ["google.cloud.oracledatabase.v1.AutonomousDatabase", "google/cloud/oracledatabase/v1/autonomous_database.proto"], + ["google.cloud.oracledatabase.v1.AutonomousDbVersion", "google/cloud/oracledatabase/v1/autonomous_db_version.proto"], + ["google.cloud.oracledatabase.v1.AutonomousDatabaseCharacterSet", "google/cloud/oracledatabase/v1/autonomous_database_character_set.proto"], + ["google.cloud.oracledatabase.v1.AutonomousDatabaseBackup", "google/cloud/oracledatabase/v1/autonomous_db_backup.proto"], + ] + imports.each do |type_name, expected_filename| + import_file = pool.lookup(type_name).file_descriptor + if import_file.name != expected_filename + warn "- #{file.name} imports #{expected_filename}, but that import was loaded as #{import_file.name}" + end + end + warn "Each proto file must use a consistent fully-qualified name." + warn "This will become an error in the next major version." +end + +module Google + module Cloud + module OracleDatabase + module V1 + ListCloudExadataInfrastructuresRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.oracledatabase.v1.ListCloudExadataInfrastructuresRequest").msgclass + ListCloudExadataInfrastructuresResponse = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.oracledatabase.v1.ListCloudExadataInfrastructuresResponse").msgclass + GetCloudExadataInfrastructureRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.oracledatabase.v1.GetCloudExadataInfrastructureRequest").msgclass + CreateCloudExadataInfrastructureRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.oracledatabase.v1.CreateCloudExadataInfrastructureRequest").msgclass + DeleteCloudExadataInfrastructureRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.oracledatabase.v1.DeleteCloudExadataInfrastructureRequest").msgclass + ListCloudVmClustersRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.oracledatabase.v1.ListCloudVmClustersRequest").msgclass + ListCloudVmClustersResponse = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.oracledatabase.v1.ListCloudVmClustersResponse").msgclass + GetCloudVmClusterRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.oracledatabase.v1.GetCloudVmClusterRequest").msgclass + CreateCloudVmClusterRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.oracledatabase.v1.CreateCloudVmClusterRequest").msgclass + DeleteCloudVmClusterRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.oracledatabase.v1.DeleteCloudVmClusterRequest").msgclass + ListEntitlementsRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.oracledatabase.v1.ListEntitlementsRequest").msgclass + ListEntitlementsResponse = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.oracledatabase.v1.ListEntitlementsResponse").msgclass + ListDbServersRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.oracledatabase.v1.ListDbServersRequest").msgclass + ListDbServersResponse = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.oracledatabase.v1.ListDbServersResponse").msgclass + ListDbNodesRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.oracledatabase.v1.ListDbNodesRequest").msgclass + ListDbNodesResponse = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.oracledatabase.v1.ListDbNodesResponse").msgclass + ListGiVersionsRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.oracledatabase.v1.ListGiVersionsRequest").msgclass + ListGiVersionsResponse = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.oracledatabase.v1.ListGiVersionsResponse").msgclass + ListDbSystemShapesRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.oracledatabase.v1.ListDbSystemShapesRequest").msgclass + ListDbSystemShapesResponse = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.oracledatabase.v1.ListDbSystemShapesResponse").msgclass + OperationMetadata = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.oracledatabase.v1.OperationMetadata").msgclass + ListAutonomousDatabasesRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.oracledatabase.v1.ListAutonomousDatabasesRequest").msgclass + ListAutonomousDatabasesResponse = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.oracledatabase.v1.ListAutonomousDatabasesResponse").msgclass + GetAutonomousDatabaseRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.oracledatabase.v1.GetAutonomousDatabaseRequest").msgclass + CreateAutonomousDatabaseRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.oracledatabase.v1.CreateAutonomousDatabaseRequest").msgclass + DeleteAutonomousDatabaseRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.oracledatabase.v1.DeleteAutonomousDatabaseRequest").msgclass + RestoreAutonomousDatabaseRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.oracledatabase.v1.RestoreAutonomousDatabaseRequest").msgclass + GenerateAutonomousDatabaseWalletRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.oracledatabase.v1.GenerateAutonomousDatabaseWalletRequest").msgclass + GenerateAutonomousDatabaseWalletResponse = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.oracledatabase.v1.GenerateAutonomousDatabaseWalletResponse").msgclass + ListAutonomousDbVersionsRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.oracledatabase.v1.ListAutonomousDbVersionsRequest").msgclass + ListAutonomousDbVersionsResponse = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.oracledatabase.v1.ListAutonomousDbVersionsResponse").msgclass + ListAutonomousDatabaseCharacterSetsRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.oracledatabase.v1.ListAutonomousDatabaseCharacterSetsRequest").msgclass + ListAutonomousDatabaseCharacterSetsResponse = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.oracledatabase.v1.ListAutonomousDatabaseCharacterSetsResponse").msgclass + ListAutonomousDatabaseBackupsRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.oracledatabase.v1.ListAutonomousDatabaseBackupsRequest").msgclass + ListAutonomousDatabaseBackupsResponse = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.oracledatabase.v1.ListAutonomousDatabaseBackupsResponse").msgclass + end + end + end +end diff --git a/google-cloud-oracle_database-v1/lib/google/cloud/oracledatabase/v1/oracledatabase_services_pb.rb b/google-cloud-oracle_database-v1/lib/google/cloud/oracledatabase/v1/oracledatabase_services_pb.rb new file mode 100644 index 000000000000..53f15f766216 --- /dev/null +++ b/google-cloud-oracle_database-v1/lib/google/cloud/oracledatabase/v1/oracledatabase_services_pb.rb @@ -0,0 +1,89 @@ +# Generated by the protocol buffer compiler. DO NOT EDIT! +# Source: google/cloud/oracledatabase/v1/oracledatabase.proto for package 'Google.Cloud.OracleDatabase.V1' +# Original file comments: +# Copyright 2024 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# + +require 'grpc' +require 'google/cloud/oracledatabase/v1/oracledatabase_pb' + +module Google + module Cloud + module OracleDatabase + module V1 + module OracleDatabase + # Service describing handlers for resources + class Service + + include ::GRPC::GenericService + + self.marshal_class_method = :encode + self.unmarshal_class_method = :decode + self.service_name = 'google.cloud.oracledatabase.v1.OracleDatabase' + + # Lists Exadata Infrastructures in a given project and location. + rpc :ListCloudExadataInfrastructures, ::Google::Cloud::OracleDatabase::V1::ListCloudExadataInfrastructuresRequest, ::Google::Cloud::OracleDatabase::V1::ListCloudExadataInfrastructuresResponse + # Gets details of a single Exadata Infrastructure. + rpc :GetCloudExadataInfrastructure, ::Google::Cloud::OracleDatabase::V1::GetCloudExadataInfrastructureRequest, ::Google::Cloud::OracleDatabase::V1::CloudExadataInfrastructure + # Creates a new Exadata Infrastructure in a given project and location. + rpc :CreateCloudExadataInfrastructure, ::Google::Cloud::OracleDatabase::V1::CreateCloudExadataInfrastructureRequest, ::Google::Longrunning::Operation + # Deletes a single Exadata Infrastructure. + rpc :DeleteCloudExadataInfrastructure, ::Google::Cloud::OracleDatabase::V1::DeleteCloudExadataInfrastructureRequest, ::Google::Longrunning::Operation + # Lists the VM Clusters in a given project and location. + rpc :ListCloudVmClusters, ::Google::Cloud::OracleDatabase::V1::ListCloudVmClustersRequest, ::Google::Cloud::OracleDatabase::V1::ListCloudVmClustersResponse + # Gets details of a single VM Cluster. + rpc :GetCloudVmCluster, ::Google::Cloud::OracleDatabase::V1::GetCloudVmClusterRequest, ::Google::Cloud::OracleDatabase::V1::CloudVmCluster + # Creates a new VM Cluster in a given project and location. + rpc :CreateCloudVmCluster, ::Google::Cloud::OracleDatabase::V1::CreateCloudVmClusterRequest, ::Google::Longrunning::Operation + # Deletes a single VM Cluster. + rpc :DeleteCloudVmCluster, ::Google::Cloud::OracleDatabase::V1::DeleteCloudVmClusterRequest, ::Google::Longrunning::Operation + # Lists the entitlements in a given project. + rpc :ListEntitlements, ::Google::Cloud::OracleDatabase::V1::ListEntitlementsRequest, ::Google::Cloud::OracleDatabase::V1::ListEntitlementsResponse + # Lists the database servers of an Exadata Infrastructure instance. + rpc :ListDbServers, ::Google::Cloud::OracleDatabase::V1::ListDbServersRequest, ::Google::Cloud::OracleDatabase::V1::ListDbServersResponse + # Lists the database nodes of a VM Cluster. + rpc :ListDbNodes, ::Google::Cloud::OracleDatabase::V1::ListDbNodesRequest, ::Google::Cloud::OracleDatabase::V1::ListDbNodesResponse + # Lists all the valid Oracle Grid Infrastructure (GI) versions for the given + # project and location. + rpc :ListGiVersions, ::Google::Cloud::OracleDatabase::V1::ListGiVersionsRequest, ::Google::Cloud::OracleDatabase::V1::ListGiVersionsResponse + # Lists the database system shapes available for the project and location. + rpc :ListDbSystemShapes, ::Google::Cloud::OracleDatabase::V1::ListDbSystemShapesRequest, ::Google::Cloud::OracleDatabase::V1::ListDbSystemShapesResponse + # Lists the Autonomous Databases in a given project and location. + rpc :ListAutonomousDatabases, ::Google::Cloud::OracleDatabase::V1::ListAutonomousDatabasesRequest, ::Google::Cloud::OracleDatabase::V1::ListAutonomousDatabasesResponse + # Gets the details of a single Autonomous Database. + rpc :GetAutonomousDatabase, ::Google::Cloud::OracleDatabase::V1::GetAutonomousDatabaseRequest, ::Google::Cloud::OracleDatabase::V1::AutonomousDatabase + # Creates a new Autonomous Database in a given project and location. + rpc :CreateAutonomousDatabase, ::Google::Cloud::OracleDatabase::V1::CreateAutonomousDatabaseRequest, ::Google::Longrunning::Operation + # Deletes a single Autonomous Database. + rpc :DeleteAutonomousDatabase, ::Google::Cloud::OracleDatabase::V1::DeleteAutonomousDatabaseRequest, ::Google::Longrunning::Operation + # Restores a single Autonomous Database. + rpc :RestoreAutonomousDatabase, ::Google::Cloud::OracleDatabase::V1::RestoreAutonomousDatabaseRequest, ::Google::Longrunning::Operation + # Generates a wallet for an Autonomous Database. + rpc :GenerateAutonomousDatabaseWallet, ::Google::Cloud::OracleDatabase::V1::GenerateAutonomousDatabaseWalletRequest, ::Google::Cloud::OracleDatabase::V1::GenerateAutonomousDatabaseWalletResponse + # Lists all the available Autonomous Database versions for a project and + # location. + rpc :ListAutonomousDbVersions, ::Google::Cloud::OracleDatabase::V1::ListAutonomousDbVersionsRequest, ::Google::Cloud::OracleDatabase::V1::ListAutonomousDbVersionsResponse + # Lists Autonomous Database Character Sets in a given project and location. + rpc :ListAutonomousDatabaseCharacterSets, ::Google::Cloud::OracleDatabase::V1::ListAutonomousDatabaseCharacterSetsRequest, ::Google::Cloud::OracleDatabase::V1::ListAutonomousDatabaseCharacterSetsResponse + # Lists the long-term and automatic backups of an Autonomous Database. + rpc :ListAutonomousDatabaseBackups, ::Google::Cloud::OracleDatabase::V1::ListAutonomousDatabaseBackupsRequest, ::Google::Cloud::OracleDatabase::V1::ListAutonomousDatabaseBackupsResponse + end + + Stub = Service.rpc_stub_class + end + end + end + end +end diff --git a/google-cloud-oracle_database-v1/lib/google/cloud/oracledatabase/v1/vm_cluster_pb.rb b/google-cloud-oracle_database-v1/lib/google/cloud/oracledatabase/v1/vm_cluster_pb.rb new file mode 100644 index 000000000000..6d699af4e975 --- /dev/null +++ b/google-cloud-oracle_database-v1/lib/google/cloud/oracledatabase/v1/vm_cluster_pb.rb @@ -0,0 +1,54 @@ +# frozen_string_literal: true +# Generated by the protocol buffer compiler. DO NOT EDIT! +# source: google/cloud/oracledatabase/v1/vm_cluster.proto + +require 'google/protobuf' + +require 'google/api/field_behavior_pb' +require 'google/api/resource_pb' +require 'google/protobuf/timestamp_pb' +require 'google/type/datetime_pb' + + +descriptor_data = "\n/google/cloud/oracledatabase/v1/vm_cluster.proto\x12\x1egoogle.cloud.oracledatabase.v1\x1a\x1fgoogle/api/field_behavior.proto\x1a\x19google/api/resource.proto\x1a\x1fgoogle/protobuf/timestamp.proto\x1a\x1agoogle/type/datetime.proto\"\xd6\x05\n\x0e\x43loudVmCluster\x12\x11\n\x04name\x18\x01 \x01(\tB\x03\xe0\x41\x08\x12`\n\x16\x65xadata_infrastructure\x18\x02 \x01(\tB@\xe0\x41\x02\xfa\x41:\n8oracledatabase.googleapis.com/CloudExadataInfrastructure\x12\x19\n\x0c\x64isplay_name\x18\x03 \x01(\tB\x03\xe0\x41\x01\x12\x1c\n\x0fgcp_oracle_zone\x18\x0c \x01(\tB\x03\xe0\x41\x03\x12Q\n\nproperties\x18\x06 \x01(\x0b\x32\x38.google.cloud.oracledatabase.v1.CloudVmClusterPropertiesB\x03\xe0\x41\x01\x12O\n\x06labels\x18\x07 \x03(\x0b\x32:.google.cloud.oracledatabase.v1.CloudVmCluster.LabelsEntryB\x03\xe0\x41\x01\x12\x34\n\x0b\x63reate_time\x18\x08 \x01(\x0b\x32\x1a.google.protobuf.TimestampB\x03\xe0\x41\x03\x12\x11\n\x04\x63idr\x18\t \x01(\tB\x03\xe0\x41\x02\x12\x1f\n\x12\x62\x61\x63kup_subnet_cidr\x18\n \x01(\tB\x03\xe0\x41\x02\x12\x37\n\x07network\x18\x0b \x01(\tB&\xe0\x41\x02\xfa\x41 \n\x1e\x63ompute.googleapis.com/Network\x1a-\n\x0bLabelsEntry\x12\x0b\n\x03key\x18\x01 \x01(\t\x12\r\n\x05value\x18\x02 \x01(\t:\x02\x38\x01:\x9f\x01\xea\x41\x9b\x01\n,oracledatabase.googleapis.com/CloudVmCluster\x12Jprojects/{project}/locations/{location}/cloudVmClusters/{cloud_vm_cluster}*\x0f\x63loudVmClusters2\x0e\x63loudVmCluster\"\x9c\x0c\n\x18\x43loudVmClusterProperties\x12\x11\n\x04ocid\x18\x01 \x01(\tB\x03\xe0\x41\x03\x12_\n\x0clicense_type\x18\x02 \x01(\x0e\x32\x44.google.cloud.oracledatabase.v1.CloudVmClusterProperties.LicenseTypeB\x03\xe0\x41\x02\x12\x17\n\ngi_version\x18\x03 \x01(\tB\x03\xe0\x41\x01\x12-\n\ttime_zone\x18\x04 \x01(\x0b\x32\x15.google.type.TimeZoneB\x03\xe0\x41\x01\x12\x1c\n\x0fssh_public_keys\x18\x05 \x03(\tB\x03\xe0\x41\x01\x12\x17\n\nnode_count\x18\x06 \x01(\x05\x42\x03\xe0\x41\x01\x12\x12\n\x05shape\x18\x07 \x01(\tB\x03\xe0\x41\x03\x12\x17\n\nocpu_count\x18\x08 \x01(\x02\x42\x03\xe0\x41\x01\x12\x1b\n\x0ememory_size_gb\x18\t \x01(\x05\x42\x03\xe0\x41\x01\x12$\n\x17\x64\x62_node_storage_size_gb\x18\n \x01(\x05\x42\x03\xe0\x41\x01\x12\x1c\n\x0fstorage_size_gb\x18\x0b \x01(\x05\x42\x03\xe0\x41\x03\x12!\n\x14\x64\x61ta_storage_size_tb\x18\x0c \x01(\x01\x42\x03\xe0\x41\x01\x12\x65\n\x0f\x64isk_redundancy\x18\r \x01(\x0e\x32G.google.cloud.oracledatabase.v1.CloudVmClusterProperties.DiskRedundancyB\x03\xe0\x41\x01\x12%\n\x18sparse_diskgroup_enabled\x18\x0e \x01(\x08\x42\x03\xe0\x41\x01\x12!\n\x14local_backup_enabled\x18\x0f \x01(\x08\x42\x03\xe0\x41\x01\x12\x1c\n\x0fhostname_prefix\x18\x10 \x01(\tB\x03\xe0\x41\x01\x12g\n#diagnostics_data_collection_options\x18\x13 \x01(\x0b\x32\x35.google.cloud.oracledatabase.v1.DataCollectionOptionsB\x03\xe0\x41\x01\x12R\n\x05state\x18\x14 \x01(\x0e\x32>.google.cloud.oracledatabase.v1.CloudVmClusterProperties.StateB\x03\xe0\x41\x03\x12#\n\x16scan_listener_port_tcp\x18\x15 \x01(\x05\x42\x03\xe0\x41\x03\x12\'\n\x1ascan_listener_port_tcp_ssl\x18\x16 \x01(\x05\x42\x03\xe0\x41\x03\x12\x13\n\x06\x64omain\x18\x17 \x01(\tB\x03\xe0\x41\x03\x12\x15\n\x08scan_dns\x18\x18 \x01(\tB\x03\xe0\x41\x03\x12\x15\n\x08hostname\x18\x19 \x01(\tB\x03\xe0\x41\x03\x12\x1b\n\x0e\x63pu_core_count\x18\x1a \x01(\x05\x42\x03\xe0\x41\x02\x12\x1b\n\x0esystem_version\x18\x1b \x01(\tB\x03\xe0\x41\x03\x12\x18\n\x0bscan_ip_ids\x18\x1c \x03(\tB\x03\xe0\x41\x03\x12\x1f\n\x12scan_dns_record_id\x18\x1d \x01(\tB\x03\xe0\x41\x03\x12\x14\n\x07oci_url\x18\x1e \x01(\tB\x03\xe0\x41\x03\x12\x1c\n\x0f\x64\x62_server_ocids\x18\x1f \x03(\tB\x03\xe0\x41\x01\x12\x1b\n\x0e\x63ompartment_id\x18 \x01(\tB\x03\xe0\x41\x03\x12\x1c\n\x0f\x64ns_listener_ip\x18# \x01(\tB\x03\xe0\x41\x03\x12\x19\n\x0c\x63luster_name\x18$ \x01(\tB\x03\xe0\x41\x01\"]\n\x0bLicenseType\x12\x1c\n\x18LICENSE_TYPE_UNSPECIFIED\x10\x00\x12\x14\n\x10LICENSE_INCLUDED\x10\x01\x12\x1a\n\x16\x42RING_YOUR_OWN_LICENSE\x10\x02\"G\n\x0e\x44iskRedundancy\x12\x1f\n\x1b\x44ISK_REDUNDANCY_UNSPECIFIED\x10\x00\x12\x08\n\x04HIGH\x10\x01\x12\n\n\x06NORMAL\x10\x02\"\x97\x01\n\x05State\x12\x15\n\x11STATE_UNSPECIFIED\x10\x00\x12\x10\n\x0cPROVISIONING\x10\x01\x12\r\n\tAVAILABLE\x10\x02\x12\x0c\n\x08UPDATING\x10\x03\x12\x0f\n\x0bTERMINATING\x10\x04\x12\x0e\n\nTERMINATED\x10\x05\x12\n\n\x06\x46\x41ILED\x10\x06\x12\x1b\n\x17MAINTENANCE_IN_PROGRESS\x10\x07\"\x8c\x01\n\x15\x44\x61taCollectionOptions\x12\'\n\x1a\x64iagnostics_events_enabled\x18\x01 \x01(\x08\x42\x03\xe0\x41\x01\x12&\n\x19health_monitoring_enabled\x18\x02 \x01(\x08\x42\x03\xe0\x41\x01\x12\"\n\x15incident_logs_enabled\x18\x03 \x01(\x08\x42\x03\xe0\x41\x01\x42\xed\x01\n\"com.google.cloud.oracledatabase.v1B\x13\x43loudVmClusterProtoP\x01ZJcloud.google.com/go/oracledatabase/apiv1/oracledatabasepb;oracledatabasepb\xaa\x02\x1eGoogle.Cloud.OracleDatabase.V1\xca\x02\x1eGoogle\\Cloud\\OracleDatabase\\V1\xea\x02!Google::Cloud::OracleDatabase::V1b\x06proto3" + +pool = Google::Protobuf::DescriptorPool.generated_pool + +begin + pool.add_serialized_file(descriptor_data) +rescue TypeError + # Compatibility code: will be removed in the next major version. + require 'google/protobuf/descriptor_pb' + parsed = Google::Protobuf::FileDescriptorProto.decode(descriptor_data) + parsed.clear_dependency + serialized = parsed.class.encode(parsed) + file = pool.add_serialized_file(serialized) + warn "Warning: Protobuf detected an import path issue while loading generated file #{__FILE__}" + imports = [ + ["google.protobuf.Timestamp", "google/protobuf/timestamp.proto"], + ["google.type.TimeZone", "google/type/datetime.proto"], + ] + imports.each do |type_name, expected_filename| + import_file = pool.lookup(type_name).file_descriptor + if import_file.name != expected_filename + warn "- #{file.name} imports #{expected_filename}, but that import was loaded as #{import_file.name}" + end + end + warn "Each proto file must use a consistent fully-qualified name." + warn "This will become an error in the next major version." +end + +module Google + module Cloud + module OracleDatabase + module V1 + CloudVmCluster = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.oracledatabase.v1.CloudVmCluster").msgclass + CloudVmClusterProperties = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.oracledatabase.v1.CloudVmClusterProperties").msgclass + CloudVmClusterProperties::LicenseType = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.oracledatabase.v1.CloudVmClusterProperties.LicenseType").enummodule + CloudVmClusterProperties::DiskRedundancy = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.oracledatabase.v1.CloudVmClusterProperties.DiskRedundancy").enummodule + CloudVmClusterProperties::State = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.oracledatabase.v1.CloudVmClusterProperties.State").enummodule + DataCollectionOptions = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.oracledatabase.v1.DataCollectionOptions").msgclass + end + end + end +end diff --git a/google-cloud-oracle_database-v1/proto_docs/README.md b/google-cloud-oracle_database-v1/proto_docs/README.md new file mode 100644 index 000000000000..8039fb55e54d --- /dev/null +++ b/google-cloud-oracle_database-v1/proto_docs/README.md @@ -0,0 +1,4 @@ +# Oracle Database@Google Cloud V1 Protocol Buffer Documentation + +These files are for the YARD documentation of the generated protobuf files. +They are not intended to be required or loaded at runtime. diff --git a/google-cloud-oracle_database-v1/proto_docs/google/api/client.rb b/google-cloud-oracle_database-v1/proto_docs/google/api/client.rb new file mode 100644 index 000000000000..2223d8935069 --- /dev/null +++ b/google-cloud-oracle_database-v1/proto_docs/google/api/client.rb @@ -0,0 +1,420 @@ +# frozen_string_literal: true + +# Copyright 2024 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# https://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Auto-generated by gapic-generator-ruby. DO NOT EDIT! + + +module Google + module Api + # Required information for every language. + # @!attribute [rw] reference_docs_uri + # @deprecated This field is deprecated and may be removed in the next major version update. + # @return [::String] + # Link to automatically generated reference documentation. Example: + # https://cloud.google.com/nodejs/docs/reference/asset/latest + # @!attribute [rw] destinations + # @return [::Array<::Google::Api::ClientLibraryDestination>] + # The destination where API teams want this client library to be published. + class CommonLanguageSettings + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + end + + # Details about how and where to publish client libraries. + # @!attribute [rw] version + # @return [::String] + # Version of the API to apply these settings to. This is the full protobuf + # package for the API, ending in the version element. + # Examples: "google.cloud.speech.v1" and "google.spanner.admin.database.v1". + # @!attribute [rw] launch_stage + # @return [::Google::Api::LaunchStage] + # Launch stage of this version of the API. + # @!attribute [rw] rest_numeric_enums + # @return [::Boolean] + # When using transport=rest, the client request will encode enums as + # numbers rather than strings. + # @!attribute [rw] java_settings + # @return [::Google::Api::JavaSettings] + # Settings for legacy Java features, supported in the Service YAML. + # @!attribute [rw] cpp_settings + # @return [::Google::Api::CppSettings] + # Settings for C++ client libraries. + # @!attribute [rw] php_settings + # @return [::Google::Api::PhpSettings] + # Settings for PHP client libraries. + # @!attribute [rw] python_settings + # @return [::Google::Api::PythonSettings] + # Settings for Python client libraries. + # @!attribute [rw] node_settings + # @return [::Google::Api::NodeSettings] + # Settings for Node client libraries. + # @!attribute [rw] dotnet_settings + # @return [::Google::Api::DotnetSettings] + # Settings for .NET client libraries. + # @!attribute [rw] ruby_settings + # @return [::Google::Api::RubySettings] + # Settings for Ruby client libraries. + # @!attribute [rw] go_settings + # @return [::Google::Api::GoSettings] + # Settings for Go client libraries. + class ClientLibrarySettings + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + end + + # This message configures the settings for publishing [Google Cloud Client + # libraries](https://cloud.google.com/apis/docs/cloud-client-libraries) + # generated from the service config. + # @!attribute [rw] method_settings + # @return [::Array<::Google::Api::MethodSettings>] + # A list of API method settings, e.g. the behavior for methods that use the + # long-running operation pattern. + # @!attribute [rw] new_issue_uri + # @return [::String] + # Link to a *public* URI where users can report issues. Example: + # https://issuetracker.google.com/issues/new?component=190865&template=1161103 + # @!attribute [rw] documentation_uri + # @return [::String] + # Link to product home page. Example: + # https://cloud.google.com/asset-inventory/docs/overview + # @!attribute [rw] api_short_name + # @return [::String] + # Used as a tracking tag when collecting data about the APIs developer + # relations artifacts like docs, packages delivered to package managers, + # etc. Example: "speech". + # @!attribute [rw] github_label + # @return [::String] + # GitHub label to apply to issues and pull requests opened for this API. + # @!attribute [rw] codeowner_github_teams + # @return [::Array<::String>] + # GitHub teams to be added to CODEOWNERS in the directory in GitHub + # containing source code for the client libraries for this API. + # @!attribute [rw] doc_tag_prefix + # @return [::String] + # A prefix used in sample code when demarking regions to be included in + # documentation. + # @!attribute [rw] organization + # @return [::Google::Api::ClientLibraryOrganization] + # For whom the client library is being published. + # @!attribute [rw] library_settings + # @return [::Array<::Google::Api::ClientLibrarySettings>] + # Client library settings. If the same version string appears multiple + # times in this list, then the last one wins. Settings from earlier + # settings with the same version string are discarded. + # @!attribute [rw] proto_reference_documentation_uri + # @return [::String] + # Optional link to proto reference documentation. Example: + # https://cloud.google.com/pubsub/lite/docs/reference/rpc + # @!attribute [rw] rest_reference_documentation_uri + # @return [::String] + # Optional link to REST reference documentation. Example: + # https://cloud.google.com/pubsub/lite/docs/reference/rest + class Publishing + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + end + + # Settings for Java client libraries. + # @!attribute [rw] library_package + # @return [::String] + # The package name to use in Java. Clobbers the java_package option + # set in the protobuf. This should be used **only** by APIs + # who have already set the language_settings.java.package_name" field + # in gapic.yaml. API teams should use the protobuf java_package option + # where possible. + # + # Example of a YAML configuration:: + # + # publishing: + # java_settings: + # library_package: com.google.cloud.pubsub.v1 + # @!attribute [rw] service_class_names + # @return [::Google::Protobuf::Map{::String => ::String}] + # Configure the Java class name to use instead of the service's for its + # corresponding generated GAPIC client. Keys are fully-qualified + # service names as they appear in the protobuf (including the full + # the language_settings.java.interface_names" field in gapic.yaml. API + # teams should otherwise use the service name as it appears in the + # protobuf. + # + # Example of a YAML configuration:: + # + # publishing: + # java_settings: + # service_class_names: + # - google.pubsub.v1.Publisher: TopicAdmin + # - google.pubsub.v1.Subscriber: SubscriptionAdmin + # @!attribute [rw] common + # @return [::Google::Api::CommonLanguageSettings] + # Some settings. + class JavaSettings + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + + # @!attribute [rw] key + # @return [::String] + # @!attribute [rw] value + # @return [::String] + class ServiceClassNamesEntry + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + end + end + + # Settings for C++ client libraries. + # @!attribute [rw] common + # @return [::Google::Api::CommonLanguageSettings] + # Some settings. + class CppSettings + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + end + + # Settings for Php client libraries. + # @!attribute [rw] common + # @return [::Google::Api::CommonLanguageSettings] + # Some settings. + class PhpSettings + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + end + + # Settings for Python client libraries. + # @!attribute [rw] common + # @return [::Google::Api::CommonLanguageSettings] + # Some settings. + # @!attribute [rw] experimental_features + # @return [::Google::Api::PythonSettings::ExperimentalFeatures] + # Experimental features to be included during client library generation. + class PythonSettings + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + + # Experimental features to be included during client library generation. + # These fields will be deprecated once the feature graduates and is enabled + # by default. + # @!attribute [rw] rest_async_io_enabled + # @return [::Boolean] + # Enables generation of asynchronous REST clients if `rest` transport is + # enabled. By default, asynchronous REST clients will not be generated. + # This feature will be enabled by default 1 month after launching the + # feature in preview packages. + class ExperimentalFeatures + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + end + end + + # Settings for Node client libraries. + # @!attribute [rw] common + # @return [::Google::Api::CommonLanguageSettings] + # Some settings. + class NodeSettings + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + end + + # Settings for Dotnet client libraries. + # @!attribute [rw] common + # @return [::Google::Api::CommonLanguageSettings] + # Some settings. + # @!attribute [rw] renamed_services + # @return [::Google::Protobuf::Map{::String => ::String}] + # Map from original service names to renamed versions. + # This is used when the default generated types + # would cause a naming conflict. (Neither name is + # fully-qualified.) + # Example: Subscriber to SubscriberServiceApi. + # @!attribute [rw] renamed_resources + # @return [::Google::Protobuf::Map{::String => ::String}] + # Map from full resource types to the effective short name + # for the resource. This is used when otherwise resource + # named from different services would cause naming collisions. + # Example entry: + # "datalabeling.googleapis.com/Dataset": "DataLabelingDataset" + # @!attribute [rw] ignored_resources + # @return [::Array<::String>] + # List of full resource types to ignore during generation. + # This is typically used for API-specific Location resources, + # which should be handled by the generator as if they were actually + # the common Location resources. + # Example entry: "documentai.googleapis.com/Location" + # @!attribute [rw] forced_namespace_aliases + # @return [::Array<::String>] + # Namespaces which must be aliased in snippets due to + # a known (but non-generator-predictable) naming collision + # @!attribute [rw] handwritten_signatures + # @return [::Array<::String>] + # Method signatures (in the form "service.method(signature)") + # which are provided separately, so shouldn't be generated. + # Snippets *calling* these methods are still generated, however. + class DotnetSettings + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + + # @!attribute [rw] key + # @return [::String] + # @!attribute [rw] value + # @return [::String] + class RenamedServicesEntry + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + end + + # @!attribute [rw] key + # @return [::String] + # @!attribute [rw] value + # @return [::String] + class RenamedResourcesEntry + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + end + end + + # Settings for Ruby client libraries. + # @!attribute [rw] common + # @return [::Google::Api::CommonLanguageSettings] + # Some settings. + class RubySettings + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + end + + # Settings for Go client libraries. + # @!attribute [rw] common + # @return [::Google::Api::CommonLanguageSettings] + # Some settings. + class GoSettings + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + end + + # Describes the generator configuration for a method. + # @!attribute [rw] selector + # @return [::String] + # The fully qualified name of the method, for which the options below apply. + # This is used to find the method to apply the options. + # + # Example: + # + # publishing: + # method_settings: + # - selector: google.storage.control.v2.StorageControl.CreateFolder + # # method settings for CreateFolder... + # @!attribute [rw] long_running + # @return [::Google::Api::MethodSettings::LongRunning] + # Describes settings to use for long-running operations when generating + # API methods for RPCs. Complements RPCs that use the annotations in + # google/longrunning/operations.proto. + # + # Example of a YAML configuration:: + # + # publishing: + # method_settings: + # - selector: google.cloud.speech.v2.Speech.BatchRecognize + # long_running: + # initial_poll_delay: 60s # 1 minute + # poll_delay_multiplier: 1.5 + # max_poll_delay: 360s # 6 minutes + # total_poll_timeout: 54000s # 90 minutes + # @!attribute [rw] auto_populated_fields + # @return [::Array<::String>] + # List of top-level fields of the request message, that should be + # automatically populated by the client libraries based on their + # (google.api.field_info).format. Currently supported format: UUID4. + # + # Example of a YAML configuration: + # + # publishing: + # method_settings: + # - selector: google.example.v1.ExampleService.CreateExample + # auto_populated_fields: + # - request_id + class MethodSettings + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + + # Describes settings to use when generating API methods that use the + # long-running operation pattern. + # All default values below are from those used in the client library + # generators (e.g. + # [Java](https://github.com/googleapis/gapic-generator-java/blob/04c2faa191a9b5a10b92392fe8482279c4404803/src/main/java/com/google/api/generator/gapic/composer/common/RetrySettingsComposer.java)). + # @!attribute [rw] initial_poll_delay + # @return [::Google::Protobuf::Duration] + # Initial delay after which the first poll request will be made. + # Default value: 5 seconds. + # @!attribute [rw] poll_delay_multiplier + # @return [::Float] + # Multiplier to gradually increase delay between subsequent polls until it + # reaches max_poll_delay. + # Default value: 1.5. + # @!attribute [rw] max_poll_delay + # @return [::Google::Protobuf::Duration] + # Maximum time between two subsequent poll requests. + # Default value: 45 seconds. + # @!attribute [rw] total_poll_timeout + # @return [::Google::Protobuf::Duration] + # Total polling timeout. + # Default value: 5 minutes. + class LongRunning + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + end + end + + # The organization for which the client libraries are being published. + # Affects the url where generated docs are published, etc. + module ClientLibraryOrganization + # Not useful. + CLIENT_LIBRARY_ORGANIZATION_UNSPECIFIED = 0 + + # Google Cloud Platform Org. + CLOUD = 1 + + # Ads (Advertising) Org. + ADS = 2 + + # Photos Org. + PHOTOS = 3 + + # Street View Org. + STREET_VIEW = 4 + + # Shopping Org. + SHOPPING = 5 + + # Geo Org. + GEO = 6 + + # Generative AI - https://developers.generativeai.google + GENERATIVE_AI = 7 + end + + # To where should client libraries be published? + module ClientLibraryDestination + # Client libraries will neither be generated nor published to package + # managers. + CLIENT_LIBRARY_DESTINATION_UNSPECIFIED = 0 + + # Generate the client library in a repo under github.com/googleapis, + # but don't publish it to package managers. + GITHUB = 10 + + # Publish the library to package managers like nuget.org and npmjs.com. + PACKAGE_MANAGER = 20 + end + end +end diff --git a/google-cloud-oracle_database-v1/proto_docs/google/api/field_behavior.rb b/google-cloud-oracle_database-v1/proto_docs/google/api/field_behavior.rb new file mode 100644 index 000000000000..b03587481349 --- /dev/null +++ b/google-cloud-oracle_database-v1/proto_docs/google/api/field_behavior.rb @@ -0,0 +1,85 @@ +# frozen_string_literal: true + +# Copyright 2024 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# https://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Auto-generated by gapic-generator-ruby. DO NOT EDIT! + + +module Google + module Api + # An indicator of the behavior of a given field (for example, that a field + # is required in requests, or given as output but ignored as input). + # This **does not** change the behavior in protocol buffers itself; it only + # denotes the behavior and may affect how API tooling handles the field. + # + # Note: This enum **may** receive new values in the future. + module FieldBehavior + # Conventional default for enums. Do not use this. + FIELD_BEHAVIOR_UNSPECIFIED = 0 + + # Specifically denotes a field as optional. + # While all fields in protocol buffers are optional, this may be specified + # for emphasis if appropriate. + OPTIONAL = 1 + + # Denotes a field as required. + # This indicates that the field **must** be provided as part of the request, + # and failure to do so will cause an error (usually `INVALID_ARGUMENT`). + REQUIRED = 2 + + # Denotes a field as output only. + # This indicates that the field is provided in responses, but including the + # field in a request does nothing (the server *must* ignore it and + # *must not* throw an error as a result of the field's presence). + OUTPUT_ONLY = 3 + + # Denotes a field as input only. + # This indicates that the field is provided in requests, and the + # corresponding field is not included in output. + INPUT_ONLY = 4 + + # Denotes a field as immutable. + # This indicates that the field may be set once in a request to create a + # resource, but may not be changed thereafter. + IMMUTABLE = 5 + + # Denotes that a (repeated) field is an unordered list. + # This indicates that the service may provide the elements of the list + # in any arbitrary order, rather than the order the user originally + # provided. Additionally, the list's order may or may not be stable. + UNORDERED_LIST = 6 + + # Denotes that this field returns a non-empty default value if not set. + # This indicates that if the user provides the empty value in a request, + # a non-empty value will be returned. The user will not be aware of what + # non-empty value to expect. + NON_EMPTY_DEFAULT = 7 + + # Denotes that the field in a resource (a message annotated with + # google.api.resource) is used in the resource name to uniquely identify the + # resource. For AIP-compliant APIs, this should only be applied to the + # `name` field on the resource. + # + # This behavior should not be applied to references to other resources within + # the message. + # + # The identifier field of resources often have different field behavior + # depending on the request it is embedded in (e.g. for Create methods name + # is optional and unused, while for Update methods it is required). Instead + # of method-specific annotations, only `IDENTIFIER` is required. + IDENTIFIER = 8 + end + end +end diff --git a/google-cloud-oracle_database-v1/proto_docs/google/api/field_info.rb b/google-cloud-oracle_database-v1/proto_docs/google/api/field_info.rb new file mode 100644 index 000000000000..d558fed6cef1 --- /dev/null +++ b/google-cloud-oracle_database-v1/proto_docs/google/api/field_info.rb @@ -0,0 +1,88 @@ +# frozen_string_literal: true + +# Copyright 2024 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# https://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Auto-generated by gapic-generator-ruby. DO NOT EDIT! + + +module Google + module Api + # Rich semantic information of an API field beyond basic typing. + # @!attribute [rw] format + # @return [::Google::Api::FieldInfo::Format] + # The standard format of a field value. This does not explicitly configure + # any API consumer, just documents the API's format for the field it is + # applied to. + # @!attribute [rw] referenced_types + # @return [::Array<::Google::Api::TypeReference>] + # The type(s) that the annotated, generic field may represent. + # + # Currently, this must only be used on fields of type `google.protobuf.Any`. + # Supporting other generic types may be considered in the future. + class FieldInfo + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + + # The standard format of a field value. The supported formats are all backed + # by either an RFC defined by the IETF or a Google-defined AIP. + module Format + # Default, unspecified value. + FORMAT_UNSPECIFIED = 0 + + # Universally Unique Identifier, version 4, value as defined by + # https://datatracker.ietf.org/doc/html/rfc4122. The value may be + # normalized to entirely lowercase letters. For example, the value + # `F47AC10B-58CC-0372-8567-0E02B2C3D479` would be normalized to + # `f47ac10b-58cc-0372-8567-0e02b2c3d479`. + UUID4 = 1 + + # Internet Protocol v4 value as defined by [RFC + # 791](https://datatracker.ietf.org/doc/html/rfc791). The value may be + # condensed, with leading zeros in each octet stripped. For example, + # `001.022.233.040` would be condensed to `1.22.233.40`. + IPV4 = 2 + + # Internet Protocol v6 value as defined by [RFC + # 2460](https://datatracker.ietf.org/doc/html/rfc2460). The value may be + # normalized to entirely lowercase letters with zeros compressed, following + # [RFC 5952](https://datatracker.ietf.org/doc/html/rfc5952). For example, + # the value `2001:0DB8:0::0` would be normalized to `2001:db8::`. + IPV6 = 3 + + # An IP address in either v4 or v6 format as described by the individual + # values defined herein. See the comments on the IPV4 and IPV6 types for + # allowed normalizations of each. + IPV4_OR_IPV6 = 4 + end + end + + # A reference to a message type, for use in {::Google::Api::FieldInfo FieldInfo}. + # @!attribute [rw] type_name + # @return [::String] + # The name of the type that the annotated, generic field may represent. + # If the type is in the same protobuf package, the value can be the simple + # message name e.g., `"MyMessage"`. Otherwise, the value must be the + # fully-qualified message name e.g., `"google.library.v1.Book"`. + # + # If the type(s) are unknown to the service (e.g. the field accepts generic + # user input), use the wildcard `"*"` to denote this behavior. + # + # See [AIP-202](https://google.aip.dev/202#type-references) for more details. + class TypeReference + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + end + end +end diff --git a/google-cloud-oracle_database-v1/proto_docs/google/api/launch_stage.rb b/google-cloud-oracle_database-v1/proto_docs/google/api/launch_stage.rb new file mode 100644 index 000000000000..38b4b61e6061 --- /dev/null +++ b/google-cloud-oracle_database-v1/proto_docs/google/api/launch_stage.rb @@ -0,0 +1,71 @@ +# frozen_string_literal: true + +# Copyright 2024 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# https://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Auto-generated by gapic-generator-ruby. DO NOT EDIT! + + +module Google + module Api + # The launch stage as defined by [Google Cloud Platform + # Launch Stages](https://cloud.google.com/terms/launch-stages). + module LaunchStage + # Do not use this default value. + LAUNCH_STAGE_UNSPECIFIED = 0 + + # The feature is not yet implemented. Users can not use it. + UNIMPLEMENTED = 6 + + # Prelaunch features are hidden from users and are only visible internally. + PRELAUNCH = 7 + + # Early Access features are limited to a closed group of testers. To use + # these features, you must sign up in advance and sign a Trusted Tester + # agreement (which includes confidentiality provisions). These features may + # be unstable, changed in backward-incompatible ways, and are not + # guaranteed to be released. + EARLY_ACCESS = 1 + + # Alpha is a limited availability test for releases before they are cleared + # for widespread use. By Alpha, all significant design issues are resolved + # and we are in the process of verifying functionality. Alpha customers + # need to apply for access, agree to applicable terms, and have their + # projects allowlisted. Alpha releases don't have to be feature complete, + # no SLAs are provided, and there are no technical support obligations, but + # they will be far enough along that customers can actually use them in + # test environments or for limited-use tests -- just like they would in + # normal production cases. + ALPHA = 2 + + # Beta is the point at which we are ready to open a release for any + # customer to use. There are no SLA or technical support obligations in a + # Beta release. Products will be complete from a feature perspective, but + # may have some open outstanding issues. Beta releases are suitable for + # limited production use cases. + BETA = 3 + + # GA features are open to all developers and are considered stable and + # fully qualified for production use. + GA = 4 + + # Deprecated features are scheduled to be shut down and removed. For more + # information, see the "Deprecation Policy" section of our [Terms of + # Service](https://cloud.google.com/terms/) + # and the [Google Cloud Platform Subject to the Deprecation + # Policy](https://cloud.google.com/terms/deprecation) documentation. + DEPRECATED = 5 + end + end +end diff --git a/google-cloud-oracle_database-v1/proto_docs/google/api/resource.rb b/google-cloud-oracle_database-v1/proto_docs/google/api/resource.rb new file mode 100644 index 000000000000..935946d52792 --- /dev/null +++ b/google-cloud-oracle_database-v1/proto_docs/google/api/resource.rb @@ -0,0 +1,227 @@ +# frozen_string_literal: true + +# Copyright 2024 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# https://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Auto-generated by gapic-generator-ruby. DO NOT EDIT! + + +module Google + module Api + # A simple descriptor of a resource type. + # + # ResourceDescriptor annotates a resource message (either by means of a + # protobuf annotation or use in the service config), and associates the + # resource's schema, the resource type, and the pattern of the resource name. + # + # Example: + # + # message Topic { + # // Indicates this message defines a resource schema. + # // Declares the resource type in the format of {service}/{kind}. + # // For Kubernetes resources, the format is {api group}/{kind}. + # option (google.api.resource) = { + # type: "pubsub.googleapis.com/Topic" + # pattern: "projects/{project}/topics/{topic}" + # }; + # } + # + # The ResourceDescriptor Yaml config will look like: + # + # resources: + # - type: "pubsub.googleapis.com/Topic" + # pattern: "projects/{project}/topics/{topic}" + # + # Sometimes, resources have multiple patterns, typically because they can + # live under multiple parents. + # + # Example: + # + # message LogEntry { + # option (google.api.resource) = { + # type: "logging.googleapis.com/LogEntry" + # pattern: "projects/{project}/logs/{log}" + # pattern: "folders/{folder}/logs/{log}" + # pattern: "organizations/{organization}/logs/{log}" + # pattern: "billingAccounts/{billing_account}/logs/{log}" + # }; + # } + # + # The ResourceDescriptor Yaml config will look like: + # + # resources: + # - type: 'logging.googleapis.com/LogEntry' + # pattern: "projects/{project}/logs/{log}" + # pattern: "folders/{folder}/logs/{log}" + # pattern: "organizations/{organization}/logs/{log}" + # pattern: "billingAccounts/{billing_account}/logs/{log}" + # @!attribute [rw] type + # @return [::String] + # The resource type. It must be in the format of + # \\{service_name}/\\{resource_type_kind}. The `resource_type_kind` must be + # singular and must not include version numbers. + # + # Example: `storage.googleapis.com/Bucket` + # + # The value of the resource_type_kind must follow the regular expression + # /[A-Za-z][a-zA-Z0-9]+/. It should start with an upper case character and + # should use PascalCase (UpperCamelCase). The maximum number of + # characters allowed for the `resource_type_kind` is 100. + # @!attribute [rw] pattern + # @return [::Array<::String>] + # Optional. The relative resource name pattern associated with this resource + # type. The DNS prefix of the full resource name shouldn't be specified here. + # + # The path pattern must follow the syntax, which aligns with HTTP binding + # syntax: + # + # Template = Segment { "/" Segment } ; + # Segment = LITERAL | Variable ; + # Variable = "{" LITERAL "}" ; + # + # Examples: + # + # - "projects/\\{project}/topics/\\{topic}" + # - "projects/\\{project}/knowledgeBases/\\{knowledge_base}" + # + # The components in braces correspond to the IDs for each resource in the + # hierarchy. It is expected that, if multiple patterns are provided, + # the same component name (e.g. "project") refers to IDs of the same + # type of resource. + # @!attribute [rw] name_field + # @return [::String] + # Optional. The field on the resource that designates the resource name + # field. If omitted, this is assumed to be "name". + # @!attribute [rw] history + # @return [::Google::Api::ResourceDescriptor::History] + # Optional. The historical or future-looking state of the resource pattern. + # + # Example: + # + # // The InspectTemplate message originally only supported resource + # // names with organization, and project was added later. + # message InspectTemplate { + # option (google.api.resource) = { + # type: "dlp.googleapis.com/InspectTemplate" + # pattern: + # "organizations/{organization}/inspectTemplates/{inspect_template}" + # pattern: "projects/{project}/inspectTemplates/{inspect_template}" + # history: ORIGINALLY_SINGLE_PATTERN + # }; + # } + # @!attribute [rw] plural + # @return [::String] + # The plural name used in the resource name and permission names, such as + # 'projects' for the resource name of 'projects/\\{project}' and the permission + # name of 'cloudresourcemanager.googleapis.com/projects.get'. One exception + # to this is for Nested Collections that have stuttering names, as defined + # in [AIP-122](https://google.aip.dev/122#nested-collections), where the + # collection ID in the resource name pattern does not necessarily directly + # match the `plural` value. + # + # It is the same concept of the `plural` field in k8s CRD spec + # https://kubernetes.io/docs/tasks/access-kubernetes-api/custom-resources/custom-resource-definitions/ + # + # Note: The plural form is required even for singleton resources. See + # https://aip.dev/156 + # @!attribute [rw] singular + # @return [::String] + # The same concept of the `singular` field in k8s CRD spec + # https://kubernetes.io/docs/tasks/access-kubernetes-api/custom-resources/custom-resource-definitions/ + # Such as "project" for the `resourcemanager.googleapis.com/Project` type. + # @!attribute [rw] style + # @return [::Array<::Google::Api::ResourceDescriptor::Style>] + # Style flag(s) for this resource. + # These indicate that a resource is expected to conform to a given + # style. See the specific style flags for additional information. + class ResourceDescriptor + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + + # A description of the historical or future-looking state of the + # resource pattern. + module History + # The "unset" value. + HISTORY_UNSPECIFIED = 0 + + # The resource originally had one pattern and launched as such, and + # additional patterns were added later. + ORIGINALLY_SINGLE_PATTERN = 1 + + # The resource has one pattern, but the API owner expects to add more + # later. (This is the inverse of ORIGINALLY_SINGLE_PATTERN, and prevents + # that from being necessary once there are multiple patterns.) + FUTURE_MULTI_PATTERN = 2 + end + + # A flag representing a specific style that a resource claims to conform to. + module Style + # The unspecified value. Do not use. + STYLE_UNSPECIFIED = 0 + + # This resource is intended to be "declarative-friendly". + # + # Declarative-friendly resources must be more strictly consistent, and + # setting this to true communicates to tools that this resource should + # adhere to declarative-friendly expectations. + # + # Note: This is used by the API linter (linter.aip.dev) to enable + # additional checks. + DECLARATIVE_FRIENDLY = 1 + end + end + + # Defines a proto annotation that describes a string field that refers to + # an API resource. + # @!attribute [rw] type + # @return [::String] + # The resource type that the annotated field references. + # + # Example: + # + # message Subscription { + # string topic = 2 [(google.api.resource_reference) = { + # type: "pubsub.googleapis.com/Topic" + # }]; + # } + # + # Occasionally, a field may reference an arbitrary resource. In this case, + # APIs use the special value * in their resource reference. + # + # Example: + # + # message GetIamPolicyRequest { + # string resource = 2 [(google.api.resource_reference) = { + # type: "*" + # }]; + # } + # @!attribute [rw] child_type + # @return [::String] + # The resource type of a child collection that the annotated field + # references. This is useful for annotating the `parent` field that + # doesn't have a fixed resource type. + # + # Example: + # + # message ListLogEntriesRequest { + # string parent = 1 [(google.api.resource_reference) = { + # child_type: "logging.googleapis.com/LogEntry" + # }; + # } + class ResourceReference + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + end + end +end diff --git a/google-cloud-oracle_database-v1/proto_docs/google/cloud/oracledatabase/v1/autonomous_database.rb b/google-cloud-oracle_database-v1/proto_docs/google/cloud/oracledatabase/v1/autonomous_database.rb new file mode 100644 index 000000000000..b7b4bad18776 --- /dev/null +++ b/google-cloud-oracle_database-v1/proto_docs/google/cloud/oracledatabase/v1/autonomous_database.rb @@ -0,0 +1,844 @@ +# frozen_string_literal: true + +# Copyright 2024 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# https://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Auto-generated by gapic-generator-ruby. DO NOT EDIT! + + +module Google + module Cloud + module OracleDatabase + module V1 + # Details of the Autonomous Database resource. + # https://docs.oracle.com/en-us/iaas/api/#/en/database/20160918/AutonomousDatabase/ + # @!attribute [rw] name + # @return [::String] + # Identifier. The name of the Autonomous Database resource in the following + # format: + # projects/\\{project}/locations/\\{region}/autonomousDatabases/\\{autonomous_database} + # @!attribute [rw] database + # @return [::String] + # Optional. The name of the Autonomous Database. The database name must be + # unique in the project. The name must begin with a letter and can contain a + # maximum of 30 alphanumeric characters. + # @!attribute [rw] display_name + # @return [::String] + # Optional. The display name for the Autonomous Database. The name does not + # have to be unique within your project. + # @!attribute [r] entitlement_id + # @return [::String] + # Output only. The ID of the subscription entitlement associated with the + # Autonomous Database. + # @!attribute [rw] admin_password + # @return [::String] + # Optional. The password for the default ADMIN user. + # @!attribute [rw] properties + # @return [::Google::Cloud::OracleDatabase::V1::AutonomousDatabaseProperties] + # Optional. The properties of the Autonomous Database. + # @!attribute [rw] labels + # @return [::Google::Protobuf::Map{::String => ::String}] + # Optional. The labels or tags associated with the Autonomous Database. + # @!attribute [rw] network + # @return [::String] + # Required. The name of the VPC network used by the Autonomous Database in + # the following format: projects/\\{project}/global/networks/\\{network} + # @!attribute [rw] cidr + # @return [::String] + # Required. The subnet CIDR range for the Autonmous Database. + # @!attribute [r] create_time + # @return [::Google::Protobuf::Timestamp] + # Output only. The date and time that the Autonomous Database was created. + class AutonomousDatabase + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + + # @!attribute [rw] key + # @return [::String] + # @!attribute [rw] value + # @return [::String] + class LabelsEntry + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + end + end + + # The properties of an Autonomous Database. + # @!attribute [r] ocid + # @return [::String] + # Output only. OCID of the Autonomous Database. + # https://docs.oracle.com/en-us/iaas/Content/General/Concepts/identifiers.htm#Oracle + # @!attribute [rw] compute_count + # @return [::Float] + # Optional. The number of compute servers for the Autonomous Database. + # @!attribute [rw] cpu_core_count + # @return [::Integer] + # Optional. The number of CPU cores to be made available to the database. + # @!attribute [rw] data_storage_size_tb + # @return [::Integer] + # Optional. The size of the data stored in the database, in terabytes. + # @!attribute [rw] data_storage_size_gb + # @return [::Integer] + # Optional. The size of the data stored in the database, in gigabytes. + # @!attribute [rw] db_workload + # @return [::Google::Cloud::OracleDatabase::V1::DBWorkload] + # Required. The workload type of the Autonomous Database. + # @!attribute [rw] db_edition + # @return [::Google::Cloud::OracleDatabase::V1::AutonomousDatabaseProperties::DatabaseEdition] + # Optional. The edition of the Autonomous Databases. + # @!attribute [rw] character_set + # @return [::String] + # Optional. The character set for the Autonomous Database. The default is + # AL32UTF8. + # @!attribute [rw] n_character_set + # @return [::String] + # Optional. The national character set for the Autonomous Database. The + # default is AL16UTF16. + # @!attribute [rw] private_endpoint_ip + # @return [::String] + # Optional. The private endpoint IP address for the Autonomous Database. + # @!attribute [rw] private_endpoint_label + # @return [::String] + # Optional. The private endpoint label for the Autonomous Database. + # @!attribute [rw] db_version + # @return [::String] + # Optional. The Oracle Database version for the Autonomous Database. + # @!attribute [rw] is_auto_scaling_enabled + # @return [::Boolean] + # Optional. This field indicates if auto scaling is enabled for the + # Autonomous Database CPU core count. + # @!attribute [rw] is_storage_auto_scaling_enabled + # @return [::Boolean] + # Optional. This field indicates if auto scaling is enabled for the + # Autonomous Database storage. + # @!attribute [rw] license_type + # @return [::Google::Cloud::OracleDatabase::V1::AutonomousDatabaseProperties::LicenseType] + # Required. The license type used for the Autonomous Database. + # @!attribute [rw] customer_contacts + # @return [::Array<::Google::Cloud::OracleDatabase::V1::CustomerContact>] + # Optional. The list of customer contacts. + # @!attribute [rw] secret_id + # @return [::String] + # Optional. The ID of the Oracle Cloud Infrastructure vault secret. + # @!attribute [rw] vault_id + # @return [::String] + # Optional. The ID of the Oracle Cloud Infrastructure vault. + # @!attribute [rw] maintenance_schedule_type + # @return [::Google::Cloud::OracleDatabase::V1::AutonomousDatabaseProperties::MaintenanceScheduleType] + # Optional. The maintenance schedule of the Autonomous Database. + # @!attribute [rw] mtls_connection_required + # @return [::Boolean] + # Optional. This field specifies if the Autonomous Database requires mTLS + # connections. + # @!attribute [rw] backup_retention_period_days + # @return [::Integer] + # Optional. The retention period for the Autonomous Database. This field is + # specified in days, can range from 1 day to 60 days, and has a default value + # of 60 days. + # @!attribute [r] actual_used_data_storage_size_tb + # @return [::Float] + # Output only. The amount of storage currently being used for user and system + # data, in terabytes. + # @!attribute [r] allocated_storage_size_tb + # @return [::Float] + # Output only. The amount of storage currently allocated for the database + # tables and billed for, rounded up in terabytes. + # @!attribute [r] apex_details + # @return [::Google::Cloud::OracleDatabase::V1::AutonomousDatabaseApex] + # Output only. The details for the Oracle APEX Application Development. + # @!attribute [r] are_primary_allowlisted_ips_used + # @return [::Boolean] + # Output only. This field indicates the status of Data Guard and Access + # control for the Autonomous Database. The field's value is null if Data + # Guard is disabled or Access Control is disabled. The field's value is TRUE + # if both Data Guard and Access Control are enabled, and the Autonomous + # Database is using primary IP access control list (ACL) for standby. The + # field's value is FALSE if both Data Guard and Access Control are enabled, + # and the Autonomous Database is using a different IP access control list + # (ACL) for standby compared to primary. + # @!attribute [r] lifecycle_details + # @return [::String] + # Output only. The details of the current lifestyle state of the Autonomous + # Database. + # @!attribute [r] state + # @return [::Google::Cloud::OracleDatabase::V1::State] + # Output only. The current lifecycle state of the Autonomous Database. + # @!attribute [r] autonomous_container_database_id + # @return [::String] + # Output only. The Autonomous Container Database OCID. + # @!attribute [r] available_upgrade_versions + # @return [::Array<::String>] + # Output only. The list of available Oracle Database upgrade versions for an + # Autonomous Database. + # @!attribute [r] connection_strings + # @return [::Google::Cloud::OracleDatabase::V1::AutonomousDatabaseConnectionStrings] + # Output only. The connection strings used to connect to an Autonomous + # Database. + # @!attribute [r] connection_urls + # @return [::Google::Cloud::OracleDatabase::V1::AutonomousDatabaseConnectionUrls] + # Output only. The Oracle Connection URLs for an Autonomous Database. + # @!attribute [r] failed_data_recovery_duration + # @return [::Google::Protobuf::Duration] + # Output only. This field indicates the number of seconds of data loss during + # a Data Guard failover. + # @!attribute [r] memory_table_gbs + # @return [::Integer] + # Output only. The memory assigned to in-memory tables in an Autonomous + # Database. + # @!attribute [r] is_local_data_guard_enabled + # @return [::Boolean] + # Output only. This field indicates whether the Autonomous Database has local + # (in-region) Data Guard enabled. + # @!attribute [r] local_adg_auto_failover_max_data_loss_limit + # @return [::Integer] + # Output only. This field indicates the maximum data loss limit for an + # Autonomous Database, in seconds. + # @!attribute [r] local_standby_db + # @return [::Google::Cloud::OracleDatabase::V1::AutonomousDatabaseStandbySummary] + # Output only. The details of the Autonomous Data Guard standby database. + # @!attribute [r] memory_per_oracle_compute_unit_gbs + # @return [::Integer] + # Output only. The amount of memory enabled per ECPU, in gigabytes. + # @!attribute [r] local_disaster_recovery_type + # @return [::Google::Cloud::OracleDatabase::V1::AutonomousDatabaseProperties::LocalDisasterRecoveryType] + # Output only. This field indicates the local disaster recovery (DR) type of + # an Autonomous Database. + # @!attribute [r] data_safe_state + # @return [::Google::Cloud::OracleDatabase::V1::AutonomousDatabaseProperties::DataSafeState] + # Output only. The current state of the Data Safe registration for the + # Autonomous Database. + # @!attribute [r] database_management_state + # @return [::Google::Cloud::OracleDatabase::V1::AutonomousDatabaseProperties::DatabaseManagementState] + # Output only. The current state of database management for the Autonomous + # Database. + # @!attribute [r] open_mode + # @return [::Google::Cloud::OracleDatabase::V1::AutonomousDatabaseProperties::OpenMode] + # Output only. This field indicates the current mode of the Autonomous + # Database. + # @!attribute [r] operations_insights_state + # @return [::Google::Cloud::OracleDatabase::V1::OperationsInsightsState] + # Output only. This field indicates the state of Operations Insights for the + # Autonomous Database. + # @!attribute [r] peer_db_ids + # @return [::Array<::String>] + # Output only. The list of OCIDs of standby databases located in Autonomous + # Data Guard remote regions that are associated with the source database. + # @!attribute [r] permission_level + # @return [::Google::Cloud::OracleDatabase::V1::AutonomousDatabaseProperties::PermissionLevel] + # Output only. The permission level of the Autonomous Database. + # @!attribute [r] private_endpoint + # @return [::String] + # Output only. The private endpoint for the Autonomous Database. + # @!attribute [r] refreshable_mode + # @return [::Google::Cloud::OracleDatabase::V1::AutonomousDatabaseProperties::RefreshableMode] + # Output only. The refresh mode of the cloned Autonomous Database. + # @!attribute [r] refreshable_state + # @return [::Google::Cloud::OracleDatabase::V1::AutonomousDatabaseProperties::RefreshableState] + # Output only. The refresh State of the clone. + # @!attribute [r] role + # @return [::Google::Cloud::OracleDatabase::V1::AutonomousDatabaseProperties::Role] + # Output only. The Data Guard role of the Autonomous Database. + # @!attribute [r] scheduled_operation_details + # @return [::Array<::Google::Cloud::OracleDatabase::V1::ScheduledOperationDetails>] + # Output only. The list and details of the scheduled operations of the + # Autonomous Database. + # @!attribute [r] sql_web_developer_url + # @return [::String] + # Output only. The SQL Web Developer URL for the Autonomous Database. + # @!attribute [r] supported_clone_regions + # @return [::Array<::String>] + # Output only. The list of available regions that can be used to create a + # clone for the Autonomous Database. + # @!attribute [r] used_data_storage_size_tbs + # @return [::Integer] + # Output only. The storage space used by Autonomous Database, in gigabytes. + # @!attribute [r] oci_url + # @return [::String] + # Output only. The Oracle Cloud Infrastructure link for the Autonomous + # Database. + # @!attribute [r] total_auto_backup_storage_size_gbs + # @return [::Float] + # Output only. The storage space used by automatic backups of Autonomous + # Database, in gigabytes. + # @!attribute [r] next_long_term_backup_time + # @return [::Google::Protobuf::Timestamp] + # Output only. The long term backup schedule of the Autonomous Database. + # @!attribute [r] maintenance_begin_time + # @return [::Google::Protobuf::Timestamp] + # Output only. The date and time when maintenance will begin. + # @!attribute [r] maintenance_end_time + # @return [::Google::Protobuf::Timestamp] + # Output only. The date and time when maintenance will end. + class AutonomousDatabaseProperties + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + + # The editions available for the Autonomous Database. + module DatabaseEdition + # Default unspecified value. + DATABASE_EDITION_UNSPECIFIED = 0 + + # Standard Database Edition + STANDARD_EDITION = 1 + + # Enterprise Database Edition + ENTERPRISE_EDITION = 2 + end + + # The license types available for the Autonomous Database. + module LicenseType + # Unspecified + LICENSE_TYPE_UNSPECIFIED = 0 + + # License included part of offer + LICENSE_INCLUDED = 1 + + # Bring your own license + BRING_YOUR_OWN_LICENSE = 2 + end + + # The available maintenance schedules for the Autonomous Database. + module MaintenanceScheduleType + # Default unspecified value. + MAINTENANCE_SCHEDULE_TYPE_UNSPECIFIED = 0 + + # An EARLY maintenance schedule patches the database before + # the regular scheduled maintenance. + EARLY = 1 + + # A REGULAR maintenance schedule follows the normal maintenance cycle. + REGULAR = 2 + end + + # The types of local disaster recovery available for an Autonomous Database. + module LocalDisasterRecoveryType + # Default unspecified value. + LOCAL_DISASTER_RECOVERY_TYPE_UNSPECIFIED = 0 + + # Autonomous Data Guard recovery. + ADG = 1 + + # Backup based recovery. + BACKUP_BASED = 2 + end + + # Varies states of the Data Safe registration for the Autonomous Database. + module DataSafeState + # Default unspecified value. + DATA_SAFE_STATE_UNSPECIFIED = 0 + + # Registering data safe state. + REGISTERING = 1 + + # Registered data safe state. + REGISTERED = 2 + + # Deregistering data safe state. + DEREGISTERING = 3 + + # Not registered data safe state. + NOT_REGISTERED = 4 + + # Failed data safe state. + FAILED = 5 + end + + # The different states of database management for an Autonomous Database. + module DatabaseManagementState + # Default unspecified value. + DATABASE_MANAGEMENT_STATE_UNSPECIFIED = 0 + + # Enabling Database Management state + ENABLING = 1 + + # Enabled Database Management state + ENABLED = 2 + + # Disabling Database Management state + DISABLING = 3 + + # Not Enabled Database Management state + NOT_ENABLED = 4 + + # Failed enabling Database Management state + FAILED_ENABLING = 5 + + # Failed disabling Database Management state + FAILED_DISABLING = 6 + end + + # This field indicates the modes of an Autonomous Database. + module OpenMode + # Default unspecified value. + OPEN_MODE_UNSPECIFIED = 0 + + # Read Only Mode + READ_ONLY = 1 + + # Read Write Mode + READ_WRITE = 2 + end + + # The types of permission levels for an Autonomous Database. + module PermissionLevel + # Default unspecified value. + PERMISSION_LEVEL_UNSPECIFIED = 0 + + # Restricted mode allows access only by admin users. + RESTRICTED = 1 + + # Normal access. + UNRESTRICTED = 2 + end + + # The refresh mode of the cloned Autonomous Database. + module RefreshableMode + # The default unspecified value. + REFRESHABLE_MODE_UNSPECIFIED = 0 + + # AUTOMATIC indicates that the cloned database is automatically + # refreshed with data from the source Autonomous Database. + AUTOMATIC = 1 + + # MANUAL indicates that the cloned database is manually refreshed with + # data from the source Autonomous Database. + MANUAL = 2 + end + + # The refresh state of the cloned Autonomous Database. + module RefreshableState + # Default unspecified value. + REFRESHABLE_STATE_UNSPECIFIED = 0 + + # Refreshing + REFRESHING = 1 + + # Not refreshed + NOT_REFRESHING = 2 + end + + # The Data Guard role of the Autonomous Database. + module Role + # Default unspecified value. + ROLE_UNSPECIFIED = 0 + + # Primary role + PRIMARY = 1 + + # Standby role + STANDBY = 2 + + # Disabled standby role + DISABLED_STANDBY = 3 + + # Backup copy role + BACKUP_COPY = 4 + + # Snapshot standby role + SNAPSHOT_STANDBY = 5 + end + end + + # Oracle APEX Application Development. + # https://docs.oracle.com/en-us/iaas/api/#/en/database/20160918/datatypes/AutonomousDatabaseApex + # @!attribute [r] apex_version + # @return [::String] + # Output only. The Oracle APEX Application Development version. + # @!attribute [r] ords_version + # @return [::String] + # Output only. The Oracle REST Data Services (ORDS) version. + class AutonomousDatabaseApex + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + end + + # The connection string used to connect to the Autonomous Database. + # https://docs.oracle.com/en-us/iaas/api/#/en/database/20160918/datatypes/AutonomousDatabaseConnectionStrings + # @!attribute [r] all_connection_strings + # @return [::Google::Cloud::OracleDatabase::V1::AllConnectionStrings] + # Output only. Returns all connection strings that can be used to connect to + # the Autonomous Database. + # @!attribute [r] dedicated + # @return [::String] + # Output only. The database service provides the least level of resources to + # each SQL statement, but supports the most number of concurrent SQL + # statements. + # @!attribute [r] high + # @return [::String] + # Output only. The database service provides the highest level of resources + # to each SQL statement. + # @!attribute [r] low + # @return [::String] + # Output only. The database service provides the least level of resources to + # each SQL statement. + # @!attribute [r] medium + # @return [::String] + # Output only. The database service provides a lower level of resources to + # each SQL statement. + # @!attribute [r] profiles + # @return [::Array<::Google::Cloud::OracleDatabase::V1::DatabaseConnectionStringProfile>] + # Output only. A list of connection string profiles to allow clients to + # group, filter, and select values based on the structured metadata. + class AutonomousDatabaseConnectionStrings + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + end + + # The connection string profile to allow clients to group. + # https://docs.oracle.com/en-us/iaas/api/#/en/database/20160918/datatypes/DatabaseConnectionStringProfile + # @!attribute [r] consumer_group + # @return [::Google::Cloud::OracleDatabase::V1::DatabaseConnectionStringProfile::ConsumerGroup] + # Output only. The current consumer group being used by the connection. + # @!attribute [r] display_name + # @return [::String] + # Output only. The display name for the database connection. + # @!attribute [r] host_format + # @return [::Google::Cloud::OracleDatabase::V1::DatabaseConnectionStringProfile::HostFormat] + # Output only. The host name format being currently used in connection + # string. + # @!attribute [r] is_regional + # @return [::Boolean] + # Output only. This field indicates if the connection string is regional and + # is only applicable for cross-region Data Guard. + # @!attribute [r] protocol + # @return [::Google::Cloud::OracleDatabase::V1::DatabaseConnectionStringProfile::Protocol] + # Output only. The protocol being used by the connection. + # @!attribute [r] session_mode + # @return [::Google::Cloud::OracleDatabase::V1::DatabaseConnectionStringProfile::SessionMode] + # Output only. The current session mode of the connection. + # @!attribute [r] syntax_format + # @return [::Google::Cloud::OracleDatabase::V1::DatabaseConnectionStringProfile::SyntaxFormat] + # Output only. The syntax of the connection string. + # @!attribute [r] tls_authentication + # @return [::Google::Cloud::OracleDatabase::V1::DatabaseConnectionStringProfile::TLSAuthentication] + # Output only. This field indicates the TLS authentication type of the + # connection. + # @!attribute [r] value + # @return [::String] + # Output only. The value of the connection string. + class DatabaseConnectionStringProfile + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + + # The various consumer groups available in the connection string profile. + module ConsumerGroup + # Default unspecified value. + CONSUMER_GROUP_UNSPECIFIED = 0 + + # High consumer group. + HIGH = 1 + + # Medium consumer group. + MEDIUM = 2 + + # Low consumer group. + LOW = 3 + + # TP consumer group. + TP = 4 + + # TPURGENT consumer group. + TPURGENT = 5 + end + + # The host name format being used in the connection string. + module HostFormat + # Default unspecified value. + HOST_FORMAT_UNSPECIFIED = 0 + + # FQDN + FQDN = 1 + + # IP + IP = 2 + end + + # The protocol being used by the connection. + module Protocol + # Default unspecified value. + PROTOCOL_UNSPECIFIED = 0 + + # Tcp + TCP = 1 + + # Tcps + TCPS = 2 + end + + # The session mode of the connection. + module SessionMode + # Default unspecified value. + SESSION_MODE_UNSPECIFIED = 0 + + # Direct + DIRECT = 1 + + # Indirect + INDIRECT = 2 + end + + # Specifies syntax of the connection string. + module SyntaxFormat + # Default unspecified value. + SYNTAX_FORMAT_UNSPECIFIED = 0 + + # Long + LONG = 1 + + # Ezconnect + EZCONNECT = 2 + + # Ezconnectplus + EZCONNECTPLUS = 3 + end + + # This field indicates the TLS authentication type of the connection. + module TLSAuthentication + # Default unspecified value. + TLS_AUTHENTICATION_UNSPECIFIED = 0 + + # Server + SERVER = 1 + + # Mutual + MUTUAL = 2 + end + end + + # A list of all connection strings that can be used to connect to the + # Autonomous Database. + # @!attribute [r] high + # @return [::String] + # Output only. The database service provides the highest level of resources + # to each SQL statement. + # @!attribute [r] low + # @return [::String] + # Output only. The database service provides the least level of resources to + # each SQL statement. + # @!attribute [r] medium + # @return [::String] + # Output only. The database service provides a lower level of resources to + # each SQL statement. + class AllConnectionStrings + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + end + + # The URLs for accessing Oracle Application Express (APEX) and SQL Developer + # Web with a browser from a Compute instance. + # https://docs.oracle.com/en-us/iaas/api/#/en/database/20160918/datatypes/AutonomousDatabaseConnectionUrls + # @!attribute [r] apex_uri + # @return [::String] + # Output only. Oracle Application Express (APEX) URL. + # @!attribute [r] database_transforms_uri + # @return [::String] + # Output only. The URL of the Database Transforms for the Autonomous + # Database. + # @!attribute [r] graph_studio_uri + # @return [::String] + # Output only. The URL of the Graph Studio for the Autonomous Database. + # @!attribute [r] machine_learning_notebook_uri + # @return [::String] + # Output only. The URL of the Oracle Machine Learning (OML) Notebook for the + # Autonomous Database. + # @!attribute [r] machine_learning_user_management_uri + # @return [::String] + # Output only. The URL of Machine Learning user management the Autonomous + # Database. + # @!attribute [r] mongo_db_uri + # @return [::String] + # Output only. The URL of the MongoDB API for the Autonomous Database. + # @!attribute [r] ords_uri + # @return [::String] + # Output only. The Oracle REST Data Services (ORDS) URL of the Web Access for + # the Autonomous Database. + # @!attribute [r] sql_dev_web_uri + # @return [::String] + # Output only. The URL of the Oracle SQL Developer Web for the Autonomous + # Database. + class AutonomousDatabaseConnectionUrls + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + end + + # Autonomous Data Guard standby database details. + # https://docs.oracle.com/en-us/iaas/api/#/en/database/20160918/datatypes/AutonomousDatabaseStandbySummary + # @!attribute [r] lag_time_duration + # @return [::Google::Protobuf::Duration] + # Output only. The amount of time, in seconds, that the data of the standby + # database lags in comparison to the data of the primary database. + # @!attribute [r] lifecycle_details + # @return [::String] + # Output only. The additional details about the current lifecycle state of + # the Autonomous Database. + # @!attribute [r] state + # @return [::Google::Cloud::OracleDatabase::V1::State] + # Output only. The current lifecycle state of the Autonomous Database. + # @!attribute [r] data_guard_role_changed_time + # @return [::Google::Protobuf::Timestamp] + # Output only. The date and time the Autonomous Data Guard role was switched + # for the standby Autonomous Database. + # @!attribute [r] disaster_recovery_role_changed_time + # @return [::Google::Protobuf::Timestamp] + # Output only. The date and time the Disaster Recovery role was switched for + # the standby Autonomous Database. + class AutonomousDatabaseStandbySummary + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + end + + # Details of scheduled operation. + # https://docs.oracle.com/en-us/iaas/api/#/en/database/20160918/datatypes/ScheduledOperationDetails + # @!attribute [r] day_of_week + # @return [::Google::Type::DayOfWeek] + # Output only. Day of week. + # @!attribute [r] start_time + # @return [::Google::Type::TimeOfDay] + # Output only. Auto start time. + # @!attribute [r] stop_time + # @return [::Google::Type::TimeOfDay] + # Output only. Auto stop time. + class ScheduledOperationDetails + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + end + + # The type of wallet generation. + module GenerateType + # Default unspecified value. + GENERATE_TYPE_UNSPECIFIED = 0 + + # Used to generate wallet for all databases in the region. + ALL = 1 + + # Used to generate wallet for a single database. + SINGLE = 2 + end + + # The various lifecycle states of the Autonomous Database. + module State + # Default unspecified value. + STATE_UNSPECIFIED = 0 + + # Indicates that the Autonomous Database is in provisioning state. + PROVISIONING = 1 + + # Indicates that the Autonomous Database is in available state. + AVAILABLE = 2 + + # Indicates that the Autonomous Database is in stopping state. + STOPPING = 3 + + # Indicates that the Autonomous Database is in stopped state. + STOPPED = 4 + + # Indicates that the Autonomous Database is in starting state. + STARTING = 5 + + # Indicates that the Autonomous Database is in terminating state. + TERMINATING = 6 + + # Indicates that the Autonomous Database is in terminated state. + TERMINATED = 7 + + # Indicates that the Autonomous Database is in unavailable state. + UNAVAILABLE = 8 + + # Indicates that the Autonomous Database restore is in progress. + RESTORE_IN_PROGRESS = 9 + + # Indicates that the Autonomous Database failed to restore. + RESTORE_FAILED = 10 + + # Indicates that the Autonomous Database backup is in progress. + BACKUP_IN_PROGRESS = 11 + + # Indicates that the Autonomous Database scale is in progress. + SCALE_IN_PROGRESS = 12 + + # Indicates that the Autonomous Database is available but needs attention + # state. + AVAILABLE_NEEDS_ATTENTION = 13 + + # Indicates that the Autonomous Database is in updating state. + UPDATING = 14 + + # Indicates that the Autonomous Database's maintenance is in progress state. + MAINTENANCE_IN_PROGRESS = 15 + + # Indicates that the Autonomous Database is in restarting state. + RESTARTING = 16 + + # Indicates that the Autonomous Database is in recreating state. + RECREATING = 17 + + # Indicates that the Autonomous Database's role change is in progress state. + ROLE_CHANGE_IN_PROGRESS = 18 + + # Indicates that the Autonomous Database is in upgrading state. + UPGRADING = 19 + + # Indicates that the Autonomous Database is in inaccessible state. + INACCESSIBLE = 20 + + # Indicates that the Autonomous Database is in standby state. + STANDBY = 21 + end + + # The state of the Operations Insights for this Autonomous Database. + module OperationsInsightsState + # Default unspecified value. + OPERATIONS_INSIGHTS_STATE_UNSPECIFIED = 0 + + # Enabling status for operation insights. + ENABLING = 1 + + # Enabled status for operation insights. + ENABLED = 2 + + # Disabling status for operation insights. + DISABLING = 3 + + # Not Enabled status for operation insights. + NOT_ENABLED = 4 + + # Failed enabling status for operation insights. + FAILED_ENABLING = 5 + + # Failed disabling status for operation insights. + FAILED_DISABLING = 6 + end + + # The various states available for the Autonomous Database workload type. + module DBWorkload + # Default unspecified value. + DB_WORKLOAD_UNSPECIFIED = 0 + + # Autonomous Transaction Processing database. + OLTP = 1 + + # Autonomous Data Warehouse database. + DW = 2 + + # Autonomous JSON Database. + AJD = 3 + + # Autonomous Database with the Oracle APEX Application Development workload + # type. + APEX = 4 + end + end + end + end +end diff --git a/google-cloud-oracle_database-v1/proto_docs/google/cloud/oracledatabase/v1/autonomous_database_character_set.rb b/google-cloud-oracle_database-v1/proto_docs/google/cloud/oracledatabase/v1/autonomous_database_character_set.rb new file mode 100644 index 000000000000..e10a95811848 --- /dev/null +++ b/google-cloud-oracle_database-v1/proto_docs/google/cloud/oracledatabase/v1/autonomous_database_character_set.rb @@ -0,0 +1,57 @@ +# frozen_string_literal: true + +# Copyright 2024 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# https://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Auto-generated by gapic-generator-ruby. DO NOT EDIT! + + +module Google + module Cloud + module OracleDatabase + module V1 + # Details of the Autonomous Database character set resource. + # https://docs.oracle.com/en-us/iaas/api/#/en/database/20160918/AutonomousDatabaseCharacterSets/ + # @!attribute [rw] name + # @return [::String] + # Identifier. The name of the Autonomous Database Character Set resource in + # the following format: + # projects/\\{project}/locations/\\{region}/autonomousDatabaseCharacterSets/\\{autonomous_database_character_set} + # @!attribute [r] character_set_type + # @return [::Google::Cloud::OracleDatabase::V1::AutonomousDatabaseCharacterSet::CharacterSetType] + # Output only. The character set type for the Autonomous Database. + # @!attribute [r] character_set + # @return [::String] + # Output only. The character set name for the Autonomous Database which is + # the ID in the resource name. + class AutonomousDatabaseCharacterSet + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + + # The type of character set an Autonomous Database can have. + module CharacterSetType + # Character set type is not specified. + CHARACTER_SET_TYPE_UNSPECIFIED = 0 + + # Character set type is set to database. + DATABASE = 1 + + # Character set type is set to national. + NATIONAL = 2 + end + end + end + end + end +end diff --git a/google-cloud-oracle_database-v1/proto_docs/google/cloud/oracledatabase/v1/autonomous_db_backup.rb b/google-cloud-oracle_database-v1/proto_docs/google/cloud/oracledatabase/v1/autonomous_db_backup.rb new file mode 100644 index 000000000000..4fc119ea9fcd --- /dev/null +++ b/google-cloud-oracle_database-v1/proto_docs/google/cloud/oracledatabase/v1/autonomous_db_backup.rb @@ -0,0 +1,175 @@ +# frozen_string_literal: true + +# Copyright 2024 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# https://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Auto-generated by gapic-generator-ruby. DO NOT EDIT! + + +module Google + module Cloud + module OracleDatabase + module V1 + # Details of the Autonomous Database Backup resource. + # https://docs.oracle.com/en-us/iaas/api/#/en/database/20160918/AutonomousDatabaseBackup/ + # @!attribute [rw] name + # @return [::String] + # Identifier. The name of the Autonomous Database Backup resource with the + # format: + # projects/\\{project}/locations/\\{region}/autonomousDatabaseBackups/\\{autonomous_database_backup} + # @!attribute [rw] autonomous_database + # @return [::String] + # Required. The name of the Autonomous Database resource for which the backup + # is being created. Format: + # projects/\\{project}/locations/\\{region}/autonomousDatabases/\\{autonomous_database} + # @!attribute [rw] display_name + # @return [::String] + # Optional. User friendly name for the Backup. The name does not have to be + # unique. + # @!attribute [rw] properties + # @return [::Google::Cloud::OracleDatabase::V1::AutonomousDatabaseBackupProperties] + # Optional. Various properties of the backup. + # @!attribute [rw] labels + # @return [::Google::Protobuf::Map{::String => ::String}] + # Optional. labels or tags associated with the resource. + class AutonomousDatabaseBackup + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + + # @!attribute [rw] key + # @return [::String] + # @!attribute [rw] value + # @return [::String] + class LabelsEntry + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + end + end + + # Properties of the Autonomous Database Backup resource. + # @!attribute [r] ocid + # @return [::String] + # Output only. OCID of the Autonomous Database backup. + # https://docs.oracle.com/en-us/iaas/Content/General/Concepts/identifiers.htm#Oracle + # @!attribute [rw] retention_period_days + # @return [::Integer] + # Optional. Retention period in days for the backup. + # @!attribute [r] compartment_id + # @return [::String] + # Output only. The OCID of the compartment. + # @!attribute [r] database_size_tb + # @return [::Float] + # Output only. The quantity of data in the database, in terabytes. + # @!attribute [r] db_version + # @return [::String] + # Output only. A valid Oracle Database version for Autonomous Database. + # @!attribute [r] is_long_term_backup + # @return [::Boolean] + # Output only. Indicates if the backup is long term backup. + # @!attribute [r] is_automatic_backup + # @return [::Boolean] + # Output only. Indicates if the backup is automatic or user initiated. + # @!attribute [r] is_restorable + # @return [::Boolean] + # Output only. Indicates if the backup can be used to restore the Autonomous + # Database. + # @!attribute [rw] key_store_id + # @return [::String] + # Optional. The OCID of the key store of Oracle Vault. + # @!attribute [rw] key_store_wallet + # @return [::String] + # Optional. The wallet name for Oracle Key Vault. + # @!attribute [rw] kms_key_id + # @return [::String] + # Optional. The OCID of the key container that is used as the master + # encryption key in database transparent data encryption (TDE) operations. + # @!attribute [rw] kms_key_version_id + # @return [::String] + # Optional. The OCID of the key container version that is used in database + # transparent data encryption (TDE) operations KMS Key can have multiple key + # versions. If none is specified, the current key version (latest) of the Key + # Id is used for the operation. Autonomous Database Serverless does not use + # key versions, hence is not applicable for Autonomous Database Serverless + # instances. + # @!attribute [r] lifecycle_details + # @return [::String] + # Output only. Additional information about the current lifecycle state. + # @!attribute [r] lifecycle_state + # @return [::Google::Cloud::OracleDatabase::V1::AutonomousDatabaseBackupProperties::State] + # Output only. The lifecycle state of the backup. + # @!attribute [r] size_tb + # @return [::Float] + # Output only. The backup size in terabytes. + # @!attribute [r] available_till_time + # @return [::Google::Protobuf::Timestamp] + # Output only. Timestamp until when the backup will be available. + # @!attribute [r] end_time + # @return [::Google::Protobuf::Timestamp] + # Output only. The date and time the backup completed. + # @!attribute [r] start_time + # @return [::Google::Protobuf::Timestamp] + # Output only. The date and time the backup started. + # @!attribute [r] type + # @return [::Google::Cloud::OracleDatabase::V1::AutonomousDatabaseBackupProperties::Type] + # Output only. The type of the backup. + # @!attribute [rw] vault_id + # @return [::String] + # Optional. The OCID of the vault. + class AutonomousDatabaseBackupProperties + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + + # // The various lifecycle states of the Autonomous Database Backup. + module State + # Default unspecified value. + STATE_UNSPECIFIED = 0 + + # Indicates that the resource is in creating state. + CREATING = 1 + + # Indicates that the resource is in active state. + ACTIVE = 2 + + # Indicates that the resource is in deleting state. + DELETING = 3 + + # Indicates that the resource is in deleted state. + DELETED = 4 + + # Indicates that the resource is in failed state. + FAILED = 6 + + # Indicates that the resource is in updating state. + UPDATING = 7 + end + + # The type of the backup. + module Type + # Default unspecified value. + TYPE_UNSPECIFIED = 0 + + # Incremental backups. + INCREMENTAL = 1 + + # Full backups. + FULL = 2 + + # Long term backups. + LONG_TERM = 3 + end + end + end + end + end +end diff --git a/google-cloud-oracle_database-v1/proto_docs/google/cloud/oracledatabase/v1/autonomous_db_version.rb b/google-cloud-oracle_database-v1/proto_docs/google/cloud/oracledatabase/v1/autonomous_db_version.rb new file mode 100644 index 000000000000..4f363b8949d8 --- /dev/null +++ b/google-cloud-oracle_database-v1/proto_docs/google/cloud/oracledatabase/v1/autonomous_db_version.rb @@ -0,0 +1,48 @@ +# frozen_string_literal: true + +# Copyright 2024 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# https://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Auto-generated by gapic-generator-ruby. DO NOT EDIT! + + +module Google + module Cloud + module OracleDatabase + module V1 + # Details of the Autonomous Database version. + # https://docs.oracle.com/en-us/iaas/api/#/en/database/20160918/AutonomousDbVersionSummary/ + # @!attribute [rw] name + # @return [::String] + # Identifier. The name of the Autonomous Database Version resource with the + # format: + # projects/\\{project}/locations/\\{region}/autonomousDbVersions/\\{autonomous_db_version} + # @!attribute [r] version + # @return [::String] + # Output only. An Oracle Database version for Autonomous Database. + # @!attribute [r] db_workload + # @return [::Google::Cloud::OracleDatabase::V1::DBWorkload] + # Output only. The Autonomous Database workload type. + # @!attribute [r] workload_uri + # @return [::String] + # Output only. A URL that points to a detailed description of the Autonomous + # Database version. + class AutonomousDbVersion + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + end + end + end + end +end diff --git a/google-cloud-oracle_database-v1/proto_docs/google/cloud/oracledatabase/v1/common.rb b/google-cloud-oracle_database-v1/proto_docs/google/cloud/oracledatabase/v1/common.rb new file mode 100644 index 000000000000..2e285ddcd8b4 --- /dev/null +++ b/google-cloud-oracle_database-v1/proto_docs/google/cloud/oracledatabase/v1/common.rb @@ -0,0 +1,37 @@ +# frozen_string_literal: true + +# Copyright 2024 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# https://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Auto-generated by gapic-generator-ruby. DO NOT EDIT! + + +module Google + module Cloud + module OracleDatabase + module V1 + # The CustomerContact reference as defined by Oracle. + # https://docs.oracle.com/en-us/iaas/api/#/en/database/20160918/datatypes/CustomerContact + # @!attribute [rw] email + # @return [::String] + # Required. The email address used by Oracle to send notifications regarding + # databases and infrastructure. + class CustomerContact + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + end + end + end + end +end diff --git a/google-cloud-oracle_database-v1/proto_docs/google/cloud/oracledatabase/v1/db_node.rb b/google-cloud-oracle_database-v1/proto_docs/google/cloud/oracledatabase/v1/db_node.rb new file mode 100644 index 000000000000..9a1ee9d2a1a6 --- /dev/null +++ b/google-cloud-oracle_database-v1/proto_docs/google/cloud/oracledatabase/v1/db_node.rb @@ -0,0 +1,103 @@ +# frozen_string_literal: true + +# Copyright 2024 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# https://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Auto-generated by gapic-generator-ruby. DO NOT EDIT! + + +module Google + module Cloud + module OracleDatabase + module V1 + # Details of the database node resource. + # https://docs.oracle.com/en-us/iaas/api/#/en/database/20160918/DbNode/ + # @!attribute [rw] name + # @return [::String] + # Identifier. The name of the database node resource in the following format: + # projects/\\{project}/locations/\\{location}/cloudVmClusters/\\{cloud_vm_cluster}/dbNodes/\\{db_node} + # @!attribute [rw] properties + # @return [::Google::Cloud::OracleDatabase::V1::DbNodeProperties] + # Optional. Various properties of the database node. + class DbNode + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + end + + # Various properties and settings associated with Db node. + # @!attribute [r] ocid + # @return [::String] + # Output only. OCID of database node. + # @!attribute [rw] ocpu_count + # @return [::Integer] + # Optional. OCPU count per database node. + # @!attribute [rw] memory_size_gb + # @return [::Integer] + # Memory allocated in GBs. + # @!attribute [rw] db_node_storage_size_gb + # @return [::Integer] + # Optional. Local storage per database node. + # @!attribute [rw] db_server_ocid + # @return [::String] + # Optional. Database server OCID. + # @!attribute [rw] hostname + # @return [::String] + # Optional. DNS + # @!attribute [r] state + # @return [::Google::Cloud::OracleDatabase::V1::DbNodeProperties::State] + # Output only. State of the database node. + # @!attribute [rw] total_cpu_core_count + # @return [::Integer] + # Total CPU core count of the database node. + class DbNodeProperties + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + + # The various lifecycle states of the database node. + module State + # Default unspecified value. + STATE_UNSPECIFIED = 0 + + # Indicates that the resource is in provisioning state. + PROVISIONING = 1 + + # Indicates that the resource is in available state. + AVAILABLE = 2 + + # Indicates that the resource is in updating state. + UPDATING = 3 + + # Indicates that the resource is in stopping state. + STOPPING = 4 + + # Indicates that the resource is in stopped state. + STOPPED = 5 + + # Indicates that the resource is in starting state. + STARTING = 6 + + # Indicates that the resource is in terminating state. + TERMINATING = 7 + + # Indicates that the resource is in terminated state. + TERMINATED = 8 + + # Indicates that the resource is in failed state. + FAILED = 9 + end + end + end + end + end +end diff --git a/google-cloud-oracle_database-v1/proto_docs/google/cloud/oracledatabase/v1/db_server.rb b/google-cloud-oracle_database-v1/proto_docs/google/cloud/oracledatabase/v1/db_server.rb new file mode 100644 index 000000000000..9a6fff7396ca --- /dev/null +++ b/google-cloud-oracle_database-v1/proto_docs/google/cloud/oracledatabase/v1/db_server.rb @@ -0,0 +1,100 @@ +# frozen_string_literal: true + +# Copyright 2024 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# https://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Auto-generated by gapic-generator-ruby. DO NOT EDIT! + + +module Google + module Cloud + module OracleDatabase + module V1 + # Details of the database server resource. + # https://docs.oracle.com/en-us/iaas/api/#/en/database/20160918/DbServer/ + # @!attribute [rw] name + # @return [::String] + # Identifier. The name of the database server resource with the format: + # projects/\\{project}/locations/\\{location}/cloudExadataInfrastructures/\\{cloud_exadata_infrastructure}/dbServers/\\{db_server} + # @!attribute [rw] display_name + # @return [::String] + # Optional. User friendly name for this resource. + # @!attribute [rw] properties + # @return [::Google::Cloud::OracleDatabase::V1::DbServerProperties] + # Optional. Various properties of the database server. + class DbServer + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + end + + # Various properties and settings associated with Exadata database server. + # @!attribute [r] ocid + # @return [::String] + # Output only. OCID of database server. + # @!attribute [rw] ocpu_count + # @return [::Integer] + # Optional. OCPU count per database. + # @!attribute [rw] max_ocpu_count + # @return [::Integer] + # Optional. Maximum OCPU count per database. + # @!attribute [rw] memory_size_gb + # @return [::Integer] + # Optional. Memory allocated in GBs. + # @!attribute [rw] max_memory_size_gb + # @return [::Integer] + # Optional. Maximum memory allocated in GBs. + # @!attribute [rw] db_node_storage_size_gb + # @return [::Integer] + # Optional. Local storage per VM. + # @!attribute [rw] max_db_node_storage_size_gb + # @return [::Integer] + # Optional. Maximum local storage per VM. + # @!attribute [rw] vm_count + # @return [::Integer] + # Optional. Vm count per database. + # @!attribute [r] state + # @return [::Google::Cloud::OracleDatabase::V1::DbServerProperties::State] + # Output only. State of the database server. + # @!attribute [r] db_node_ids + # @return [::Array<::String>] + # Output only. OCID of database nodes associated with the database server. + class DbServerProperties + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + + # The various lifecycle states of the database server. + module State + # Default unspecified value. + STATE_UNSPECIFIED = 0 + + # Indicates that the resource is in creating state. + CREATING = 1 + + # Indicates that the resource is in available state. + AVAILABLE = 2 + + # Indicates that the resource is in unavailable state. + UNAVAILABLE = 3 + + # Indicates that the resource is in deleting state. + DELETING = 4 + + # Indicates that the resource is in deleted state. + DELETED = 5 + end + end + end + end + end +end diff --git a/google-cloud-oracle_database-v1/proto_docs/google/cloud/oracledatabase/v1/db_system_shape.rb b/google-cloud-oracle_database-v1/proto_docs/google/cloud/oracledatabase/v1/db_system_shape.rb new file mode 100644 index 000000000000..089587776c85 --- /dev/null +++ b/google-cloud-oracle_database-v1/proto_docs/google/cloud/oracledatabase/v1/db_system_shape.rb @@ -0,0 +1,70 @@ +# frozen_string_literal: true + +# Copyright 2024 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# https://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Auto-generated by gapic-generator-ruby. DO NOT EDIT! + + +module Google + module Cloud + module OracleDatabase + module V1 + # Details of the Database System Shapes resource. + # https://docs.oracle.com/en-us/iaas/api/#/en/database/20160918/DbSystemShapeSummary/ + # @!attribute [rw] name + # @return [::String] + # Identifier. The name of the Database System Shape resource with the format: + # projects/\\{project}/locations/\\{region}/dbSystemShapes/\\{db_system_shape} + # @!attribute [rw] shape + # @return [::String] + # Optional. shape + # @!attribute [rw] min_node_count + # @return [::Integer] + # Optional. Minimum number of database servers. + # @!attribute [rw] max_node_count + # @return [::Integer] + # Optional. Maximum number of database servers. + # @!attribute [rw] min_storage_count + # @return [::Integer] + # Optional. Minimum number of storage servers. + # @!attribute [rw] max_storage_count + # @return [::Integer] + # Optional. Maximum number of storage servers. + # @!attribute [rw] available_core_count_per_node + # @return [::Integer] + # Optional. Number of cores per node. + # @!attribute [rw] available_memory_per_node_gb + # @return [::Integer] + # Optional. Memory per database server node in gigabytes. + # @!attribute [rw] available_data_storage_tb + # @return [::Integer] + # Optional. Storage per storage server in terabytes. + # @!attribute [rw] min_core_count_per_node + # @return [::Integer] + # Optional. Minimum core count per node. + # @!attribute [rw] min_memory_per_node_gb + # @return [::Integer] + # Optional. Minimum memory per node in gigabytes. + # @!attribute [rw] min_db_node_storage_per_node_gb + # @return [::Integer] + # Optional. Minimum node storage per database server in gigabytes. + class DbSystemShape + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + end + end + end + end +end diff --git a/google-cloud-oracle_database-v1/proto_docs/google/cloud/oracledatabase/v1/entitlement.rb b/google-cloud-oracle_database-v1/proto_docs/google/cloud/oracledatabase/v1/entitlement.rb new file mode 100644 index 000000000000..ede09e0894de --- /dev/null +++ b/google-cloud-oracle_database-v1/proto_docs/google/cloud/oracledatabase/v1/entitlement.rb @@ -0,0 +1,78 @@ +# frozen_string_literal: true + +# Copyright 2024 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# https://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Auto-generated by gapic-generator-ruby. DO NOT EDIT! + + +module Google + module Cloud + module OracleDatabase + module V1 + # Details of the Entitlement resource. + # @!attribute [rw] name + # @return [::String] + # Identifier. The name of the Entitlement resource with the format: + # projects/\\{project}/locations/\\{region}/entitlements/\\{entitlement} + # @!attribute [rw] cloud_account_details + # @return [::Google::Cloud::OracleDatabase::V1::CloudAccountDetails] + # Details of the OCI Cloud Account. + # @!attribute [r] entitlement_id + # @return [::String] + # Output only. Google Cloud Marketplace order ID (aka entitlement ID) + # @!attribute [r] state + # @return [::Google::Cloud::OracleDatabase::V1::Entitlement::State] + # Output only. Entitlement State. + class Entitlement + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + + # The various lifecycle states of the subscription. + module State + # Default unspecified value. + STATE_UNSPECIFIED = 0 + + # Account not linked. + ACCOUNT_NOT_LINKED = 1 + + # Account is linked but not active. + ACCOUNT_NOT_ACTIVE = 2 + + # Entitlement and Account are active. + ACTIVE = 3 + end + end + + # Details of the OCI Cloud Account. + # @!attribute [r] cloud_account + # @return [::String] + # Output only. OCI account name. + # @!attribute [r] cloud_account_home_region + # @return [::String] + # Output only. OCI account home region. + # @!attribute [r] link_existing_account_uri + # @return [::String] + # Output only. URL to link an existing account. + # @!attribute [r] account_creation_uri + # @return [::String] + # Output only. URL to create a new account and link. + class CloudAccountDetails + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + end + end + end + end +end diff --git a/google-cloud-oracle_database-v1/proto_docs/google/cloud/oracledatabase/v1/exadata_infra.rb b/google-cloud-oracle_database-v1/proto_docs/google/cloud/oracledatabase/v1/exadata_infra.rb new file mode 100644 index 000000000000..c3eb88d5e270 --- /dev/null +++ b/google-cloud-oracle_database-v1/proto_docs/google/cloud/oracledatabase/v1/exadata_infra.rb @@ -0,0 +1,266 @@ +# frozen_string_literal: true + +# Copyright 2024 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# https://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Auto-generated by gapic-generator-ruby. DO NOT EDIT! + + +module Google + module Cloud + module OracleDatabase + module V1 + # Represents CloudExadataInfrastructure resource. + # https://docs.oracle.com/en-us/iaas/api/#/en/database/20160918/CloudExadataInfrastructure/ + # @!attribute [rw] name + # @return [::String] + # Identifier. The name of the Exadata Infrastructure resource with the + # format: + # projects/\\{project}/locations/\\{region}/cloudExadataInfrastructures/\\{cloud_exadata_infrastructure} + # @!attribute [rw] display_name + # @return [::String] + # Optional. User friendly name for this resource. + # @!attribute [rw] gcp_oracle_zone + # @return [::String] + # Optional. Google Cloud Platform location where Oracle Exadata is hosted. + # @!attribute [r] entitlement_id + # @return [::String] + # Output only. Entitlement ID of the private offer against which this + # infrastructure resource is provisioned. + # @!attribute [rw] properties + # @return [::Google::Cloud::OracleDatabase::V1::CloudExadataInfrastructureProperties] + # Optional. Various properties of the infra. + # @!attribute [rw] labels + # @return [::Google::Protobuf::Map{::String => ::String}] + # Optional. Labels or tags associated with the resource. + # @!attribute [r] create_time + # @return [::Google::Protobuf::Timestamp] + # Output only. The date and time that the Exadata Infrastructure was created. + class CloudExadataInfrastructure + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + + # @!attribute [rw] key + # @return [::String] + # @!attribute [rw] value + # @return [::String] + class LabelsEntry + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + end + end + + # Various properties of Exadata Infrastructure. + # @!attribute [r] ocid + # @return [::String] + # Output only. OCID of created infra. + # https://docs.oracle.com/en-us/iaas/Content/General/Concepts/identifiers.htm#Oracle + # @!attribute [rw] compute_count + # @return [::Integer] + # Optional. The number of compute servers for the Exadata Infrastructure. + # @!attribute [rw] storage_count + # @return [::Integer] + # Optional. The number of Cloud Exadata storage servers for the Exadata + # Infrastructure. + # @!attribute [rw] total_storage_size_gb + # @return [::Integer] + # Optional. The total storage allocated to the Exadata Infrastructure + # resource, in gigabytes (GB). + # @!attribute [r] available_storage_size_gb + # @return [::Integer] + # Output only. The available storage can be allocated to the Exadata + # Infrastructure resource, in gigabytes (GB). + # @!attribute [rw] maintenance_window + # @return [::Google::Cloud::OracleDatabase::V1::MaintenanceWindow] + # Optional. Maintenance window for repair. + # @!attribute [r] state + # @return [::Google::Cloud::OracleDatabase::V1::CloudExadataInfrastructureProperties::State] + # Output only. The current lifecycle state of the Exadata Infrastructure. + # @!attribute [rw] shape + # @return [::String] + # Required. The shape of the Exadata Infrastructure. The shape determines the + # amount of CPU, storage, and memory resources allocated to the instance. + # @!attribute [r] oci_url + # @return [::String] + # Output only. Deep link to the OCI console to view this resource. + # @!attribute [rw] cpu_count + # @return [::Integer] + # Optional. The number of enabled CPU cores. + # @!attribute [r] max_cpu_count + # @return [::Integer] + # Output only. The total number of CPU cores available. + # @!attribute [rw] memory_size_gb + # @return [::Integer] + # Optional. The memory allocated in GBs. + # @!attribute [r] max_memory_gb + # @return [::Integer] + # Output only. The total memory available in GBs. + # @!attribute [rw] db_node_storage_size_gb + # @return [::Integer] + # Optional. The local node storage allocated in GBs. + # @!attribute [r] max_db_node_storage_size_gb + # @return [::Integer] + # Output only. The total local node storage available in GBs. + # @!attribute [r] data_storage_size_tb + # @return [::Float] + # Output only. Size, in terabytes, of the DATA disk group. + # @!attribute [r] max_data_storage_tb + # @return [::Float] + # Output only. The total available DATA disk group size. + # @!attribute [r] activated_storage_count + # @return [::Integer] + # Output only. The requested number of additional storage servers activated + # for the Exadata Infrastructure. + # @!attribute [r] additional_storage_count + # @return [::Integer] + # Output only. The requested number of additional storage servers for the + # Exadata Infrastructure. + # @!attribute [r] db_server_version + # @return [::String] + # Output only. The software version of the database servers (dom0) in the + # Exadata Infrastructure. + # @!attribute [r] storage_server_version + # @return [::String] + # Output only. The software version of the storage servers (cells) in the + # Exadata Infrastructure. + # @!attribute [r] next_maintenance_run_id + # @return [::String] + # Output only. The OCID of the next maintenance run. + # @!attribute [r] next_maintenance_run_time + # @return [::Google::Protobuf::Timestamp] + # Output only. The time when the next maintenance run will occur. + # @!attribute [r] next_security_maintenance_run_time + # @return [::Google::Protobuf::Timestamp] + # Output only. The time when the next security maintenance run will occur. + # @!attribute [rw] customer_contacts + # @return [::Array<::Google::Cloud::OracleDatabase::V1::CustomerContact>] + # Optional. The list of customer contacts. + # @!attribute [r] monthly_storage_server_version + # @return [::String] + # Output only. The monthly software version of the storage servers (cells) + # in the Exadata Infrastructure. Example: 20.1.15 + # @!attribute [r] monthly_db_server_version + # @return [::String] + # Output only. The monthly software version of the database servers (dom0) + # in the Exadata Infrastructure. Example: 20.1.15 + class CloudExadataInfrastructureProperties + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + + # The various lifecycle states of the Exadata Infrastructure. + module State + # Default unspecified value. + STATE_UNSPECIFIED = 0 + + # The Exadata Infrastructure is being provisioned. + PROVISIONING = 1 + + # The Exadata Infrastructure is available for use. + AVAILABLE = 2 + + # The Exadata Infrastructure is being updated. + UPDATING = 3 + + # The Exadata Infrastructure is being terminated. + TERMINATING = 4 + + # The Exadata Infrastructure is terminated. + TERMINATED = 5 + + # The Exadata Infrastructure is in failed state. + FAILED = 6 + + # The Exadata Infrastructure is in maintenance. + MAINTENANCE_IN_PROGRESS = 7 + end + end + + # Maintenance window as defined by Oracle. + # https://docs.oracle.com/en-us/iaas/api/#/en/database/20160918/datatypes/MaintenanceWindow + # @!attribute [rw] preference + # @return [::Google::Cloud::OracleDatabase::V1::MaintenanceWindow::MaintenanceWindowPreference] + # Optional. The maintenance window scheduling preference. + # @!attribute [rw] months + # @return [::Array<::Google::Type::Month>] + # Optional. Months during the year when maintenance should be performed. + # @!attribute [rw] weeks_of_month + # @return [::Array<::Integer>] + # Optional. Weeks during the month when maintenance should be performed. + # Weeks start on the 1st, 8th, 15th, and 22nd days of the month, and have a + # duration of 7 days. Weeks start and end based on calendar dates, not days + # of the week. + # @!attribute [rw] days_of_week + # @return [::Array<::Google::Type::DayOfWeek>] + # Optional. Days during the week when maintenance should be performed. + # @!attribute [rw] hours_of_day + # @return [::Array<::Integer>] + # Optional. The window of hours during the day when maintenance should be + # performed. The window is a 4 hour slot. Valid values are: + # 0 - represents time slot 0:00 - 3:59 UTC + # 4 - represents time slot 4:00 - 7:59 UTC + # 8 - represents time slot 8:00 - 11:59 UTC + # 12 - represents time slot 12:00 - 15:59 UTC + # 16 - represents time slot 16:00 - 19:59 UTC + # 20 - represents time slot 20:00 - 23:59 UTC + # @!attribute [rw] lead_time_week + # @return [::Integer] + # Optional. Lead time window allows user to set a lead time to prepare for a + # down time. The lead time is in weeks and valid value is between 1 to 4. + # @!attribute [rw] patching_mode + # @return [::Google::Cloud::OracleDatabase::V1::MaintenanceWindow::PatchingMode] + # Optional. Cloud CloudExadataInfrastructure node patching method, either + # "ROLLING" + # or "NONROLLING". Default value is ROLLING. + # @!attribute [rw] custom_action_timeout_mins + # @return [::Integer] + # Optional. Determines the amount of time the system will wait before the + # start of each database server patching operation. Custom action timeout is + # in minutes and valid value is between 15 to 120 (inclusive). + # @!attribute [rw] is_custom_action_timeout_enabled + # @return [::Boolean] + # Optional. If true, enables the configuration of a custom action timeout + # (waiting period) between database server patching operations. + class MaintenanceWindow + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + + # Maintenance window preference. + module MaintenanceWindowPreference + # Default unspecified value. + MAINTENANCE_WINDOW_PREFERENCE_UNSPECIFIED = 0 + + # Custom preference. + CUSTOM_PREFERENCE = 1 + + # No preference. + NO_PREFERENCE = 2 + end + + # Patching mode. + module PatchingMode + # Default unspecified value. + PATCHING_MODE_UNSPECIFIED = 0 + + # Updates the Cloud Exadata database server hosts in a rolling fashion. + ROLLING = 1 + + # The non-rolling maintenance method first updates your storage servers at + # the same time, then your database servers at the same time. + NON_ROLLING = 2 + end + end + end + end + end +end diff --git a/google-cloud-oracle_database-v1/proto_docs/google/cloud/oracledatabase/v1/gi_version.rb b/google-cloud-oracle_database-v1/proto_docs/google/cloud/oracledatabase/v1/gi_version.rb new file mode 100644 index 000000000000..62dd34e88ddc --- /dev/null +++ b/google-cloud-oracle_database-v1/proto_docs/google/cloud/oracledatabase/v1/gi_version.rb @@ -0,0 +1,41 @@ +# frozen_string_literal: true + +# Copyright 2024 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# https://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Auto-generated by gapic-generator-ruby. DO NOT EDIT! + + +module Google + module Cloud + module OracleDatabase + module V1 + # Details of the Oracle Grid Infrastructure (GI) version resource. + # https://docs.oracle.com/en-us/iaas/api/#/en/database/20160918/GiVersionSummary/ + # @!attribute [rw] name + # @return [::String] + # Identifier. The name of the Oracle Grid Infrastructure (GI) version + # resource with the format: + # projects/\\{project}/locations/\\{region}/giVersions/\\{gi_versions} + # @!attribute [rw] version + # @return [::String] + # Optional. version + class GiVersion + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + end + end + end + end +end diff --git a/google-cloud-oracle_database-v1/proto_docs/google/cloud/oracledatabase/v1/location_metadata.rb b/google-cloud-oracle_database-v1/proto_docs/google/cloud/oracledatabase/v1/location_metadata.rb new file mode 100644 index 000000000000..a614155cf2de --- /dev/null +++ b/google-cloud-oracle_database-v1/proto_docs/google/cloud/oracledatabase/v1/location_metadata.rb @@ -0,0 +1,35 @@ +# frozen_string_literal: true + +# Copyright 2024 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# https://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Auto-generated by gapic-generator-ruby. DO NOT EDIT! + + +module Google + module Cloud + module OracleDatabase + module V1 + # Metadata for a given `::Google::Cloud::Location::Location`. + # @!attribute [r] gcp_oracle_zones + # @return [::Array<::String>] + # Output only. Google Cloud Platform Oracle zones in a location. + class LocationMetadata + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + end + end + end + end +end diff --git a/google-cloud-oracle_database-v1/proto_docs/google/cloud/oracledatabase/v1/oracledatabase.rb b/google-cloud-oracle_database-v1/proto_docs/google/cloud/oracledatabase/v1/oracledatabase.rb new file mode 100644 index 000000000000..19cb8c6eca74 --- /dev/null +++ b/google-cloud-oracle_database-v1/proto_docs/google/cloud/oracledatabase/v1/oracledatabase.rb @@ -0,0 +1,649 @@ +# frozen_string_literal: true + +# Copyright 2024 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# https://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Auto-generated by gapic-generator-ruby. DO NOT EDIT! + + +module Google + module Cloud + module OracleDatabase + module V1 + # The request for `CloudExadataInfrastructures.List`. + # @!attribute [rw] parent + # @return [::String] + # Required. The parent value for CloudExadataInfrastructure in the following + # format: projects/\\{project}/locations/\\{location}. + # @!attribute [rw] page_size + # @return [::Integer] + # Optional. The maximum number of items to return. + # If unspecified, at most 50 Exadata infrastructures will be returned. + # The maximum value is 1000; values above 1000 will be coerced to 1000. + # @!attribute [rw] page_token + # @return [::String] + # Optional. A token identifying a page of results the server should return. + class ListCloudExadataInfrastructuresRequest + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + end + + # The response for `CloudExadataInfrastructures.list`. + # @!attribute [rw] cloud_exadata_infrastructures + # @return [::Array<::Google::Cloud::OracleDatabase::V1::CloudExadataInfrastructure>] + # The list of Exadata Infrastructures. + # @!attribute [rw] next_page_token + # @return [::String] + # A token for fetching next page of response. + class ListCloudExadataInfrastructuresResponse + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + end + + # The request for `CloudExadataInfrastructure.Get`. + # @!attribute [rw] name + # @return [::String] + # Required. The name of the Cloud Exadata Infrastructure in the following + # format: + # projects/\\{project}/locations/\\{location}/cloudExadataInfrastructures/\\{cloud_exadata_infrastructure}. + class GetCloudExadataInfrastructureRequest + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + end + + # The request for `CloudExadataInfrastructure.Create`. + # @!attribute [rw] parent + # @return [::String] + # Required. The parent value for CloudExadataInfrastructure in the following + # format: projects/\\{project}/locations/\\{location}. + # @!attribute [rw] cloud_exadata_infrastructure_id + # @return [::String] + # Required. The ID of the Exadata Infrastructure to create. This value is + # restricted to (^[a-z]([a-z0-9-]\\{0,61}[a-z0-9])?$) and must be a maximum of + # 63 characters in length. The value must start with a letter and end with a + # letter or a number. + # @!attribute [rw] cloud_exadata_infrastructure + # @return [::Google::Cloud::OracleDatabase::V1::CloudExadataInfrastructure] + # Required. Details of the Exadata Infrastructure instance to create. + # @!attribute [rw] request_id + # @return [::String] + # Optional. An optional ID to identify the request. This value is used to + # identify duplicate requests. If you make a request with the same request ID + # and the original request is still in progress or completed, the server + # ignores the second request. This prevents clients from + # accidentally creating duplicate commitments. + # + # The request ID must be a valid UUID with the exception that zero UUID is + # not supported (00000000-0000-0000-0000-000000000000). + class CreateCloudExadataInfrastructureRequest + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + end + + # The request for `CloudExadataInfrastructure.Delete`. + # @!attribute [rw] name + # @return [::String] + # Required. The name of the Cloud Exadata Infrastructure in the following + # format: + # projects/\\{project}/locations/\\{location}/cloudExadataInfrastructures/\\{cloud_exadata_infrastructure}. + # @!attribute [rw] request_id + # @return [::String] + # Optional. An optional ID to identify the request. This value is used to + # identify duplicate requests. If you make a request with the same request ID + # and the original request is still in progress or completed, the server + # ignores the second request. This prevents clients from + # accidentally creating duplicate commitments. + # + # The request ID must be a valid UUID with the exception that zero UUID is + # not supported (00000000-0000-0000-0000-000000000000). + # @!attribute [rw] force + # @return [::Boolean] + # Optional. If set to true, all VM clusters for this Exadata Infrastructure + # will be deleted. An Exadata Infrastructure can only be deleted once all its + # VM clusters have been deleted. + class DeleteCloudExadataInfrastructureRequest + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + end + + # The request for `CloudVmCluster.List`. + # @!attribute [rw] parent + # @return [::String] + # Required. The name of the parent in the following format: + # projects/\\{project}/locations/\\{location}. + # @!attribute [rw] page_size + # @return [::Integer] + # Optional. The number of VM clusters to return. + # If unspecified, at most 50 VM clusters will be returned. + # The maximum value is 1,000. + # @!attribute [rw] page_token + # @return [::String] + # Optional. A token identifying the page of results the server returns. + # @!attribute [rw] filter + # @return [::String] + # Optional. An expression for filtering the results of the request. + class ListCloudVmClustersRequest + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + end + + # The response for `CloudVmCluster.List`. + # @!attribute [rw] cloud_vm_clusters + # @return [::Array<::Google::Cloud::OracleDatabase::V1::CloudVmCluster>] + # The list of VM Clusters. + # @!attribute [rw] next_page_token + # @return [::String] + # A token to fetch the next page of results. + class ListCloudVmClustersResponse + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + end + + # The request for `CloudVmCluster.Get`. + # @!attribute [rw] name + # @return [::String] + # Required. The name of the Cloud VM Cluster in the following format: + # projects/\\{project}/locations/\\{location}/cloudVmClusters/\\{cloud_vm_cluster}. + class GetCloudVmClusterRequest + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + end + + # The request for `CloudVmCluster.Create`. + # @!attribute [rw] parent + # @return [::String] + # Required. The name of the parent in the following format: + # projects/\\{project}/locations/\\{location}. + # @!attribute [rw] cloud_vm_cluster_id + # @return [::String] + # Required. The ID of the VM Cluster to create. This value is restricted + # to (^[a-z]([a-z0-9-]\\{0,61}[a-z0-9])?$) and must be a maximum of 63 + # characters in length. The value must start with a letter and end with + # a letter or a number. + # @!attribute [rw] cloud_vm_cluster + # @return [::Google::Cloud::OracleDatabase::V1::CloudVmCluster] + # Required. The resource being created + # @!attribute [rw] request_id + # @return [::String] + # Optional. An optional ID to identify the request. This value is used to + # identify duplicate requests. If you make a request with the same request ID + # and the original request is still in progress or completed, the server + # ignores the second request. This prevents clients from + # accidentally creating duplicate commitments. + # + # The request ID must be a valid UUID with the exception that zero UUID is + # not supported (00000000-0000-0000-0000-000000000000). + class CreateCloudVmClusterRequest + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + end + + # The request for `CloudVmCluster.Delete`. + # @!attribute [rw] name + # @return [::String] + # Required. The name of the Cloud VM Cluster in the following format: + # projects/\\{project}/locations/\\{location}/cloudVmClusters/\\{cloud_vm_cluster}. + # @!attribute [rw] request_id + # @return [::String] + # Optional. An optional ID to identify the request. This value is used to + # identify duplicate requests. If you make a request with the same request ID + # and the original request is still in progress or completed, the server + # ignores the second request. This prevents clients from + # accidentally creating duplicate commitments. + # + # The request ID must be a valid UUID with the exception that zero UUID is + # not supported (00000000-0000-0000-0000-000000000000). + # @!attribute [rw] force + # @return [::Boolean] + # Optional. If set to true, all child resources for the VM Cluster will be + # deleted. A VM Cluster can only be deleted once all its child resources have + # been deleted. + class DeleteCloudVmClusterRequest + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + end + + # The request for `Entitlement.List`. + # @!attribute [rw] parent + # @return [::String] + # Required. The parent value for the entitlement in the following format: + # projects/\\{project}/locations/\\{location}. + # @!attribute [rw] page_size + # @return [::Integer] + # Optional. The maximum number of items to return. + # If unspecified, a maximum of 50 entitlements will be returned. + # The maximum value is 1000. + # @!attribute [rw] page_token + # @return [::String] + # Optional. A token identifying a page of results the server should return. + class ListEntitlementsRequest + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + end + + # The response for `Entitlement.List`. + # @!attribute [rw] entitlements + # @return [::Array<::Google::Cloud::OracleDatabase::V1::Entitlement>] + # The list of Entitlements + # @!attribute [rw] next_page_token + # @return [::String] + # A token identifying a page of results the server should return. + class ListEntitlementsResponse + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + end + + # The request for `DbServer.List`. + # @!attribute [rw] parent + # @return [::String] + # Required. The parent value for database server in the following format: + # projects/\\{project}/locations/\\{location}/cloudExadataInfrastructures/\\{cloudExadataInfrastructure}. + # @!attribute [rw] page_size + # @return [::Integer] + # Optional. The maximum number of items to return. + # If unspecified, a maximum of 50 db servers will be returned. + # The maximum value is 1000; values above 1000 will be reset to 1000. + # @!attribute [rw] page_token + # @return [::String] + # Optional. A token identifying a page of results the server should return. + class ListDbServersRequest + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + end + + # The response for `DbServer.List`. + # @!attribute [rw] db_servers + # @return [::Array<::Google::Cloud::OracleDatabase::V1::DbServer>] + # The list of database servers. + # @!attribute [rw] next_page_token + # @return [::String] + # A token identifying a page of results the server should return. + class ListDbServersResponse + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + end + + # The request for `DbNode.List`. + # @!attribute [rw] parent + # @return [::String] + # Required. The parent value for database node in the following format: + # projects/\\{project}/locations/\\{location}/cloudVmClusters/\\{cloudVmCluster}. + # @!attribute [rw] page_size + # @return [::Integer] + # Optional. The maximum number of items to return. + # If unspecified, at most 50 db nodes will be returned. + # The maximum value is 1000; values above 1000 will be coerced to 1000. + # @!attribute [rw] page_token + # @return [::String] + # Optional. A token identifying a page of results the node should return. + class ListDbNodesRequest + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + end + + # The response for `DbNode.List`. + # @!attribute [rw] db_nodes + # @return [::Array<::Google::Cloud::OracleDatabase::V1::DbNode>] + # The list of DB Nodes + # @!attribute [rw] next_page_token + # @return [::String] + # A token identifying a page of results the node should return. + class ListDbNodesResponse + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + end + + # The request for `GiVersion.List`. + # @!attribute [rw] parent + # @return [::String] + # Required. The parent value for Grid Infrastructure Version in the following + # format: Format: projects/\\{project}/locations/\\{location}. + # @!attribute [rw] page_size + # @return [::Integer] + # Optional. The maximum number of items to return. + # If unspecified, a maximum of 50 Oracle Grid Infrastructure (GI) versions + # will be returned. The maximum value is 1000; values above 1000 will be + # reset to 1000. + # @!attribute [rw] page_token + # @return [::String] + # Optional. A token identifying a page of results the server should return. + class ListGiVersionsRequest + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + end + + # The response for `GiVersion.List`. + # @!attribute [rw] gi_versions + # @return [::Array<::Google::Cloud::OracleDatabase::V1::GiVersion>] + # The list of Oracle Grid Infrastructure (GI) versions. + # @!attribute [rw] next_page_token + # @return [::String] + # A token identifying a page of results the server should return. + class ListGiVersionsResponse + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + end + + # The request for `DbSystemShape.List`. + # @!attribute [rw] parent + # @return [::String] + # Required. The parent value for Database System Shapes in the following + # format: projects/\\{project}/locations/\\{location}. + # @!attribute [rw] page_size + # @return [::Integer] + # Optional. The maximum number of items to return. + # If unspecified, at most 50 database system shapes will be returned. + # The maximum value is 1000; values above 1000 will be coerced to 1000. + # @!attribute [rw] page_token + # @return [::String] + # Optional. A token identifying a page of results the server should return. + class ListDbSystemShapesRequest + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + end + + # The response for `DbSystemShape.List`. + # @!attribute [rw] db_system_shapes + # @return [::Array<::Google::Cloud::OracleDatabase::V1::DbSystemShape>] + # The list of Database System shapes. + # @!attribute [rw] next_page_token + # @return [::String] + # A token identifying a page of results the server should return. + class ListDbSystemShapesResponse + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + end + + # Represents the metadata of the long-running operation. + # @!attribute [r] create_time + # @return [::Google::Protobuf::Timestamp] + # Output only. The time the operation was created. + # @!attribute [r] end_time + # @return [::Google::Protobuf::Timestamp] + # Output only. The time the operation finished running. + # @!attribute [r] target + # @return [::String] + # Output only. Server-defined resource path for the target of the operation. + # @!attribute [r] verb + # @return [::String] + # Output only. Name of the verb executed by the operation. + # @!attribute [r] status_message + # @return [::String] + # Output only. The status of the operation. + # @!attribute [r] requested_cancellation + # @return [::Boolean] + # Output only. Identifies whether the user has requested cancellation + # of the operation. Operations that have been cancelled successfully + # have [Operation.error][] value with a + # {::Google::Rpc::Status#code google.rpc.Status.code} of 1, corresponding to + # `Code.CANCELLED`. + # @!attribute [r] api_version + # @return [::String] + # Output only. API version used to start the operation. + # @!attribute [r] percent_complete + # @return [::Float] + # Output only. An estimated percentage of the operation that has been + # completed at a given moment of time, between 0 and 100. + class OperationMetadata + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + end + + # The request for `AutonomousDatabase.List`. + # @!attribute [rw] parent + # @return [::String] + # Required. The parent value for the Autonomous Database in the following + # format: projects/\\{project}/locations/\\{location}. + # @!attribute [rw] page_size + # @return [::Integer] + # Optional. The maximum number of items to return. + # If unspecified, at most 50 Autonomous Database will be returned. + # The maximum value is 1000; values above 1000 will be coerced to 1000. + # @!attribute [rw] page_token + # @return [::String] + # Optional. A token identifying a page of results the server should return. + # @!attribute [rw] filter + # @return [::String] + # Optional. An expression for filtering the results of the request. + # @!attribute [rw] order_by + # @return [::String] + # Optional. An expression for ordering the results of the request. + class ListAutonomousDatabasesRequest + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + end + + # The response for `AutonomousDatabase.List`. + # @!attribute [rw] autonomous_databases + # @return [::Array<::Google::Cloud::OracleDatabase::V1::AutonomousDatabase>] + # The list of Autonomous Databases. + # @!attribute [rw] next_page_token + # @return [::String] + # A token identifying a page of results the server should return. + class ListAutonomousDatabasesResponse + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + end + + # The request for `AutonomousDatabase.Get`. + # @!attribute [rw] name + # @return [::String] + # Required. The name of the Autonomous Database in the following format: + # projects/\\{project}/locations/\\{location}/autonomousDatabases/\\{autonomous_database}. + class GetAutonomousDatabaseRequest + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + end + + # The request for `AutonomousDatabase.Create`. + # @!attribute [rw] parent + # @return [::String] + # Required. The name of the parent in the following format: + # projects/\\{project}/locations/\\{location}. + # @!attribute [rw] autonomous_database_id + # @return [::String] + # Required. The ID of the Autonomous Database to create. This value is + # restricted to (^[a-z]([a-z0-9-]\\{0,61}[a-z0-9])?$) and must be a maximum of + # 63 characters in length. The value must start with a letter and end with a + # letter or a number. + # @!attribute [rw] autonomous_database + # @return [::Google::Cloud::OracleDatabase::V1::AutonomousDatabase] + # Required. The Autonomous Database being created. + # @!attribute [rw] request_id + # @return [::String] + # Optional. An optional ID to identify the request. This value is used to + # identify duplicate requests. If you make a request with the same request ID + # and the original request is still in progress or completed, the server + # ignores the second request. This prevents clients from + # accidentally creating duplicate commitments. + # + # The request ID must be a valid UUID with the exception that zero UUID is + # not supported (00000000-0000-0000-0000-000000000000). + class CreateAutonomousDatabaseRequest + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + end + + # The request for `AutonomousDatabase.Delete`. + # @!attribute [rw] name + # @return [::String] + # Required. The name of the resource in the following format: + # projects/\\{project}/locations/\\{location}/autonomousDatabases/\\{autonomous_database}. + # @!attribute [rw] request_id + # @return [::String] + # Optional. An optional ID to identify the request. This value is used to + # identify duplicate requests. If you make a request with the same request ID + # and the original request is still in progress or completed, the server + # ignores the second request. This prevents clients from + # accidentally creating duplicate commitments. + # + # The request ID must be a valid UUID with the exception that zero UUID is + # not supported (00000000-0000-0000-0000-000000000000). + class DeleteAutonomousDatabaseRequest + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + end + + # The request for `AutonomousDatabase.Restore`. + # @!attribute [rw] name + # @return [::String] + # Required. The name of the Autonomous Database in the following format: + # projects/\\{project}/locations/\\{location}/autonomousDatabases/\\{autonomous_database}. + # @!attribute [rw] restore_time + # @return [::Google::Protobuf::Timestamp] + # Required. The time and date to restore the database to. + class RestoreAutonomousDatabaseRequest + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + end + + # The request for `AutonomousDatabase.GenerateWallet`. + # @!attribute [rw] name + # @return [::String] + # Required. The name of the Autonomous Database in the following format: + # projects/\\{project}/locations/\\{location}/autonomousDatabases/\\{autonomous_database}. + # @!attribute [rw] type + # @return [::Google::Cloud::OracleDatabase::V1::GenerateType] + # Optional. The type of wallet generation for the Autonomous Database. The + # default value is SINGLE. + # @!attribute [rw] is_regional + # @return [::Boolean] + # Optional. True when requesting regional connection strings in PDB connect + # info, applicable to cross-region Data Guard only. + # @!attribute [rw] password + # @return [::String] + # Required. The password used to encrypt the keys inside the wallet. The + # password must be a minimum of 8 characters. + class GenerateAutonomousDatabaseWalletRequest + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + end + + # The response for `AutonomousDatabase.GenerateWallet`. + # @!attribute [r] archive_content + # @return [::String] + # Output only. The base64 encoded wallet files. + class GenerateAutonomousDatabaseWalletResponse + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + end + + # The request for `AutonomousDbVersion.List`. + # @!attribute [rw] parent + # @return [::String] + # Required. The parent value for the Autonomous Database in the following + # format: projects/\\{project}/locations/\\{location}. + # @!attribute [rw] page_size + # @return [::Integer] + # Optional. The maximum number of items to return. + # If unspecified, at most 50 Autonomous DB Versions will be returned. + # The maximum value is 1000; values above 1000 will be coerced to 1000. + # @!attribute [rw] page_token + # @return [::String] + # Optional. A token identifying a page of results the server should return. + class ListAutonomousDbVersionsRequest + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + end + + # The response for `AutonomousDbVersion.List`. + # @!attribute [rw] autonomous_db_versions + # @return [::Array<::Google::Cloud::OracleDatabase::V1::AutonomousDbVersion>] + # The list of Autonomous Database versions. + # @!attribute [rw] next_page_token + # @return [::String] + # A token identifying a page of results the server should return. + class ListAutonomousDbVersionsResponse + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + end + + # The request for `AutonomousDatabaseCharacterSet.List`. + # @!attribute [rw] parent + # @return [::String] + # Required. The parent value for the Autonomous Database in the following + # format: projects/\\{project}/locations/\\{location}. + # @!attribute [rw] page_size + # @return [::Integer] + # Optional. The maximum number of items to return. + # If unspecified, at most 50 Autonomous DB Character Sets will be returned. + # The maximum value is 1000; values above 1000 will be coerced to 1000. + # @!attribute [rw] page_token + # @return [::String] + # Optional. A token identifying a page of results the server should return. + # @!attribute [rw] filter + # @return [::String] + # Optional. An expression for filtering the results of the request. Only the + # **character_set_type** field is supported in the following format: + # `character_set_type="{characterSetType}"`. Accepted values include + # `DATABASE` and `NATIONAL`. + class ListAutonomousDatabaseCharacterSetsRequest + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + end + + # The response for `AutonomousDatabaseCharacterSet.List`. + # @!attribute [rw] autonomous_database_character_sets + # @return [::Array<::Google::Cloud::OracleDatabase::V1::AutonomousDatabaseCharacterSet>] + # The list of Autonomous Database Character Sets. + # @!attribute [rw] next_page_token + # @return [::String] + # A token identifying a page of results the server should return. + class ListAutonomousDatabaseCharacterSetsResponse + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + end + + # The request for `AutonomousDatabaseBackup.List`. + # @!attribute [rw] parent + # @return [::String] + # Required. The parent value for ListAutonomousDatabaseBackups in the + # following format: projects/\\{project}/locations/\\{location}. + # @!attribute [rw] filter + # @return [::String] + # Optional. An expression for filtering the results of the request. Only the + # **autonomous_database_id** field is supported in the following format: + # `autonomous_database_id="{autonomous_database_id}"`. The accepted values + # must be a valid Autonomous Database ID, limited to the naming + # restrictions of the ID: ^[a-z]([a-z0-9-]\\{0,61}[a-z0-9])?$). + # The ID must start with a letter, end with a letter or a number, and be + # a maximum of 63 characters. + # @!attribute [rw] page_size + # @return [::Integer] + # Optional. The maximum number of items to return. + # If unspecified, at most 50 Autonomous DB Backups will be returned. + # The maximum value is 1000; values above 1000 will be coerced to 1000. + # @!attribute [rw] page_token + # @return [::String] + # Optional. A token identifying a page of results the server should return. + class ListAutonomousDatabaseBackupsRequest + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + end + + # The response for `AutonomousDatabaseBackup.List`. + # @!attribute [rw] autonomous_database_backups + # @return [::Array<::Google::Cloud::OracleDatabase::V1::AutonomousDatabaseBackup>] + # The list of Autonomous Database Backups. + # @!attribute [rw] next_page_token + # @return [::String] + # A token identifying a page of results the server should return. + class ListAutonomousDatabaseBackupsResponse + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + end + end + end + end +end diff --git a/google-cloud-oracle_database-v1/proto_docs/google/cloud/oracledatabase/v1/vm_cluster.rb b/google-cloud-oracle_database-v1/proto_docs/google/cloud/oracledatabase/v1/vm_cluster.rb new file mode 100644 index 000000000000..f2037dd23db9 --- /dev/null +++ b/google-cloud-oracle_database-v1/proto_docs/google/cloud/oracledatabase/v1/vm_cluster.rb @@ -0,0 +1,251 @@ +# frozen_string_literal: true + +# Copyright 2024 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# https://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Auto-generated by gapic-generator-ruby. DO NOT EDIT! + + +module Google + module Cloud + module OracleDatabase + module V1 + # Details of the Cloud VM Cluster resource. + # https://docs.oracle.com/en-us/iaas/api/#/en/database/20160918/CloudVmCluster/ + # @!attribute [rw] name + # @return [::String] + # Identifier. The name of the VM Cluster resource with the format: + # projects/\\{project}/locations/\\{region}/cloudVmClusters/\\{cloud_vm_cluster} + # @!attribute [rw] exadata_infrastructure + # @return [::String] + # Required. The name of the Exadata Infrastructure resource on which VM + # cluster resource is created, in the following format: + # projects/\\{project}/locations/\\{region}/cloudExadataInfrastuctures/\\{cloud_extradata_infrastructure} + # @!attribute [rw] display_name + # @return [::String] + # Optional. User friendly name for this resource. + # @!attribute [r] gcp_oracle_zone + # @return [::String] + # Output only. Google Cloud Platform location where Oracle Exadata is hosted. + # It is same as Google Cloud Platform Oracle zone of Exadata infrastructure. + # @!attribute [rw] properties + # @return [::Google::Cloud::OracleDatabase::V1::CloudVmClusterProperties] + # Optional. Various properties of the VM Cluster. + # @!attribute [rw] labels + # @return [::Google::Protobuf::Map{::String => ::String}] + # Optional. Labels or tags associated with the VM Cluster. + # @!attribute [r] create_time + # @return [::Google::Protobuf::Timestamp] + # Output only. The date and time that the VM cluster was created. + # @!attribute [rw] cidr + # @return [::String] + # Required. Network settings. CIDR to use for cluster IP allocation. + # @!attribute [rw] backup_subnet_cidr + # @return [::String] + # Required. CIDR range of the backup subnet. + # @!attribute [rw] network + # @return [::String] + # Required. The name of the VPC network. + # Format: projects/\\{project}/global/networks/\\{network} + class CloudVmCluster + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + + # @!attribute [rw] key + # @return [::String] + # @!attribute [rw] value + # @return [::String] + class LabelsEntry + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + end + end + + # Various properties and settings associated with Exadata VM cluster. + # @!attribute [r] ocid + # @return [::String] + # Output only. Oracle Cloud Infrastructure ID of VM Cluster. + # @!attribute [rw] license_type + # @return [::Google::Cloud::OracleDatabase::V1::CloudVmClusterProperties::LicenseType] + # Required. License type of VM Cluster. + # @!attribute [rw] gi_version + # @return [::String] + # Optional. Grid Infrastructure Version. + # @!attribute [rw] time_zone + # @return [::Google::Type::TimeZone] + # Optional. Time zone of VM Cluster to set. Defaults to UTC if not specified. + # @!attribute [rw] ssh_public_keys + # @return [::Array<::String>] + # Optional. SSH public keys to be stored with cluster. + # @!attribute [rw] node_count + # @return [::Integer] + # Optional. Number of database servers. + # @!attribute [r] shape + # @return [::String] + # Output only. Shape of VM Cluster. + # @!attribute [rw] ocpu_count + # @return [::Float] + # Optional. OCPU count per VM. Minimum is 0.1. + # @!attribute [rw] memory_size_gb + # @return [::Integer] + # Optional. Memory allocated in GBs. + # @!attribute [rw] db_node_storage_size_gb + # @return [::Integer] + # Optional. Local storage per VM. + # @!attribute [r] storage_size_gb + # @return [::Integer] + # Output only. The storage allocation for the disk group, in gigabytes (GB). + # @!attribute [rw] data_storage_size_tb + # @return [::Float] + # Optional. The data disk group size to be allocated in TBs. + # @!attribute [rw] disk_redundancy + # @return [::Google::Cloud::OracleDatabase::V1::CloudVmClusterProperties::DiskRedundancy] + # Optional. The type of redundancy. + # @!attribute [rw] sparse_diskgroup_enabled + # @return [::Boolean] + # Optional. Use exadata sparse snapshots. + # @!attribute [rw] local_backup_enabled + # @return [::Boolean] + # Optional. Use local backup. + # @!attribute [rw] hostname_prefix + # @return [::String] + # Optional. Prefix for VM cluster host names. + # @!attribute [rw] diagnostics_data_collection_options + # @return [::Google::Cloud::OracleDatabase::V1::DataCollectionOptions] + # Optional. Data collection options for diagnostics. + # @!attribute [r] state + # @return [::Google::Cloud::OracleDatabase::V1::CloudVmClusterProperties::State] + # Output only. State of the cluster. + # @!attribute [r] scan_listener_port_tcp + # @return [::Integer] + # Output only. SCAN listener port - TCP + # @!attribute [r] scan_listener_port_tcp_ssl + # @return [::Integer] + # Output only. SCAN listener port - TLS + # @!attribute [r] domain + # @return [::String] + # Output only. Parent DNS domain where SCAN DNS and hosts names are + # qualified. ex: ocispdelegated.ocisp10jvnet.oraclevcn.com + # @!attribute [r] scan_dns + # @return [::String] + # Output only. SCAN DNS name. + # ex: sp2-yi0xq-scan.ocispdelegated.ocisp10jvnet.oraclevcn.com + # @!attribute [r] hostname + # @return [::String] + # Output only. host name without domain. + # format: "-" with some suffix. + # ex: sp2-yi0xq where "sp2" is the hostname_prefix. + # @!attribute [rw] cpu_core_count + # @return [::Integer] + # Required. Number of enabled CPU cores. + # @!attribute [r] system_version + # @return [::String] + # Output only. Operating system version of the image. + # @!attribute [r] scan_ip_ids + # @return [::Array<::String>] + # Output only. OCIDs of scan IPs. + # @!attribute [r] scan_dns_record_id + # @return [::String] + # Output only. OCID of scan DNS record. + # @!attribute [r] oci_url + # @return [::String] + # Output only. Deep link to the OCI console to view this resource. + # @!attribute [rw] db_server_ocids + # @return [::Array<::String>] + # Optional. OCID of database servers. + # @!attribute [r] compartment_id + # @return [::String] + # Output only. Compartment ID of cluster. + # @!attribute [r] dns_listener_ip + # @return [::String] + # Output only. DNS listener IP. + # @!attribute [rw] cluster_name + # @return [::String] + # Optional. OCI Cluster name. + class CloudVmClusterProperties + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + + # Different licenses supported. + module LicenseType + # Unspecified + LICENSE_TYPE_UNSPECIFIED = 0 + + # License included part of offer + LICENSE_INCLUDED = 1 + + # Bring your own license + BRING_YOUR_OWN_LICENSE = 2 + end + + # Types of disk redundancy provided by Oracle. + module DiskRedundancy + # Unspecified. + DISK_REDUNDANCY_UNSPECIFIED = 0 + + # High - 3 way mirror. + HIGH = 1 + + # Normal - 2 way mirror. + NORMAL = 2 + end + + # The various lifecycle states of the VM cluster. + module State + # Default unspecified value. + STATE_UNSPECIFIED = 0 + + # Indicates that the resource is in provisioning state. + PROVISIONING = 1 + + # Indicates that the resource is in available state. + AVAILABLE = 2 + + # Indicates that the resource is in updating state. + UPDATING = 3 + + # Indicates that the resource is in terminating state. + TERMINATING = 4 + + # Indicates that the resource is in terminated state. + TERMINATED = 5 + + # Indicates that the resource is in failed state. + FAILED = 6 + + # Indicates that the resource is in maintenance in progress state. + MAINTENANCE_IN_PROGRESS = 7 + end + end + + # Data collection options for diagnostics. + # @!attribute [rw] diagnostics_events_enabled + # @return [::Boolean] + # Optional. Indicates whether diagnostic collection is enabled for the VM + # cluster + # @!attribute [rw] health_monitoring_enabled + # @return [::Boolean] + # Optional. Indicates whether health monitoring is enabled for the VM cluster + # @!attribute [rw] incident_logs_enabled + # @return [::Boolean] + # Optional. Indicates whether incident logs and trace collection are enabled + # for the VM cluster + class DataCollectionOptions + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + end + end + end + end +end diff --git a/google-cloud-oracle_database-v1/proto_docs/google/longrunning/operations.rb b/google-cloud-oracle_database-v1/proto_docs/google/longrunning/operations.rb new file mode 100644 index 000000000000..54b83fb82b7d --- /dev/null +++ b/google-cloud-oracle_database-v1/proto_docs/google/longrunning/operations.rb @@ -0,0 +1,164 @@ +# frozen_string_literal: true + +# Copyright 2024 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# https://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Auto-generated by gapic-generator-ruby. DO NOT EDIT! + + +module Google + module Longrunning + # This resource represents a long-running operation that is the result of a + # network API call. + # @!attribute [rw] name + # @return [::String] + # The server-assigned name, which is only unique within the same service that + # originally returns it. If you use the default HTTP mapping, the + # `name` should be a resource name ending with `operations/{unique_id}`. + # @!attribute [rw] metadata + # @return [::Google::Protobuf::Any] + # Service-specific metadata associated with the operation. It typically + # contains progress information and common metadata such as create time. + # Some services might not provide such metadata. Any method that returns a + # long-running operation should document the metadata type, if any. + # @!attribute [rw] done + # @return [::Boolean] + # If the value is `false`, it means the operation is still in progress. + # If `true`, the operation is completed, and either `error` or `response` is + # available. + # @!attribute [rw] error + # @return [::Google::Rpc::Status] + # The error result of the operation in case of failure or cancellation. + # @!attribute [rw] response + # @return [::Google::Protobuf::Any] + # The normal response of the operation in case of success. If the original + # method returns no data on success, such as `Delete`, the response is + # `google.protobuf.Empty`. If the original method is standard + # `Get`/`Create`/`Update`, the response should be the resource. For other + # methods, the response should have the type `XxxResponse`, where `Xxx` + # is the original method name. For example, if the original method name + # is `TakeSnapshot()`, the inferred response type is + # `TakeSnapshotResponse`. + class Operation + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + end + + # The request message for Operations.GetOperation. + # @!attribute [rw] name + # @return [::String] + # The name of the operation resource. + class GetOperationRequest + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + end + + # The request message for Operations.ListOperations. + # @!attribute [rw] name + # @return [::String] + # The name of the operation's parent resource. + # @!attribute [rw] filter + # @return [::String] + # The standard list filter. + # @!attribute [rw] page_size + # @return [::Integer] + # The standard list page size. + # @!attribute [rw] page_token + # @return [::String] + # The standard list page token. + class ListOperationsRequest + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + end + + # The response message for Operations.ListOperations. + # @!attribute [rw] operations + # @return [::Array<::Google::Longrunning::Operation>] + # A list of operations that matches the specified filter in the request. + # @!attribute [rw] next_page_token + # @return [::String] + # The standard List next-page token. + class ListOperationsResponse + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + end + + # The request message for Operations.CancelOperation. + # @!attribute [rw] name + # @return [::String] + # The name of the operation resource to be cancelled. + class CancelOperationRequest + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + end + + # The request message for Operations.DeleteOperation. + # @!attribute [rw] name + # @return [::String] + # The name of the operation resource to be deleted. + class DeleteOperationRequest + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + end + + # The request message for Operations.WaitOperation. + # @!attribute [rw] name + # @return [::String] + # The name of the operation resource to wait on. + # @!attribute [rw] timeout + # @return [::Google::Protobuf::Duration] + # The maximum duration to wait before timing out. If left blank, the wait + # will be at most the time permitted by the underlying HTTP/RPC protocol. + # If RPC context deadline is also specified, the shorter one will be used. + class WaitOperationRequest + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + end + + # A message representing the message types used by a long-running operation. + # + # Example: + # + # rpc LongRunningRecognize(LongRunningRecognizeRequest) + # returns (google.longrunning.Operation) { + # option (google.longrunning.operation_info) = { + # response_type: "LongRunningRecognizeResponse" + # metadata_type: "LongRunningRecognizeMetadata" + # }; + # } + # @!attribute [rw] response_type + # @return [::String] + # Required. The message name of the primary return type for this + # long-running operation. + # This type will be used to deserialize the LRO's response. + # + # If the response is in a different package from the rpc, a fully-qualified + # message name must be used (e.g. `google.protobuf.Struct`). + # + # Note: Altering this value constitutes a breaking change. + # @!attribute [rw] metadata_type + # @return [::String] + # Required. The message name of the metadata type for this long-running + # operation. + # + # If the response is in a different package from the rpc, a fully-qualified + # message name must be used (e.g. `google.protobuf.Struct`). + # + # Note: Altering this value constitutes a breaking change. + class OperationInfo + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + end + end +end diff --git a/google-cloud-oracle_database-v1/proto_docs/google/protobuf/any.rb b/google-cloud-oracle_database-v1/proto_docs/google/protobuf/any.rb new file mode 100644 index 000000000000..fb4d6862eac9 --- /dev/null +++ b/google-cloud-oracle_database-v1/proto_docs/google/protobuf/any.rb @@ -0,0 +1,145 @@ +# frozen_string_literal: true + +# Copyright 2024 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# https://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Auto-generated by gapic-generator-ruby. DO NOT EDIT! + + +module Google + module Protobuf + # `Any` contains an arbitrary serialized protocol buffer message along with a + # URL that describes the type of the serialized message. + # + # Protobuf library provides support to pack/unpack Any values in the form + # of utility functions or additional generated methods of the Any type. + # + # Example 1: Pack and unpack a message in C++. + # + # Foo foo = ...; + # Any any; + # any.PackFrom(foo); + # ... + # if (any.UnpackTo(&foo)) { + # ... + # } + # + # Example 2: Pack and unpack a message in Java. + # + # Foo foo = ...; + # Any any = Any.pack(foo); + # ... + # if (any.is(Foo.class)) { + # foo = any.unpack(Foo.class); + # } + # // or ... + # if (any.isSameTypeAs(Foo.getDefaultInstance())) { + # foo = any.unpack(Foo.getDefaultInstance()); + # } + # + # Example 3: Pack and unpack a message in Python. + # + # foo = Foo(...) + # any = Any() + # any.Pack(foo) + # ... + # if any.Is(Foo.DESCRIPTOR): + # any.Unpack(foo) + # ... + # + # Example 4: Pack and unpack a message in Go + # + # foo := &pb.Foo{...} + # any, err := anypb.New(foo) + # if err != nil { + # ... + # } + # ... + # foo := &pb.Foo{} + # if err := any.UnmarshalTo(foo); err != nil { + # ... + # } + # + # The pack methods provided by protobuf library will by default use + # 'type.googleapis.com/full.type.name' as the type URL and the unpack + # methods only use the fully qualified type name after the last '/' + # in the type URL, for example "foo.bar.com/x/y.z" will yield type + # name "y.z". + # + # JSON + # ==== + # The JSON representation of an `Any` value uses the regular + # representation of the deserialized, embedded message, with an + # additional field `@type` which contains the type URL. Example: + # + # package google.profile; + # message Person { + # string first_name = 1; + # string last_name = 2; + # } + # + # { + # "@type": "type.googleapis.com/google.profile.Person", + # "firstName": , + # "lastName": + # } + # + # If the embedded message type is well-known and has a custom JSON + # representation, that representation will be embedded adding a field + # `value` which holds the custom JSON in addition to the `@type` + # field. Example (for message [google.protobuf.Duration][]): + # + # { + # "@type": "type.googleapis.com/google.protobuf.Duration", + # "value": "1.212s" + # } + # @!attribute [rw] type_url + # @return [::String] + # A URL/resource name that uniquely identifies the type of the serialized + # protocol buffer message. This string must contain at least + # one "/" character. The last segment of the URL's path must represent + # the fully qualified name of the type (as in + # `path/google.protobuf.Duration`). The name should be in a canonical form + # (e.g., leading "." is not accepted). + # + # In practice, teams usually precompile into the binary all types that they + # expect it to use in the context of Any. However, for URLs which use the + # scheme `http`, `https`, or no scheme, one can optionally set up a type + # server that maps type URLs to message definitions as follows: + # + # * If no scheme is provided, `https` is assumed. + # * An HTTP GET on the URL must yield a [google.protobuf.Type][] + # value in binary format, or produce an error. + # * Applications are allowed to cache lookup results based on the + # URL, or have them precompiled into a binary to avoid any + # lookup. Therefore, binary compatibility needs to be preserved + # on changes to types. (Use versioned type names to manage + # breaking changes.) + # + # Note: this functionality is not currently available in the official + # protobuf release, and it is not used for type URLs beginning with + # type.googleapis.com. As of May 2023, there are no widely used type server + # implementations and no plans to implement one. + # + # Schemes other than `http`, `https` (or the empty scheme) might be + # used with implementation specific semantics. + # @!attribute [rw] value + # @return [::String] + # Must be a valid serialized protocol buffer of the above specified type. + class Any + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + end + end +end diff --git a/google-cloud-oracle_database-v1/proto_docs/google/protobuf/duration.rb b/google-cloud-oracle_database-v1/proto_docs/google/protobuf/duration.rb new file mode 100644 index 000000000000..b5731a824060 --- /dev/null +++ b/google-cloud-oracle_database-v1/proto_docs/google/protobuf/duration.rb @@ -0,0 +1,98 @@ +# frozen_string_literal: true + +# Copyright 2024 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# https://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Auto-generated by gapic-generator-ruby. DO NOT EDIT! + + +module Google + module Protobuf + # A Duration represents a signed, fixed-length span of time represented + # as a count of seconds and fractions of seconds at nanosecond + # resolution. It is independent of any calendar and concepts like "day" + # or "month". It is related to Timestamp in that the difference between + # two Timestamp values is a Duration and it can be added or subtracted + # from a Timestamp. Range is approximately +-10,000 years. + # + # # Examples + # + # Example 1: Compute Duration from two Timestamps in pseudo code. + # + # Timestamp start = ...; + # Timestamp end = ...; + # Duration duration = ...; + # + # duration.seconds = end.seconds - start.seconds; + # duration.nanos = end.nanos - start.nanos; + # + # if (duration.seconds < 0 && duration.nanos > 0) { + # duration.seconds += 1; + # duration.nanos -= 1000000000; + # } else if (duration.seconds > 0 && duration.nanos < 0) { + # duration.seconds -= 1; + # duration.nanos += 1000000000; + # } + # + # Example 2: Compute Timestamp from Timestamp + Duration in pseudo code. + # + # Timestamp start = ...; + # Duration duration = ...; + # Timestamp end = ...; + # + # end.seconds = start.seconds + duration.seconds; + # end.nanos = start.nanos + duration.nanos; + # + # if (end.nanos < 0) { + # end.seconds -= 1; + # end.nanos += 1000000000; + # } else if (end.nanos >= 1000000000) { + # end.seconds += 1; + # end.nanos -= 1000000000; + # } + # + # Example 3: Compute Duration from datetime.timedelta in Python. + # + # td = datetime.timedelta(days=3, minutes=10) + # duration = Duration() + # duration.FromTimedelta(td) + # + # # JSON Mapping + # + # In JSON format, the Duration type is encoded as a string rather than an + # object, where the string ends in the suffix "s" (indicating seconds) and + # is preceded by the number of seconds, with nanoseconds expressed as + # fractional seconds. For example, 3 seconds with 0 nanoseconds should be + # encoded in JSON format as "3s", while 3 seconds and 1 nanosecond should + # be expressed in JSON format as "3.000000001s", and 3 seconds and 1 + # microsecond should be expressed in JSON format as "3.000001s". + # @!attribute [rw] seconds + # @return [::Integer] + # Signed seconds of the span of time. Must be from -315,576,000,000 + # to +315,576,000,000 inclusive. Note: these bounds are computed from: + # 60 sec/min * 60 min/hr * 24 hr/day * 365.25 days/year * 10000 years + # @!attribute [rw] nanos + # @return [::Integer] + # Signed fractions of a second at nanosecond resolution of the span + # of time. Durations less than one second are represented with a 0 + # `seconds` field and a positive or negative `nanos` field. For durations + # of one second or more, a non-zero value for the `nanos` field must be + # of the same sign as the `seconds` field. Must be from -999,999,999 + # to +999,999,999 inclusive. + class Duration + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + end + end +end diff --git a/google-cloud-oracle_database-v1/proto_docs/google/protobuf/empty.rb b/google-cloud-oracle_database-v1/proto_docs/google/protobuf/empty.rb new file mode 100644 index 000000000000..8c6b19d52e3d --- /dev/null +++ b/google-cloud-oracle_database-v1/proto_docs/google/protobuf/empty.rb @@ -0,0 +1,34 @@ +# frozen_string_literal: true + +# Copyright 2024 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# https://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Auto-generated by gapic-generator-ruby. DO NOT EDIT! + + +module Google + module Protobuf + # A generic empty message that you can re-use to avoid defining duplicated + # empty messages in your APIs. A typical example is to use it as the request + # or the response type of an API method. For instance: + # + # service Foo { + # rpc Bar(google.protobuf.Empty) returns (google.protobuf.Empty); + # } + class Empty + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + end + end +end diff --git a/google-cloud-oracle_database-v1/proto_docs/google/protobuf/timestamp.rb b/google-cloud-oracle_database-v1/proto_docs/google/protobuf/timestamp.rb new file mode 100644 index 000000000000..4ac9c4801a3f --- /dev/null +++ b/google-cloud-oracle_database-v1/proto_docs/google/protobuf/timestamp.rb @@ -0,0 +1,127 @@ +# frozen_string_literal: true + +# Copyright 2024 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# https://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Auto-generated by gapic-generator-ruby. DO NOT EDIT! + + +module Google + module Protobuf + # A Timestamp represents a point in time independent of any time zone or local + # calendar, encoded as a count of seconds and fractions of seconds at + # nanosecond resolution. The count is relative to an epoch at UTC midnight on + # January 1, 1970, in the proleptic Gregorian calendar which extends the + # Gregorian calendar backwards to year one. + # + # All minutes are 60 seconds long. Leap seconds are "smeared" so that no leap + # second table is needed for interpretation, using a [24-hour linear + # smear](https://developers.google.com/time/smear). + # + # The range is from 0001-01-01T00:00:00Z to 9999-12-31T23:59:59.999999999Z. By + # restricting to that range, we ensure that we can convert to and from [RFC + # 3339](https://www.ietf.org/rfc/rfc3339.txt) date strings. + # + # # Examples + # + # Example 1: Compute Timestamp from POSIX `time()`. + # + # Timestamp timestamp; + # timestamp.set_seconds(time(NULL)); + # timestamp.set_nanos(0); + # + # Example 2: Compute Timestamp from POSIX `gettimeofday()`. + # + # struct timeval tv; + # gettimeofday(&tv, NULL); + # + # Timestamp timestamp; + # timestamp.set_seconds(tv.tv_sec); + # timestamp.set_nanos(tv.tv_usec * 1000); + # + # Example 3: Compute Timestamp from Win32 `GetSystemTimeAsFileTime()`. + # + # FILETIME ft; + # GetSystemTimeAsFileTime(&ft); + # UINT64 ticks = (((UINT64)ft.dwHighDateTime) << 32) | ft.dwLowDateTime; + # + # // A Windows tick is 100 nanoseconds. Windows epoch 1601-01-01T00:00:00Z + # // is 11644473600 seconds before Unix epoch 1970-01-01T00:00:00Z. + # Timestamp timestamp; + # timestamp.set_seconds((INT64) ((ticks / 10000000) - 11644473600LL)); + # timestamp.set_nanos((INT32) ((ticks % 10000000) * 100)); + # + # Example 4: Compute Timestamp from Java `System.currentTimeMillis()`. + # + # long millis = System.currentTimeMillis(); + # + # Timestamp timestamp = Timestamp.newBuilder().setSeconds(millis / 1000) + # .setNanos((int) ((millis % 1000) * 1000000)).build(); + # + # Example 5: Compute Timestamp from Java `Instant.now()`. + # + # Instant now = Instant.now(); + # + # Timestamp timestamp = + # Timestamp.newBuilder().setSeconds(now.getEpochSecond()) + # .setNanos(now.getNano()).build(); + # + # Example 6: Compute Timestamp from current time in Python. + # + # timestamp = Timestamp() + # timestamp.GetCurrentTime() + # + # # JSON Mapping + # + # In JSON format, the Timestamp type is encoded as a string in the + # [RFC 3339](https://www.ietf.org/rfc/rfc3339.txt) format. That is, the + # format is "\\{year}-\\{month}-\\{day}T\\{hour}:\\{min}:\\{sec}[.\\{frac_sec}]Z" + # where \\{year} is always expressed using four digits while \\{month}, \\{day}, + # \\{hour}, \\{min}, and \\{sec} are zero-padded to two digits each. The fractional + # seconds, which can go up to 9 digits (i.e. up to 1 nanosecond resolution), + # are optional. The "Z" suffix indicates the timezone ("UTC"); the timezone + # is required. A proto3 JSON serializer should always use UTC (as indicated by + # "Z") when printing the Timestamp type and a proto3 JSON parser should be + # able to accept both UTC and other timezones (as indicated by an offset). + # + # For example, "2017-01-15T01:30:15.01Z" encodes 15.01 seconds past + # 01:30 UTC on January 15, 2017. + # + # In JavaScript, one can convert a Date object to this format using the + # standard + # [toISOString()](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date/toISOString) + # method. In Python, a standard `datetime.datetime` object can be converted + # to this format using + # [`strftime`](https://docs.python.org/2/library/time.html#time.strftime) with + # the time format spec '%Y-%m-%dT%H:%M:%S.%fZ'. Likewise, in Java, one can use + # the Joda Time's [`ISODateTimeFormat.dateTime()`]( + # http://joda-time.sourceforge.net/apidocs/org/joda/time/format/ISODateTimeFormat.html#dateTime() + # ) to obtain a formatter capable of generating timestamps in this format. + # @!attribute [rw] seconds + # @return [::Integer] + # Represents seconds of UTC time since Unix epoch + # 1970-01-01T00:00:00Z. Must be from 0001-01-01T00:00:00Z to + # 9999-12-31T23:59:59Z inclusive. + # @!attribute [rw] nanos + # @return [::Integer] + # Non-negative fractions of a second at nanosecond resolution. Negative + # second values with fractions must still have non-negative nanos values + # that count forward in time. Must be from 0 to 999,999,999 + # inclusive. + class Timestamp + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + end + end +end diff --git a/google-cloud-oracle_database-v1/proto_docs/google/rpc/status.rb b/google-cloud-oracle_database-v1/proto_docs/google/rpc/status.rb new file mode 100644 index 000000000000..09acc69b6125 --- /dev/null +++ b/google-cloud-oracle_database-v1/proto_docs/google/rpc/status.rb @@ -0,0 +1,48 @@ +# frozen_string_literal: true + +# Copyright 2024 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# https://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Auto-generated by gapic-generator-ruby. DO NOT EDIT! + + +module Google + module Rpc + # The `Status` type defines a logical error model that is suitable for + # different programming environments, including REST APIs and RPC APIs. It is + # used by [gRPC](https://github.com/grpc). Each `Status` message contains + # three pieces of data: error code, error message, and error details. + # + # You can find out more about this error model and how to work with it in the + # [API Design Guide](https://cloud.google.com/apis/design/errors). + # @!attribute [rw] code + # @return [::Integer] + # The status code, which should be an enum value of + # [google.rpc.Code][google.rpc.Code]. + # @!attribute [rw] message + # @return [::String] + # A developer-facing error message, which should be in English. Any + # user-facing error message should be localized and sent in the + # {::Google::Rpc::Status#details google.rpc.Status.details} field, or localized + # by the client. + # @!attribute [rw] details + # @return [::Array<::Google::Protobuf::Any>] + # A list of messages that carry the error details. There is a common set of + # message types for APIs to use. + class Status + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + end + end +end diff --git a/google-cloud-oracle_database-v1/proto_docs/google/type/datetime.rb b/google-cloud-oracle_database-v1/proto_docs/google/type/datetime.rb new file mode 100644 index 000000000000..7be9d37b7d84 --- /dev/null +++ b/google-cloud-oracle_database-v1/proto_docs/google/type/datetime.rb @@ -0,0 +1,99 @@ +# frozen_string_literal: true + +# Copyright 2024 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# https://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Auto-generated by gapic-generator-ruby. DO NOT EDIT! + + +module Google + module Type + # Represents civil time (or occasionally physical time). + # + # This type can represent a civil time in one of a few possible ways: + # + # * When utc_offset is set and time_zone is unset: a civil time on a calendar + # day with a particular offset from UTC. + # * When time_zone is set and utc_offset is unset: a civil time on a calendar + # day in a particular time zone. + # * When neither time_zone nor utc_offset is set: a civil time on a calendar + # day in local time. + # + # The date is relative to the Proleptic Gregorian Calendar. + # + # If year is 0, the DateTime is considered not to have a specific year. month + # and day must have valid, non-zero values. + # + # This type may also be used to represent a physical time if all the date and + # time fields are set and either case of the `time_offset` oneof is set. + # Consider using `Timestamp` message for physical time instead. If your use + # case also would like to store the user's timezone, that can be done in + # another field. + # + # This type is more flexible than some applications may want. Make sure to + # document and validate your application's limitations. + # @!attribute [rw] year + # @return [::Integer] + # Optional. Year of date. Must be from 1 to 9999, or 0 if specifying a + # datetime without a year. + # @!attribute [rw] month + # @return [::Integer] + # Required. Month of year. Must be from 1 to 12. + # @!attribute [rw] day + # @return [::Integer] + # Required. Day of month. Must be from 1 to 31 and valid for the year and + # month. + # @!attribute [rw] hours + # @return [::Integer] + # Required. Hours of day in 24 hour format. Should be from 0 to 23. An API + # may choose to allow the value "24:00:00" for scenarios like business + # closing time. + # @!attribute [rw] minutes + # @return [::Integer] + # Required. Minutes of hour of day. Must be from 0 to 59. + # @!attribute [rw] seconds + # @return [::Integer] + # Required. Seconds of minutes of the time. Must normally be from 0 to 59. An + # API may allow the value 60 if it allows leap-seconds. + # @!attribute [rw] nanos + # @return [::Integer] + # Required. Fractions of seconds in nanoseconds. Must be from 0 to + # 999,999,999. + # @!attribute [rw] utc_offset + # @return [::Google::Protobuf::Duration] + # UTC offset. Must be whole seconds, between -18 hours and +18 hours. + # For example, a UTC offset of -4:00 would be represented as + # { seconds: -14400 }. + # @!attribute [rw] time_zone + # @return [::Google::Type::TimeZone] + # Time zone. + class DateTime + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + end + + # Represents a time zone from the + # [IANA Time Zone Database](https://www.iana.org/time-zones). + # @!attribute [rw] id + # @return [::String] + # IANA Time Zone Database time zone, e.g. "America/New_York". + # @!attribute [rw] version + # @return [::String] + # Optional. IANA Time Zone Database version number, e.g. "2019a". + class TimeZone + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + end + end +end diff --git a/google-cloud-oracle_database-v1/proto_docs/google/type/dayofweek.rb b/google-cloud-oracle_database-v1/proto_docs/google/type/dayofweek.rb new file mode 100644 index 000000000000..4fd080d9b331 --- /dev/null +++ b/google-cloud-oracle_database-v1/proto_docs/google/type/dayofweek.rb @@ -0,0 +1,49 @@ +# frozen_string_literal: true + +# Copyright 2024 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# https://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Auto-generated by gapic-generator-ruby. DO NOT EDIT! + + +module Google + module Type + # Represents a day of the week. + module DayOfWeek + # The day of the week is unspecified. + DAY_OF_WEEK_UNSPECIFIED = 0 + + # Monday + MONDAY = 1 + + # Tuesday + TUESDAY = 2 + + # Wednesday + WEDNESDAY = 3 + + # Thursday + THURSDAY = 4 + + # Friday + FRIDAY = 5 + + # Saturday + SATURDAY = 6 + + # Sunday + SUNDAY = 7 + end + end +end diff --git a/google-cloud-oracle_database-v1/proto_docs/google/type/month.rb b/google-cloud-oracle_database-v1/proto_docs/google/type/month.rb new file mode 100644 index 000000000000..17a31b7f2e22 --- /dev/null +++ b/google-cloud-oracle_database-v1/proto_docs/google/type/month.rb @@ -0,0 +1,64 @@ +# frozen_string_literal: true + +# Copyright 2024 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# https://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Auto-generated by gapic-generator-ruby. DO NOT EDIT! + + +module Google + module Type + # Represents a month in the Gregorian calendar. + module Month + # The unspecified month. + MONTH_UNSPECIFIED = 0 + + # The month of January. + JANUARY = 1 + + # The month of February. + FEBRUARY = 2 + + # The month of March. + MARCH = 3 + + # The month of April. + APRIL = 4 + + # The month of May. + MAY = 5 + + # The month of June. + JUNE = 6 + + # The month of July. + JULY = 7 + + # The month of August. + AUGUST = 8 + + # The month of September. + SEPTEMBER = 9 + + # The month of October. + OCTOBER = 10 + + # The month of November. + NOVEMBER = 11 + + # The month of December. + DECEMBER = 12 + end + end +end diff --git a/google-cloud-oracle_database-v1/proto_docs/google/type/timeofday.rb b/google-cloud-oracle_database-v1/proto_docs/google/type/timeofday.rb new file mode 100644 index 000000000000..dcbd7c6bd3f8 --- /dev/null +++ b/google-cloud-oracle_database-v1/proto_docs/google/type/timeofday.rb @@ -0,0 +1,45 @@ +# frozen_string_literal: true + +# Copyright 2024 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# https://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Auto-generated by gapic-generator-ruby. DO NOT EDIT! + + +module Google + module Type + # Represents a time of day. The date and time zone are either not significant + # or are specified elsewhere. An API may choose to allow leap seconds. Related + # types are [google.type.Date][google.type.Date] and + # `google.protobuf.Timestamp`. + # @!attribute [rw] hours + # @return [::Integer] + # Hours of day in 24 hour format. Should be from 0 to 23. An API may choose + # to allow the value "24:00:00" for scenarios like business closing time. + # @!attribute [rw] minutes + # @return [::Integer] + # Minutes of hour of day. Must be from 0 to 59. + # @!attribute [rw] seconds + # @return [::Integer] + # Seconds of minutes of the time. Must normally be from 0 to 59. An API may + # allow the value 60 if it allows leap-seconds. + # @!attribute [rw] nanos + # @return [::Integer] + # Fractions of seconds in nanoseconds. Must be from 0 to 999,999,999. + class TimeOfDay + include ::Google::Protobuf::MessageExts + extend ::Google::Protobuf::MessageExts::ClassMethods + end + end +end diff --git a/google-cloud-oracle_database-v1/snippets/Gemfile b/google-cloud-oracle_database-v1/snippets/Gemfile new file mode 100644 index 000000000000..c755f3e1b017 --- /dev/null +++ b/google-cloud-oracle_database-v1/snippets/Gemfile @@ -0,0 +1,32 @@ +# frozen_string_literal: true + +# Copyright 2024 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# https://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Auto-generated by gapic-generator-ruby. DO NOT EDIT! + +source "https://rubygems.org" + +if ENV["GOOGLE_CLOUD_SAMPLES_TEST"] == "master" + gem "google-cloud-oracle_database-v1", path: "../" +else + gem "google-cloud-oracle_database-v1" +end + +group :test do + gem "google-style", "~> 1.26.1" + gem "minitest", "~> 5.16" + gem "minitest-focus", "~> 1.1" + gem "minitest-hooks", "~> 1.5" +end diff --git a/google-cloud-oracle_database-v1/snippets/oracle_database/create_autonomous_database.rb b/google-cloud-oracle_database-v1/snippets/oracle_database/create_autonomous_database.rb new file mode 100644 index 000000000000..a7cf5f03901f --- /dev/null +++ b/google-cloud-oracle_database-v1/snippets/oracle_database/create_autonomous_database.rb @@ -0,0 +1,54 @@ +# frozen_string_literal: true + +# Copyright 2024 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# https://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Auto-generated by gapic-generator-ruby. DO NOT EDIT! + +# [START oracledatabase_v1_generated_OracleDatabase_CreateAutonomousDatabase_sync] +require "google/cloud/oracle_database/v1" + +## +# Snippet for the create_autonomous_database call in the OracleDatabase service +# +# This snippet has been automatically generated and should be regarded as a code +# template only. It will require modifications to work: +# - It may require correct/in-range values for request initialization. +# - It may require specifying regional endpoints when creating the service +# client as shown in https://cloud.google.com/ruby/docs/reference. +# +# This is an auto-generated example demonstrating basic usage of +# Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::Client#create_autonomous_database. +# +def create_autonomous_database + # Create a client object. The client can be reused for multiple calls. + client = Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::Client.new + + # Create a request. To set request fields, pass in keyword arguments. + request = Google::Cloud::OracleDatabase::V1::CreateAutonomousDatabaseRequest.new + + # Call the create_autonomous_database method. + result = client.create_autonomous_database request + + # The returned object is of type Gapic::Operation. You can use it to + # check the status of an operation, cancel it, or wait for results. + # Here is how to wait for a response. + result.wait_until_done! timeout: 60 + if result.response? + p result.response + else + puts "No response received." + end +end +# [END oracledatabase_v1_generated_OracleDatabase_CreateAutonomousDatabase_sync] diff --git a/google-cloud-oracle_database-v1/snippets/oracle_database/create_cloud_exadata_infrastructure.rb b/google-cloud-oracle_database-v1/snippets/oracle_database/create_cloud_exadata_infrastructure.rb new file mode 100644 index 000000000000..36561e448f8f --- /dev/null +++ b/google-cloud-oracle_database-v1/snippets/oracle_database/create_cloud_exadata_infrastructure.rb @@ -0,0 +1,54 @@ +# frozen_string_literal: true + +# Copyright 2024 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# https://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Auto-generated by gapic-generator-ruby. DO NOT EDIT! + +# [START oracledatabase_v1_generated_OracleDatabase_CreateCloudExadataInfrastructure_sync] +require "google/cloud/oracle_database/v1" + +## +# Snippet for the create_cloud_exadata_infrastructure call in the OracleDatabase service +# +# This snippet has been automatically generated and should be regarded as a code +# template only. It will require modifications to work: +# - It may require correct/in-range values for request initialization. +# - It may require specifying regional endpoints when creating the service +# client as shown in https://cloud.google.com/ruby/docs/reference. +# +# This is an auto-generated example demonstrating basic usage of +# Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::Client#create_cloud_exadata_infrastructure. +# +def create_cloud_exadata_infrastructure + # Create a client object. The client can be reused for multiple calls. + client = Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::Client.new + + # Create a request. To set request fields, pass in keyword arguments. + request = Google::Cloud::OracleDatabase::V1::CreateCloudExadataInfrastructureRequest.new + + # Call the create_cloud_exadata_infrastructure method. + result = client.create_cloud_exadata_infrastructure request + + # The returned object is of type Gapic::Operation. You can use it to + # check the status of an operation, cancel it, or wait for results. + # Here is how to wait for a response. + result.wait_until_done! timeout: 60 + if result.response? + p result.response + else + puts "No response received." + end +end +# [END oracledatabase_v1_generated_OracleDatabase_CreateCloudExadataInfrastructure_sync] diff --git a/google-cloud-oracle_database-v1/snippets/oracle_database/create_cloud_vm_cluster.rb b/google-cloud-oracle_database-v1/snippets/oracle_database/create_cloud_vm_cluster.rb new file mode 100644 index 000000000000..35d158c27c85 --- /dev/null +++ b/google-cloud-oracle_database-v1/snippets/oracle_database/create_cloud_vm_cluster.rb @@ -0,0 +1,54 @@ +# frozen_string_literal: true + +# Copyright 2024 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# https://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Auto-generated by gapic-generator-ruby. DO NOT EDIT! + +# [START oracledatabase_v1_generated_OracleDatabase_CreateCloudVmCluster_sync] +require "google/cloud/oracle_database/v1" + +## +# Snippet for the create_cloud_vm_cluster call in the OracleDatabase service +# +# This snippet has been automatically generated and should be regarded as a code +# template only. It will require modifications to work: +# - It may require correct/in-range values for request initialization. +# - It may require specifying regional endpoints when creating the service +# client as shown in https://cloud.google.com/ruby/docs/reference. +# +# This is an auto-generated example demonstrating basic usage of +# Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::Client#create_cloud_vm_cluster. +# +def create_cloud_vm_cluster + # Create a client object. The client can be reused for multiple calls. + client = Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::Client.new + + # Create a request. To set request fields, pass in keyword arguments. + request = Google::Cloud::OracleDatabase::V1::CreateCloudVmClusterRequest.new + + # Call the create_cloud_vm_cluster method. + result = client.create_cloud_vm_cluster request + + # The returned object is of type Gapic::Operation. You can use it to + # check the status of an operation, cancel it, or wait for results. + # Here is how to wait for a response. + result.wait_until_done! timeout: 60 + if result.response? + p result.response + else + puts "No response received." + end +end +# [END oracledatabase_v1_generated_OracleDatabase_CreateCloudVmCluster_sync] diff --git a/google-cloud-oracle_database-v1/snippets/oracle_database/delete_autonomous_database.rb b/google-cloud-oracle_database-v1/snippets/oracle_database/delete_autonomous_database.rb new file mode 100644 index 000000000000..2e276329cbd4 --- /dev/null +++ b/google-cloud-oracle_database-v1/snippets/oracle_database/delete_autonomous_database.rb @@ -0,0 +1,54 @@ +# frozen_string_literal: true + +# Copyright 2024 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# https://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Auto-generated by gapic-generator-ruby. DO NOT EDIT! + +# [START oracledatabase_v1_generated_OracleDatabase_DeleteAutonomousDatabase_sync] +require "google/cloud/oracle_database/v1" + +## +# Snippet for the delete_autonomous_database call in the OracleDatabase service +# +# This snippet has been automatically generated and should be regarded as a code +# template only. It will require modifications to work: +# - It may require correct/in-range values for request initialization. +# - It may require specifying regional endpoints when creating the service +# client as shown in https://cloud.google.com/ruby/docs/reference. +# +# This is an auto-generated example demonstrating basic usage of +# Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::Client#delete_autonomous_database. +# +def delete_autonomous_database + # Create a client object. The client can be reused for multiple calls. + client = Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::Client.new + + # Create a request. To set request fields, pass in keyword arguments. + request = Google::Cloud::OracleDatabase::V1::DeleteAutonomousDatabaseRequest.new + + # Call the delete_autonomous_database method. + result = client.delete_autonomous_database request + + # The returned object is of type Gapic::Operation. You can use it to + # check the status of an operation, cancel it, or wait for results. + # Here is how to wait for a response. + result.wait_until_done! timeout: 60 + if result.response? + p result.response + else + puts "No response received." + end +end +# [END oracledatabase_v1_generated_OracleDatabase_DeleteAutonomousDatabase_sync] diff --git a/google-cloud-oracle_database-v1/snippets/oracle_database/delete_cloud_exadata_infrastructure.rb b/google-cloud-oracle_database-v1/snippets/oracle_database/delete_cloud_exadata_infrastructure.rb new file mode 100644 index 000000000000..622611a73287 --- /dev/null +++ b/google-cloud-oracle_database-v1/snippets/oracle_database/delete_cloud_exadata_infrastructure.rb @@ -0,0 +1,54 @@ +# frozen_string_literal: true + +# Copyright 2024 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# https://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Auto-generated by gapic-generator-ruby. DO NOT EDIT! + +# [START oracledatabase_v1_generated_OracleDatabase_DeleteCloudExadataInfrastructure_sync] +require "google/cloud/oracle_database/v1" + +## +# Snippet for the delete_cloud_exadata_infrastructure call in the OracleDatabase service +# +# This snippet has been automatically generated and should be regarded as a code +# template only. It will require modifications to work: +# - It may require correct/in-range values for request initialization. +# - It may require specifying regional endpoints when creating the service +# client as shown in https://cloud.google.com/ruby/docs/reference. +# +# This is an auto-generated example demonstrating basic usage of +# Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::Client#delete_cloud_exadata_infrastructure. +# +def delete_cloud_exadata_infrastructure + # Create a client object. The client can be reused for multiple calls. + client = Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::Client.new + + # Create a request. To set request fields, pass in keyword arguments. + request = Google::Cloud::OracleDatabase::V1::DeleteCloudExadataInfrastructureRequest.new + + # Call the delete_cloud_exadata_infrastructure method. + result = client.delete_cloud_exadata_infrastructure request + + # The returned object is of type Gapic::Operation. You can use it to + # check the status of an operation, cancel it, or wait for results. + # Here is how to wait for a response. + result.wait_until_done! timeout: 60 + if result.response? + p result.response + else + puts "No response received." + end +end +# [END oracledatabase_v1_generated_OracleDatabase_DeleteCloudExadataInfrastructure_sync] diff --git a/google-cloud-oracle_database-v1/snippets/oracle_database/delete_cloud_vm_cluster.rb b/google-cloud-oracle_database-v1/snippets/oracle_database/delete_cloud_vm_cluster.rb new file mode 100644 index 000000000000..63971591d9ad --- /dev/null +++ b/google-cloud-oracle_database-v1/snippets/oracle_database/delete_cloud_vm_cluster.rb @@ -0,0 +1,54 @@ +# frozen_string_literal: true + +# Copyright 2024 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# https://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Auto-generated by gapic-generator-ruby. DO NOT EDIT! + +# [START oracledatabase_v1_generated_OracleDatabase_DeleteCloudVmCluster_sync] +require "google/cloud/oracle_database/v1" + +## +# Snippet for the delete_cloud_vm_cluster call in the OracleDatabase service +# +# This snippet has been automatically generated and should be regarded as a code +# template only. It will require modifications to work: +# - It may require correct/in-range values for request initialization. +# - It may require specifying regional endpoints when creating the service +# client as shown in https://cloud.google.com/ruby/docs/reference. +# +# This is an auto-generated example demonstrating basic usage of +# Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::Client#delete_cloud_vm_cluster. +# +def delete_cloud_vm_cluster + # Create a client object. The client can be reused for multiple calls. + client = Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::Client.new + + # Create a request. To set request fields, pass in keyword arguments. + request = Google::Cloud::OracleDatabase::V1::DeleteCloudVmClusterRequest.new + + # Call the delete_cloud_vm_cluster method. + result = client.delete_cloud_vm_cluster request + + # The returned object is of type Gapic::Operation. You can use it to + # check the status of an operation, cancel it, or wait for results. + # Here is how to wait for a response. + result.wait_until_done! timeout: 60 + if result.response? + p result.response + else + puts "No response received." + end +end +# [END oracledatabase_v1_generated_OracleDatabase_DeleteCloudVmCluster_sync] diff --git a/google-cloud-oracle_database-v1/snippets/oracle_database/generate_autonomous_database_wallet.rb b/google-cloud-oracle_database-v1/snippets/oracle_database/generate_autonomous_database_wallet.rb new file mode 100644 index 000000000000..b120d86ed959 --- /dev/null +++ b/google-cloud-oracle_database-v1/snippets/oracle_database/generate_autonomous_database_wallet.rb @@ -0,0 +1,47 @@ +# frozen_string_literal: true + +# Copyright 2024 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# https://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Auto-generated by gapic-generator-ruby. DO NOT EDIT! + +# [START oracledatabase_v1_generated_OracleDatabase_GenerateAutonomousDatabaseWallet_sync] +require "google/cloud/oracle_database/v1" + +## +# Snippet for the generate_autonomous_database_wallet call in the OracleDatabase service +# +# This snippet has been automatically generated and should be regarded as a code +# template only. It will require modifications to work: +# - It may require correct/in-range values for request initialization. +# - It may require specifying regional endpoints when creating the service +# client as shown in https://cloud.google.com/ruby/docs/reference. +# +# This is an auto-generated example demonstrating basic usage of +# Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::Client#generate_autonomous_database_wallet. +# +def generate_autonomous_database_wallet + # Create a client object. The client can be reused for multiple calls. + client = Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::Client.new + + # Create a request. To set request fields, pass in keyword arguments. + request = Google::Cloud::OracleDatabase::V1::GenerateAutonomousDatabaseWalletRequest.new + + # Call the generate_autonomous_database_wallet method. + result = client.generate_autonomous_database_wallet request + + # The returned object is of type Google::Cloud::OracleDatabase::V1::GenerateAutonomousDatabaseWalletResponse. + p result +end +# [END oracledatabase_v1_generated_OracleDatabase_GenerateAutonomousDatabaseWallet_sync] diff --git a/google-cloud-oracle_database-v1/snippets/oracle_database/get_autonomous_database.rb b/google-cloud-oracle_database-v1/snippets/oracle_database/get_autonomous_database.rb new file mode 100644 index 000000000000..52c50c905f52 --- /dev/null +++ b/google-cloud-oracle_database-v1/snippets/oracle_database/get_autonomous_database.rb @@ -0,0 +1,47 @@ +# frozen_string_literal: true + +# Copyright 2024 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# https://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Auto-generated by gapic-generator-ruby. DO NOT EDIT! + +# [START oracledatabase_v1_generated_OracleDatabase_GetAutonomousDatabase_sync] +require "google/cloud/oracle_database/v1" + +## +# Snippet for the get_autonomous_database call in the OracleDatabase service +# +# This snippet has been automatically generated and should be regarded as a code +# template only. It will require modifications to work: +# - It may require correct/in-range values for request initialization. +# - It may require specifying regional endpoints when creating the service +# client as shown in https://cloud.google.com/ruby/docs/reference. +# +# This is an auto-generated example demonstrating basic usage of +# Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::Client#get_autonomous_database. +# +def get_autonomous_database + # Create a client object. The client can be reused for multiple calls. + client = Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::Client.new + + # Create a request. To set request fields, pass in keyword arguments. + request = Google::Cloud::OracleDatabase::V1::GetAutonomousDatabaseRequest.new + + # Call the get_autonomous_database method. + result = client.get_autonomous_database request + + # The returned object is of type Google::Cloud::OracleDatabase::V1::AutonomousDatabase. + p result +end +# [END oracledatabase_v1_generated_OracleDatabase_GetAutonomousDatabase_sync] diff --git a/google-cloud-oracle_database-v1/snippets/oracle_database/get_cloud_exadata_infrastructure.rb b/google-cloud-oracle_database-v1/snippets/oracle_database/get_cloud_exadata_infrastructure.rb new file mode 100644 index 000000000000..66a9c496ebc8 --- /dev/null +++ b/google-cloud-oracle_database-v1/snippets/oracle_database/get_cloud_exadata_infrastructure.rb @@ -0,0 +1,47 @@ +# frozen_string_literal: true + +# Copyright 2024 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# https://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Auto-generated by gapic-generator-ruby. DO NOT EDIT! + +# [START oracledatabase_v1_generated_OracleDatabase_GetCloudExadataInfrastructure_sync] +require "google/cloud/oracle_database/v1" + +## +# Snippet for the get_cloud_exadata_infrastructure call in the OracleDatabase service +# +# This snippet has been automatically generated and should be regarded as a code +# template only. It will require modifications to work: +# - It may require correct/in-range values for request initialization. +# - It may require specifying regional endpoints when creating the service +# client as shown in https://cloud.google.com/ruby/docs/reference. +# +# This is an auto-generated example demonstrating basic usage of +# Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::Client#get_cloud_exadata_infrastructure. +# +def get_cloud_exadata_infrastructure + # Create a client object. The client can be reused for multiple calls. + client = Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::Client.new + + # Create a request. To set request fields, pass in keyword arguments. + request = Google::Cloud::OracleDatabase::V1::GetCloudExadataInfrastructureRequest.new + + # Call the get_cloud_exadata_infrastructure method. + result = client.get_cloud_exadata_infrastructure request + + # The returned object is of type Google::Cloud::OracleDatabase::V1::CloudExadataInfrastructure. + p result +end +# [END oracledatabase_v1_generated_OracleDatabase_GetCloudExadataInfrastructure_sync] diff --git a/google-cloud-oracle_database-v1/snippets/oracle_database/get_cloud_vm_cluster.rb b/google-cloud-oracle_database-v1/snippets/oracle_database/get_cloud_vm_cluster.rb new file mode 100644 index 000000000000..26be0c5a118e --- /dev/null +++ b/google-cloud-oracle_database-v1/snippets/oracle_database/get_cloud_vm_cluster.rb @@ -0,0 +1,47 @@ +# frozen_string_literal: true + +# Copyright 2024 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# https://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Auto-generated by gapic-generator-ruby. DO NOT EDIT! + +# [START oracledatabase_v1_generated_OracleDatabase_GetCloudVmCluster_sync] +require "google/cloud/oracle_database/v1" + +## +# Snippet for the get_cloud_vm_cluster call in the OracleDatabase service +# +# This snippet has been automatically generated and should be regarded as a code +# template only. It will require modifications to work: +# - It may require correct/in-range values for request initialization. +# - It may require specifying regional endpoints when creating the service +# client as shown in https://cloud.google.com/ruby/docs/reference. +# +# This is an auto-generated example demonstrating basic usage of +# Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::Client#get_cloud_vm_cluster. +# +def get_cloud_vm_cluster + # Create a client object. The client can be reused for multiple calls. + client = Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::Client.new + + # Create a request. To set request fields, pass in keyword arguments. + request = Google::Cloud::OracleDatabase::V1::GetCloudVmClusterRequest.new + + # Call the get_cloud_vm_cluster method. + result = client.get_cloud_vm_cluster request + + # The returned object is of type Google::Cloud::OracleDatabase::V1::CloudVmCluster. + p result +end +# [END oracledatabase_v1_generated_OracleDatabase_GetCloudVmCluster_sync] diff --git a/google-cloud-oracle_database-v1/snippets/oracle_database/list_autonomous_database_backups.rb b/google-cloud-oracle_database-v1/snippets/oracle_database/list_autonomous_database_backups.rb new file mode 100644 index 000000000000..1fca51c6c3be --- /dev/null +++ b/google-cloud-oracle_database-v1/snippets/oracle_database/list_autonomous_database_backups.rb @@ -0,0 +1,51 @@ +# frozen_string_literal: true + +# Copyright 2024 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# https://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Auto-generated by gapic-generator-ruby. DO NOT EDIT! + +# [START oracledatabase_v1_generated_OracleDatabase_ListAutonomousDatabaseBackups_sync] +require "google/cloud/oracle_database/v1" + +## +# Snippet for the list_autonomous_database_backups call in the OracleDatabase service +# +# This snippet has been automatically generated and should be regarded as a code +# template only. It will require modifications to work: +# - It may require correct/in-range values for request initialization. +# - It may require specifying regional endpoints when creating the service +# client as shown in https://cloud.google.com/ruby/docs/reference. +# +# This is an auto-generated example demonstrating basic usage of +# Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::Client#list_autonomous_database_backups. +# +def list_autonomous_database_backups + # Create a client object. The client can be reused for multiple calls. + client = Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::Client.new + + # Create a request. To set request fields, pass in keyword arguments. + request = Google::Cloud::OracleDatabase::V1::ListAutonomousDatabaseBackupsRequest.new + + # Call the list_autonomous_database_backups method. + result = client.list_autonomous_database_backups request + + # The returned object is of type Gapic::PagedEnumerable. You can iterate + # over elements, and API calls will be issued to fetch pages as needed. + result.each do |item| + # Each element is of type ::Google::Cloud::OracleDatabase::V1::AutonomousDatabaseBackup. + p item + end +end +# [END oracledatabase_v1_generated_OracleDatabase_ListAutonomousDatabaseBackups_sync] diff --git a/google-cloud-oracle_database-v1/snippets/oracle_database/list_autonomous_database_character_sets.rb b/google-cloud-oracle_database-v1/snippets/oracle_database/list_autonomous_database_character_sets.rb new file mode 100644 index 000000000000..e653ffbb9532 --- /dev/null +++ b/google-cloud-oracle_database-v1/snippets/oracle_database/list_autonomous_database_character_sets.rb @@ -0,0 +1,51 @@ +# frozen_string_literal: true + +# Copyright 2024 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# https://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Auto-generated by gapic-generator-ruby. DO NOT EDIT! + +# [START oracledatabase_v1_generated_OracleDatabase_ListAutonomousDatabaseCharacterSets_sync] +require "google/cloud/oracle_database/v1" + +## +# Snippet for the list_autonomous_database_character_sets call in the OracleDatabase service +# +# This snippet has been automatically generated and should be regarded as a code +# template only. It will require modifications to work: +# - It may require correct/in-range values for request initialization. +# - It may require specifying regional endpoints when creating the service +# client as shown in https://cloud.google.com/ruby/docs/reference. +# +# This is an auto-generated example demonstrating basic usage of +# Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::Client#list_autonomous_database_character_sets. +# +def list_autonomous_database_character_sets + # Create a client object. The client can be reused for multiple calls. + client = Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::Client.new + + # Create a request. To set request fields, pass in keyword arguments. + request = Google::Cloud::OracleDatabase::V1::ListAutonomousDatabaseCharacterSetsRequest.new + + # Call the list_autonomous_database_character_sets method. + result = client.list_autonomous_database_character_sets request + + # The returned object is of type Gapic::PagedEnumerable. You can iterate + # over elements, and API calls will be issued to fetch pages as needed. + result.each do |item| + # Each element is of type ::Google::Cloud::OracleDatabase::V1::AutonomousDatabaseCharacterSet. + p item + end +end +# [END oracledatabase_v1_generated_OracleDatabase_ListAutonomousDatabaseCharacterSets_sync] diff --git a/google-cloud-oracle_database-v1/snippets/oracle_database/list_autonomous_databases.rb b/google-cloud-oracle_database-v1/snippets/oracle_database/list_autonomous_databases.rb new file mode 100644 index 000000000000..b10d99fb94ef --- /dev/null +++ b/google-cloud-oracle_database-v1/snippets/oracle_database/list_autonomous_databases.rb @@ -0,0 +1,51 @@ +# frozen_string_literal: true + +# Copyright 2024 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# https://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Auto-generated by gapic-generator-ruby. DO NOT EDIT! + +# [START oracledatabase_v1_generated_OracleDatabase_ListAutonomousDatabases_sync] +require "google/cloud/oracle_database/v1" + +## +# Snippet for the list_autonomous_databases call in the OracleDatabase service +# +# This snippet has been automatically generated and should be regarded as a code +# template only. It will require modifications to work: +# - It may require correct/in-range values for request initialization. +# - It may require specifying regional endpoints when creating the service +# client as shown in https://cloud.google.com/ruby/docs/reference. +# +# This is an auto-generated example demonstrating basic usage of +# Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::Client#list_autonomous_databases. +# +def list_autonomous_databases + # Create a client object. The client can be reused for multiple calls. + client = Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::Client.new + + # Create a request. To set request fields, pass in keyword arguments. + request = Google::Cloud::OracleDatabase::V1::ListAutonomousDatabasesRequest.new + + # Call the list_autonomous_databases method. + result = client.list_autonomous_databases request + + # The returned object is of type Gapic::PagedEnumerable. You can iterate + # over elements, and API calls will be issued to fetch pages as needed. + result.each do |item| + # Each element is of type ::Google::Cloud::OracleDatabase::V1::AutonomousDatabase. + p item + end +end +# [END oracledatabase_v1_generated_OracleDatabase_ListAutonomousDatabases_sync] diff --git a/google-cloud-oracle_database-v1/snippets/oracle_database/list_autonomous_db_versions.rb b/google-cloud-oracle_database-v1/snippets/oracle_database/list_autonomous_db_versions.rb new file mode 100644 index 000000000000..5e901da0e827 --- /dev/null +++ b/google-cloud-oracle_database-v1/snippets/oracle_database/list_autonomous_db_versions.rb @@ -0,0 +1,51 @@ +# frozen_string_literal: true + +# Copyright 2024 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# https://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Auto-generated by gapic-generator-ruby. DO NOT EDIT! + +# [START oracledatabase_v1_generated_OracleDatabase_ListAutonomousDbVersions_sync] +require "google/cloud/oracle_database/v1" + +## +# Snippet for the list_autonomous_db_versions call in the OracleDatabase service +# +# This snippet has been automatically generated and should be regarded as a code +# template only. It will require modifications to work: +# - It may require correct/in-range values for request initialization. +# - It may require specifying regional endpoints when creating the service +# client as shown in https://cloud.google.com/ruby/docs/reference. +# +# This is an auto-generated example demonstrating basic usage of +# Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::Client#list_autonomous_db_versions. +# +def list_autonomous_db_versions + # Create a client object. The client can be reused for multiple calls. + client = Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::Client.new + + # Create a request. To set request fields, pass in keyword arguments. + request = Google::Cloud::OracleDatabase::V1::ListAutonomousDbVersionsRequest.new + + # Call the list_autonomous_db_versions method. + result = client.list_autonomous_db_versions request + + # The returned object is of type Gapic::PagedEnumerable. You can iterate + # over elements, and API calls will be issued to fetch pages as needed. + result.each do |item| + # Each element is of type ::Google::Cloud::OracleDatabase::V1::AutonomousDbVersion. + p item + end +end +# [END oracledatabase_v1_generated_OracleDatabase_ListAutonomousDbVersions_sync] diff --git a/google-cloud-oracle_database-v1/snippets/oracle_database/list_cloud_exadata_infrastructures.rb b/google-cloud-oracle_database-v1/snippets/oracle_database/list_cloud_exadata_infrastructures.rb new file mode 100644 index 000000000000..872447e37e60 --- /dev/null +++ b/google-cloud-oracle_database-v1/snippets/oracle_database/list_cloud_exadata_infrastructures.rb @@ -0,0 +1,51 @@ +# frozen_string_literal: true + +# Copyright 2024 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# https://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Auto-generated by gapic-generator-ruby. DO NOT EDIT! + +# [START oracledatabase_v1_generated_OracleDatabase_ListCloudExadataInfrastructures_sync] +require "google/cloud/oracle_database/v1" + +## +# Snippet for the list_cloud_exadata_infrastructures call in the OracleDatabase service +# +# This snippet has been automatically generated and should be regarded as a code +# template only. It will require modifications to work: +# - It may require correct/in-range values for request initialization. +# - It may require specifying regional endpoints when creating the service +# client as shown in https://cloud.google.com/ruby/docs/reference. +# +# This is an auto-generated example demonstrating basic usage of +# Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::Client#list_cloud_exadata_infrastructures. +# +def list_cloud_exadata_infrastructures + # Create a client object. The client can be reused for multiple calls. + client = Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::Client.new + + # Create a request. To set request fields, pass in keyword arguments. + request = Google::Cloud::OracleDatabase::V1::ListCloudExadataInfrastructuresRequest.new + + # Call the list_cloud_exadata_infrastructures method. + result = client.list_cloud_exadata_infrastructures request + + # The returned object is of type Gapic::PagedEnumerable. You can iterate + # over elements, and API calls will be issued to fetch pages as needed. + result.each do |item| + # Each element is of type ::Google::Cloud::OracleDatabase::V1::CloudExadataInfrastructure. + p item + end +end +# [END oracledatabase_v1_generated_OracleDatabase_ListCloudExadataInfrastructures_sync] diff --git a/google-cloud-oracle_database-v1/snippets/oracle_database/list_cloud_vm_clusters.rb b/google-cloud-oracle_database-v1/snippets/oracle_database/list_cloud_vm_clusters.rb new file mode 100644 index 000000000000..5cab97923a88 --- /dev/null +++ b/google-cloud-oracle_database-v1/snippets/oracle_database/list_cloud_vm_clusters.rb @@ -0,0 +1,51 @@ +# frozen_string_literal: true + +# Copyright 2024 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# https://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Auto-generated by gapic-generator-ruby. DO NOT EDIT! + +# [START oracledatabase_v1_generated_OracleDatabase_ListCloudVmClusters_sync] +require "google/cloud/oracle_database/v1" + +## +# Snippet for the list_cloud_vm_clusters call in the OracleDatabase service +# +# This snippet has been automatically generated and should be regarded as a code +# template only. It will require modifications to work: +# - It may require correct/in-range values for request initialization. +# - It may require specifying regional endpoints when creating the service +# client as shown in https://cloud.google.com/ruby/docs/reference. +# +# This is an auto-generated example demonstrating basic usage of +# Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::Client#list_cloud_vm_clusters. +# +def list_cloud_vm_clusters + # Create a client object. The client can be reused for multiple calls. + client = Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::Client.new + + # Create a request. To set request fields, pass in keyword arguments. + request = Google::Cloud::OracleDatabase::V1::ListCloudVmClustersRequest.new + + # Call the list_cloud_vm_clusters method. + result = client.list_cloud_vm_clusters request + + # The returned object is of type Gapic::PagedEnumerable. You can iterate + # over elements, and API calls will be issued to fetch pages as needed. + result.each do |item| + # Each element is of type ::Google::Cloud::OracleDatabase::V1::CloudVmCluster. + p item + end +end +# [END oracledatabase_v1_generated_OracleDatabase_ListCloudVmClusters_sync] diff --git a/google-cloud-oracle_database-v1/snippets/oracle_database/list_db_nodes.rb b/google-cloud-oracle_database-v1/snippets/oracle_database/list_db_nodes.rb new file mode 100644 index 000000000000..307bbb4e9024 --- /dev/null +++ b/google-cloud-oracle_database-v1/snippets/oracle_database/list_db_nodes.rb @@ -0,0 +1,51 @@ +# frozen_string_literal: true + +# Copyright 2024 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# https://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Auto-generated by gapic-generator-ruby. DO NOT EDIT! + +# [START oracledatabase_v1_generated_OracleDatabase_ListDbNodes_sync] +require "google/cloud/oracle_database/v1" + +## +# Snippet for the list_db_nodes call in the OracleDatabase service +# +# This snippet has been automatically generated and should be regarded as a code +# template only. It will require modifications to work: +# - It may require correct/in-range values for request initialization. +# - It may require specifying regional endpoints when creating the service +# client as shown in https://cloud.google.com/ruby/docs/reference. +# +# This is an auto-generated example demonstrating basic usage of +# Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::Client#list_db_nodes. +# +def list_db_nodes + # Create a client object. The client can be reused for multiple calls. + client = Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::Client.new + + # Create a request. To set request fields, pass in keyword arguments. + request = Google::Cloud::OracleDatabase::V1::ListDbNodesRequest.new + + # Call the list_db_nodes method. + result = client.list_db_nodes request + + # The returned object is of type Gapic::PagedEnumerable. You can iterate + # over elements, and API calls will be issued to fetch pages as needed. + result.each do |item| + # Each element is of type ::Google::Cloud::OracleDatabase::V1::DbNode. + p item + end +end +# [END oracledatabase_v1_generated_OracleDatabase_ListDbNodes_sync] diff --git a/google-cloud-oracle_database-v1/snippets/oracle_database/list_db_servers.rb b/google-cloud-oracle_database-v1/snippets/oracle_database/list_db_servers.rb new file mode 100644 index 000000000000..efea1e276ec1 --- /dev/null +++ b/google-cloud-oracle_database-v1/snippets/oracle_database/list_db_servers.rb @@ -0,0 +1,51 @@ +# frozen_string_literal: true + +# Copyright 2024 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# https://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Auto-generated by gapic-generator-ruby. DO NOT EDIT! + +# [START oracledatabase_v1_generated_OracleDatabase_ListDbServers_sync] +require "google/cloud/oracle_database/v1" + +## +# Snippet for the list_db_servers call in the OracleDatabase service +# +# This snippet has been automatically generated and should be regarded as a code +# template only. It will require modifications to work: +# - It may require correct/in-range values for request initialization. +# - It may require specifying regional endpoints when creating the service +# client as shown in https://cloud.google.com/ruby/docs/reference. +# +# This is an auto-generated example demonstrating basic usage of +# Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::Client#list_db_servers. +# +def list_db_servers + # Create a client object. The client can be reused for multiple calls. + client = Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::Client.new + + # Create a request. To set request fields, pass in keyword arguments. + request = Google::Cloud::OracleDatabase::V1::ListDbServersRequest.new + + # Call the list_db_servers method. + result = client.list_db_servers request + + # The returned object is of type Gapic::PagedEnumerable. You can iterate + # over elements, and API calls will be issued to fetch pages as needed. + result.each do |item| + # Each element is of type ::Google::Cloud::OracleDatabase::V1::DbServer. + p item + end +end +# [END oracledatabase_v1_generated_OracleDatabase_ListDbServers_sync] diff --git a/google-cloud-oracle_database-v1/snippets/oracle_database/list_db_system_shapes.rb b/google-cloud-oracle_database-v1/snippets/oracle_database/list_db_system_shapes.rb new file mode 100644 index 000000000000..9205bd04d1d8 --- /dev/null +++ b/google-cloud-oracle_database-v1/snippets/oracle_database/list_db_system_shapes.rb @@ -0,0 +1,51 @@ +# frozen_string_literal: true + +# Copyright 2024 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# https://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Auto-generated by gapic-generator-ruby. DO NOT EDIT! + +# [START oracledatabase_v1_generated_OracleDatabase_ListDbSystemShapes_sync] +require "google/cloud/oracle_database/v1" + +## +# Snippet for the list_db_system_shapes call in the OracleDatabase service +# +# This snippet has been automatically generated and should be regarded as a code +# template only. It will require modifications to work: +# - It may require correct/in-range values for request initialization. +# - It may require specifying regional endpoints when creating the service +# client as shown in https://cloud.google.com/ruby/docs/reference. +# +# This is an auto-generated example demonstrating basic usage of +# Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::Client#list_db_system_shapes. +# +def list_db_system_shapes + # Create a client object. The client can be reused for multiple calls. + client = Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::Client.new + + # Create a request. To set request fields, pass in keyword arguments. + request = Google::Cloud::OracleDatabase::V1::ListDbSystemShapesRequest.new + + # Call the list_db_system_shapes method. + result = client.list_db_system_shapes request + + # The returned object is of type Gapic::PagedEnumerable. You can iterate + # over elements, and API calls will be issued to fetch pages as needed. + result.each do |item| + # Each element is of type ::Google::Cloud::OracleDatabase::V1::DbSystemShape. + p item + end +end +# [END oracledatabase_v1_generated_OracleDatabase_ListDbSystemShapes_sync] diff --git a/google-cloud-oracle_database-v1/snippets/oracle_database/list_entitlements.rb b/google-cloud-oracle_database-v1/snippets/oracle_database/list_entitlements.rb new file mode 100644 index 000000000000..db9a4cecdf8a --- /dev/null +++ b/google-cloud-oracle_database-v1/snippets/oracle_database/list_entitlements.rb @@ -0,0 +1,51 @@ +# frozen_string_literal: true + +# Copyright 2024 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# https://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Auto-generated by gapic-generator-ruby. DO NOT EDIT! + +# [START oracledatabase_v1_generated_OracleDatabase_ListEntitlements_sync] +require "google/cloud/oracle_database/v1" + +## +# Snippet for the list_entitlements call in the OracleDatabase service +# +# This snippet has been automatically generated and should be regarded as a code +# template only. It will require modifications to work: +# - It may require correct/in-range values for request initialization. +# - It may require specifying regional endpoints when creating the service +# client as shown in https://cloud.google.com/ruby/docs/reference. +# +# This is an auto-generated example demonstrating basic usage of +# Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::Client#list_entitlements. +# +def list_entitlements + # Create a client object. The client can be reused for multiple calls. + client = Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::Client.new + + # Create a request. To set request fields, pass in keyword arguments. + request = Google::Cloud::OracleDatabase::V1::ListEntitlementsRequest.new + + # Call the list_entitlements method. + result = client.list_entitlements request + + # The returned object is of type Gapic::PagedEnumerable. You can iterate + # over elements, and API calls will be issued to fetch pages as needed. + result.each do |item| + # Each element is of type ::Google::Cloud::OracleDatabase::V1::Entitlement. + p item + end +end +# [END oracledatabase_v1_generated_OracleDatabase_ListEntitlements_sync] diff --git a/google-cloud-oracle_database-v1/snippets/oracle_database/list_gi_versions.rb b/google-cloud-oracle_database-v1/snippets/oracle_database/list_gi_versions.rb new file mode 100644 index 000000000000..79902d680ea8 --- /dev/null +++ b/google-cloud-oracle_database-v1/snippets/oracle_database/list_gi_versions.rb @@ -0,0 +1,51 @@ +# frozen_string_literal: true + +# Copyright 2024 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# https://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Auto-generated by gapic-generator-ruby. DO NOT EDIT! + +# [START oracledatabase_v1_generated_OracleDatabase_ListGiVersions_sync] +require "google/cloud/oracle_database/v1" + +## +# Snippet for the list_gi_versions call in the OracleDatabase service +# +# This snippet has been automatically generated and should be regarded as a code +# template only. It will require modifications to work: +# - It may require correct/in-range values for request initialization. +# - It may require specifying regional endpoints when creating the service +# client as shown in https://cloud.google.com/ruby/docs/reference. +# +# This is an auto-generated example demonstrating basic usage of +# Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::Client#list_gi_versions. +# +def list_gi_versions + # Create a client object. The client can be reused for multiple calls. + client = Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::Client.new + + # Create a request. To set request fields, pass in keyword arguments. + request = Google::Cloud::OracleDatabase::V1::ListGiVersionsRequest.new + + # Call the list_gi_versions method. + result = client.list_gi_versions request + + # The returned object is of type Gapic::PagedEnumerable. You can iterate + # over elements, and API calls will be issued to fetch pages as needed. + result.each do |item| + # Each element is of type ::Google::Cloud::OracleDatabase::V1::GiVersion. + p item + end +end +# [END oracledatabase_v1_generated_OracleDatabase_ListGiVersions_sync] diff --git a/google-cloud-oracle_database-v1/snippets/oracle_database/restore_autonomous_database.rb b/google-cloud-oracle_database-v1/snippets/oracle_database/restore_autonomous_database.rb new file mode 100644 index 000000000000..68d951b52657 --- /dev/null +++ b/google-cloud-oracle_database-v1/snippets/oracle_database/restore_autonomous_database.rb @@ -0,0 +1,54 @@ +# frozen_string_literal: true + +# Copyright 2024 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# https://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Auto-generated by gapic-generator-ruby. DO NOT EDIT! + +# [START oracledatabase_v1_generated_OracleDatabase_RestoreAutonomousDatabase_sync] +require "google/cloud/oracle_database/v1" + +## +# Snippet for the restore_autonomous_database call in the OracleDatabase service +# +# This snippet has been automatically generated and should be regarded as a code +# template only. It will require modifications to work: +# - It may require correct/in-range values for request initialization. +# - It may require specifying regional endpoints when creating the service +# client as shown in https://cloud.google.com/ruby/docs/reference. +# +# This is an auto-generated example demonstrating basic usage of +# Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::Client#restore_autonomous_database. +# +def restore_autonomous_database + # Create a client object. The client can be reused for multiple calls. + client = Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::Client.new + + # Create a request. To set request fields, pass in keyword arguments. + request = Google::Cloud::OracleDatabase::V1::RestoreAutonomousDatabaseRequest.new + + # Call the restore_autonomous_database method. + result = client.restore_autonomous_database request + + # The returned object is of type Gapic::Operation. You can use it to + # check the status of an operation, cancel it, or wait for results. + # Here is how to wait for a response. + result.wait_until_done! timeout: 60 + if result.response? + p result.response + else + puts "No response received." + end +end +# [END oracledatabase_v1_generated_OracleDatabase_RestoreAutonomousDatabase_sync] diff --git a/google-cloud-oracle_database-v1/snippets/snippet_metadata_google.cloud.oracledatabase.v1.json b/google-cloud-oracle_database-v1/snippets/snippet_metadata_google.cloud.oracledatabase.v1.json new file mode 100644 index 000000000000..fb221a3149d1 --- /dev/null +++ b/google-cloud-oracle_database-v1/snippets/snippet_metadata_google.cloud.oracledatabase.v1.json @@ -0,0 +1,895 @@ +{ + "client_library": { + "name": "google-cloud-oracle_database-v1", + "version": "", + "language": "RUBY", + "apis": [ + { + "id": "google.cloud.oracledatabase.v1", + "version": "v1" + } + ] + }, + "snippets": [ + { + "region_tag": "oracledatabase_v1_generated_OracleDatabase_ListCloudExadataInfrastructures_sync", + "title": "Snippet for the list_cloud_exadata_infrastructures call in the OracleDatabase service", + "description": "This is an auto-generated example demonstrating basic usage of Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::Client#list_cloud_exadata_infrastructures.", + "file": "oracle_database/list_cloud_exadata_infrastructures.rb", + "language": "RUBY", + "client_method": { + "short_name": "list_cloud_exadata_infrastructures", + "full_name": "::Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::Client#list_cloud_exadata_infrastructures", + "async": false, + "parameters": [ + { + "type": "::Google::Cloud::OracleDatabase::V1::ListCloudExadataInfrastructuresRequest", + "name": "request" + } + ], + "result_type": "::Google::Cloud::OracleDatabase::V1::ListCloudExadataInfrastructuresResponse", + "client": { + "short_name": "OracleDatabase::Rest::Client", + "full_name": "::Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::Client" + }, + "method": { + "short_name": "ListCloudExadataInfrastructures", + "full_name": "google.cloud.oracledatabase.v1.OracleDatabase.ListCloudExadataInfrastructures", + "service": { + "short_name": "OracleDatabase", + "full_name": "google.cloud.oracledatabase.v1.OracleDatabase" + } + } + }, + "canonical": true, + "origin": "API_DEFINITION", + "segments": [ + { + "start": 20, + "end": 50, + "type": "FULL" + } + ] + }, + { + "region_tag": "oracledatabase_v1_generated_OracleDatabase_GetCloudExadataInfrastructure_sync", + "title": "Snippet for the get_cloud_exadata_infrastructure call in the OracleDatabase service", + "description": "This is an auto-generated example demonstrating basic usage of Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::Client#get_cloud_exadata_infrastructure.", + "file": "oracle_database/get_cloud_exadata_infrastructure.rb", + "language": "RUBY", + "client_method": { + "short_name": "get_cloud_exadata_infrastructure", + "full_name": "::Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::Client#get_cloud_exadata_infrastructure", + "async": false, + "parameters": [ + { + "type": "::Google::Cloud::OracleDatabase::V1::GetCloudExadataInfrastructureRequest", + "name": "request" + } + ], + "result_type": "::Google::Cloud::OracleDatabase::V1::CloudExadataInfrastructure", + "client": { + "short_name": "OracleDatabase::Rest::Client", + "full_name": "::Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::Client" + }, + "method": { + "short_name": "GetCloudExadataInfrastructure", + "full_name": "google.cloud.oracledatabase.v1.OracleDatabase.GetCloudExadataInfrastructure", + "service": { + "short_name": "OracleDatabase", + "full_name": "google.cloud.oracledatabase.v1.OracleDatabase" + } + } + }, + "canonical": true, + "origin": "API_DEFINITION", + "segments": [ + { + "start": 20, + "end": 46, + "type": "FULL" + } + ] + }, + { + "region_tag": "oracledatabase_v1_generated_OracleDatabase_CreateCloudExadataInfrastructure_sync", + "title": "Snippet for the create_cloud_exadata_infrastructure call in the OracleDatabase service", + "description": "This is an auto-generated example demonstrating basic usage of Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::Client#create_cloud_exadata_infrastructure.", + "file": "oracle_database/create_cloud_exadata_infrastructure.rb", + "language": "RUBY", + "client_method": { + "short_name": "create_cloud_exadata_infrastructure", + "full_name": "::Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::Client#create_cloud_exadata_infrastructure", + "async": false, + "parameters": [ + { + "type": "::Google::Cloud::OracleDatabase::V1::CreateCloudExadataInfrastructureRequest", + "name": "request" + } + ], + "result_type": "::Google::Longrunning::Operation", + "client": { + "short_name": "OracleDatabase::Rest::Client", + "full_name": "::Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::Client" + }, + "method": { + "short_name": "CreateCloudExadataInfrastructure", + "full_name": "google.cloud.oracledatabase.v1.OracleDatabase.CreateCloudExadataInfrastructure", + "service": { + "short_name": "OracleDatabase", + "full_name": "google.cloud.oracledatabase.v1.OracleDatabase" + } + } + }, + "canonical": true, + "origin": "API_DEFINITION", + "segments": [ + { + "start": 20, + "end": 53, + "type": "FULL" + } + ] + }, + { + "region_tag": "oracledatabase_v1_generated_OracleDatabase_DeleteCloudExadataInfrastructure_sync", + "title": "Snippet for the delete_cloud_exadata_infrastructure call in the OracleDatabase service", + "description": "This is an auto-generated example demonstrating basic usage of Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::Client#delete_cloud_exadata_infrastructure.", + "file": "oracle_database/delete_cloud_exadata_infrastructure.rb", + "language": "RUBY", + "client_method": { + "short_name": "delete_cloud_exadata_infrastructure", + "full_name": "::Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::Client#delete_cloud_exadata_infrastructure", + "async": false, + "parameters": [ + { + "type": "::Google::Cloud::OracleDatabase::V1::DeleteCloudExadataInfrastructureRequest", + "name": "request" + } + ], + "result_type": "::Google::Longrunning::Operation", + "client": { + "short_name": "OracleDatabase::Rest::Client", + "full_name": "::Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::Client" + }, + "method": { + "short_name": "DeleteCloudExadataInfrastructure", + "full_name": "google.cloud.oracledatabase.v1.OracleDatabase.DeleteCloudExadataInfrastructure", + "service": { + "short_name": "OracleDatabase", + "full_name": "google.cloud.oracledatabase.v1.OracleDatabase" + } + } + }, + "canonical": true, + "origin": "API_DEFINITION", + "segments": [ + { + "start": 20, + "end": 53, + "type": "FULL" + } + ] + }, + { + "region_tag": "oracledatabase_v1_generated_OracleDatabase_ListCloudVmClusters_sync", + "title": "Snippet for the list_cloud_vm_clusters call in the OracleDatabase service", + "description": "This is an auto-generated example demonstrating basic usage of Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::Client#list_cloud_vm_clusters.", + "file": "oracle_database/list_cloud_vm_clusters.rb", + "language": "RUBY", + "client_method": { + "short_name": "list_cloud_vm_clusters", + "full_name": "::Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::Client#list_cloud_vm_clusters", + "async": false, + "parameters": [ + { + "type": "::Google::Cloud::OracleDatabase::V1::ListCloudVmClustersRequest", + "name": "request" + } + ], + "result_type": "::Google::Cloud::OracleDatabase::V1::ListCloudVmClustersResponse", + "client": { + "short_name": "OracleDatabase::Rest::Client", + "full_name": "::Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::Client" + }, + "method": { + "short_name": "ListCloudVmClusters", + "full_name": "google.cloud.oracledatabase.v1.OracleDatabase.ListCloudVmClusters", + "service": { + "short_name": "OracleDatabase", + "full_name": "google.cloud.oracledatabase.v1.OracleDatabase" + } + } + }, + "canonical": true, + "origin": "API_DEFINITION", + "segments": [ + { + "start": 20, + "end": 50, + "type": "FULL" + } + ] + }, + { + "region_tag": "oracledatabase_v1_generated_OracleDatabase_GetCloudVmCluster_sync", + "title": "Snippet for the get_cloud_vm_cluster call in the OracleDatabase service", + "description": "This is an auto-generated example demonstrating basic usage of Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::Client#get_cloud_vm_cluster.", + "file": "oracle_database/get_cloud_vm_cluster.rb", + "language": "RUBY", + "client_method": { + "short_name": "get_cloud_vm_cluster", + "full_name": "::Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::Client#get_cloud_vm_cluster", + "async": false, + "parameters": [ + { + "type": "::Google::Cloud::OracleDatabase::V1::GetCloudVmClusterRequest", + "name": "request" + } + ], + "result_type": "::Google::Cloud::OracleDatabase::V1::CloudVmCluster", + "client": { + "short_name": "OracleDatabase::Rest::Client", + "full_name": "::Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::Client" + }, + "method": { + "short_name": "GetCloudVmCluster", + "full_name": "google.cloud.oracledatabase.v1.OracleDatabase.GetCloudVmCluster", + "service": { + "short_name": "OracleDatabase", + "full_name": "google.cloud.oracledatabase.v1.OracleDatabase" + } + } + }, + "canonical": true, + "origin": "API_DEFINITION", + "segments": [ + { + "start": 20, + "end": 46, + "type": "FULL" + } + ] + }, + { + "region_tag": "oracledatabase_v1_generated_OracleDatabase_CreateCloudVmCluster_sync", + "title": "Snippet for the create_cloud_vm_cluster call in the OracleDatabase service", + "description": "This is an auto-generated example demonstrating basic usage of Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::Client#create_cloud_vm_cluster.", + "file": "oracle_database/create_cloud_vm_cluster.rb", + "language": "RUBY", + "client_method": { + "short_name": "create_cloud_vm_cluster", + "full_name": "::Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::Client#create_cloud_vm_cluster", + "async": false, + "parameters": [ + { + "type": "::Google::Cloud::OracleDatabase::V1::CreateCloudVmClusterRequest", + "name": "request" + } + ], + "result_type": "::Google::Longrunning::Operation", + "client": { + "short_name": "OracleDatabase::Rest::Client", + "full_name": "::Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::Client" + }, + "method": { + "short_name": "CreateCloudVmCluster", + "full_name": "google.cloud.oracledatabase.v1.OracleDatabase.CreateCloudVmCluster", + "service": { + "short_name": "OracleDatabase", + "full_name": "google.cloud.oracledatabase.v1.OracleDatabase" + } + } + }, + "canonical": true, + "origin": "API_DEFINITION", + "segments": [ + { + "start": 20, + "end": 53, + "type": "FULL" + } + ] + }, + { + "region_tag": "oracledatabase_v1_generated_OracleDatabase_DeleteCloudVmCluster_sync", + "title": "Snippet for the delete_cloud_vm_cluster call in the OracleDatabase service", + "description": "This is an auto-generated example demonstrating basic usage of Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::Client#delete_cloud_vm_cluster.", + "file": "oracle_database/delete_cloud_vm_cluster.rb", + "language": "RUBY", + "client_method": { + "short_name": "delete_cloud_vm_cluster", + "full_name": "::Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::Client#delete_cloud_vm_cluster", + "async": false, + "parameters": [ + { + "type": "::Google::Cloud::OracleDatabase::V1::DeleteCloudVmClusterRequest", + "name": "request" + } + ], + "result_type": "::Google::Longrunning::Operation", + "client": { + "short_name": "OracleDatabase::Rest::Client", + "full_name": "::Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::Client" + }, + "method": { + "short_name": "DeleteCloudVmCluster", + "full_name": "google.cloud.oracledatabase.v1.OracleDatabase.DeleteCloudVmCluster", + "service": { + "short_name": "OracleDatabase", + "full_name": "google.cloud.oracledatabase.v1.OracleDatabase" + } + } + }, + "canonical": true, + "origin": "API_DEFINITION", + "segments": [ + { + "start": 20, + "end": 53, + "type": "FULL" + } + ] + }, + { + "region_tag": "oracledatabase_v1_generated_OracleDatabase_ListEntitlements_sync", + "title": "Snippet for the list_entitlements call in the OracleDatabase service", + "description": "This is an auto-generated example demonstrating basic usage of Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::Client#list_entitlements.", + "file": "oracle_database/list_entitlements.rb", + "language": "RUBY", + "client_method": { + "short_name": "list_entitlements", + "full_name": "::Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::Client#list_entitlements", + "async": false, + "parameters": [ + { + "type": "::Google::Cloud::OracleDatabase::V1::ListEntitlementsRequest", + "name": "request" + } + ], + "result_type": "::Google::Cloud::OracleDatabase::V1::ListEntitlementsResponse", + "client": { + "short_name": "OracleDatabase::Rest::Client", + "full_name": "::Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::Client" + }, + "method": { + "short_name": "ListEntitlements", + "full_name": "google.cloud.oracledatabase.v1.OracleDatabase.ListEntitlements", + "service": { + "short_name": "OracleDatabase", + "full_name": "google.cloud.oracledatabase.v1.OracleDatabase" + } + } + }, + "canonical": true, + "origin": "API_DEFINITION", + "segments": [ + { + "start": 20, + "end": 50, + "type": "FULL" + } + ] + }, + { + "region_tag": "oracledatabase_v1_generated_OracleDatabase_ListDbServers_sync", + "title": "Snippet for the list_db_servers call in the OracleDatabase service", + "description": "This is an auto-generated example demonstrating basic usage of Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::Client#list_db_servers.", + "file": "oracle_database/list_db_servers.rb", + "language": "RUBY", + "client_method": { + "short_name": "list_db_servers", + "full_name": "::Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::Client#list_db_servers", + "async": false, + "parameters": [ + { + "type": "::Google::Cloud::OracleDatabase::V1::ListDbServersRequest", + "name": "request" + } + ], + "result_type": "::Google::Cloud::OracleDatabase::V1::ListDbServersResponse", + "client": { + "short_name": "OracleDatabase::Rest::Client", + "full_name": "::Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::Client" + }, + "method": { + "short_name": "ListDbServers", + "full_name": "google.cloud.oracledatabase.v1.OracleDatabase.ListDbServers", + "service": { + "short_name": "OracleDatabase", + "full_name": "google.cloud.oracledatabase.v1.OracleDatabase" + } + } + }, + "canonical": true, + "origin": "API_DEFINITION", + "segments": [ + { + "start": 20, + "end": 50, + "type": "FULL" + } + ] + }, + { + "region_tag": "oracledatabase_v1_generated_OracleDatabase_ListDbNodes_sync", + "title": "Snippet for the list_db_nodes call in the OracleDatabase service", + "description": "This is an auto-generated example demonstrating basic usage of Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::Client#list_db_nodes.", + "file": "oracle_database/list_db_nodes.rb", + "language": "RUBY", + "client_method": { + "short_name": "list_db_nodes", + "full_name": "::Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::Client#list_db_nodes", + "async": false, + "parameters": [ + { + "type": "::Google::Cloud::OracleDatabase::V1::ListDbNodesRequest", + "name": "request" + } + ], + "result_type": "::Google::Cloud::OracleDatabase::V1::ListDbNodesResponse", + "client": { + "short_name": "OracleDatabase::Rest::Client", + "full_name": "::Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::Client" + }, + "method": { + "short_name": "ListDbNodes", + "full_name": "google.cloud.oracledatabase.v1.OracleDatabase.ListDbNodes", + "service": { + "short_name": "OracleDatabase", + "full_name": "google.cloud.oracledatabase.v1.OracleDatabase" + } + } + }, + "canonical": true, + "origin": "API_DEFINITION", + "segments": [ + { + "start": 20, + "end": 50, + "type": "FULL" + } + ] + }, + { + "region_tag": "oracledatabase_v1_generated_OracleDatabase_ListGiVersions_sync", + "title": "Snippet for the list_gi_versions call in the OracleDatabase service", + "description": "This is an auto-generated example demonstrating basic usage of Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::Client#list_gi_versions.", + "file": "oracle_database/list_gi_versions.rb", + "language": "RUBY", + "client_method": { + "short_name": "list_gi_versions", + "full_name": "::Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::Client#list_gi_versions", + "async": false, + "parameters": [ + { + "type": "::Google::Cloud::OracleDatabase::V1::ListGiVersionsRequest", + "name": "request" + } + ], + "result_type": "::Google::Cloud::OracleDatabase::V1::ListGiVersionsResponse", + "client": { + "short_name": "OracleDatabase::Rest::Client", + "full_name": "::Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::Client" + }, + "method": { + "short_name": "ListGiVersions", + "full_name": "google.cloud.oracledatabase.v1.OracleDatabase.ListGiVersions", + "service": { + "short_name": "OracleDatabase", + "full_name": "google.cloud.oracledatabase.v1.OracleDatabase" + } + } + }, + "canonical": true, + "origin": "API_DEFINITION", + "segments": [ + { + "start": 20, + "end": 50, + "type": "FULL" + } + ] + }, + { + "region_tag": "oracledatabase_v1_generated_OracleDatabase_ListDbSystemShapes_sync", + "title": "Snippet for the list_db_system_shapes call in the OracleDatabase service", + "description": "This is an auto-generated example demonstrating basic usage of Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::Client#list_db_system_shapes.", + "file": "oracle_database/list_db_system_shapes.rb", + "language": "RUBY", + "client_method": { + "short_name": "list_db_system_shapes", + "full_name": "::Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::Client#list_db_system_shapes", + "async": false, + "parameters": [ + { + "type": "::Google::Cloud::OracleDatabase::V1::ListDbSystemShapesRequest", + "name": "request" + } + ], + "result_type": "::Google::Cloud::OracleDatabase::V1::ListDbSystemShapesResponse", + "client": { + "short_name": "OracleDatabase::Rest::Client", + "full_name": "::Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::Client" + }, + "method": { + "short_name": "ListDbSystemShapes", + "full_name": "google.cloud.oracledatabase.v1.OracleDatabase.ListDbSystemShapes", + "service": { + "short_name": "OracleDatabase", + "full_name": "google.cloud.oracledatabase.v1.OracleDatabase" + } + } + }, + "canonical": true, + "origin": "API_DEFINITION", + "segments": [ + { + "start": 20, + "end": 50, + "type": "FULL" + } + ] + }, + { + "region_tag": "oracledatabase_v1_generated_OracleDatabase_ListAutonomousDatabases_sync", + "title": "Snippet for the list_autonomous_databases call in the OracleDatabase service", + "description": "This is an auto-generated example demonstrating basic usage of Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::Client#list_autonomous_databases.", + "file": "oracle_database/list_autonomous_databases.rb", + "language": "RUBY", + "client_method": { + "short_name": "list_autonomous_databases", + "full_name": "::Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::Client#list_autonomous_databases", + "async": false, + "parameters": [ + { + "type": "::Google::Cloud::OracleDatabase::V1::ListAutonomousDatabasesRequest", + "name": "request" + } + ], + "result_type": "::Google::Cloud::OracleDatabase::V1::ListAutonomousDatabasesResponse", + "client": { + "short_name": "OracleDatabase::Rest::Client", + "full_name": "::Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::Client" + }, + "method": { + "short_name": "ListAutonomousDatabases", + "full_name": "google.cloud.oracledatabase.v1.OracleDatabase.ListAutonomousDatabases", + "service": { + "short_name": "OracleDatabase", + "full_name": "google.cloud.oracledatabase.v1.OracleDatabase" + } + } + }, + "canonical": true, + "origin": "API_DEFINITION", + "segments": [ + { + "start": 20, + "end": 50, + "type": "FULL" + } + ] + }, + { + "region_tag": "oracledatabase_v1_generated_OracleDatabase_GetAutonomousDatabase_sync", + "title": "Snippet for the get_autonomous_database call in the OracleDatabase service", + "description": "This is an auto-generated example demonstrating basic usage of Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::Client#get_autonomous_database.", + "file": "oracle_database/get_autonomous_database.rb", + "language": "RUBY", + "client_method": { + "short_name": "get_autonomous_database", + "full_name": "::Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::Client#get_autonomous_database", + "async": false, + "parameters": [ + { + "type": "::Google::Cloud::OracleDatabase::V1::GetAutonomousDatabaseRequest", + "name": "request" + } + ], + "result_type": "::Google::Cloud::OracleDatabase::V1::AutonomousDatabase", + "client": { + "short_name": "OracleDatabase::Rest::Client", + "full_name": "::Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::Client" + }, + "method": { + "short_name": "GetAutonomousDatabase", + "full_name": "google.cloud.oracledatabase.v1.OracleDatabase.GetAutonomousDatabase", + "service": { + "short_name": "OracleDatabase", + "full_name": "google.cloud.oracledatabase.v1.OracleDatabase" + } + } + }, + "canonical": true, + "origin": "API_DEFINITION", + "segments": [ + { + "start": 20, + "end": 46, + "type": "FULL" + } + ] + }, + { + "region_tag": "oracledatabase_v1_generated_OracleDatabase_CreateAutonomousDatabase_sync", + "title": "Snippet for the create_autonomous_database call in the OracleDatabase service", + "description": "This is an auto-generated example demonstrating basic usage of Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::Client#create_autonomous_database.", + "file": "oracle_database/create_autonomous_database.rb", + "language": "RUBY", + "client_method": { + "short_name": "create_autonomous_database", + "full_name": "::Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::Client#create_autonomous_database", + "async": false, + "parameters": [ + { + "type": "::Google::Cloud::OracleDatabase::V1::CreateAutonomousDatabaseRequest", + "name": "request" + } + ], + "result_type": "::Google::Longrunning::Operation", + "client": { + "short_name": "OracleDatabase::Rest::Client", + "full_name": "::Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::Client" + }, + "method": { + "short_name": "CreateAutonomousDatabase", + "full_name": "google.cloud.oracledatabase.v1.OracleDatabase.CreateAutonomousDatabase", + "service": { + "short_name": "OracleDatabase", + "full_name": "google.cloud.oracledatabase.v1.OracleDatabase" + } + } + }, + "canonical": true, + "origin": "API_DEFINITION", + "segments": [ + { + "start": 20, + "end": 53, + "type": "FULL" + } + ] + }, + { + "region_tag": "oracledatabase_v1_generated_OracleDatabase_DeleteAutonomousDatabase_sync", + "title": "Snippet for the delete_autonomous_database call in the OracleDatabase service", + "description": "This is an auto-generated example demonstrating basic usage of Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::Client#delete_autonomous_database.", + "file": "oracle_database/delete_autonomous_database.rb", + "language": "RUBY", + "client_method": { + "short_name": "delete_autonomous_database", + "full_name": "::Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::Client#delete_autonomous_database", + "async": false, + "parameters": [ + { + "type": "::Google::Cloud::OracleDatabase::V1::DeleteAutonomousDatabaseRequest", + "name": "request" + } + ], + "result_type": "::Google::Longrunning::Operation", + "client": { + "short_name": "OracleDatabase::Rest::Client", + "full_name": "::Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::Client" + }, + "method": { + "short_name": "DeleteAutonomousDatabase", + "full_name": "google.cloud.oracledatabase.v1.OracleDatabase.DeleteAutonomousDatabase", + "service": { + "short_name": "OracleDatabase", + "full_name": "google.cloud.oracledatabase.v1.OracleDatabase" + } + } + }, + "canonical": true, + "origin": "API_DEFINITION", + "segments": [ + { + "start": 20, + "end": 53, + "type": "FULL" + } + ] + }, + { + "region_tag": "oracledatabase_v1_generated_OracleDatabase_RestoreAutonomousDatabase_sync", + "title": "Snippet for the restore_autonomous_database call in the OracleDatabase service", + "description": "This is an auto-generated example demonstrating basic usage of Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::Client#restore_autonomous_database.", + "file": "oracle_database/restore_autonomous_database.rb", + "language": "RUBY", + "client_method": { + "short_name": "restore_autonomous_database", + "full_name": "::Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::Client#restore_autonomous_database", + "async": false, + "parameters": [ + { + "type": "::Google::Cloud::OracleDatabase::V1::RestoreAutonomousDatabaseRequest", + "name": "request" + } + ], + "result_type": "::Google::Longrunning::Operation", + "client": { + "short_name": "OracleDatabase::Rest::Client", + "full_name": "::Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::Client" + }, + "method": { + "short_name": "RestoreAutonomousDatabase", + "full_name": "google.cloud.oracledatabase.v1.OracleDatabase.RestoreAutonomousDatabase", + "service": { + "short_name": "OracleDatabase", + "full_name": "google.cloud.oracledatabase.v1.OracleDatabase" + } + } + }, + "canonical": true, + "origin": "API_DEFINITION", + "segments": [ + { + "start": 20, + "end": 53, + "type": "FULL" + } + ] + }, + { + "region_tag": "oracledatabase_v1_generated_OracleDatabase_GenerateAutonomousDatabaseWallet_sync", + "title": "Snippet for the generate_autonomous_database_wallet call in the OracleDatabase service", + "description": "This is an auto-generated example demonstrating basic usage of Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::Client#generate_autonomous_database_wallet.", + "file": "oracle_database/generate_autonomous_database_wallet.rb", + "language": "RUBY", + "client_method": { + "short_name": "generate_autonomous_database_wallet", + "full_name": "::Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::Client#generate_autonomous_database_wallet", + "async": false, + "parameters": [ + { + "type": "::Google::Cloud::OracleDatabase::V1::GenerateAutonomousDatabaseWalletRequest", + "name": "request" + } + ], + "result_type": "::Google::Cloud::OracleDatabase::V1::GenerateAutonomousDatabaseWalletResponse", + "client": { + "short_name": "OracleDatabase::Rest::Client", + "full_name": "::Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::Client" + }, + "method": { + "short_name": "GenerateAutonomousDatabaseWallet", + "full_name": "google.cloud.oracledatabase.v1.OracleDatabase.GenerateAutonomousDatabaseWallet", + "service": { + "short_name": "OracleDatabase", + "full_name": "google.cloud.oracledatabase.v1.OracleDatabase" + } + } + }, + "canonical": true, + "origin": "API_DEFINITION", + "segments": [ + { + "start": 20, + "end": 46, + "type": "FULL" + } + ] + }, + { + "region_tag": "oracledatabase_v1_generated_OracleDatabase_ListAutonomousDbVersions_sync", + "title": "Snippet for the list_autonomous_db_versions call in the OracleDatabase service", + "description": "This is an auto-generated example demonstrating basic usage of Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::Client#list_autonomous_db_versions.", + "file": "oracle_database/list_autonomous_db_versions.rb", + "language": "RUBY", + "client_method": { + "short_name": "list_autonomous_db_versions", + "full_name": "::Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::Client#list_autonomous_db_versions", + "async": false, + "parameters": [ + { + "type": "::Google::Cloud::OracleDatabase::V1::ListAutonomousDbVersionsRequest", + "name": "request" + } + ], + "result_type": "::Google::Cloud::OracleDatabase::V1::ListAutonomousDbVersionsResponse", + "client": { + "short_name": "OracleDatabase::Rest::Client", + "full_name": "::Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::Client" + }, + "method": { + "short_name": "ListAutonomousDbVersions", + "full_name": "google.cloud.oracledatabase.v1.OracleDatabase.ListAutonomousDbVersions", + "service": { + "short_name": "OracleDatabase", + "full_name": "google.cloud.oracledatabase.v1.OracleDatabase" + } + } + }, + "canonical": true, + "origin": "API_DEFINITION", + "segments": [ + { + "start": 20, + "end": 50, + "type": "FULL" + } + ] + }, + { + "region_tag": "oracledatabase_v1_generated_OracleDatabase_ListAutonomousDatabaseCharacterSets_sync", + "title": "Snippet for the list_autonomous_database_character_sets call in the OracleDatabase service", + "description": "This is an auto-generated example demonstrating basic usage of Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::Client#list_autonomous_database_character_sets.", + "file": "oracle_database/list_autonomous_database_character_sets.rb", + "language": "RUBY", + "client_method": { + "short_name": "list_autonomous_database_character_sets", + "full_name": "::Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::Client#list_autonomous_database_character_sets", + "async": false, + "parameters": [ + { + "type": "::Google::Cloud::OracleDatabase::V1::ListAutonomousDatabaseCharacterSetsRequest", + "name": "request" + } + ], + "result_type": "::Google::Cloud::OracleDatabase::V1::ListAutonomousDatabaseCharacterSetsResponse", + "client": { + "short_name": "OracleDatabase::Rest::Client", + "full_name": "::Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::Client" + }, + "method": { + "short_name": "ListAutonomousDatabaseCharacterSets", + "full_name": "google.cloud.oracledatabase.v1.OracleDatabase.ListAutonomousDatabaseCharacterSets", + "service": { + "short_name": "OracleDatabase", + "full_name": "google.cloud.oracledatabase.v1.OracleDatabase" + } + } + }, + "canonical": true, + "origin": "API_DEFINITION", + "segments": [ + { + "start": 20, + "end": 50, + "type": "FULL" + } + ] + }, + { + "region_tag": "oracledatabase_v1_generated_OracleDatabase_ListAutonomousDatabaseBackups_sync", + "title": "Snippet for the list_autonomous_database_backups call in the OracleDatabase service", + "description": "This is an auto-generated example demonstrating basic usage of Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::Client#list_autonomous_database_backups.", + "file": "oracle_database/list_autonomous_database_backups.rb", + "language": "RUBY", + "client_method": { + "short_name": "list_autonomous_database_backups", + "full_name": "::Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::Client#list_autonomous_database_backups", + "async": false, + "parameters": [ + { + "type": "::Google::Cloud::OracleDatabase::V1::ListAutonomousDatabaseBackupsRequest", + "name": "request" + } + ], + "result_type": "::Google::Cloud::OracleDatabase::V1::ListAutonomousDatabaseBackupsResponse", + "client": { + "short_name": "OracleDatabase::Rest::Client", + "full_name": "::Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::Client" + }, + "method": { + "short_name": "ListAutonomousDatabaseBackups", + "full_name": "google.cloud.oracledatabase.v1.OracleDatabase.ListAutonomousDatabaseBackups", + "service": { + "short_name": "OracleDatabase", + "full_name": "google.cloud.oracledatabase.v1.OracleDatabase" + } + } + }, + "canonical": true, + "origin": "API_DEFINITION", + "segments": [ + { + "start": 20, + "end": 50, + "type": "FULL" + } + ] + } + ] +} \ No newline at end of file diff --git a/google-cloud-oracle_database-v1/test/google/cloud/oracle_database/v1/oracle_database_rest_test.rb b/google-cloud-oracle_database-v1/test/google/cloud/oracle_database/v1/oracle_database_rest_test.rb new file mode 100644 index 000000000000..6f3a60f49e8c --- /dev/null +++ b/google-cloud-oracle_database-v1/test/google/cloud/oracle_database/v1/oracle_database_rest_test.rb @@ -0,0 +1,1324 @@ +# frozen_string_literal: true + +# Copyright 2024 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# https://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Auto-generated by gapic-generator-ruby. DO NOT EDIT! + +require "helper" +require "gapic/rest" +require "google/cloud/oracledatabase/v1/oracledatabase_pb" +require "google/cloud/oracle_database/v1/oracle_database/rest" + + +class ::Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::ClientTest < Minitest::Test + class ClientStub + attr_accessor :call_count, :requests + + def initialize response, &block + @response = response + @block = block + @call_count = 0 + @requests = [] + end + + def make_get_request uri:, params: {}, options: {} + make_http_request :get, uri: uri, body: nil, params: params, options: options + end + + def make_delete_request uri:, params: {}, options: {} + make_http_request :delete, uri: uri, body: nil, params: params, options: options + end + + def make_post_request uri:, body: nil, params: {}, options: {} + make_http_request :post, uri: uri, body: body, params: params, options: options + end + + def make_patch_request uri:, body:, params: {}, options: {} + make_http_request :patch, uri: uri, body: body, params: params, options: options + end + + def make_put_request uri:, body:, params: {}, options: {} + make_http_request :put, uri: uri, body: body, params: params, options: options + end + + def make_http_request *args, **kwargs + @call_count += 1 + + @requests << @block&.call(*args, **kwargs) + + @response + end + + def endpoint + "endpoint.example.com" + end + + def universe_domain + "example.com" + end + end + + def test_list_cloud_exadata_infrastructures + # Create test objects. + client_result = ::Google::Cloud::OracleDatabase::V1::ListCloudExadataInfrastructuresResponse.new + http_response = OpenStruct.new body: client_result.to_json + + call_options = {} + + # Create request parameters for a unary method. + parent = "hello world" + page_size = 42 + page_token = "hello world" + + list_cloud_exadata_infrastructures_client_stub = ClientStub.new http_response do |_verb, uri:, body:, params:, options:| + assert options.metadata.key? :"x-goog-api-client" + assert options.metadata[:"x-goog-api-client"].include? "rest" + refute options.metadata[:"x-goog-api-client"].include? "grpc" + end + + ::Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::ServiceStub.stub :transcode_list_cloud_exadata_infrastructures_request, ["", "", {}] do + Gapic::Rest::ClientStub.stub :new, list_cloud_exadata_infrastructures_client_stub do + # Create client + client = ::Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::Client.new do |config| + config.credentials = :dummy_value + end + + # Use hash object + client.list_cloud_exadata_infrastructures({ parent: parent, page_size: page_size, page_token: page_token }) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use named arguments + client.list_cloud_exadata_infrastructures parent: parent, page_size: page_size, page_token: page_token do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use protobuf object + client.list_cloud_exadata_infrastructures ::Google::Cloud::OracleDatabase::V1::ListCloudExadataInfrastructuresRequest.new(parent: parent, page_size: page_size, page_token: page_token) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use hash object with options + client.list_cloud_exadata_infrastructures({ parent: parent, page_size: page_size, page_token: page_token }, call_options) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use protobuf object with options + client.list_cloud_exadata_infrastructures(::Google::Cloud::OracleDatabase::V1::ListCloudExadataInfrastructuresRequest.new(parent: parent, page_size: page_size, page_token: page_token), call_options) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Verify method calls + assert_equal 5, list_cloud_exadata_infrastructures_client_stub.call_count + end + end + end + + def test_get_cloud_exadata_infrastructure + # Create test objects. + client_result = ::Google::Cloud::OracleDatabase::V1::CloudExadataInfrastructure.new + http_response = OpenStruct.new body: client_result.to_json + + call_options = {} + + # Create request parameters for a unary method. + name = "hello world" + + get_cloud_exadata_infrastructure_client_stub = ClientStub.new http_response do |_verb, uri:, body:, params:, options:| + assert options.metadata.key? :"x-goog-api-client" + assert options.metadata[:"x-goog-api-client"].include? "rest" + refute options.metadata[:"x-goog-api-client"].include? "grpc" + end + + ::Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::ServiceStub.stub :transcode_get_cloud_exadata_infrastructure_request, ["", "", {}] do + Gapic::Rest::ClientStub.stub :new, get_cloud_exadata_infrastructure_client_stub do + # Create client + client = ::Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::Client.new do |config| + config.credentials = :dummy_value + end + + # Use hash object + client.get_cloud_exadata_infrastructure({ name: name }) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use named arguments + client.get_cloud_exadata_infrastructure name: name do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use protobuf object + client.get_cloud_exadata_infrastructure ::Google::Cloud::OracleDatabase::V1::GetCloudExadataInfrastructureRequest.new(name: name) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use hash object with options + client.get_cloud_exadata_infrastructure({ name: name }, call_options) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use protobuf object with options + client.get_cloud_exadata_infrastructure(::Google::Cloud::OracleDatabase::V1::GetCloudExadataInfrastructureRequest.new(name: name), call_options) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Verify method calls + assert_equal 5, get_cloud_exadata_infrastructure_client_stub.call_count + end + end + end + + def test_create_cloud_exadata_infrastructure + # Create test objects. + client_result = ::Google::Longrunning::Operation.new + http_response = OpenStruct.new body: client_result.to_json + + call_options = {} + + # Create request parameters for a unary method. + parent = "hello world" + cloud_exadata_infrastructure_id = "hello world" + cloud_exadata_infrastructure = {} + request_id = "hello world" + + create_cloud_exadata_infrastructure_client_stub = ClientStub.new http_response do |_verb, uri:, body:, params:, options:| + assert options.metadata.key? :"x-goog-api-client" + assert options.metadata[:"x-goog-api-client"].include? "rest" + refute options.metadata[:"x-goog-api-client"].include? "grpc" + end + + ::Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::ServiceStub.stub :transcode_create_cloud_exadata_infrastructure_request, ["", "", {}] do + Gapic::Rest::ClientStub.stub :new, create_cloud_exadata_infrastructure_client_stub do + # Create client + client = ::Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::Client.new do |config| + config.credentials = :dummy_value + end + + # Use hash object + client.create_cloud_exadata_infrastructure({ parent: parent, cloud_exadata_infrastructure_id: cloud_exadata_infrastructure_id, cloud_exadata_infrastructure: cloud_exadata_infrastructure, request_id: request_id }) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use named arguments + client.create_cloud_exadata_infrastructure parent: parent, cloud_exadata_infrastructure_id: cloud_exadata_infrastructure_id, cloud_exadata_infrastructure: cloud_exadata_infrastructure, request_id: request_id do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use protobuf object + client.create_cloud_exadata_infrastructure ::Google::Cloud::OracleDatabase::V1::CreateCloudExadataInfrastructureRequest.new(parent: parent, cloud_exadata_infrastructure_id: cloud_exadata_infrastructure_id, cloud_exadata_infrastructure: cloud_exadata_infrastructure, request_id: request_id) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use hash object with options + client.create_cloud_exadata_infrastructure({ parent: parent, cloud_exadata_infrastructure_id: cloud_exadata_infrastructure_id, cloud_exadata_infrastructure: cloud_exadata_infrastructure, request_id: request_id }, call_options) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use protobuf object with options + client.create_cloud_exadata_infrastructure(::Google::Cloud::OracleDatabase::V1::CreateCloudExadataInfrastructureRequest.new(parent: parent, cloud_exadata_infrastructure_id: cloud_exadata_infrastructure_id, cloud_exadata_infrastructure: cloud_exadata_infrastructure, request_id: request_id), call_options) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Verify method calls + assert_equal 5, create_cloud_exadata_infrastructure_client_stub.call_count + end + end + end + + def test_delete_cloud_exadata_infrastructure + # Create test objects. + client_result = ::Google::Longrunning::Operation.new + http_response = OpenStruct.new body: client_result.to_json + + call_options = {} + + # Create request parameters for a unary method. + name = "hello world" + request_id = "hello world" + force = true + + delete_cloud_exadata_infrastructure_client_stub = ClientStub.new http_response do |_verb, uri:, body:, params:, options:| + assert options.metadata.key? :"x-goog-api-client" + assert options.metadata[:"x-goog-api-client"].include? "rest" + refute options.metadata[:"x-goog-api-client"].include? "grpc" + end + + ::Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::ServiceStub.stub :transcode_delete_cloud_exadata_infrastructure_request, ["", "", {}] do + Gapic::Rest::ClientStub.stub :new, delete_cloud_exadata_infrastructure_client_stub do + # Create client + client = ::Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::Client.new do |config| + config.credentials = :dummy_value + end + + # Use hash object + client.delete_cloud_exadata_infrastructure({ name: name, request_id: request_id, force: force }) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use named arguments + client.delete_cloud_exadata_infrastructure name: name, request_id: request_id, force: force do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use protobuf object + client.delete_cloud_exadata_infrastructure ::Google::Cloud::OracleDatabase::V1::DeleteCloudExadataInfrastructureRequest.new(name: name, request_id: request_id, force: force) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use hash object with options + client.delete_cloud_exadata_infrastructure({ name: name, request_id: request_id, force: force }, call_options) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use protobuf object with options + client.delete_cloud_exadata_infrastructure(::Google::Cloud::OracleDatabase::V1::DeleteCloudExadataInfrastructureRequest.new(name: name, request_id: request_id, force: force), call_options) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Verify method calls + assert_equal 5, delete_cloud_exadata_infrastructure_client_stub.call_count + end + end + end + + def test_list_cloud_vm_clusters + # Create test objects. + client_result = ::Google::Cloud::OracleDatabase::V1::ListCloudVmClustersResponse.new + http_response = OpenStruct.new body: client_result.to_json + + call_options = {} + + # Create request parameters for a unary method. + parent = "hello world" + page_size = 42 + page_token = "hello world" + filter = "hello world" + + list_cloud_vm_clusters_client_stub = ClientStub.new http_response do |_verb, uri:, body:, params:, options:| + assert options.metadata.key? :"x-goog-api-client" + assert options.metadata[:"x-goog-api-client"].include? "rest" + refute options.metadata[:"x-goog-api-client"].include? "grpc" + end + + ::Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::ServiceStub.stub :transcode_list_cloud_vm_clusters_request, ["", "", {}] do + Gapic::Rest::ClientStub.stub :new, list_cloud_vm_clusters_client_stub do + # Create client + client = ::Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::Client.new do |config| + config.credentials = :dummy_value + end + + # Use hash object + client.list_cloud_vm_clusters({ parent: parent, page_size: page_size, page_token: page_token, filter: filter }) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use named arguments + client.list_cloud_vm_clusters parent: parent, page_size: page_size, page_token: page_token, filter: filter do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use protobuf object + client.list_cloud_vm_clusters ::Google::Cloud::OracleDatabase::V1::ListCloudVmClustersRequest.new(parent: parent, page_size: page_size, page_token: page_token, filter: filter) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use hash object with options + client.list_cloud_vm_clusters({ parent: parent, page_size: page_size, page_token: page_token, filter: filter }, call_options) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use protobuf object with options + client.list_cloud_vm_clusters(::Google::Cloud::OracleDatabase::V1::ListCloudVmClustersRequest.new(parent: parent, page_size: page_size, page_token: page_token, filter: filter), call_options) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Verify method calls + assert_equal 5, list_cloud_vm_clusters_client_stub.call_count + end + end + end + + def test_get_cloud_vm_cluster + # Create test objects. + client_result = ::Google::Cloud::OracleDatabase::V1::CloudVmCluster.new + http_response = OpenStruct.new body: client_result.to_json + + call_options = {} + + # Create request parameters for a unary method. + name = "hello world" + + get_cloud_vm_cluster_client_stub = ClientStub.new http_response do |_verb, uri:, body:, params:, options:| + assert options.metadata.key? :"x-goog-api-client" + assert options.metadata[:"x-goog-api-client"].include? "rest" + refute options.metadata[:"x-goog-api-client"].include? "grpc" + end + + ::Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::ServiceStub.stub :transcode_get_cloud_vm_cluster_request, ["", "", {}] do + Gapic::Rest::ClientStub.stub :new, get_cloud_vm_cluster_client_stub do + # Create client + client = ::Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::Client.new do |config| + config.credentials = :dummy_value + end + + # Use hash object + client.get_cloud_vm_cluster({ name: name }) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use named arguments + client.get_cloud_vm_cluster name: name do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use protobuf object + client.get_cloud_vm_cluster ::Google::Cloud::OracleDatabase::V1::GetCloudVmClusterRequest.new(name: name) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use hash object with options + client.get_cloud_vm_cluster({ name: name }, call_options) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use protobuf object with options + client.get_cloud_vm_cluster(::Google::Cloud::OracleDatabase::V1::GetCloudVmClusterRequest.new(name: name), call_options) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Verify method calls + assert_equal 5, get_cloud_vm_cluster_client_stub.call_count + end + end + end + + def test_create_cloud_vm_cluster + # Create test objects. + client_result = ::Google::Longrunning::Operation.new + http_response = OpenStruct.new body: client_result.to_json + + call_options = {} + + # Create request parameters for a unary method. + parent = "hello world" + cloud_vm_cluster_id = "hello world" + cloud_vm_cluster = {} + request_id = "hello world" + + create_cloud_vm_cluster_client_stub = ClientStub.new http_response do |_verb, uri:, body:, params:, options:| + assert options.metadata.key? :"x-goog-api-client" + assert options.metadata[:"x-goog-api-client"].include? "rest" + refute options.metadata[:"x-goog-api-client"].include? "grpc" + end + + ::Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::ServiceStub.stub :transcode_create_cloud_vm_cluster_request, ["", "", {}] do + Gapic::Rest::ClientStub.stub :new, create_cloud_vm_cluster_client_stub do + # Create client + client = ::Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::Client.new do |config| + config.credentials = :dummy_value + end + + # Use hash object + client.create_cloud_vm_cluster({ parent: parent, cloud_vm_cluster_id: cloud_vm_cluster_id, cloud_vm_cluster: cloud_vm_cluster, request_id: request_id }) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use named arguments + client.create_cloud_vm_cluster parent: parent, cloud_vm_cluster_id: cloud_vm_cluster_id, cloud_vm_cluster: cloud_vm_cluster, request_id: request_id do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use protobuf object + client.create_cloud_vm_cluster ::Google::Cloud::OracleDatabase::V1::CreateCloudVmClusterRequest.new(parent: parent, cloud_vm_cluster_id: cloud_vm_cluster_id, cloud_vm_cluster: cloud_vm_cluster, request_id: request_id) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use hash object with options + client.create_cloud_vm_cluster({ parent: parent, cloud_vm_cluster_id: cloud_vm_cluster_id, cloud_vm_cluster: cloud_vm_cluster, request_id: request_id }, call_options) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use protobuf object with options + client.create_cloud_vm_cluster(::Google::Cloud::OracleDatabase::V1::CreateCloudVmClusterRequest.new(parent: parent, cloud_vm_cluster_id: cloud_vm_cluster_id, cloud_vm_cluster: cloud_vm_cluster, request_id: request_id), call_options) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Verify method calls + assert_equal 5, create_cloud_vm_cluster_client_stub.call_count + end + end + end + + def test_delete_cloud_vm_cluster + # Create test objects. + client_result = ::Google::Longrunning::Operation.new + http_response = OpenStruct.new body: client_result.to_json + + call_options = {} + + # Create request parameters for a unary method. + name = "hello world" + request_id = "hello world" + force = true + + delete_cloud_vm_cluster_client_stub = ClientStub.new http_response do |_verb, uri:, body:, params:, options:| + assert options.metadata.key? :"x-goog-api-client" + assert options.metadata[:"x-goog-api-client"].include? "rest" + refute options.metadata[:"x-goog-api-client"].include? "grpc" + end + + ::Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::ServiceStub.stub :transcode_delete_cloud_vm_cluster_request, ["", "", {}] do + Gapic::Rest::ClientStub.stub :new, delete_cloud_vm_cluster_client_stub do + # Create client + client = ::Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::Client.new do |config| + config.credentials = :dummy_value + end + + # Use hash object + client.delete_cloud_vm_cluster({ name: name, request_id: request_id, force: force }) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use named arguments + client.delete_cloud_vm_cluster name: name, request_id: request_id, force: force do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use protobuf object + client.delete_cloud_vm_cluster ::Google::Cloud::OracleDatabase::V1::DeleteCloudVmClusterRequest.new(name: name, request_id: request_id, force: force) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use hash object with options + client.delete_cloud_vm_cluster({ name: name, request_id: request_id, force: force }, call_options) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use protobuf object with options + client.delete_cloud_vm_cluster(::Google::Cloud::OracleDatabase::V1::DeleteCloudVmClusterRequest.new(name: name, request_id: request_id, force: force), call_options) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Verify method calls + assert_equal 5, delete_cloud_vm_cluster_client_stub.call_count + end + end + end + + def test_list_entitlements + # Create test objects. + client_result = ::Google::Cloud::OracleDatabase::V1::ListEntitlementsResponse.new + http_response = OpenStruct.new body: client_result.to_json + + call_options = {} + + # Create request parameters for a unary method. + parent = "hello world" + page_size = 42 + page_token = "hello world" + + list_entitlements_client_stub = ClientStub.new http_response do |_verb, uri:, body:, params:, options:| + assert options.metadata.key? :"x-goog-api-client" + assert options.metadata[:"x-goog-api-client"].include? "rest" + refute options.metadata[:"x-goog-api-client"].include? "grpc" + end + + ::Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::ServiceStub.stub :transcode_list_entitlements_request, ["", "", {}] do + Gapic::Rest::ClientStub.stub :new, list_entitlements_client_stub do + # Create client + client = ::Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::Client.new do |config| + config.credentials = :dummy_value + end + + # Use hash object + client.list_entitlements({ parent: parent, page_size: page_size, page_token: page_token }) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use named arguments + client.list_entitlements parent: parent, page_size: page_size, page_token: page_token do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use protobuf object + client.list_entitlements ::Google::Cloud::OracleDatabase::V1::ListEntitlementsRequest.new(parent: parent, page_size: page_size, page_token: page_token) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use hash object with options + client.list_entitlements({ parent: parent, page_size: page_size, page_token: page_token }, call_options) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use protobuf object with options + client.list_entitlements(::Google::Cloud::OracleDatabase::V1::ListEntitlementsRequest.new(parent: parent, page_size: page_size, page_token: page_token), call_options) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Verify method calls + assert_equal 5, list_entitlements_client_stub.call_count + end + end + end + + def test_list_db_servers + # Create test objects. + client_result = ::Google::Cloud::OracleDatabase::V1::ListDbServersResponse.new + http_response = OpenStruct.new body: client_result.to_json + + call_options = {} + + # Create request parameters for a unary method. + parent = "hello world" + page_size = 42 + page_token = "hello world" + + list_db_servers_client_stub = ClientStub.new http_response do |_verb, uri:, body:, params:, options:| + assert options.metadata.key? :"x-goog-api-client" + assert options.metadata[:"x-goog-api-client"].include? "rest" + refute options.metadata[:"x-goog-api-client"].include? "grpc" + end + + ::Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::ServiceStub.stub :transcode_list_db_servers_request, ["", "", {}] do + Gapic::Rest::ClientStub.stub :new, list_db_servers_client_stub do + # Create client + client = ::Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::Client.new do |config| + config.credentials = :dummy_value + end + + # Use hash object + client.list_db_servers({ parent: parent, page_size: page_size, page_token: page_token }) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use named arguments + client.list_db_servers parent: parent, page_size: page_size, page_token: page_token do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use protobuf object + client.list_db_servers ::Google::Cloud::OracleDatabase::V1::ListDbServersRequest.new(parent: parent, page_size: page_size, page_token: page_token) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use hash object with options + client.list_db_servers({ parent: parent, page_size: page_size, page_token: page_token }, call_options) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use protobuf object with options + client.list_db_servers(::Google::Cloud::OracleDatabase::V1::ListDbServersRequest.new(parent: parent, page_size: page_size, page_token: page_token), call_options) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Verify method calls + assert_equal 5, list_db_servers_client_stub.call_count + end + end + end + + def test_list_db_nodes + # Create test objects. + client_result = ::Google::Cloud::OracleDatabase::V1::ListDbNodesResponse.new + http_response = OpenStruct.new body: client_result.to_json + + call_options = {} + + # Create request parameters for a unary method. + parent = "hello world" + page_size = 42 + page_token = "hello world" + + list_db_nodes_client_stub = ClientStub.new http_response do |_verb, uri:, body:, params:, options:| + assert options.metadata.key? :"x-goog-api-client" + assert options.metadata[:"x-goog-api-client"].include? "rest" + refute options.metadata[:"x-goog-api-client"].include? "grpc" + end + + ::Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::ServiceStub.stub :transcode_list_db_nodes_request, ["", "", {}] do + Gapic::Rest::ClientStub.stub :new, list_db_nodes_client_stub do + # Create client + client = ::Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::Client.new do |config| + config.credentials = :dummy_value + end + + # Use hash object + client.list_db_nodes({ parent: parent, page_size: page_size, page_token: page_token }) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use named arguments + client.list_db_nodes parent: parent, page_size: page_size, page_token: page_token do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use protobuf object + client.list_db_nodes ::Google::Cloud::OracleDatabase::V1::ListDbNodesRequest.new(parent: parent, page_size: page_size, page_token: page_token) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use hash object with options + client.list_db_nodes({ parent: parent, page_size: page_size, page_token: page_token }, call_options) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use protobuf object with options + client.list_db_nodes(::Google::Cloud::OracleDatabase::V1::ListDbNodesRequest.new(parent: parent, page_size: page_size, page_token: page_token), call_options) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Verify method calls + assert_equal 5, list_db_nodes_client_stub.call_count + end + end + end + + def test_list_gi_versions + # Create test objects. + client_result = ::Google::Cloud::OracleDatabase::V1::ListGiVersionsResponse.new + http_response = OpenStruct.new body: client_result.to_json + + call_options = {} + + # Create request parameters for a unary method. + parent = "hello world" + page_size = 42 + page_token = "hello world" + + list_gi_versions_client_stub = ClientStub.new http_response do |_verb, uri:, body:, params:, options:| + assert options.metadata.key? :"x-goog-api-client" + assert options.metadata[:"x-goog-api-client"].include? "rest" + refute options.metadata[:"x-goog-api-client"].include? "grpc" + end + + ::Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::ServiceStub.stub :transcode_list_gi_versions_request, ["", "", {}] do + Gapic::Rest::ClientStub.stub :new, list_gi_versions_client_stub do + # Create client + client = ::Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::Client.new do |config| + config.credentials = :dummy_value + end + + # Use hash object + client.list_gi_versions({ parent: parent, page_size: page_size, page_token: page_token }) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use named arguments + client.list_gi_versions parent: parent, page_size: page_size, page_token: page_token do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use protobuf object + client.list_gi_versions ::Google::Cloud::OracleDatabase::V1::ListGiVersionsRequest.new(parent: parent, page_size: page_size, page_token: page_token) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use hash object with options + client.list_gi_versions({ parent: parent, page_size: page_size, page_token: page_token }, call_options) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use protobuf object with options + client.list_gi_versions(::Google::Cloud::OracleDatabase::V1::ListGiVersionsRequest.new(parent: parent, page_size: page_size, page_token: page_token), call_options) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Verify method calls + assert_equal 5, list_gi_versions_client_stub.call_count + end + end + end + + def test_list_db_system_shapes + # Create test objects. + client_result = ::Google::Cloud::OracleDatabase::V1::ListDbSystemShapesResponse.new + http_response = OpenStruct.new body: client_result.to_json + + call_options = {} + + # Create request parameters for a unary method. + parent = "hello world" + page_size = 42 + page_token = "hello world" + + list_db_system_shapes_client_stub = ClientStub.new http_response do |_verb, uri:, body:, params:, options:| + assert options.metadata.key? :"x-goog-api-client" + assert options.metadata[:"x-goog-api-client"].include? "rest" + refute options.metadata[:"x-goog-api-client"].include? "grpc" + end + + ::Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::ServiceStub.stub :transcode_list_db_system_shapes_request, ["", "", {}] do + Gapic::Rest::ClientStub.stub :new, list_db_system_shapes_client_stub do + # Create client + client = ::Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::Client.new do |config| + config.credentials = :dummy_value + end + + # Use hash object + client.list_db_system_shapes({ parent: parent, page_size: page_size, page_token: page_token }) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use named arguments + client.list_db_system_shapes parent: parent, page_size: page_size, page_token: page_token do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use protobuf object + client.list_db_system_shapes ::Google::Cloud::OracleDatabase::V1::ListDbSystemShapesRequest.new(parent: parent, page_size: page_size, page_token: page_token) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use hash object with options + client.list_db_system_shapes({ parent: parent, page_size: page_size, page_token: page_token }, call_options) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use protobuf object with options + client.list_db_system_shapes(::Google::Cloud::OracleDatabase::V1::ListDbSystemShapesRequest.new(parent: parent, page_size: page_size, page_token: page_token), call_options) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Verify method calls + assert_equal 5, list_db_system_shapes_client_stub.call_count + end + end + end + + def test_list_autonomous_databases + # Create test objects. + client_result = ::Google::Cloud::OracleDatabase::V1::ListAutonomousDatabasesResponse.new + http_response = OpenStruct.new body: client_result.to_json + + call_options = {} + + # Create request parameters for a unary method. + parent = "hello world" + page_size = 42 + page_token = "hello world" + filter = "hello world" + order_by = "hello world" + + list_autonomous_databases_client_stub = ClientStub.new http_response do |_verb, uri:, body:, params:, options:| + assert options.metadata.key? :"x-goog-api-client" + assert options.metadata[:"x-goog-api-client"].include? "rest" + refute options.metadata[:"x-goog-api-client"].include? "grpc" + end + + ::Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::ServiceStub.stub :transcode_list_autonomous_databases_request, ["", "", {}] do + Gapic::Rest::ClientStub.stub :new, list_autonomous_databases_client_stub do + # Create client + client = ::Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::Client.new do |config| + config.credentials = :dummy_value + end + + # Use hash object + client.list_autonomous_databases({ parent: parent, page_size: page_size, page_token: page_token, filter: filter, order_by: order_by }) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use named arguments + client.list_autonomous_databases parent: parent, page_size: page_size, page_token: page_token, filter: filter, order_by: order_by do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use protobuf object + client.list_autonomous_databases ::Google::Cloud::OracleDatabase::V1::ListAutonomousDatabasesRequest.new(parent: parent, page_size: page_size, page_token: page_token, filter: filter, order_by: order_by) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use hash object with options + client.list_autonomous_databases({ parent: parent, page_size: page_size, page_token: page_token, filter: filter, order_by: order_by }, call_options) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use protobuf object with options + client.list_autonomous_databases(::Google::Cloud::OracleDatabase::V1::ListAutonomousDatabasesRequest.new(parent: parent, page_size: page_size, page_token: page_token, filter: filter, order_by: order_by), call_options) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Verify method calls + assert_equal 5, list_autonomous_databases_client_stub.call_count + end + end + end + + def test_get_autonomous_database + # Create test objects. + client_result = ::Google::Cloud::OracleDatabase::V1::AutonomousDatabase.new + http_response = OpenStruct.new body: client_result.to_json + + call_options = {} + + # Create request parameters for a unary method. + name = "hello world" + + get_autonomous_database_client_stub = ClientStub.new http_response do |_verb, uri:, body:, params:, options:| + assert options.metadata.key? :"x-goog-api-client" + assert options.metadata[:"x-goog-api-client"].include? "rest" + refute options.metadata[:"x-goog-api-client"].include? "grpc" + end + + ::Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::ServiceStub.stub :transcode_get_autonomous_database_request, ["", "", {}] do + Gapic::Rest::ClientStub.stub :new, get_autonomous_database_client_stub do + # Create client + client = ::Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::Client.new do |config| + config.credentials = :dummy_value + end + + # Use hash object + client.get_autonomous_database({ name: name }) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use named arguments + client.get_autonomous_database name: name do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use protobuf object + client.get_autonomous_database ::Google::Cloud::OracleDatabase::V1::GetAutonomousDatabaseRequest.new(name: name) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use hash object with options + client.get_autonomous_database({ name: name }, call_options) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use protobuf object with options + client.get_autonomous_database(::Google::Cloud::OracleDatabase::V1::GetAutonomousDatabaseRequest.new(name: name), call_options) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Verify method calls + assert_equal 5, get_autonomous_database_client_stub.call_count + end + end + end + + def test_create_autonomous_database + # Create test objects. + client_result = ::Google::Longrunning::Operation.new + http_response = OpenStruct.new body: client_result.to_json + + call_options = {} + + # Create request parameters for a unary method. + parent = "hello world" + autonomous_database_id = "hello world" + autonomous_database = {} + request_id = "hello world" + + create_autonomous_database_client_stub = ClientStub.new http_response do |_verb, uri:, body:, params:, options:| + assert options.metadata.key? :"x-goog-api-client" + assert options.metadata[:"x-goog-api-client"].include? "rest" + refute options.metadata[:"x-goog-api-client"].include? "grpc" + end + + ::Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::ServiceStub.stub :transcode_create_autonomous_database_request, ["", "", {}] do + Gapic::Rest::ClientStub.stub :new, create_autonomous_database_client_stub do + # Create client + client = ::Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::Client.new do |config| + config.credentials = :dummy_value + end + + # Use hash object + client.create_autonomous_database({ parent: parent, autonomous_database_id: autonomous_database_id, autonomous_database: autonomous_database, request_id: request_id }) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use named arguments + client.create_autonomous_database parent: parent, autonomous_database_id: autonomous_database_id, autonomous_database: autonomous_database, request_id: request_id do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use protobuf object + client.create_autonomous_database ::Google::Cloud::OracleDatabase::V1::CreateAutonomousDatabaseRequest.new(parent: parent, autonomous_database_id: autonomous_database_id, autonomous_database: autonomous_database, request_id: request_id) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use hash object with options + client.create_autonomous_database({ parent: parent, autonomous_database_id: autonomous_database_id, autonomous_database: autonomous_database, request_id: request_id }, call_options) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use protobuf object with options + client.create_autonomous_database(::Google::Cloud::OracleDatabase::V1::CreateAutonomousDatabaseRequest.new(parent: parent, autonomous_database_id: autonomous_database_id, autonomous_database: autonomous_database, request_id: request_id), call_options) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Verify method calls + assert_equal 5, create_autonomous_database_client_stub.call_count + end + end + end + + def test_delete_autonomous_database + # Create test objects. + client_result = ::Google::Longrunning::Operation.new + http_response = OpenStruct.new body: client_result.to_json + + call_options = {} + + # Create request parameters for a unary method. + name = "hello world" + request_id = "hello world" + + delete_autonomous_database_client_stub = ClientStub.new http_response do |_verb, uri:, body:, params:, options:| + assert options.metadata.key? :"x-goog-api-client" + assert options.metadata[:"x-goog-api-client"].include? "rest" + refute options.metadata[:"x-goog-api-client"].include? "grpc" + end + + ::Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::ServiceStub.stub :transcode_delete_autonomous_database_request, ["", "", {}] do + Gapic::Rest::ClientStub.stub :new, delete_autonomous_database_client_stub do + # Create client + client = ::Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::Client.new do |config| + config.credentials = :dummy_value + end + + # Use hash object + client.delete_autonomous_database({ name: name, request_id: request_id }) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use named arguments + client.delete_autonomous_database name: name, request_id: request_id do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use protobuf object + client.delete_autonomous_database ::Google::Cloud::OracleDatabase::V1::DeleteAutonomousDatabaseRequest.new(name: name, request_id: request_id) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use hash object with options + client.delete_autonomous_database({ name: name, request_id: request_id }, call_options) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use protobuf object with options + client.delete_autonomous_database(::Google::Cloud::OracleDatabase::V1::DeleteAutonomousDatabaseRequest.new(name: name, request_id: request_id), call_options) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Verify method calls + assert_equal 5, delete_autonomous_database_client_stub.call_count + end + end + end + + def test_restore_autonomous_database + # Create test objects. + client_result = ::Google::Longrunning::Operation.new + http_response = OpenStruct.new body: client_result.to_json + + call_options = {} + + # Create request parameters for a unary method. + name = "hello world" + restore_time = {} + + restore_autonomous_database_client_stub = ClientStub.new http_response do |_verb, uri:, body:, params:, options:| + assert options.metadata.key? :"x-goog-api-client" + assert options.metadata[:"x-goog-api-client"].include? "rest" + refute options.metadata[:"x-goog-api-client"].include? "grpc" + end + + ::Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::ServiceStub.stub :transcode_restore_autonomous_database_request, ["", "", {}] do + Gapic::Rest::ClientStub.stub :new, restore_autonomous_database_client_stub do + # Create client + client = ::Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::Client.new do |config| + config.credentials = :dummy_value + end + + # Use hash object + client.restore_autonomous_database({ name: name, restore_time: restore_time }) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use named arguments + client.restore_autonomous_database name: name, restore_time: restore_time do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use protobuf object + client.restore_autonomous_database ::Google::Cloud::OracleDatabase::V1::RestoreAutonomousDatabaseRequest.new(name: name, restore_time: restore_time) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use hash object with options + client.restore_autonomous_database({ name: name, restore_time: restore_time }, call_options) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use protobuf object with options + client.restore_autonomous_database(::Google::Cloud::OracleDatabase::V1::RestoreAutonomousDatabaseRequest.new(name: name, restore_time: restore_time), call_options) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Verify method calls + assert_equal 5, restore_autonomous_database_client_stub.call_count + end + end + end + + def test_generate_autonomous_database_wallet + # Create test objects. + client_result = ::Google::Cloud::OracleDatabase::V1::GenerateAutonomousDatabaseWalletResponse.new + http_response = OpenStruct.new body: client_result.to_json + + call_options = {} + + # Create request parameters for a unary method. + name = "hello world" + type = :GENERATE_TYPE_UNSPECIFIED + is_regional = true + password = "hello world" + + generate_autonomous_database_wallet_client_stub = ClientStub.new http_response do |_verb, uri:, body:, params:, options:| + assert options.metadata.key? :"x-goog-api-client" + assert options.metadata[:"x-goog-api-client"].include? "rest" + refute options.metadata[:"x-goog-api-client"].include? "grpc" + end + + ::Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::ServiceStub.stub :transcode_generate_autonomous_database_wallet_request, ["", "", {}] do + Gapic::Rest::ClientStub.stub :new, generate_autonomous_database_wallet_client_stub do + # Create client + client = ::Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::Client.new do |config| + config.credentials = :dummy_value + end + + # Use hash object + client.generate_autonomous_database_wallet({ name: name, type: type, is_regional: is_regional, password: password }) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use named arguments + client.generate_autonomous_database_wallet name: name, type: type, is_regional: is_regional, password: password do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use protobuf object + client.generate_autonomous_database_wallet ::Google::Cloud::OracleDatabase::V1::GenerateAutonomousDatabaseWalletRequest.new(name: name, type: type, is_regional: is_regional, password: password) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use hash object with options + client.generate_autonomous_database_wallet({ name: name, type: type, is_regional: is_regional, password: password }, call_options) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use protobuf object with options + client.generate_autonomous_database_wallet(::Google::Cloud::OracleDatabase::V1::GenerateAutonomousDatabaseWalletRequest.new(name: name, type: type, is_regional: is_regional, password: password), call_options) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Verify method calls + assert_equal 5, generate_autonomous_database_wallet_client_stub.call_count + end + end + end + + def test_list_autonomous_db_versions + # Create test objects. + client_result = ::Google::Cloud::OracleDatabase::V1::ListAutonomousDbVersionsResponse.new + http_response = OpenStruct.new body: client_result.to_json + + call_options = {} + + # Create request parameters for a unary method. + parent = "hello world" + page_size = 42 + page_token = "hello world" + + list_autonomous_db_versions_client_stub = ClientStub.new http_response do |_verb, uri:, body:, params:, options:| + assert options.metadata.key? :"x-goog-api-client" + assert options.metadata[:"x-goog-api-client"].include? "rest" + refute options.metadata[:"x-goog-api-client"].include? "grpc" + end + + ::Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::ServiceStub.stub :transcode_list_autonomous_db_versions_request, ["", "", {}] do + Gapic::Rest::ClientStub.stub :new, list_autonomous_db_versions_client_stub do + # Create client + client = ::Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::Client.new do |config| + config.credentials = :dummy_value + end + + # Use hash object + client.list_autonomous_db_versions({ parent: parent, page_size: page_size, page_token: page_token }) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use named arguments + client.list_autonomous_db_versions parent: parent, page_size: page_size, page_token: page_token do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use protobuf object + client.list_autonomous_db_versions ::Google::Cloud::OracleDatabase::V1::ListAutonomousDbVersionsRequest.new(parent: parent, page_size: page_size, page_token: page_token) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use hash object with options + client.list_autonomous_db_versions({ parent: parent, page_size: page_size, page_token: page_token }, call_options) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use protobuf object with options + client.list_autonomous_db_versions(::Google::Cloud::OracleDatabase::V1::ListAutonomousDbVersionsRequest.new(parent: parent, page_size: page_size, page_token: page_token), call_options) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Verify method calls + assert_equal 5, list_autonomous_db_versions_client_stub.call_count + end + end + end + + def test_list_autonomous_database_character_sets + # Create test objects. + client_result = ::Google::Cloud::OracleDatabase::V1::ListAutonomousDatabaseCharacterSetsResponse.new + http_response = OpenStruct.new body: client_result.to_json + + call_options = {} + + # Create request parameters for a unary method. + parent = "hello world" + page_size = 42 + page_token = "hello world" + filter = "hello world" + + list_autonomous_database_character_sets_client_stub = ClientStub.new http_response do |_verb, uri:, body:, params:, options:| + assert options.metadata.key? :"x-goog-api-client" + assert options.metadata[:"x-goog-api-client"].include? "rest" + refute options.metadata[:"x-goog-api-client"].include? "grpc" + end + + ::Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::ServiceStub.stub :transcode_list_autonomous_database_character_sets_request, ["", "", {}] do + Gapic::Rest::ClientStub.stub :new, list_autonomous_database_character_sets_client_stub do + # Create client + client = ::Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::Client.new do |config| + config.credentials = :dummy_value + end + + # Use hash object + client.list_autonomous_database_character_sets({ parent: parent, page_size: page_size, page_token: page_token, filter: filter }) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use named arguments + client.list_autonomous_database_character_sets parent: parent, page_size: page_size, page_token: page_token, filter: filter do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use protobuf object + client.list_autonomous_database_character_sets ::Google::Cloud::OracleDatabase::V1::ListAutonomousDatabaseCharacterSetsRequest.new(parent: parent, page_size: page_size, page_token: page_token, filter: filter) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use hash object with options + client.list_autonomous_database_character_sets({ parent: parent, page_size: page_size, page_token: page_token, filter: filter }, call_options) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use protobuf object with options + client.list_autonomous_database_character_sets(::Google::Cloud::OracleDatabase::V1::ListAutonomousDatabaseCharacterSetsRequest.new(parent: parent, page_size: page_size, page_token: page_token, filter: filter), call_options) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Verify method calls + assert_equal 5, list_autonomous_database_character_sets_client_stub.call_count + end + end + end + + def test_list_autonomous_database_backups + # Create test objects. + client_result = ::Google::Cloud::OracleDatabase::V1::ListAutonomousDatabaseBackupsResponse.new + http_response = OpenStruct.new body: client_result.to_json + + call_options = {} + + # Create request parameters for a unary method. + parent = "hello world" + filter = "hello world" + page_size = 42 + page_token = "hello world" + + list_autonomous_database_backups_client_stub = ClientStub.new http_response do |_verb, uri:, body:, params:, options:| + assert options.metadata.key? :"x-goog-api-client" + assert options.metadata[:"x-goog-api-client"].include? "rest" + refute options.metadata[:"x-goog-api-client"].include? "grpc" + end + + ::Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::ServiceStub.stub :transcode_list_autonomous_database_backups_request, ["", "", {}] do + Gapic::Rest::ClientStub.stub :new, list_autonomous_database_backups_client_stub do + # Create client + client = ::Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::Client.new do |config| + config.credentials = :dummy_value + end + + # Use hash object + client.list_autonomous_database_backups({ parent: parent, filter: filter, page_size: page_size, page_token: page_token }) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use named arguments + client.list_autonomous_database_backups parent: parent, filter: filter, page_size: page_size, page_token: page_token do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use protobuf object + client.list_autonomous_database_backups ::Google::Cloud::OracleDatabase::V1::ListAutonomousDatabaseBackupsRequest.new(parent: parent, filter: filter, page_size: page_size, page_token: page_token) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use hash object with options + client.list_autonomous_database_backups({ parent: parent, filter: filter, page_size: page_size, page_token: page_token }, call_options) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Use protobuf object with options + client.list_autonomous_database_backups(::Google::Cloud::OracleDatabase::V1::ListAutonomousDatabaseBackupsRequest.new(parent: parent, filter: filter, page_size: page_size, page_token: page_token), call_options) do |_result, response| + assert_equal http_response, response.underlying_op + end + + # Verify method calls + assert_equal 5, list_autonomous_database_backups_client_stub.call_count + end + end + end + + def test_configure + credentials_token = :dummy_value + + client = block_config = config = nil + dummy_stub = ClientStub.new nil + Gapic::Rest::ClientStub.stub :new, dummy_stub do + client = ::Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::Client.new do |config| + config.credentials = credentials_token + end + end + + config = client.configure do |c| + block_config = c + end + + assert_same block_config, config + assert_kind_of ::Google::Cloud::OracleDatabase::V1::OracleDatabase::Rest::Client::Configuration, config + end +end diff --git a/google-cloud-oracle_database-v1/test/helper.rb b/google-cloud-oracle_database-v1/test/helper.rb new file mode 100644 index 000000000000..48407bca7edb --- /dev/null +++ b/google-cloud-oracle_database-v1/test/helper.rb @@ -0,0 +1,25 @@ +# frozen_string_literal: true + +# Copyright 2024 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# https://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# Auto-generated by gapic-generator-ruby. DO NOT EDIT! + +require "minitest/autorun" +require "minitest/focus" +require "minitest/rg" + +require "grpc" + +require "ostruct" diff --git a/release-please-config.json b/release-please-config.json index ae9b2597d546..4acf86e8cdf2 100644 --- a/release-please-config.json +++ b/release-please-config.json @@ -1027,6 +1027,10 @@ "component": "google-cloud-optimization-v1", "version_file": "lib/google/cloud/optimization/v1/version.rb" }, + "google-cloud-oracle_database-v1": { + "component": "google-cloud-oracle_database-v1", + "version_file": "lib/google/cloud/oracle_database/v1/version.rb" + }, "google-cloud-orchestration-airflow-service": { "component": "google-cloud-orchestration-airflow-service", "version_file": "lib/google/cloud/orchestration/airflow/service/version.rb"