diff --git a/.github/.OwlBot.lock.yaml b/.github/.OwlBot.lock.yaml index 6610882f83..0f0647b00e 100644 --- a/.github/.OwlBot.lock.yaml +++ b/.github/.OwlBot.lock.yaml @@ -13,5 +13,4 @@ # limitations under the License. docker: image: gcr.io/cloud-devrel-public-resources/owlbot-java:latest - digest: sha256:04f254abfe5f47fe73ae6f91d68d55c3b76e722a4943066c3bb0ce03573b4ad9 -# created: 2022-07-18T21:44:23.94208526Z + digest: sha256:e76136cc48f90aa19ba29cdfbd4002111467e44a1c9d905867d98dafafbd03bb diff --git a/.github/CODEOWNERS b/.github/CODEOWNERS index 63b6b62ecf..a194648554 100644 --- a/.github/CODEOWNERS +++ b/.github/CODEOWNERS @@ -13,3 +13,6 @@ # The java-samples-reviewers team is the default owner for samples changes samples/**/*.java @googleapis/java-samples-reviewers + +# Generated snippets should not be owned by samples reviewers +samples/snippets/generated/ @googleapis/yoshi-java diff --git a/.github/release-please.yml b/.github/release-please.yml index ba18707fd2..6db6b50898 100644 --- a/.github/release-please.yml +++ b/.github/release-please.yml @@ -30,5 +30,12 @@ branches: - >- google-cloud-bigtable/src/main/java/com/google/cloud/bigtable/Version.java branch: v2.6.x + - bumpMinorPreMajor: true + handleGHRelease: true + releaseType: java-backport + extraFiles: + - >- + google-cloud-bigtable/src/main/java/com/google/cloud/bigtable/Version.java + branch: 2.16.x extraFiles: - google-cloud-bigtable/src/main/java/com/google/cloud/bigtable/Version.java diff --git a/.github/sync-repo-settings.yaml b/.github/sync-repo-settings.yaml index 36d4054793..f871299692 100644 --- a/.github/sync-repo-settings.yaml +++ b/.github/sync-repo-settings.yaml @@ -77,6 +77,23 @@ branchProtectionRules: - 'Kokoro - Test: Integration' - cla/google - OwlBot Post Processor + - pattern: 2.16.x + isAdminEnforced: true + requiredApprovingReviewCount: 1 + requiresCodeOwnerReviews: true + requiresStrictStatusChecks: false + requiredStatusCheckContexts: + - dependencies (8) + - dependencies (11) + - lint + - clirr + - units (8) + - units (11) + - 'Kokoro - Test: Integration' + - cla/google + - OwlBot Post Processor + - 'Kokoro - Test: Java GraalVM Native Image' + - 'Kokoro - Test: Java 17 GraalVM Native Image' permissionRules: - team: yoshi-admins permission: admin diff --git a/.kokoro/dependencies.sh b/.kokoro/dependencies.sh index d7476cfe97..bd8960246f 100755 --- a/.kokoro/dependencies.sh +++ b/.kokoro/dependencies.sh @@ -57,54 +57,3 @@ retry_with_backoff 3 10 \ -Dclirr.skip=true mvn -B dependency:analyze -DfailOnWarning=true - -echo "****************** DEPENDENCY LIST COMPLETENESS CHECK *******************" -## Run dependency list completeness check -function completenessCheck() { - # Output dep list with compile scope generated using the original pom - # Running mvn dependency:list on Java versions that support modules will also include the module of the dependency. - # This is stripped from the output as it is not present in the flattened pom. - # Only dependencies with 'compile' or 'runtime' scope are included from original dependency list. - msg "Generating dependency list using original pom..." - mvn dependency:list -f pom.xml -DincludeScope=runtime -Dsort=true | grep '\[INFO] .*:.*:.*:.*:.*' | sed -e 's/ --.*//' >.org-list.txt - - # Output dep list generated using the flattened pom (only 'compile' and 'runtime' scopes) - msg "Generating dependency list using flattened pom..." - mvn dependency:list -f .flattened-pom.xml -DincludeScope=runtime -Dsort=true | grep '\[INFO] .*:.*:.*:.*:.*' >.new-list.txt - - # Compare two dependency lists - msg "Comparing dependency lists..." - diff .org-list.txt .new-list.txt >.diff.txt - if [[ $? == 0 ]] - then - msg "Success. No diff!" - else - msg "Diff found. See below: " - msg "You can also check .diff.txt file located in $1." - cat .diff.txt - return 1 - fi -} - -# Allow failures to continue running the script -set +e - -error_count=0 -for path in **/.flattened-pom.xml -do - # Check flattened pom in each dir that contains it for completeness - dir=$(dirname "$path") - pushd "$dir" - completenessCheck "$dir" - error_count=$(($error_count + $?)) - popd -done - -if [[ $error_count == 0 ]] -then - msg "All checks passed." - exit 0 -else - msg "Errors found. See log statements above." - exit 1 -fi diff --git a/.kokoro/presubmit/graalvm-native-17.cfg b/.kokoro/presubmit/graalvm-native-17.cfg index c91ac4f993..d33de23da9 100644 --- a/.kokoro/presubmit/graalvm-native-17.cfg +++ b/.kokoro/presubmit/graalvm-native-17.cfg @@ -3,7 +3,7 @@ # Configure the docker image for kokoro-trampoline. env_vars: { key: "TRAMPOLINE_IMAGE" - value: "gcr.io/cloud-devrel-kokoro-resources/graalvm17" + value: "gcr.io/cloud-devrel-kokoro-resources/graalvm17:22.3.0" } env_vars: { diff --git a/.kokoro/presubmit/graalvm-native.cfg b/.kokoro/presubmit/graalvm-native.cfg index dcae17d91b..7b8e7f0fb0 100644 --- a/.kokoro/presubmit/graalvm-native.cfg +++ b/.kokoro/presubmit/graalvm-native.cfg @@ -3,7 +3,7 @@ # Configure the docker image for kokoro-trampoline. env_vars: { key: "TRAMPOLINE_IMAGE" - value: "gcr.io/cloud-devrel-kokoro-resources/graalvm" + value: "gcr.io/cloud-devrel-kokoro-resources/graalvm:22.3.0" } env_vars: { diff --git a/.kokoro/release/publish_javadoc.sh b/.kokoro/release/publish_javadoc.sh index a6782c6cfd..587f196a94 100755 --- a/.kokoro/release/publish_javadoc.sh +++ b/.kokoro/release/publish_javadoc.sh @@ -28,7 +28,7 @@ fi pushd $(dirname "$0")/../../ # install docuploader package -python3 -m pip install gcp-docuploader +python3 -m pip install --require-hashes -r .kokoro/requirements.txt # compile all packages mvn clean install -B -q -DskipTests=true diff --git a/.kokoro/release/publish_javadoc11.sh b/.kokoro/release/publish_javadoc11.sh index 2af6c7caba..c0eda642e3 100755 --- a/.kokoro/release/publish_javadoc11.sh +++ b/.kokoro/release/publish_javadoc11.sh @@ -28,7 +28,7 @@ fi pushd $(dirname "$0")/../../ # install docuploader package -python3 -m pip install gcp-docuploader +python3 -m pip install --require-hashes -r .kokoro/requirements.txt # compile all packages mvn clean install -B -q -DskipTests=true diff --git a/.kokoro/release/stage.sh b/.kokoro/release/stage.sh index 1dba8de108..61e714d6ba 100755 --- a/.kokoro/release/stage.sh +++ b/.kokoro/release/stage.sh @@ -16,7 +16,8 @@ set -eo pipefail # Start the releasetool reporter -python3 -m pip install gcp-releasetool +requirementsFile=$(realpath $(dirname "${BASH_SOURCE[0]}")/../requirements.txt) +python3 -m pip install --require-hashes -r $requirementsFile python3 -m releasetool publish-reporter-script > /tmp/publisher-script; source /tmp/publisher-script source $(dirname "$0")/common.sh diff --git a/.kokoro/requirements.in b/.kokoro/requirements.in new file mode 100644 index 0000000000..924f94ae6f --- /dev/null +++ b/.kokoro/requirements.in @@ -0,0 +1,34 @@ +gcp-docuploader==0.6.3 +google-crc32c==1.3.0 +googleapis-common-protos==1.56.3 +gcp-releasetool==1.9.1 +cryptography==38.0.3 +cachetools==4.2.4 +cffi==1.15.1 +jeepney==0.7.1 +jinja2==3.0.3 +markupsafe==2.0.1 +keyring==23.4.1 +packaging==21.3 +protobuf==3.19.5 +pyjwt==2.4.0 +pyparsing==3.0.9 +pycparser==2.21 +pyperclip==1.8.2 +python-dateutil==2.8.2 +requests==2.27.1 +certifi==2022.9.24 +importlib-metadata==4.8.3 +zipp==3.6.0 +google_api_core==2.8.2 +google-cloud-storage==2.0.0 +google-resumable-media==2.3.3 +google-cloud-core==2.3.1 +typing-extensions==4.1.1 +urllib3==1.26.12 +zipp==3.6.0 +rsa==4.9 +six==1.16.0 +attrs==22.1.0 +google-auth==2.14.1 +idna==3.4 \ No newline at end of file diff --git a/.kokoro/requirements.txt b/.kokoro/requirements.txt new file mode 100644 index 0000000000..71fcafc703 --- /dev/null +++ b/.kokoro/requirements.txt @@ -0,0 +1,456 @@ +# +# This file is autogenerated by pip-compile with python 3.10 +# To update, run: +# +# pip-compile --generate-hashes requirements.in +# +attrs==22.1.0 \ + --hash=sha256:29adc2665447e5191d0e7c568fde78b21f9672d344281d0c6e1ab085429b22b6 \ + --hash=sha256:86efa402f67bf2df34f51a335487cf46b1ec130d02b8d39fd248abfd30da551c + # via + # -r requirements.in + # gcp-releasetool +cachetools==4.2.4 \ + --hash=sha256:89ea6f1b638d5a73a4f9226be57ac5e4f399d22770b92355f92dcb0f7f001693 \ + --hash=sha256:92971d3cb7d2a97efff7c7bb1657f21a8f5fb309a37530537c71b1774189f2d1 + # via + # -r requirements.in + # google-auth +certifi==2022.9.24 \ + --hash=sha256:0d9c601124e5a6ba9712dbc60d9c53c21e34f5f641fe83002317394311bdce14 \ + --hash=sha256:90c1a32f1d68f940488354e36370f6cca89f0f106db09518524c88d6ed83f382 + # via + # -r requirements.in + # requests +cffi==1.15.1 \ + --hash=sha256:00a9ed42e88df81ffae7a8ab6d9356b371399b91dbdf0c3cb1e84c03a13aceb5 \ + --hash=sha256:03425bdae262c76aad70202debd780501fabeaca237cdfddc008987c0e0f59ef \ + --hash=sha256:04ed324bda3cda42b9b695d51bb7d54b680b9719cfab04227cdd1e04e5de3104 \ + --hash=sha256:0e2642fe3142e4cc4af0799748233ad6da94c62a8bec3a6648bf8ee68b1c7426 \ + --hash=sha256:173379135477dc8cac4bc58f45db08ab45d228b3363adb7af79436135d028405 \ + --hash=sha256:198caafb44239b60e252492445da556afafc7d1e3ab7a1fb3f0584ef6d742375 \ + --hash=sha256:1e74c6b51a9ed6589199c787bf5f9875612ca4a8a0785fb2d4a84429badaf22a \ + --hash=sha256:2012c72d854c2d03e45d06ae57f40d78e5770d252f195b93f581acf3ba44496e \ + --hash=sha256:21157295583fe8943475029ed5abdcf71eb3911894724e360acff1d61c1d54bc \ + --hash=sha256:2470043b93ff09bf8fb1d46d1cb756ce6132c54826661a32d4e4d132e1977adf \ + --hash=sha256:285d29981935eb726a4399badae8f0ffdff4f5050eaa6d0cfc3f64b857b77185 \ + --hash=sha256:30d78fbc8ebf9c92c9b7823ee18eb92f2e6ef79b45ac84db507f52fbe3ec4497 \ + --hash=sha256:320dab6e7cb2eacdf0e658569d2575c4dad258c0fcc794f46215e1e39f90f2c3 \ + --hash=sha256:33ab79603146aace82c2427da5ca6e58f2b3f2fb5da893ceac0c42218a40be35 \ + --hash=sha256:3548db281cd7d2561c9ad9984681c95f7b0e38881201e157833a2342c30d5e8c \ + --hash=sha256:3799aecf2e17cf585d977b780ce79ff0dc9b78d799fc694221ce814c2c19db83 \ + --hash=sha256:39d39875251ca8f612b6f33e6b1195af86d1b3e60086068be9cc053aa4376e21 \ + --hash=sha256:3b926aa83d1edb5aa5b427b4053dc420ec295a08e40911296b9eb1b6170f6cca \ + --hash=sha256:3bcde07039e586f91b45c88f8583ea7cf7a0770df3a1649627bf598332cb6984 \ + --hash=sha256:3d08afd128ddaa624a48cf2b859afef385b720bb4b43df214f85616922e6a5ac \ + --hash=sha256:3eb6971dcff08619f8d91607cfc726518b6fa2a9eba42856be181c6d0d9515fd \ + --hash=sha256:40f4774f5a9d4f5e344f31a32b5096977b5d48560c5592e2f3d2c4374bd543ee \ + --hash=sha256:4289fc34b2f5316fbb762d75362931e351941fa95fa18789191b33fc4cf9504a \ + --hash=sha256:470c103ae716238bbe698d67ad020e1db9d9dba34fa5a899b5e21577e6d52ed2 \ + --hash=sha256:4f2c9f67e9821cad2e5f480bc8d83b8742896f1242dba247911072d4fa94c192 \ + --hash=sha256:50a74364d85fd319352182ef59c5c790484a336f6db772c1a9231f1c3ed0cbd7 \ + --hash=sha256:54a2db7b78338edd780e7ef7f9f6c442500fb0d41a5a4ea24fff1c929d5af585 \ + --hash=sha256:5635bd9cb9731e6d4a1132a498dd34f764034a8ce60cef4f5319c0541159392f \ + --hash=sha256:59c0b02d0a6c384d453fece7566d1c7e6b7bae4fc5874ef2ef46d56776d61c9e \ + --hash=sha256:5d598b938678ebf3c67377cdd45e09d431369c3b1a5b331058c338e201f12b27 \ + --hash=sha256:5df2768244d19ab7f60546d0c7c63ce1581f7af8b5de3eb3004b9b6fc8a9f84b \ + --hash=sha256:5ef34d190326c3b1f822a5b7a45f6c4535e2f47ed06fec77d3d799c450b2651e \ + --hash=sha256:6975a3fac6bc83c4a65c9f9fcab9e47019a11d3d2cf7f3c0d03431bf145a941e \ + --hash=sha256:6c9a799e985904922a4d207a94eae35c78ebae90e128f0c4e521ce339396be9d \ + --hash=sha256:70df4e3b545a17496c9b3f41f5115e69a4f2e77e94e1d2a8e1070bc0c38c8a3c \ + --hash=sha256:7473e861101c9e72452f9bf8acb984947aa1661a7704553a9f6e4baa5ba64415 \ + --hash=sha256:8102eaf27e1e448db915d08afa8b41d6c7ca7a04b7d73af6514df10a3e74bd82 \ + --hash=sha256:87c450779d0914f2861b8526e035c5e6da0a3199d8f1add1a665e1cbc6fc6d02 \ + --hash=sha256:8b7ee99e510d7b66cdb6c593f21c043c248537a32e0bedf02e01e9553a172314 \ + --hash=sha256:91fc98adde3d7881af9b59ed0294046f3806221863722ba7d8d120c575314325 \ + --hash=sha256:94411f22c3985acaec6f83c6df553f2dbe17b698cc7f8ae751ff2237d96b9e3c \ + --hash=sha256:98d85c6a2bef81588d9227dde12db8a7f47f639f4a17c9ae08e773aa9c697bf3 \ + --hash=sha256:9ad5db27f9cabae298d151c85cf2bad1d359a1b9c686a275df03385758e2f914 \ + --hash=sha256:a0b71b1b8fbf2b96e41c4d990244165e2c9be83d54962a9a1d118fd8657d2045 \ + --hash=sha256:a0f100c8912c114ff53e1202d0078b425bee3649ae34d7b070e9697f93c5d52d \ + --hash=sha256:a591fe9e525846e4d154205572a029f653ada1a78b93697f3b5a8f1f2bc055b9 \ + --hash=sha256:a5c84c68147988265e60416b57fc83425a78058853509c1b0629c180094904a5 \ + --hash=sha256:a66d3508133af6e8548451b25058d5812812ec3798c886bf38ed24a98216fab2 \ + --hash=sha256:a8c4917bd7ad33e8eb21e9a5bbba979b49d9a97acb3a803092cbc1133e20343c \ + --hash=sha256:b3bbeb01c2b273cca1e1e0c5df57f12dce9a4dd331b4fa1635b8bec26350bde3 \ + --hash=sha256:cba9d6b9a7d64d4bd46167096fc9d2f835e25d7e4c121fb2ddfc6528fb0413b2 \ + --hash=sha256:cc4d65aeeaa04136a12677d3dd0b1c0c94dc43abac5860ab33cceb42b801c1e8 \ + --hash=sha256:ce4bcc037df4fc5e3d184794f27bdaab018943698f4ca31630bc7f84a7b69c6d \ + --hash=sha256:cec7d9412a9102bdc577382c3929b337320c4c4c4849f2c5cdd14d7368c5562d \ + --hash=sha256:d400bfb9a37b1351253cb402671cea7e89bdecc294e8016a707f6d1d8ac934f9 \ + --hash=sha256:d61f4695e6c866a23a21acab0509af1cdfd2c013cf256bbf5b6b5e2695827162 \ + --hash=sha256:db0fbb9c62743ce59a9ff687eb5f4afbe77e5e8403d6697f7446e5f609976f76 \ + --hash=sha256:dd86c085fae2efd48ac91dd7ccffcfc0571387fe1193d33b6394db7ef31fe2a4 \ + --hash=sha256:e00b098126fd45523dd056d2efba6c5a63b71ffe9f2bbe1a4fe1716e1d0c331e \ + --hash=sha256:e229a521186c75c8ad9490854fd8bbdd9a0c9aa3a524326b55be83b54d4e0ad9 \ + --hash=sha256:e263d77ee3dd201c3a142934a086a4450861778baaeeb45db4591ef65550b0a6 \ + --hash=sha256:ed9cb427ba5504c1dc15ede7d516b84757c3e3d7868ccc85121d9310d27eed0b \ + --hash=sha256:fa6693661a4c91757f4412306191b6dc88c1703f780c8234035eac011922bc01 \ + --hash=sha256:fcd131dd944808b5bdb38e6f5b53013c5aa4f334c5cad0c72742f6eba4b73db0 + # via + # -r requirements.in + # cryptography +charset-normalizer==2.0.12 \ + --hash=sha256:2857e29ff0d34db842cd7ca3230549d1a697f96ee6d3fb071cfa6c7393832597 \ + --hash=sha256:6881edbebdb17b39b4eaaa821b438bf6eddffb4468cf344f09f89def34a8b1df + # via requests +click==8.0.4 \ + --hash=sha256:6a7a62563bbfabfda3a38f3023a1db4a35978c0abd76f6c9605ecd6554d6d9b1 \ + --hash=sha256:8458d7b1287c5fb128c90e23381cf99dcde74beaf6c7ff6384ce84d6fe090adb + # via + # gcp-docuploader + # gcp-releasetool +colorlog==6.7.0 \ + --hash=sha256:0d33ca236784a1ba3ff9c532d4964126d8a2c44f1f0cb1d2b0728196f512f662 \ + --hash=sha256:bd94bd21c1e13fac7bd3153f4bc3a7dc0eb0974b8bc2fdf1a989e474f6e582e5 + # via gcp-docuploader +cryptography==38.0.3 \ + --hash=sha256:068147f32fa662c81aebab95c74679b401b12b57494872886eb5c1139250ec5d \ + --hash=sha256:06fc3cc7b6f6cca87bd56ec80a580c88f1da5306f505876a71c8cfa7050257dd \ + --hash=sha256:25c1d1f19729fb09d42e06b4bf9895212292cb27bb50229f5aa64d039ab29146 \ + --hash=sha256:402852a0aea73833d982cabb6d0c3bb582c15483d29fb7085ef2c42bfa7e38d7 \ + --hash=sha256:4e269dcd9b102c5a3d72be3c45d8ce20377b8076a43cbed6f660a1afe365e436 \ + --hash=sha256:5419a127426084933076132d317911e3c6eb77568a1ce23c3ac1e12d111e61e0 \ + --hash=sha256:554bec92ee7d1e9d10ded2f7e92a5d70c1f74ba9524947c0ba0c850c7b011828 \ + --hash=sha256:5e89468fbd2fcd733b5899333bc54d0d06c80e04cd23d8c6f3e0542358c6060b \ + --hash=sha256:65535bc550b70bd6271984d9863a37741352b4aad6fb1b3344a54e6950249b55 \ + --hash=sha256:6ab9516b85bebe7aa83f309bacc5f44a61eeb90d0b4ec125d2d003ce41932d36 \ + --hash=sha256:6addc3b6d593cd980989261dc1cce38263c76954d758c3c94de51f1e010c9a50 \ + --hash=sha256:728f2694fa743a996d7784a6194da430f197d5c58e2f4e278612b359f455e4a2 \ + --hash=sha256:785e4056b5a8b28f05a533fab69febf5004458e20dad7e2e13a3120d8ecec75a \ + --hash=sha256:78cf5eefac2b52c10398a42765bfa981ce2372cbc0457e6bf9658f41ec3c41d8 \ + --hash=sha256:7f836217000342d448e1c9a342e9163149e45d5b5eca76a30e84503a5a96cab0 \ + --hash=sha256:8d41a46251bf0634e21fac50ffd643216ccecfaf3701a063257fe0b2be1b6548 \ + --hash=sha256:984fe150f350a3c91e84de405fe49e688aa6092b3525f407a18b9646f6612320 \ + --hash=sha256:9b24bcff7853ed18a63cfb0c2b008936a9554af24af2fb146e16d8e1aed75748 \ + --hash=sha256:b1b35d9d3a65542ed2e9d90115dfd16bbc027b3f07ee3304fc83580f26e43249 \ + --hash=sha256:b1b52c9e5f8aa2b802d48bd693190341fae201ea51c7a167d69fc48b60e8a959 \ + --hash=sha256:bbf203f1a814007ce24bd4d51362991d5cb90ba0c177a9c08825f2cc304d871f \ + --hash=sha256:be243c7e2bfcf6cc4cb350c0d5cdf15ca6383bbcb2a8ef51d3c9411a9d4386f0 \ + --hash=sha256:bfbe6ee19615b07a98b1d2287d6a6073f734735b49ee45b11324d85efc4d5cbd \ + --hash=sha256:c46837ea467ed1efea562bbeb543994c2d1f6e800785bd5a2c98bc096f5cb220 \ + --hash=sha256:dfb4f4dd568de1b6af9f4cda334adf7d72cf5bc052516e1b2608b683375dd95c \ + --hash=sha256:ed7b00096790213e09eb11c97cc6e2b757f15f3d2f85833cd2d3ec3fe37c1722 + # via + # -r requirements.in + # gcp-releasetool + # secretstorage +gcp-docuploader==0.6.3 \ + --hash=sha256:ba8c9d76b3bbac54b0311c503a373b00edc2dc02d6d54ea9507045adb8e870f7 \ + --hash=sha256:c0f5aaa82ce1854a386197e4e359b120ad6d4e57ae2c812fce42219a3288026b + # via -r requirements.in +gcp-releasetool==1.9.1 \ + --hash=sha256:952f4055d5d986b070ae2a71c4410b250000f9cc5a1e26398fcd55a5bbc5a15f \ + --hash=sha256:d0d3c814a97c1a237517e837d8cfa668ced8df4b882452578ecef4a4e79c583b + # via -r requirements.in +google-api-core==2.8.2 \ + --hash=sha256:06f7244c640322b508b125903bb5701bebabce8832f85aba9335ec00b3d02edc \ + --hash=sha256:93c6a91ccac79079ac6bbf8b74ee75db970cc899278b97d53bc012f35908cf50 + # via + # -r requirements.in + # google-cloud-core + # google-cloud-storage +google-auth==2.14.1 \ + --hash=sha256:f5d8701633bebc12e0deea4df8abd8aff31c28b355360597f7f2ee60f2e4d016 + # via + # -r requirements.in + # gcp-releasetool + # google-api-core + # google-cloud-core + # google-cloud-storage +google-cloud-core==2.3.1 \ + --hash=sha256:113ba4f492467d5bd442c8d724c1a25ad7384045c3178369038840ecdd19346c \ + --hash=sha256:34334359cb04187bdc80ddcf613e462dfd7a3aabbc3fe4d118517ab4b9303d53 + # via + # -r requirements.in + # google-cloud-storage +google-cloud-storage==2.0.0 \ + --hash=sha256:a57a15aead0f9dfbd4381f1bfdbe8bf89818a4bd75bab846cafcefb2db846c47 \ + --hash=sha256:ec4be60bb223a3a960f0d01697d849b86d91cad815a84915a32ed3635e93a5e7 + # via + # -r requirements.in + # gcp-docuploader +google-crc32c==1.3.0 \ + --hash=sha256:04e7c220798a72fd0f08242bc8d7a05986b2a08a0573396187fd32c1dcdd58b3 \ + --hash=sha256:05340b60bf05b574159e9bd940152a47d38af3fb43803ffe71f11d704b7696a6 \ + --hash=sha256:12674a4c3b56b706153a358eaa1018c4137a5a04635b92b4652440d3d7386206 \ + --hash=sha256:127f9cc3ac41b6a859bd9dc4321097b1a4f6aa7fdf71b4f9227b9e3ebffb4422 \ + --hash=sha256:13af315c3a0eec8bb8b8d80b8b128cb3fcd17d7e4edafc39647846345a3f003a \ + --hash=sha256:1926fd8de0acb9d15ee757175ce7242e235482a783cd4ec711cc999fc103c24e \ + --hash=sha256:226f2f9b8e128a6ca6a9af9b9e8384f7b53a801907425c9a292553a3a7218ce0 \ + --hash=sha256:276de6273eb074a35bc598f8efbc00c7869c5cf2e29c90748fccc8c898c244df \ + --hash=sha256:318f73f5484b5671f0c7f5f63741ab020a599504ed81d209b5c7129ee4667407 \ + --hash=sha256:3bbce1be3687bbfebe29abdb7631b83e6b25da3f4e1856a1611eb21854b689ea \ + --hash=sha256:42ae4781333e331a1743445931b08ebdad73e188fd554259e772556fc4937c48 \ + --hash=sha256:58be56ae0529c664cc04a9c76e68bb92b091e0194d6e3c50bea7e0f266f73713 \ + --hash=sha256:5da2c81575cc3ccf05d9830f9e8d3c70954819ca9a63828210498c0774fda1a3 \ + --hash=sha256:6311853aa2bba4064d0c28ca54e7b50c4d48e3de04f6770f6c60ebda1e975267 \ + --hash=sha256:650e2917660e696041ab3dcd7abac160b4121cd9a484c08406f24c5964099829 \ + --hash=sha256:6a4db36f9721fdf391646685ecffa404eb986cbe007a3289499020daf72e88a2 \ + --hash=sha256:779cbf1ce375b96111db98fca913c1f5ec11b1d870e529b1dc7354b2681a8c3a \ + --hash=sha256:7f6fe42536d9dcd3e2ffb9d3053f5d05221ae3bbcefbe472bdf2c71c793e3183 \ + --hash=sha256:891f712ce54e0d631370e1f4997b3f182f3368179198efc30d477c75d1f44942 \ + --hash=sha256:95c68a4b9b7828ba0428f8f7e3109c5d476ca44996ed9a5f8aac6269296e2d59 \ + --hash=sha256:96a8918a78d5d64e07c8ea4ed2bc44354e3f93f46a4866a40e8db934e4c0d74b \ + --hash=sha256:9c3cf890c3c0ecfe1510a452a165431b5831e24160c5fcf2071f0f85ca5a47cd \ + --hash=sha256:9f58099ad7affc0754ae42e6d87443299f15d739b0ce03c76f515153a5cda06c \ + --hash=sha256:a0b9e622c3b2b8d0ce32f77eba617ab0d6768b82836391e4f8f9e2074582bf02 \ + --hash=sha256:a7f9cbea4245ee36190f85fe1814e2d7b1e5f2186381b082f5d59f99b7f11328 \ + --hash=sha256:bab4aebd525218bab4ee615786c4581952eadc16b1ff031813a2fd51f0cc7b08 \ + --hash=sha256:c124b8c8779bf2d35d9b721e52d4adb41c9bfbde45e6a3f25f0820caa9aba73f \ + --hash=sha256:c9da0a39b53d2fab3e5467329ed50e951eb91386e9d0d5b12daf593973c3b168 \ + --hash=sha256:ca60076c388728d3b6ac3846842474f4250c91efbfe5afa872d3ffd69dd4b318 \ + --hash=sha256:cb6994fff247987c66a8a4e550ef374671c2b82e3c0d2115e689d21e511a652d \ + --hash=sha256:d1c1d6236feab51200272d79b3d3e0f12cf2cbb12b208c835b175a21efdb0a73 \ + --hash=sha256:dd7760a88a8d3d705ff562aa93f8445ead54f58fd482e4f9e2bafb7e177375d4 \ + --hash=sha256:dda4d8a3bb0b50f540f6ff4b6033f3a74e8bf0bd5320b70fab2c03e512a62812 \ + --hash=sha256:e0f1ff55dde0ebcfbef027edc21f71c205845585fffe30d4ec4979416613e9b3 \ + --hash=sha256:e7a539b9be7b9c00f11ef16b55486141bc2cdb0c54762f84e3c6fc091917436d \ + --hash=sha256:eb0b14523758e37802f27b7f8cd973f5f3d33be7613952c0df904b68c4842f0e \ + --hash=sha256:ed447680ff21c14aaceb6a9f99a5f639f583ccfe4ce1a5e1d48eb41c3d6b3217 \ + --hash=sha256:f52a4ad2568314ee713715b1e2d79ab55fab11e8b304fd1462ff5cccf4264b3e \ + --hash=sha256:fbd60c6aaa07c31d7754edbc2334aef50601b7f1ada67a96eb1eb57c7c72378f \ + --hash=sha256:fc28e0db232c62ca0c3600884933178f0825c99be4474cdd645e378a10588125 \ + --hash=sha256:fe31de3002e7b08eb20823b3735b97c86c5926dd0581c7710a680b418a8709d4 \ + --hash=sha256:fec221a051150eeddfdfcff162e6db92c65ecf46cb0f7bb1bf812a1520ec026b \ + --hash=sha256:ff71073ebf0e42258a42a0b34f2c09ec384977e7f6808999102eedd5b49920e3 + # via + # -r requirements.in + # google-resumable-media +google-resumable-media==2.3.3 \ + --hash=sha256:27c52620bd364d1c8116eaac4ea2afcbfb81ae9139fb3199652fcac1724bfb6c \ + --hash=sha256:5b52774ea7a829a8cdaa8bd2d4c3d4bc660c91b30857ab2668d0eb830f4ea8c5 + # via + # -r requirements.in + # google-cloud-storage +googleapis-common-protos==1.56.3 \ + --hash=sha256:6f1369b58ed6cf3a4b7054a44ebe8d03b29c309257583a2bbdc064cd1e4a1442 \ + --hash=sha256:87955d7b3a73e6e803f2572a33179de23989ebba725e05ea42f24838b792e461 + # via + # -r requirements.in + # google-api-core +idna==3.4 \ + --hash=sha256:814f528e8dead7d329833b91c5faa87d60bf71824cd12a7530b5526063d02cb4 \ + --hash=sha256:90b77e79eaa3eba6de819a0c442c0b4ceefc341a7a2ab77d7562bf49f425c5c2 + # via + # -r requirements.in + # requests +importlib-metadata==4.8.3 \ + --hash=sha256:65a9576a5b2d58ca44d133c42a241905cc45e34d2c06fd5ba2bafa221e5d7b5e \ + --hash=sha256:766abffff765960fcc18003801f7044eb6755ffae4521c8e8ce8e83b9c9b0668 + # via + # -r requirements.in + # keyring +jeepney==0.7.1 \ + --hash=sha256:1b5a0ea5c0e7b166b2f5895b91a08c14de8915afda4407fb5022a195224958ac \ + --hash=sha256:fa9e232dfa0c498bd0b8a3a73b8d8a31978304dcef0515adc859d4e096f96f4f + # via + # -r requirements.in + # keyring + # secretstorage +jinja2==3.0.3 \ + --hash=sha256:077ce6014f7b40d03b47d1f1ca4b0fc8328a692bd284016f806ed0eaca390ad8 \ + --hash=sha256:611bb273cd68f3b993fabdc4064fc858c5b47a973cb5aa7999ec1ba405c87cd7 + # via + # -r requirements.in + # gcp-releasetool +keyring==23.4.1 \ + --hash=sha256:17e49fb0d6883c2b4445359434dba95aad84aabb29bbff044ad0ed7100232eca \ + --hash=sha256:89cbd74d4683ed164c8082fb38619341097741323b3786905c6dac04d6915a55 + # via + # -r requirements.in + # gcp-releasetool +markupsafe==2.0.1 \ + --hash=sha256:01a9b8ea66f1658938f65b93a85ebe8bc016e6769611be228d797c9d998dd298 \ + --hash=sha256:023cb26ec21ece8dc3907c0e8320058b2e0cb3c55cf9564da612bc325bed5e64 \ + --hash=sha256:0446679737af14f45767963a1a9ef7620189912317d095f2d9ffa183a4d25d2b \ + --hash=sha256:04635854b943835a6ea959e948d19dcd311762c5c0c6e1f0e16ee57022669194 \ + --hash=sha256:0717a7390a68be14b8c793ba258e075c6f4ca819f15edfc2a3a027c823718567 \ + --hash=sha256:0955295dd5eec6cb6cc2fe1698f4c6d84af2e92de33fbcac4111913cd100a6ff \ + --hash=sha256:0d4b31cc67ab36e3392bbf3862cfbadac3db12bdd8b02a2731f509ed5b829724 \ + --hash=sha256:10f82115e21dc0dfec9ab5c0223652f7197feb168c940f3ef61563fc2d6beb74 \ + --hash=sha256:168cd0a3642de83558a5153c8bd34f175a9a6e7f6dc6384b9655d2697312a646 \ + --hash=sha256:1d609f577dc6e1aa17d746f8bd3c31aa4d258f4070d61b2aa5c4166c1539de35 \ + --hash=sha256:1f2ade76b9903f39aa442b4aadd2177decb66525062db244b35d71d0ee8599b6 \ + --hash=sha256:20dca64a3ef2d6e4d5d615a3fd418ad3bde77a47ec8a23d984a12b5b4c74491a \ + --hash=sha256:2a7d351cbd8cfeb19ca00de495e224dea7e7d919659c2841bbb7f420ad03e2d6 \ + --hash=sha256:2d7d807855b419fc2ed3e631034685db6079889a1f01d5d9dac950f764da3dad \ + --hash=sha256:2ef54abee730b502252bcdf31b10dacb0a416229b72c18b19e24a4509f273d26 \ + --hash=sha256:36bc903cbb393720fad60fc28c10de6acf10dc6cc883f3e24ee4012371399a38 \ + --hash=sha256:37205cac2a79194e3750b0af2a5720d95f786a55ce7df90c3af697bfa100eaac \ + --hash=sha256:3c112550557578c26af18a1ccc9e090bfe03832ae994343cfdacd287db6a6ae7 \ + --hash=sha256:3dd007d54ee88b46be476e293f48c85048603f5f516008bee124ddd891398ed6 \ + --hash=sha256:4296f2b1ce8c86a6aea78613c34bb1a672ea0e3de9c6ba08a960efe0b0a09047 \ + --hash=sha256:47ab1e7b91c098ab893b828deafa1203de86d0bc6ab587b160f78fe6c4011f75 \ + --hash=sha256:49e3ceeabbfb9d66c3aef5af3a60cc43b85c33df25ce03d0031a608b0a8b2e3f \ + --hash=sha256:4dc8f9fb58f7364b63fd9f85013b780ef83c11857ae79f2feda41e270468dd9b \ + --hash=sha256:4efca8f86c54b22348a5467704e3fec767b2db12fc39c6d963168ab1d3fc9135 \ + --hash=sha256:53edb4da6925ad13c07b6d26c2a852bd81e364f95301c66e930ab2aef5b5ddd8 \ + --hash=sha256:5855f8438a7d1d458206a2466bf82b0f104a3724bf96a1c781ab731e4201731a \ + --hash=sha256:594c67807fb16238b30c44bdf74f36c02cdf22d1c8cda91ef8a0ed8dabf5620a \ + --hash=sha256:5b6d930f030f8ed98e3e6c98ffa0652bdb82601e7a016ec2ab5d7ff23baa78d1 \ + --hash=sha256:5bb28c636d87e840583ee3adeb78172efc47c8b26127267f54a9c0ec251d41a9 \ + --hash=sha256:60bf42e36abfaf9aff1f50f52644b336d4f0a3fd6d8a60ca0d054ac9f713a864 \ + --hash=sha256:611d1ad9a4288cf3e3c16014564df047fe08410e628f89805e475368bd304914 \ + --hash=sha256:6300b8454aa6930a24b9618fbb54b5a68135092bc666f7b06901f897fa5c2fee \ + --hash=sha256:63f3268ba69ace99cab4e3e3b5840b03340efed0948ab8f78d2fd87ee5442a4f \ + --hash=sha256:6557b31b5e2c9ddf0de32a691f2312a32f77cd7681d8af66c2692efdbef84c18 \ + --hash=sha256:693ce3f9e70a6cf7d2fb9e6c9d8b204b6b39897a2c4a1aa65728d5ac97dcc1d8 \ + --hash=sha256:6a7fae0dd14cf60ad5ff42baa2e95727c3d81ded453457771d02b7d2b3f9c0c2 \ + --hash=sha256:6c4ca60fa24e85fe25b912b01e62cb969d69a23a5d5867682dd3e80b5b02581d \ + --hash=sha256:6fcf051089389abe060c9cd7caa212c707e58153afa2c649f00346ce6d260f1b \ + --hash=sha256:7d91275b0245b1da4d4cfa07e0faedd5b0812efc15b702576d103293e252af1b \ + --hash=sha256:89c687013cb1cd489a0f0ac24febe8c7a666e6e221b783e53ac50ebf68e45d86 \ + --hash=sha256:8d206346619592c6200148b01a2142798c989edcb9c896f9ac9722a99d4e77e6 \ + --hash=sha256:905fec760bd2fa1388bb5b489ee8ee5f7291d692638ea5f67982d968366bef9f \ + --hash=sha256:97383d78eb34da7e1fa37dd273c20ad4320929af65d156e35a5e2d89566d9dfb \ + --hash=sha256:984d76483eb32f1bcb536dc27e4ad56bba4baa70be32fa87152832cdd9db0833 \ + --hash=sha256:99df47edb6bda1249d3e80fdabb1dab8c08ef3975f69aed437cb69d0a5de1e28 \ + --hash=sha256:9f02365d4e99430a12647f09b6cc8bab61a6564363f313126f775eb4f6ef798e \ + --hash=sha256:a30e67a65b53ea0a5e62fe23682cfe22712e01f453b95233b25502f7c61cb415 \ + --hash=sha256:ab3ef638ace319fa26553db0624c4699e31a28bb2a835c5faca8f8acf6a5a902 \ + --hash=sha256:aca6377c0cb8a8253e493c6b451565ac77e98c2951c45f913e0b52facdcff83f \ + --hash=sha256:add36cb2dbb8b736611303cd3bfcee00afd96471b09cda130da3581cbdc56a6d \ + --hash=sha256:b2f4bf27480f5e5e8ce285a8c8fd176c0b03e93dcc6646477d4630e83440c6a9 \ + --hash=sha256:b7f2d075102dc8c794cbde1947378051c4e5180d52d276987b8d28a3bd58c17d \ + --hash=sha256:baa1a4e8f868845af802979fcdbf0bb11f94f1cb7ced4c4b8a351bb60d108145 \ + --hash=sha256:be98f628055368795d818ebf93da628541e10b75b41c559fdf36d104c5787066 \ + --hash=sha256:bf5d821ffabf0ef3533c39c518f3357b171a1651c1ff6827325e4489b0e46c3c \ + --hash=sha256:c47adbc92fc1bb2b3274c4b3a43ae0e4573d9fbff4f54cd484555edbf030baf1 \ + --hash=sha256:cdfba22ea2f0029c9261a4bd07e830a8da012291fbe44dc794e488b6c9bb353a \ + --hash=sha256:d6c7ebd4e944c85e2c3421e612a7057a2f48d478d79e61800d81468a8d842207 \ + --hash=sha256:d7f9850398e85aba693bb640262d3611788b1f29a79f0c93c565694658f4071f \ + --hash=sha256:d8446c54dc28c01e5a2dbac5a25f071f6653e6e40f3a8818e8b45d790fe6ef53 \ + --hash=sha256:deb993cacb280823246a026e3b2d81c493c53de6acfd5e6bfe31ab3402bb37dd \ + --hash=sha256:e0f138900af21926a02425cf736db95be9f4af72ba1bb21453432a07f6082134 \ + --hash=sha256:e9936f0b261d4df76ad22f8fee3ae83b60d7c3e871292cd42f40b81b70afae85 \ + --hash=sha256:f0567c4dc99f264f49fe27da5f735f414c4e7e7dd850cfd8e69f0862d7c74ea9 \ + --hash=sha256:f5653a225f31e113b152e56f154ccbe59eeb1c7487b39b9d9f9cdb58e6c79dc5 \ + --hash=sha256:f826e31d18b516f653fe296d967d700fddad5901ae07c622bb3705955e1faa94 \ + --hash=sha256:f8ba0e8349a38d3001fae7eadded3f6606f0da5d748ee53cc1dab1d6527b9509 \ + --hash=sha256:f9081981fe268bd86831e5c75f7de206ef275defcb82bc70740ae6dc507aee51 \ + --hash=sha256:fa130dd50c57d53368c9d59395cb5526eda596d3ffe36666cd81a44d56e48872 + # via + # -r requirements.in + # jinja2 +packaging==21.3 \ + --hash=sha256:dd47c42927d89ab911e606518907cc2d3a1f38bbd026385970643f9c5b8ecfeb \ + --hash=sha256:ef103e05f519cdc783ae24ea4e2e0f508a9c99b2d4969652eed6a2e1ea5bd522 + # via + # -r requirements.in + # gcp-releasetool +protobuf==3.19.5 \ + --hash=sha256:1867f93b06a183f87696871bb8d1e99ee71dbb69d468ce1f0cc8bf3d30f982f3 \ + --hash=sha256:3c4160b601220627f7e91154e572baf5e161a9c3f445a8242d536ee3d0b7b17c \ + --hash=sha256:4ee2af7051d3b10c8a4fe6fd1a2c69f201fea36aeee7086cf202a692e1b99ee1 \ + --hash=sha256:5266c36cc0af3bb3dbf44f199d225b33da66a9a5c3bdc2b14865ad10eddf0e37 \ + --hash=sha256:5470f892961af464ae6eaf0f3099e2c1190ae8c7f36f174b89491281341f79ca \ + --hash=sha256:66d14b5b90090353efe75c9fb1bf65ef7267383034688d255b500822e37d5c2f \ + --hash=sha256:67efb5d20618020aa9596e17bfc37ca068c28ec0c1507d9507f73c93d46c9855 \ + --hash=sha256:696e6cfab94cc15a14946f2bf72719dced087d437adbd994fff34f38986628bc \ + --hash=sha256:6a02172b9650f819d01fb8e224fc69b0706458fc1ab4f1c669281243c71c1a5e \ + --hash=sha256:6eca9ae238ba615d702387a2ddea635d535d769994a9968c09a4ca920c487ab9 \ + --hash=sha256:950abd6c00e7b51f87ae8b18a0ce4d69fea217f62f171426e77de5061f6d9850 \ + --hash=sha256:9e1d74032f56ff25f417cfe84c8147047732e5059137ca42efad20cbbd25f5e0 \ + --hash=sha256:9e42b1cf2ecd8a1bd161239e693f22035ba99905ae6d7efeac8a0546c7ec1a27 \ + --hash=sha256:9f957ef53e872d58a0afd3bf6d80d48535d28c99b40e75e6634cbc33ea42fd54 \ + --hash=sha256:a89aa0c042e61e11ade320b802d6db4ee5391d8d973e46d3a48172c1597789f8 \ + --hash=sha256:c0f80876a8ff0ae7064084ed094eb86497bd5a3812e6fc96a05318b92301674e \ + --hash=sha256:c44e3282cff74ad18c7e8a0375f407f69ee50c2116364b44492a196293e08b21 \ + --hash=sha256:d249519ba5ecf5dd6b18150c9b6bcde510b273714b696f3923ff8308fc11ae49 \ + --hash=sha256:d3973a2d58aefc7d1230725c2447ce7f86a71cbc094b86a77c6ee1505ac7cdb1 \ + --hash=sha256:dca2284378a5f2a86ffed35c6ac147d14c48b525eefcd1083e5a9ce28dfa8657 \ + --hash=sha256:e63b0b3c42e51c94add62b010366cd4979cb6d5f06158bcae8faac4c294f91e1 \ + --hash=sha256:f2b599a21c9a32e171ec29a2ac54e03297736c578698e11b099d031f79da114b \ + --hash=sha256:f2bde37667b18c2b5280df83bc799204394a5d2d774e4deaf9de0eb741df6833 \ + --hash=sha256:f4f909f4dde413dec435a44b0894956d55bb928ded7d6e3c726556ca4c796e84 \ + --hash=sha256:f976234e20ab2785f54224bcdafa027674e23663b132fa3ca0caa291a6cfbde7 \ + --hash=sha256:f9cebda093c2f6bfed88f1c17cdade09d4d96096421b344026feee236532d4de + # via + # -r requirements.in + # gcp-docuploader + # gcp-releasetool + # google-api-core + # google-cloud-storage + # googleapis-common-protos +pyasn1==0.4.8 \ + --hash=sha256:39c7e2ec30515947ff4e87fb6f456dfc6e84857d34be479c9d4a4ba4bf46aa5d \ + --hash=sha256:aef77c9fb94a3ac588e87841208bdec464471d9871bd5050a287cc9a475cd0ba + # via + # pyasn1-modules + # rsa +pyasn1-modules==0.2.8 \ + --hash=sha256:905f84c712230b2c592c19470d3ca8d552de726050d1d1716282a1f6146be65e \ + --hash=sha256:a50b808ffeb97cb3601dd25981f6b016cbb3d31fbf57a8b8a87428e6158d0c74 + # via google-auth +pycparser==2.21 \ + --hash=sha256:8ee45429555515e1f6b185e78100aea234072576aa43ab53aefcae078162fca9 \ + --hash=sha256:e644fdec12f7872f86c58ff790da456218b10f863970249516d60a5eaca77206 + # via + # -r requirements.in + # cffi +pyjwt==2.4.0 \ + --hash=sha256:72d1d253f32dbd4f5c88eaf1fdc62f3a19f676ccbadb9dbc5d07e951b2b26daf \ + --hash=sha256:d42908208c699b3b973cbeb01a969ba6a96c821eefb1c5bfe4c390c01d67abba + # via + # -r requirements.in + # gcp-releasetool +pyparsing==3.0.9 \ + --hash=sha256:2b020ecf7d21b687f219b71ecad3631f644a47f01403fa1d1036b0c6416d70fb \ + --hash=sha256:5026bae9a10eeaefb61dab2f09052b9f4307d44aee4eda64b309723d8d206bbc + # via + # -r requirements.in + # packaging +pyperclip==1.8.2 \ + --hash=sha256:105254a8b04934f0bc84e9c24eb360a591aaf6535c9def5f29d92af107a9bf57 + # via + # -r requirements.in + # gcp-releasetool +python-dateutil==2.8.2 \ + --hash=sha256:0123cacc1627ae19ddf3c27a5de5bd67ee4586fbdd6440d9748f8abb483d3e86 \ + --hash=sha256:961d03dc3453ebbc59dbdea9e4e11c5651520a876d0f4db161e8674aae935da9 + # via + # -r requirements.in + # gcp-releasetool +requests==2.27.1 \ + --hash=sha256:68d7c56fd5a8999887728ef304a6d12edc7be74f1cfa47714fc8b414525c9a61 \ + --hash=sha256:f22fa1e554c9ddfd16e6e41ac79759e17be9e492b3587efa038054674760e72d + # via + # -r requirements.in + # gcp-releasetool + # google-api-core + # google-cloud-storage +rsa==4.9 \ + --hash=sha256:90260d9058e514786967344d0ef75fa8727eed8a7d2e43ce9f4bcf1b536174f7 \ + --hash=sha256:e38464a49c6c85d7f1351b0126661487a7e0a14a50f1675ec50eb34d4f20ef21 + # via + # -r requirements.in + # google-auth +secretstorage==3.3.3 \ + --hash=sha256:2403533ef369eca6d2ba81718576c5e0f564d5cca1b58f73a8b23e7d4eeebd77 \ + --hash=sha256:f356e6628222568e3af06f2eba8df495efa13b3b63081dafd4f7d9a7b7bc9f99 + # via keyring +six==1.16.0 \ + --hash=sha256:1e61c37477a1626458e36f7b1d82aa5c9b094fa4802892072e49de9c60c4c926 \ + --hash=sha256:8abb2f1d86890a2dfb989f9a77cfcfd3e47c2a354b01111771326f8aa26e0254 + # via + # -r requirements.in + # gcp-docuploader + # google-auth + # python-dateutil +typing-extensions==4.1.1 \ + --hash=sha256:1a9462dcc3347a79b1f1c0271fbe79e844580bb598bafa1ed208b94da3cdcd42 \ + --hash=sha256:21c85e0fe4b9a155d0799430b0ad741cdce7e359660ccbd8b530613e8df88ce2 + # via -r requirements.in +urllib3==1.26.12 \ + --hash=sha256:3fa96cf423e6987997fc326ae8df396db2a8b7c667747d47ddd8ecba91f4a74e \ + --hash=sha256:b930dd878d5a8afb066a637fbb35144fe7901e3b209d1cd4f524bd0e9deee997 + # via + # -r requirements.in + # requests +zipp==3.6.0 \ + --hash=sha256:71c644c5369f4a6e07636f0aa966270449561fcea2e3d6747b8d23efaa9d7832 \ + --hash=sha256:9fe5ea21568a0a70e50f273397638d39b03353731e6cbbb3fd8502a33fec40bc + # via + # -r requirements.in + # importlib-metadata diff --git a/.readme-partials.yml b/.readme-partials.yml index 0cf67de41e..db6f2b40d4 100644 --- a/.readme-partials.yml +++ b/.readme-partials.yml @@ -1,7 +1,7 @@ custom_content: | ## About Cloud Bigtable - [Cloud Bigtable][cloud-bigtable] is Google's NoSQL Big Data database service. It's + [Cloud Bigtable][product-docs] is Google's NoSQL Big Data database service. It's the same database that powers many core Google services, including Search, Analytics, Maps, and Gmail. diff --git a/CHANGELOG.md b/CHANGELOG.md index 40afb09b71..2c07611802 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,146 @@ # Changelog +## [2.17.0](https://github.com/googleapis/java-bigtable/compare/v2.16.0...v2.17.0) (2022-12-07) + + +### Features + +* Add a query paginator ([#1530](https://github.com/googleapis/java-bigtable/issues/1530)) ([5c8e1f6](https://github.com/googleapis/java-bigtable/commit/5c8e1f656b15177ecef4709b9e502cef58cca479)) +* Add test proxy to java-bigtable client ([#1498](https://github.com/googleapis/java-bigtable/issues/1498)) ([132b4e4](https://github.com/googleapis/java-bigtable/commit/132b4e4fe340ca316de8eef2e2133b6dabd9dec3)) +* Implement cross-project table restore ([#1536](https://github.com/googleapis/java-bigtable/issues/1536)) ([335977c](https://github.com/googleapis/java-bigtable/commit/335977c499b1776c8fa861d13195ffc49e468e0a)) +* Next release from main branch is 2.17.0 ([#1514](https://github.com/googleapis/java-bigtable/issues/1514)) ([4fc6a93](https://github.com/googleapis/java-bigtable/commit/4fc6a93a25362df7bc107d48f94e1c00b6bd608d)) + + +### Dependencies + +* Update dependency com.google.cloud:google-cloud-monitoring-bom … ([#1531](https://github.com/googleapis/java-bigtable/issues/1531)) ([ee98338](https://github.com/googleapis/java-bigtable/commit/ee9833835a84cee202b142950b28704db682ac0c)) +* Update dependency com.google.cloud:google-cloud-shared-dependencies to v3.1.0 ([#1539](https://github.com/googleapis/java-bigtable/issues/1539)) ([3244cef](https://github.com/googleapis/java-bigtable/commit/3244cefd4d77a44bab6ccaa8f5c03e3d31575625)) +* Update dependency kr.motd.maven:os-maven-plugin to v1.7.1 ([#1518](https://github.com/googleapis/java-bigtable/issues/1518)) ([8309681](https://github.com/googleapis/java-bigtable/commit/830968109a3754a12bd0bc92674fe42ae529b924)) +* Update dependency org.graalvm.buildtools:junit-platform-native to v0.9.19 ([#1537](https://github.com/googleapis/java-bigtable/issues/1537)) ([7f7c478](https://github.com/googleapis/java-bigtable/commit/7f7c478a2163c46d10ed39ea3c1b046f971d4569)) +* Update dependency org.graalvm.buildtools:native-maven-plugin to v0.9.19 ([#1538](https://github.com/googleapis/java-bigtable/issues/1538)) ([9d3df57](https://github.com/googleapis/java-bigtable/commit/9d3df57d7bfeafd9cbcf56ecd58b52cc1b14ba7b)) + +## [2.16.0](https://github.com/googleapis/java-bigtable/compare/v2.15.1...v2.16.0) (2022-11-11) + + +### Features + +* Remove proto ReadEfficiencyStats ([#1455](https://github.com/googleapis/java-bigtable/issues/1455)) ([f6b243d](https://github.com/googleapis/java-bigtable/commit/f6b243db39c0370f0d9a4e47e553cfe62493b240)) + + +### Bug Fixes + +* Fix metric client settings ([#1509](https://github.com/googleapis/java-bigtable/issues/1509)) ([38ac115](https://github.com/googleapis/java-bigtable/commit/38ac115af07432e9c178064b59729a0b358105cd)) + +## [2.15.1](https://github.com/googleapis/java-bigtable/compare/v2.15.0...v2.15.1) (2022-11-08) + + +### Bug Fixes + +* Call record attempt compeletion on permanent failures ([#1502](https://github.com/googleapis/java-bigtable/issues/1502)) ([f409c47](https://github.com/googleapis/java-bigtable/commit/f409c4769b526b38590671178c007a9c57f9c182)) +* Fix the connectivity error count caculation ([#1401](https://github.com/googleapis/java-bigtable/issues/1401)) ([1f8cfd7](https://github.com/googleapis/java-bigtable/commit/1f8cfd722c749a8d3e30572fbdda6a2e3594d7a6)) +* Only record retry count when it's > 0 ([#1488](https://github.com/googleapis/java-bigtable/issues/1488)) ([445a667](https://github.com/googleapis/java-bigtable/commit/445a66737b45835444b26261b6f017f7fc278f45)) + + +### Dependencies + +* Update dependency com.google.cloud:google-cloud-shared-dependencies to v3.0.6 ([#1501](https://github.com/googleapis/java-bigtable/issues/1501)) ([8f61c64](https://github.com/googleapis/java-bigtable/commit/8f61c64aba815a942daae17ccb024d325c03df8a)) +* Update dependency org.graalvm.buildtools:junit-platform-native to v0.9.17 ([#1495](https://github.com/googleapis/java-bigtable/issues/1495)) ([1b7c21a](https://github.com/googleapis/java-bigtable/commit/1b7c21abc793db0e4706f119e934eecdcfce9994)) +* Update dependency org.graalvm.buildtools:native-maven-plugin to v0.9.17 ([#1496](https://github.com/googleapis/java-bigtable/issues/1496)) ([74779e3](https://github.com/googleapis/java-bigtable/commit/74779e3621c9893bf3a84dc68ddcb624785c8d71)) + +## [2.15.0](https://github.com/googleapis/java-bigtable/compare/v2.14.1...v2.15.0) (2022-10-26) + + +### Features + +* Add apis for Mutation and RowMutationEntry ([#1454](https://github.com/googleapis/java-bigtable/issues/1454)) ([a86934f](https://github.com/googleapis/java-bigtable/commit/a86934f4f70e1998e7368688df8695a4bac7006e)) + + +### Bug Fixes + +* Catch all throwables so version mismatch won't hang the client ([#1402](https://github.com/googleapis/java-bigtable/issues/1402)) ([c03b8a4](https://github.com/googleapis/java-bigtable/commit/c03b8a4245beab7258b8ed8ec76153e6a0275211)) +* Fix attempt status tag for metrics ([#1477](https://github.com/googleapis/java-bigtable/issues/1477)) ([e54cf7d](https://github.com/googleapis/java-bigtable/commit/e54cf7d61128049cea2817b409a8524636b4a6cf)) +* Rename metric names to match the external name ([#1479](https://github.com/googleapis/java-bigtable/issues/1479)) ([28ca7c3](https://github.com/googleapis/java-bigtable/commit/28ca7c310d9a157529555ab6865f89802161443b)) +* Set a longer timeout to wait for callbacks to be executed ([#1478](https://github.com/googleapis/java-bigtable/issues/1478)) ([0d9ff6a](https://github.com/googleapis/java-bigtable/commit/0d9ff6ab3bd5bf853f1d371312036b14c924ae5e)) + + +### Dependencies + +* Update dependency com.google.cloud:google-cloud-monitoring-bom to v3.5.0 ([#1464](https://github.com/googleapis/java-bigtable/issues/1464)) ([d8e58a5](https://github.com/googleapis/java-bigtable/commit/d8e58a5d88de7ea249d7bc141f1ac65592088da6)) +* Update dependency com.google.cloud:google-cloud-monitoring-bom to v3.6.0 ([#1476](https://github.com/googleapis/java-bigtable/issues/1476)) ([331dcfb](https://github.com/googleapis/java-bigtable/commit/331dcfbd06ab578cfe9673ca70cab1f6abd5ddcd)) +* Update dependency com.google.cloud:google-cloud-shared-dependencies to v3.0.5 ([#1470](https://github.com/googleapis/java-bigtable/issues/1470)) ([557a4fb](https://github.com/googleapis/java-bigtable/commit/557a4fbed77157c3ccfc3e84a0c952b647844f9b)) +* Update dependency org.graalvm.buildtools:junit-platform-native to v0.9.15 ([#1462](https://github.com/googleapis/java-bigtable/issues/1462)) ([69540cb](https://github.com/googleapis/java-bigtable/commit/69540cb2df25d5fb716e81e7513930b01c310b72)) +* Update dependency org.graalvm.buildtools:junit-platform-native to v0.9.16 ([#1467](https://github.com/googleapis/java-bigtable/issues/1467)) ([53599ca](https://github.com/googleapis/java-bigtable/commit/53599caa0f92bad1365adbc4b58a1dcb1e8a393e)) +* Update dependency org.graalvm.buildtools:native-maven-plugin to v0.9.15 ([#1463](https://github.com/googleapis/java-bigtable/issues/1463)) ([a6612f9](https://github.com/googleapis/java-bigtable/commit/a6612f90cd4a0ec9589ca797ff3a42d23478a6e6)) +* Update dependency org.graalvm.buildtools:native-maven-plugin to v0.9.16 ([#1468](https://github.com/googleapis/java-bigtable/issues/1468)) ([fe0ddb1](https://github.com/googleapis/java-bigtable/commit/fe0ddb1b183cfdf368c2387a645a613bbfd52a69)) + +## [2.14.1](https://github.com/googleapis/java-bigtable/compare/v2.14.0...v2.14.1) (2022-10-05) + + +### Dependencies + +* Update dependency com.google.cloud:google-cloud-monitoring-bom to v3.4.6 ([#1450](https://github.com/googleapis/java-bigtable/issues/1450)) ([96b1e80](https://github.com/googleapis/java-bigtable/commit/96b1e80af5e17689a84318e9a797195cde3dab45)) + +## [2.14.0](https://github.com/googleapis/java-bigtable/compare/v2.13.0...v2.14.0) (2022-10-03) + + +### Features + +* Publish the RequestStats proto ([#1400](https://github.com/googleapis/java-bigtable/issues/1400)) ([e989200](https://github.com/googleapis/java-bigtable/commit/e989200980510b14d602925df7430e01bc2f8db7)) + + +### Dependencies + +* Update dependency com.google.cloud:google-cloud-shared-dependencies to v3.0.4 ([#1446](https://github.com/googleapis/java-bigtable/issues/1446)) ([81034c5](https://github.com/googleapis/java-bigtable/commit/81034c51722d973cf5545feb33665b4e08265303)) + +## [2.13.0](https://github.com/googleapis/java-bigtable/compare/v2.12.0...v2.13.0) (2022-09-27) + + +### Features + +* Add gRPC RLS dependency ([#1248](https://github.com/googleapis/java-bigtable/issues/1248)) ([e829b92](https://github.com/googleapis/java-bigtable/commit/e829b923d97a00dcb55a14b0877bec2c8cf5ece2)) + + +### Bug Fixes + +* Add a UUID in the task value ([#1430](https://github.com/googleapis/java-bigtable/issues/1430)) ([3bfc7bc](https://github.com/googleapis/java-bigtable/commit/3bfc7bc246488a37b4470e3a75ffdd34f6761804)) + + +### Dependencies + +* Update dependency com.google.cloud:google-cloud-monitoring-bom to v3.4.5 ([#1406](https://github.com/googleapis/java-bigtable/issues/1406)) ([d906729](https://github.com/googleapis/java-bigtable/commit/d906729a4bb9a51907bf4879e8d063d5103565ac)) +* Update dependency org.graalvm.buildtools:junit-platform-native to v0.9.14 ([#1411](https://github.com/googleapis/java-bigtable/issues/1411)) ([ef7d741](https://github.com/googleapis/java-bigtable/commit/ef7d7419293f9f046dcf941148a86da713feae17)) +* Update dependency org.graalvm.buildtools:native-maven-plugin to v0.9.14 ([#1412](https://github.com/googleapis/java-bigtable/issues/1412)) ([dcae319](https://github.com/googleapis/java-bigtable/commit/dcae3195871b78aa6e102c4bc570b18c303c7760)) +* Update dependency org.junit.vintage:junit-vintage-engine to v5.9.1 ([#1409](https://github.com/googleapis/java-bigtable/issues/1409)) ([c1e195d](https://github.com/googleapis/java-bigtable/commit/c1e195d4e0470b30d97231c44b09fcb5c4881514)) + +## [2.12.0](https://github.com/googleapis/java-bigtable/compare/v2.11.2...v2.12.0) (2022-09-15) + + +### Features + +* **generated:** Publish CBT deletion_protection field in Table, UpdateTableRequest, and UpdateTable API ([f1f3f05](https://github.com/googleapis/java-bigtable/commit/f1f3f05ae2dc84a8dc853eb5467fbd157b7293c3)) + + +### Dependencies + +* Update dependency com.google.cloud:google-cloud-monitoring-bom to v3.4.3 ([#1386](https://github.com/googleapis/java-bigtable/issues/1386)) ([f460373](https://github.com/googleapis/java-bigtable/commit/f460373eb74776fae1787b74392b508643e6139f)) +* Update dependency com.google.cloud:google-cloud-monitoring-bom to v3.4.3 ([#1387](https://github.com/googleapis/java-bigtable/issues/1387)) ([e339cb1](https://github.com/googleapis/java-bigtable/commit/e339cb186289fa53a0d65c3d77fb7edbae737882)) +* Update dependency com.google.cloud:google-cloud-monitoring-bom to v3.4.4 ([#1395](https://github.com/googleapis/java-bigtable/issues/1395)) ([a2db183](https://github.com/googleapis/java-bigtable/commit/a2db183dea46cd83ea70bb89848e0579b9c61fac)) +* Update dependency com.google.cloud:google-cloud-shared-dependencies to v3.0.2 ([#1384](https://github.com/googleapis/java-bigtable/issues/1384)) ([ee3b256](https://github.com/googleapis/java-bigtable/commit/ee3b256a62c2665e2c4230d9acfc14c3d5c2aebf)) +* Update dependency com.google.cloud:google-cloud-shared-dependencies to v3.0.3 ([#1393](https://github.com/googleapis/java-bigtable/issues/1393)) ([df6c6c7](https://github.com/googleapis/java-bigtable/commit/df6c6c79715ecc7b99e026ce8dfa8645765fc9d5)) + +## [2.11.2](https://github.com/googleapis/java-bigtable/compare/v2.11.1...v2.11.2) (2022-09-07) + + +### Bug Fixes + +* Make cloud-monitoring a runtime dependency ([#1371](https://github.com/googleapis/java-bigtable/issues/1371)) ([930d043](https://github.com/googleapis/java-bigtable/commit/930d0439086d2b43735f9583175adf0626952c9b)) + + +### Dependencies + +* Update dependency com.google.cloud:google-cloud-monitoring-bom to v3.4.2 ([#1373](https://github.com/googleapis/java-bigtable/issues/1373)) ([43b8052](https://github.com/googleapis/java-bigtable/commit/43b80523cc00932a414702ad96cfd86984c0f649)) +* Update dependency com.google.cloud:google-cloud-monitoring-bom to v3.4.2 ([#1374](https://github.com/googleapis/java-bigtable/issues/1374)) ([4174f0d](https://github.com/googleapis/java-bigtable/commit/4174f0dc1b61f954ccd1c2fcf88066179a4d430b)) + ## [2.11.1](https://github.com/googleapis/java-bigtable/compare/v2.11.0...v2.11.1) (2022-08-26) diff --git a/README.md b/README.md index 87450e5569..be062c7f26 100644 --- a/README.md +++ b/README.md @@ -19,7 +19,7 @@ If you are using Maven with [BOM][libraries-bom], add this to your pom.xml file: com.google.cloud libraries-bom - 26.1.1 + 26.1.5 pom import @@ -41,7 +41,7 @@ If you are using Maven without BOM, add this to your dependencies: com.google.cloud google-cloud-bigtable - 2.11.1 + 2.17.0 ``` @@ -49,20 +49,20 @@ If you are using Maven without BOM, add this to your dependencies: If you are using Gradle 5.x or later, add this to your dependencies: ```Groovy -implementation platform('com.google.cloud:libraries-bom:26.1.1') +implementation platform('com.google.cloud:libraries-bom:26.1.5') implementation 'com.google.cloud:google-cloud-bigtable' ``` If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-bigtable:2.11.1' +implementation 'com.google.cloud:google-cloud-bigtable:2.17.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-bigtable" % "2.11.1" +libraryDependencies += "com.google.cloud" % "google-cloud-bigtable" % "2.17.0" ``` ## Authentication @@ -99,7 +99,7 @@ use this Cloud Bigtable Client Library. ## About Cloud Bigtable -[Cloud Bigtable][cloud-bigtable] is Google's NoSQL Big Data database service. It's +[Cloud Bigtable][product-docs] is Google's NoSQL Big Data database service. It's the same database that powers many core Google services, including Search, Analytics, Maps, and Gmail. @@ -490,6 +490,7 @@ Samples are in the [`samples/`](https://github.com/googleapis/java-bigtable/tree | Filters | [source code](https://github.com/googleapis/java-bigtable/blob/main/samples/snippets/src/main/java/com/example/bigtable/Filters.java) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/java-bigtable&page=editor&open_in_editor=samples/snippets/src/main/java/com/example/bigtable/Filters.java) | | Hello World | [source code](https://github.com/googleapis/java-bigtable/blob/main/samples/snippets/src/main/java/com/example/bigtable/HelloWorld.java) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/java-bigtable&page=editor&open_in_editor=samples/snippets/src/main/java/com/example/bigtable/HelloWorld.java) | | Instance Admin Example | [source code](https://github.com/googleapis/java-bigtable/blob/main/samples/snippets/src/main/java/com/example/bigtable/InstanceAdminExample.java) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/java-bigtable&page=editor&open_in_editor=samples/snippets/src/main/java/com/example/bigtable/InstanceAdminExample.java) | +| Key Salting | [source code](https://github.com/googleapis/java-bigtable/blob/main/samples/snippets/src/main/java/com/example/bigtable/KeySalting.java) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/java-bigtable&page=editor&open_in_editor=samples/snippets/src/main/java/com/example/bigtable/KeySalting.java) | | Quickstart | [source code](https://github.com/googleapis/java-bigtable/blob/main/samples/snippets/src/main/java/com/example/bigtable/Quickstart.java) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/java-bigtable&page=editor&open_in_editor=samples/snippets/src/main/java/com/example/bigtable/Quickstart.java) | | Reads | [source code](https://github.com/googleapis/java-bigtable/blob/main/samples/snippets/src/main/java/com/example/bigtable/Reads.java) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/java-bigtable&page=editor&open_in_editor=samples/snippets/src/main/java/com/example/bigtable/Reads.java) | | Table Admin Example | [source code](https://github.com/googleapis/java-bigtable/blob/main/samples/snippets/src/main/java/com/example/bigtable/TableAdminExample.java) | [![Open in Cloud Shell][shell_img]](https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/googleapis/java-bigtable&page=editor&open_in_editor=samples/snippets/src/main/java/com/example/bigtable/TableAdminExample.java) | diff --git a/google-cloud-bigtable-bom/pom.xml b/google-cloud-bigtable-bom/pom.xml index 42d5e00ed9..7659a8b216 100644 --- a/google-cloud-bigtable-bom/pom.xml +++ b/google-cloud-bigtable-bom/pom.xml @@ -3,12 +3,12 @@ 4.0.0 com.google.cloud google-cloud-bigtable-bom - 2.11.2-SNAPSHOT + 2.17.1-SNAPSHOT pom com.google.cloud google-cloud-shared-config - 1.5.1 + 1.5.5 @@ -63,42 +63,42 @@ com.google.cloud google-cloud-bigtable - 2.11.2-SNAPSHOT + 2.17.1-SNAPSHOT com.google.cloud google-cloud-bigtable-emulator - 0.148.2-SNAPSHOT + 0.154.1-SNAPSHOT com.google.cloud google-cloud-bigtable-emulator-core - 0.148.2-SNAPSHOT + 0.154.1-SNAPSHOT com.google.api.grpc grpc-google-cloud-bigtable-admin-v2 - 2.11.2-SNAPSHOT + 2.17.1-SNAPSHOT com.google.api.grpc grpc-google-cloud-bigtable-v2 - 2.11.2-SNAPSHOT + 2.17.1-SNAPSHOT com.google.api.grpc proto-google-cloud-bigtable-admin-v2 - 2.11.2-SNAPSHOT + 2.17.1-SNAPSHOT com.google.api.grpc proto-google-cloud-bigtable-v2 - 2.11.2-SNAPSHOT + 2.17.1-SNAPSHOT com.google.cloud google-cloud-bigtable-stats - 2.11.2-SNAPSHOT + 2.17.1-SNAPSHOT diff --git a/google-cloud-bigtable-deps-bom/pom.xml b/google-cloud-bigtable-deps-bom/pom.xml index c1daa36633..d485846d78 100644 --- a/google-cloud-bigtable-deps-bom/pom.xml +++ b/google-cloud-bigtable-deps-bom/pom.xml @@ -7,13 +7,13 @@ com.google.cloud google-cloud-shared-config - 1.5.1 + 1.5.5 com.google.cloud google-cloud-bigtable-deps-bom - 2.11.2-SNAPSHOT + 2.17.1-SNAPSHOT pom @@ -66,7 +66,21 @@ com.google.cloud google-cloud-shared-dependencies - 3.0.1 + 3.1.0 + pom + import + + + com.google.cloud + google-cloud-monitoring-bom + 3.7.0 + + + + io.perfmark + perfmark-api + + pom import diff --git a/google-cloud-bigtable-emulator-core/pom.xml b/google-cloud-bigtable-emulator-core/pom.xml index e9b6c5c6a2..5cc1dfa1ef 100644 --- a/google-cloud-bigtable-emulator-core/pom.xml +++ b/google-cloud-bigtable-emulator-core/pom.xml @@ -7,11 +7,11 @@ google-cloud-bigtable-parent com.google.cloud - 2.11.2-SNAPSHOT + 2.17.1-SNAPSHOT google-cloud-bigtable-emulator-core - 0.148.2-SNAPSHOT + 0.154.1-SNAPSHOT A Java wrapper for the Cloud Bigtable emulator. diff --git a/google-cloud-bigtable-emulator/pom.xml b/google-cloud-bigtable-emulator/pom.xml index 6a4454705c..05e0f41109 100644 --- a/google-cloud-bigtable-emulator/pom.xml +++ b/google-cloud-bigtable-emulator/pom.xml @@ -5,7 +5,7 @@ 4.0.0 google-cloud-bigtable-emulator - 0.148.2-SNAPSHOT + 0.154.1-SNAPSHOT Google Cloud Java - Bigtable Emulator https://github.com/googleapis/java-bigtable @@ -14,7 +14,7 @@ com.google.cloud google-cloud-bigtable-parent - 2.11.2-SNAPSHOT + 2.17.1-SNAPSHOT scm:git:git@github.com:googleapis/java-bigtable.git @@ -81,14 +81,14 @@ com.google.cloud google-cloud-bigtable-deps-bom - 2.11.2-SNAPSHOT + 2.17.1-SNAPSHOT pom import com.google.cloud google-cloud-bigtable-bom - 2.11.2-SNAPSHOT + 2.17.1-SNAPSHOT pom import @@ -99,7 +99,7 @@ com.google.cloud google-cloud-bigtable-emulator-core - 0.148.2-SNAPSHOT + 0.154.1-SNAPSHOT diff --git a/google-cloud-bigtable-stats/pom.xml b/google-cloud-bigtable-stats/pom.xml index 5b950728a8..357520c53e 100644 --- a/google-cloud-bigtable-stats/pom.xml +++ b/google-cloud-bigtable-stats/pom.xml @@ -5,7 +5,7 @@ com.google.cloud google-cloud-bigtable-parent - 2.11.2-SNAPSHOT + 2.17.1-SNAPSHOT 4.0.0 @@ -13,7 +13,7 @@ through Stackdriver. Built-in metrics will be implemented with shaded OpenCensus so it won't interfere with customer's application metrics. --> google-cloud-bigtable-stats - 2.11.2-SNAPSHOT + 2.17.1-SNAPSHOT Experimental project to shade OpenCensus dependencies. @@ -25,14 +25,7 @@ com.google.cloud google-cloud-bigtable-deps-bom - 2.11.2-SNAPSHOT - pom - import - - - com.google.cloud - google-cloud-monitoring-bom - ${cloud.monitoring.version} + 2.17.1-SNAPSHOT pom import @@ -69,6 +62,11 @@ com.google.http-client google-http-client + + + io.perfmark + perfmark-api + @@ -191,7 +189,7 @@ org.apache.maven.plugins maven-dependency-plugin - 3.3.0 + 3.4.0 diff --git a/google-cloud-bigtable-stats/src/main/java/com/google/cloud/bigtable/stats/BigtableStackdriverExportUtils.java b/google-cloud-bigtable-stats/src/main/java/com/google/cloud/bigtable/stats/BigtableStackdriverExportUtils.java index bdca097050..ff3e93158b 100644 --- a/google-cloud-bigtable-stats/src/main/java/com/google/cloud/bigtable/stats/BigtableStackdriverExportUtils.java +++ b/google-cloud-bigtable-stats/src/main/java/com/google/cloud/bigtable/stats/BigtableStackdriverExportUtils.java @@ -46,6 +46,7 @@ import java.util.List; import java.util.Map; import java.util.Set; +import java.util.UUID; import java.util.logging.Level; import java.util.logging.Logger; import javax.annotation.Nullable; @@ -168,7 +169,7 @@ static String getDefaultTaskValue() { // Generate a random number and use the same format "random_number@hostname". return "java-" + new SecureRandom().nextInt() + "@" + hostname; } - return "java-" + jvmName; + return "java-" + UUID.randomUUID() + jvmName; } private static MetricKind createMetricKind(Type type) { diff --git a/google-cloud-bigtable-stats/src/main/java/com/google/cloud/bigtable/stats/BigtableStackdriverStatsExporter.java b/google-cloud-bigtable-stats/src/main/java/com/google/cloud/bigtable/stats/BigtableStackdriverStatsExporter.java index 8896e52d89..f6c80fdf88 100644 --- a/google-cloud-bigtable-stats/src/main/java/com/google/cloud/bigtable/stats/BigtableStackdriverStatsExporter.java +++ b/google-cloud-bigtable-stats/src/main/java/com/google/cloud/bigtable/stats/BigtableStackdriverStatsExporter.java @@ -85,9 +85,8 @@ static MetricServiceClient createMetricServiceClient(Credentials credentials, Du .setTransportChannelProvider(InstantiatingGrpcChannelProvider.newBuilder().build()); settingsBuilder.setCredentialsProvider(FixedCredentialsProvider.create(credentials)); - org.threeten.bp.Duration stackdriverDuration = - org.threeten.bp.Duration.ofMillis(deadline.toMillis()); - settingsBuilder.createTimeSeriesSettings().setSimpleTimeoutNoRetries(stackdriverDuration); + org.threeten.bp.Duration timeout = org.threeten.bp.Duration.ofMillis(deadline.toMillis()); + settingsBuilder.createServiceTimeSeriesSettings().setSimpleTimeoutNoRetries(timeout); return MetricServiceClient.create(settingsBuilder.build()); } } diff --git a/google-cloud-bigtable/clirr-ignored-differences.xml b/google-cloud-bigtable/clirr-ignored-differences.xml index 80d3d22703..5e5f8c9733 100644 --- a/google-cloud-bigtable/clirr-ignored-differences.xml +++ b/google-cloud-bigtable/clirr-ignored-differences.xml @@ -54,7 +54,7 @@ 8001 com/google/cloud/bigtable/data/v2/stub/metrics/HeaderTracer$Builder - change method args is ok because HeaderTracerStreamingCallable is InternalApi + 7004 com/google/cloud/bigtable/data/v2/stub/metrics/HeaderTracerStreamingCallable @@ -81,4 +81,9 @@ 8001 com/google/cloud/bigtable/data/v2/stub/readrows/ReadRowsConvertExceptionCallable + + 5001 + com/google/cloud/bigtable/gaxx/reframing/ReframingResponseObserver + com/google/api/gax/rpc/StateCheckingResponseObserver + diff --git a/google-cloud-bigtable/pom.xml b/google-cloud-bigtable/pom.xml index 487dfeadf8..3ecf2ede99 100644 --- a/google-cloud-bigtable/pom.xml +++ b/google-cloud-bigtable/pom.xml @@ -2,7 +2,7 @@ 4.0.0 google-cloud-bigtable - 2.11.2-SNAPSHOT + 2.17.1-SNAPSHOT jar Google Cloud Bigtable https://github.com/googleapis/java-bigtable @@ -12,11 +12,11 @@ com.google.cloud google-cloud-bigtable-parent - 2.11.2-SNAPSHOT + 2.17.1-SNAPSHOT - 2.11.2-SNAPSHOT + 2.17.1-SNAPSHOT google-cloud-bigtable @@ -47,21 +47,14 @@ com.google.cloud google-cloud-bigtable-deps-bom - 2.11.2-SNAPSHOT + 2.17.1-SNAPSHOT pom import com.google.cloud google-cloud-bigtable-bom - 2.11.2-SNAPSHOT - pom - import - - - com.google.cloud - google-cloud-monitoring-bom - 3.4.2 + 2.17.1-SNAPSHOT pom import @@ -210,6 +203,16 @@ grpc-grpclb runtime + + io.grpc + grpc-googleapis + runtime + + + io.grpc + grpc-rls + runtime + io.grpc grpc-netty-shaded @@ -269,6 +272,13 @@ com.google.cloud google-cloud-monitoring + + + + io.perfmark + perfmark-api + + runtime @@ -679,7 +689,7 @@ org.apache.maven.shared maven-dependency-tree - 3.2.0 + 3.2.1 diff --git a/google-cloud-bigtable/src/main/java/com/google/cloud/bigtable/Version.java b/google-cloud-bigtable/src/main/java/com/google/cloud/bigtable/Version.java index 1b0c34607f..e546a333ba 100644 --- a/google-cloud-bigtable/src/main/java/com/google/cloud/bigtable/Version.java +++ b/google-cloud-bigtable/src/main/java/com/google/cloud/bigtable/Version.java @@ -20,6 +20,6 @@ @InternalApi("For internal use only") public final class Version { // {x-version-update-start:google-cloud-bigtable:current} - public static String VERSION = "2.11.2-SNAPSHOT"; + public static String VERSION = "2.17.1-SNAPSHOT"; // {x-version-update-end} } diff --git a/google-cloud-bigtable/src/main/java/com/google/cloud/bigtable/admin/v2/BaseBigtableInstanceAdminClient.java b/google-cloud-bigtable/src/main/java/com/google/cloud/bigtable/admin/v2/BaseBigtableInstanceAdminClient.java index 4a29a8bf4a..a3f0a5a60e 100644 --- a/google-cloud-bigtable/src/main/java/com/google/cloud/bigtable/admin/v2/BaseBigtableInstanceAdminClient.java +++ b/google-cloud-bigtable/src/main/java/com/google/cloud/bigtable/admin/v2/BaseBigtableInstanceAdminClient.java @@ -158,8 +158,11 @@ public final OperationsClient getOperationsClient() { *

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // 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/java/docs/setup#configure_endpoints_for_the_client_library
    * try (BaseBigtableInstanceAdminClient baseBigtableInstanceAdminClient =
    *     BaseBigtableInstanceAdminClient.create()) {
    *   ProjectName parent = ProjectName.of("[PROJECT]");
@@ -209,8 +212,11 @@ public final OperationFuture createInstanceAsy
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // 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/java/docs/setup#configure_endpoints_for_the_client_library
    * try (BaseBigtableInstanceAdminClient baseBigtableInstanceAdminClient =
    *     BaseBigtableInstanceAdminClient.create()) {
    *   String parent = ProjectName.of("[PROJECT]").toString();
@@ -260,8 +266,11 @@ public final OperationFuture createInstanceAsy
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // 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/java/docs/setup#configure_endpoints_for_the_client_library
    * try (BaseBigtableInstanceAdminClient baseBigtableInstanceAdminClient =
    *     BaseBigtableInstanceAdminClient.create()) {
    *   CreateInstanceRequest request =
@@ -295,8 +304,11 @@ public final OperationFuture createInstanceAsy
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // 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/java/docs/setup#configure_endpoints_for_the_client_library
    * try (BaseBigtableInstanceAdminClient baseBigtableInstanceAdminClient =
    *     BaseBigtableInstanceAdminClient.create()) {
    *   CreateInstanceRequest request =
@@ -330,8 +342,11 @@ public final OperationFuture createInstanceAsy
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // 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/java/docs/setup#configure_endpoints_for_the_client_library
    * try (BaseBigtableInstanceAdminClient baseBigtableInstanceAdminClient =
    *     BaseBigtableInstanceAdminClient.create()) {
    *   CreateInstanceRequest request =
@@ -359,8 +374,11 @@ public final UnaryCallable createInstanceCalla
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // 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/java/docs/setup#configure_endpoints_for_the_client_library
    * try (BaseBigtableInstanceAdminClient baseBigtableInstanceAdminClient =
    *     BaseBigtableInstanceAdminClient.create()) {
    *   InstanceName name = InstanceName.of("[PROJECT]", "[INSTANCE]");
@@ -385,8 +403,11 @@ public final Instance getInstance(InstanceName name) {
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // 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/java/docs/setup#configure_endpoints_for_the_client_library
    * try (BaseBigtableInstanceAdminClient baseBigtableInstanceAdminClient =
    *     BaseBigtableInstanceAdminClient.create()) {
    *   String name = InstanceName.of("[PROJECT]", "[INSTANCE]").toString();
@@ -410,8 +431,11 @@ public final Instance getInstance(String name) {
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // 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/java/docs/setup#configure_endpoints_for_the_client_library
    * try (BaseBigtableInstanceAdminClient baseBigtableInstanceAdminClient =
    *     BaseBigtableInstanceAdminClient.create()) {
    *   GetInstanceRequest request =
@@ -436,8 +460,11 @@ public final Instance getInstance(GetInstanceRequest request) {
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // 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/java/docs/setup#configure_endpoints_for_the_client_library
    * try (BaseBigtableInstanceAdminClient baseBigtableInstanceAdminClient =
    *     BaseBigtableInstanceAdminClient.create()) {
    *   GetInstanceRequest request =
@@ -462,8 +489,11 @@ public final UnaryCallable getInstanceCallable() {
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // 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/java/docs/setup#configure_endpoints_for_the_client_library
    * try (BaseBigtableInstanceAdminClient baseBigtableInstanceAdminClient =
    *     BaseBigtableInstanceAdminClient.create()) {
    *   ProjectName parent = ProjectName.of("[PROJECT]");
@@ -490,8 +520,11 @@ public final ListInstancesResponse listInstances(ProjectName parent) {
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // 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/java/docs/setup#configure_endpoints_for_the_client_library
    * try (BaseBigtableInstanceAdminClient baseBigtableInstanceAdminClient =
    *     BaseBigtableInstanceAdminClient.create()) {
    *   String parent = ProjectName.of("[PROJECT]").toString();
@@ -515,8 +548,11 @@ public final ListInstancesResponse listInstances(String parent) {
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // 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/java/docs/setup#configure_endpoints_for_the_client_library
    * try (BaseBigtableInstanceAdminClient baseBigtableInstanceAdminClient =
    *     BaseBigtableInstanceAdminClient.create()) {
    *   ListInstancesRequest request =
@@ -542,8 +578,11 @@ public final ListInstancesResponse listInstances(ListInstancesRequest request) {
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // 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/java/docs/setup#configure_endpoints_for_the_client_library
    * try (BaseBigtableInstanceAdminClient baseBigtableInstanceAdminClient =
    *     BaseBigtableInstanceAdminClient.create()) {
    *   ListInstancesRequest request =
@@ -570,8 +609,11 @@ public final UnaryCallable listInst
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // 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/java/docs/setup#configure_endpoints_for_the_client_library
    * try (BaseBigtableInstanceAdminClient baseBigtableInstanceAdminClient =
    *     BaseBigtableInstanceAdminClient.create()) {
    *   Instance request =
@@ -580,6 +622,7 @@ public final UnaryCallable listInst
    *           .setDisplayName("displayName1714148973")
    *           .putAllLabels(new HashMap())
    *           .setCreateTime(Timestamp.newBuilder().build())
+   *           .setSatisfiesPzs(true)
    *           .build();
    *   Instance response = baseBigtableInstanceAdminClient.updateInstance(request);
    * }
@@ -600,8 +643,11 @@ public final Instance updateInstance(Instance request) {
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // 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/java/docs/setup#configure_endpoints_for_the_client_library
    * try (BaseBigtableInstanceAdminClient baseBigtableInstanceAdminClient =
    *     BaseBigtableInstanceAdminClient.create()) {
    *   Instance request =
@@ -610,6 +656,7 @@ public final Instance updateInstance(Instance request) {
    *           .setDisplayName("displayName1714148973")
    *           .putAllLabels(new HashMap())
    *           .setCreateTime(Timestamp.newBuilder().build())
+   *           .setSatisfiesPzs(true)
    *           .build();
    *   ApiFuture future =
    *       baseBigtableInstanceAdminClient.updateInstanceCallable().futureCall(request);
@@ -630,8 +677,11 @@ public final UnaryCallable updateInstanceCallable() {
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // 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/java/docs/setup#configure_endpoints_for_the_client_library
    * try (BaseBigtableInstanceAdminClient baseBigtableInstanceAdminClient =
    *     BaseBigtableInstanceAdminClient.create()) {
    *   Instance instance = Instance.newBuilder().build();
@@ -664,8 +714,11 @@ public final OperationFuture partialUpdateInst
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // 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/java/docs/setup#configure_endpoints_for_the_client_library
    * try (BaseBigtableInstanceAdminClient baseBigtableInstanceAdminClient =
    *     BaseBigtableInstanceAdminClient.create()) {
    *   PartialUpdateInstanceRequest request =
@@ -693,8 +746,11 @@ public final OperationFuture partialUpdateInst
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // 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/java/docs/setup#configure_endpoints_for_the_client_library
    * try (BaseBigtableInstanceAdminClient baseBigtableInstanceAdminClient =
    *     BaseBigtableInstanceAdminClient.create()) {
    *   PartialUpdateInstanceRequest request =
@@ -724,8 +780,11 @@ public final OperationFuture partialUpdateInst
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // 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/java/docs/setup#configure_endpoints_for_the_client_library
    * try (BaseBigtableInstanceAdminClient baseBigtableInstanceAdminClient =
    *     BaseBigtableInstanceAdminClient.create()) {
    *   PartialUpdateInstanceRequest request =
@@ -752,8 +811,11 @@ public final OperationFuture partialUpdateInst
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // 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/java/docs/setup#configure_endpoints_for_the_client_library
    * try (BaseBigtableInstanceAdminClient baseBigtableInstanceAdminClient =
    *     BaseBigtableInstanceAdminClient.create()) {
    *   InstanceName name = InstanceName.of("[PROJECT]", "[INSTANCE]");
@@ -778,8 +840,11 @@ public final void deleteInstance(InstanceName name) {
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // 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/java/docs/setup#configure_endpoints_for_the_client_library
    * try (BaseBigtableInstanceAdminClient baseBigtableInstanceAdminClient =
    *     BaseBigtableInstanceAdminClient.create()) {
    *   String name = InstanceName.of("[PROJECT]", "[INSTANCE]").toString();
@@ -803,8 +868,11 @@ public final void deleteInstance(String name) {
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // 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/java/docs/setup#configure_endpoints_for_the_client_library
    * try (BaseBigtableInstanceAdminClient baseBigtableInstanceAdminClient =
    *     BaseBigtableInstanceAdminClient.create()) {
    *   DeleteInstanceRequest request =
@@ -829,8 +897,11 @@ public final void deleteInstance(DeleteInstanceRequest request) {
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // 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/java/docs/setup#configure_endpoints_for_the_client_library
    * try (BaseBigtableInstanceAdminClient baseBigtableInstanceAdminClient =
    *     BaseBigtableInstanceAdminClient.create()) {
    *   DeleteInstanceRequest request =
@@ -860,8 +931,11 @@ public final UnaryCallable deleteInstanceCallable(
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // 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/java/docs/setup#configure_endpoints_for_the_client_library
    * try (BaseBigtableInstanceAdminClient baseBigtableInstanceAdminClient =
    *     BaseBigtableInstanceAdminClient.create()) {
    *   InstanceName parent = InstanceName.of("[PROJECT]", "[INSTANCE]");
@@ -904,8 +978,11 @@ public final OperationFuture createClusterAsync(
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // 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/java/docs/setup#configure_endpoints_for_the_client_library
    * try (BaseBigtableInstanceAdminClient baseBigtableInstanceAdminClient =
    *     BaseBigtableInstanceAdminClient.create()) {
    *   String parent = InstanceName.of("[PROJECT]", "[INSTANCE]").toString();
@@ -948,8 +1025,11 @@ public final OperationFuture createClusterAsync(
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // 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/java/docs/setup#configure_endpoints_for_the_client_library
    * try (BaseBigtableInstanceAdminClient baseBigtableInstanceAdminClient =
    *     BaseBigtableInstanceAdminClient.create()) {
    *   CreateClusterRequest request =
@@ -982,8 +1062,11 @@ public final OperationFuture createClusterAsync(
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // 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/java/docs/setup#configure_endpoints_for_the_client_library
    * try (BaseBigtableInstanceAdminClient baseBigtableInstanceAdminClient =
    *     BaseBigtableInstanceAdminClient.create()) {
    *   CreateClusterRequest request =
@@ -1016,8 +1099,11 @@ public final OperationFuture createClusterAsync(
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // 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/java/docs/setup#configure_endpoints_for_the_client_library
    * try (BaseBigtableInstanceAdminClient baseBigtableInstanceAdminClient =
    *     BaseBigtableInstanceAdminClient.create()) {
    *   CreateClusterRequest request =
@@ -1044,8 +1130,11 @@ public final UnaryCallable createClusterCallabl
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // 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/java/docs/setup#configure_endpoints_for_the_client_library
    * try (BaseBigtableInstanceAdminClient baseBigtableInstanceAdminClient =
    *     BaseBigtableInstanceAdminClient.create()) {
    *   ClusterName name = ClusterName.of("[PROJECT]", "[INSTANCE]", "[CLUSTER]");
@@ -1070,8 +1159,11 @@ public final Cluster getCluster(ClusterName name) {
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // 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/java/docs/setup#configure_endpoints_for_the_client_library
    * try (BaseBigtableInstanceAdminClient baseBigtableInstanceAdminClient =
    *     BaseBigtableInstanceAdminClient.create()) {
    *   String name = ClusterName.of("[PROJECT]", "[INSTANCE]", "[CLUSTER]").toString();
@@ -1095,8 +1187,11 @@ public final Cluster getCluster(String name) {
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // 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/java/docs/setup#configure_endpoints_for_the_client_library
    * try (BaseBigtableInstanceAdminClient baseBigtableInstanceAdminClient =
    *     BaseBigtableInstanceAdminClient.create()) {
    *   GetClusterRequest request =
@@ -1121,8 +1216,11 @@ public final Cluster getCluster(GetClusterRequest request) {
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // 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/java/docs/setup#configure_endpoints_for_the_client_library
    * try (BaseBigtableInstanceAdminClient baseBigtableInstanceAdminClient =
    *     BaseBigtableInstanceAdminClient.create()) {
    *   GetClusterRequest request =
@@ -1147,8 +1245,11 @@ public final UnaryCallable getClusterCallable() {
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // 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/java/docs/setup#configure_endpoints_for_the_client_library
    * try (BaseBigtableInstanceAdminClient baseBigtableInstanceAdminClient =
    *     BaseBigtableInstanceAdminClient.create()) {
    *   InstanceName parent = InstanceName.of("[PROJECT]", "[INSTANCE]");
@@ -1177,8 +1278,11 @@ public final ListClustersResponse listClusters(InstanceName parent) {
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // 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/java/docs/setup#configure_endpoints_for_the_client_library
    * try (BaseBigtableInstanceAdminClient baseBigtableInstanceAdminClient =
    *     BaseBigtableInstanceAdminClient.create()) {
    *   String parent = InstanceName.of("[PROJECT]", "[INSTANCE]").toString();
@@ -1204,8 +1308,11 @@ public final ListClustersResponse listClusters(String parent) {
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // 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/java/docs/setup#configure_endpoints_for_the_client_library
    * try (BaseBigtableInstanceAdminClient baseBigtableInstanceAdminClient =
    *     BaseBigtableInstanceAdminClient.create()) {
    *   ListClustersRequest request =
@@ -1231,8 +1338,11 @@ public final ListClustersResponse listClusters(ListClustersRequest request) {
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // 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/java/docs/setup#configure_endpoints_for_the_client_library
    * try (BaseBigtableInstanceAdminClient baseBigtableInstanceAdminClient =
    *     BaseBigtableInstanceAdminClient.create()) {
    *   ListClustersRequest request =
@@ -1261,8 +1371,11 @@ public final UnaryCallable listCluste
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // 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/java/docs/setup#configure_endpoints_for_the_client_library
    * try (BaseBigtableInstanceAdminClient baseBigtableInstanceAdminClient =
    *     BaseBigtableInstanceAdminClient.create()) {
    *   Cluster request =
@@ -1294,8 +1407,11 @@ public final OperationFuture updateClusterAsync(
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // 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/java/docs/setup#configure_endpoints_for_the_client_library
    * try (BaseBigtableInstanceAdminClient baseBigtableInstanceAdminClient =
    *     BaseBigtableInstanceAdminClient.create()) {
    *   Cluster request =
@@ -1328,8 +1444,11 @@ public final OperationFuture updateClusterAsync(
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // 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/java/docs/setup#configure_endpoints_for_the_client_library
    * try (BaseBigtableInstanceAdminClient baseBigtableInstanceAdminClient =
    *     BaseBigtableInstanceAdminClient.create()) {
    *   Cluster request =
@@ -1368,8 +1487,11 @@ public final UnaryCallable updateClusterCallable() {
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // 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/java/docs/setup#configure_endpoints_for_the_client_library
    * try (BaseBigtableInstanceAdminClient baseBigtableInstanceAdminClient =
    *     BaseBigtableInstanceAdminClient.create()) {
    *   Cluster cluster = Cluster.newBuilder().build();
@@ -1411,8 +1533,11 @@ public final OperationFuture partialUpdat
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // 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/java/docs/setup#configure_endpoints_for_the_client_library
    * try (BaseBigtableInstanceAdminClient baseBigtableInstanceAdminClient =
    *     BaseBigtableInstanceAdminClient.create()) {
    *   PartialUpdateClusterRequest request =
@@ -1449,8 +1574,11 @@ public final OperationFuture partialUpdat
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // 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/java/docs/setup#configure_endpoints_for_the_client_library
    * try (BaseBigtableInstanceAdminClient baseBigtableInstanceAdminClient =
    *     BaseBigtableInstanceAdminClient.create()) {
    *   PartialUpdateClusterRequest request =
@@ -1489,8 +1617,11 @@ public final OperationFuture partialUpdat
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // 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/java/docs/setup#configure_endpoints_for_the_client_library
    * try (BaseBigtableInstanceAdminClient baseBigtableInstanceAdminClient =
    *     BaseBigtableInstanceAdminClient.create()) {
    *   PartialUpdateClusterRequest request =
@@ -1517,8 +1648,11 @@ public final OperationFuture partialUpdat
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // 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/java/docs/setup#configure_endpoints_for_the_client_library
    * try (BaseBigtableInstanceAdminClient baseBigtableInstanceAdminClient =
    *     BaseBigtableInstanceAdminClient.create()) {
    *   ClusterName name = ClusterName.of("[PROJECT]", "[INSTANCE]", "[CLUSTER]");
@@ -1543,8 +1677,11 @@ public final void deleteCluster(ClusterName name) {
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // 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/java/docs/setup#configure_endpoints_for_the_client_library
    * try (BaseBigtableInstanceAdminClient baseBigtableInstanceAdminClient =
    *     BaseBigtableInstanceAdminClient.create()) {
    *   String name = ClusterName.of("[PROJECT]", "[INSTANCE]", "[CLUSTER]").toString();
@@ -1568,8 +1705,11 @@ public final void deleteCluster(String name) {
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // 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/java/docs/setup#configure_endpoints_for_the_client_library
    * try (BaseBigtableInstanceAdminClient baseBigtableInstanceAdminClient =
    *     BaseBigtableInstanceAdminClient.create()) {
    *   DeleteClusterRequest request =
@@ -1594,8 +1734,11 @@ public final void deleteCluster(DeleteClusterRequest request) {
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // 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/java/docs/setup#configure_endpoints_for_the_client_library
    * try (BaseBigtableInstanceAdminClient baseBigtableInstanceAdminClient =
    *     BaseBigtableInstanceAdminClient.create()) {
    *   DeleteClusterRequest request =
@@ -1620,8 +1763,11 @@ public final UnaryCallable deleteClusterCallable()
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // 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/java/docs/setup#configure_endpoints_for_the_client_library
    * try (BaseBigtableInstanceAdminClient baseBigtableInstanceAdminClient =
    *     BaseBigtableInstanceAdminClient.create()) {
    *   InstanceName parent = InstanceName.of("[PROJECT]", "[INSTANCE]");
@@ -1659,8 +1805,11 @@ public final AppProfile createAppProfile(
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // 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/java/docs/setup#configure_endpoints_for_the_client_library
    * try (BaseBigtableInstanceAdminClient baseBigtableInstanceAdminClient =
    *     BaseBigtableInstanceAdminClient.create()) {
    *   String parent = InstanceName.of("[PROJECT]", "[INSTANCE]").toString();
@@ -1698,8 +1847,11 @@ public final AppProfile createAppProfile(
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // 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/java/docs/setup#configure_endpoints_for_the_client_library
    * try (BaseBigtableInstanceAdminClient baseBigtableInstanceAdminClient =
    *     BaseBigtableInstanceAdminClient.create()) {
    *   CreateAppProfileRequest request =
@@ -1727,8 +1879,11 @@ public final AppProfile createAppProfile(CreateAppProfileRequest request) {
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // 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/java/docs/setup#configure_endpoints_for_the_client_library
    * try (BaseBigtableInstanceAdminClient baseBigtableInstanceAdminClient =
    *     BaseBigtableInstanceAdminClient.create()) {
    *   CreateAppProfileRequest request =
@@ -1756,8 +1911,11 @@ public final UnaryCallable createAppProfile
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // 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/java/docs/setup#configure_endpoints_for_the_client_library
    * try (BaseBigtableInstanceAdminClient baseBigtableInstanceAdminClient =
    *     BaseBigtableInstanceAdminClient.create()) {
    *   AppProfileName name = AppProfileName.of("[PROJECT]", "[INSTANCE]", "[APP_PROFILE]");
@@ -1782,8 +1940,11 @@ public final AppProfile getAppProfile(AppProfileName name) {
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // 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/java/docs/setup#configure_endpoints_for_the_client_library
    * try (BaseBigtableInstanceAdminClient baseBigtableInstanceAdminClient =
    *     BaseBigtableInstanceAdminClient.create()) {
    *   String name = AppProfileName.of("[PROJECT]", "[INSTANCE]", "[APP_PROFILE]").toString();
@@ -1807,8 +1968,11 @@ public final AppProfile getAppProfile(String name) {
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // 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/java/docs/setup#configure_endpoints_for_the_client_library
    * try (BaseBigtableInstanceAdminClient baseBigtableInstanceAdminClient =
    *     BaseBigtableInstanceAdminClient.create()) {
    *   GetAppProfileRequest request =
@@ -1833,8 +1997,11 @@ public final AppProfile getAppProfile(GetAppProfileRequest request) {
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // 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/java/docs/setup#configure_endpoints_for_the_client_library
    * try (BaseBigtableInstanceAdminClient baseBigtableInstanceAdminClient =
    *     BaseBigtableInstanceAdminClient.create()) {
    *   GetAppProfileRequest request =
@@ -1859,8 +2026,11 @@ public final UnaryCallable getAppProfileCallab
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // 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/java/docs/setup#configure_endpoints_for_the_client_library
    * try (BaseBigtableInstanceAdminClient baseBigtableInstanceAdminClient =
    *     BaseBigtableInstanceAdminClient.create()) {
    *   InstanceName parent = InstanceName.of("[PROJECT]", "[INSTANCE]");
@@ -1892,8 +2062,11 @@ public final ListAppProfilesPagedResponse listAppProfiles(InstanceName parent) {
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // 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/java/docs/setup#configure_endpoints_for_the_client_library
    * try (BaseBigtableInstanceAdminClient baseBigtableInstanceAdminClient =
    *     BaseBigtableInstanceAdminClient.create()) {
    *   String parent = InstanceName.of("[PROJECT]", "[INSTANCE]").toString();
@@ -1922,8 +2095,11 @@ public final ListAppProfilesPagedResponse listAppProfiles(String parent) {
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // 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/java/docs/setup#configure_endpoints_for_the_client_library
    * try (BaseBigtableInstanceAdminClient baseBigtableInstanceAdminClient =
    *     BaseBigtableInstanceAdminClient.create()) {
    *   ListAppProfilesRequest request =
@@ -1953,8 +2129,11 @@ public final ListAppProfilesPagedResponse listAppProfiles(ListAppProfilesRequest
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // 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/java/docs/setup#configure_endpoints_for_the_client_library
    * try (BaseBigtableInstanceAdminClient baseBigtableInstanceAdminClient =
    *     BaseBigtableInstanceAdminClient.create()) {
    *   ListAppProfilesRequest request =
@@ -1984,8 +2163,11 @@ public final ListAppProfilesPagedResponse listAppProfiles(ListAppProfilesRequest
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // 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/java/docs/setup#configure_endpoints_for_the_client_library
    * try (BaseBigtableInstanceAdminClient baseBigtableInstanceAdminClient =
    *     BaseBigtableInstanceAdminClient.create()) {
    *   ListAppProfilesRequest request =
@@ -2022,8 +2204,11 @@ public final ListAppProfilesPagedResponse listAppProfiles(ListAppProfilesRequest
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // 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/java/docs/setup#configure_endpoints_for_the_client_library
    * try (BaseBigtableInstanceAdminClient baseBigtableInstanceAdminClient =
    *     BaseBigtableInstanceAdminClient.create()) {
    *   AppProfile appProfile = AppProfile.newBuilder().build();
@@ -2055,8 +2240,11 @@ public final OperationFuture updateAppProf
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // 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/java/docs/setup#configure_endpoints_for_the_client_library
    * try (BaseBigtableInstanceAdminClient baseBigtableInstanceAdminClient =
    *     BaseBigtableInstanceAdminClient.create()) {
    *   UpdateAppProfileRequest request =
@@ -2084,8 +2272,11 @@ public final OperationFuture updateAppProf
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // 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/java/docs/setup#configure_endpoints_for_the_client_library
    * try (BaseBigtableInstanceAdminClient baseBigtableInstanceAdminClient =
    *     BaseBigtableInstanceAdminClient.create()) {
    *   UpdateAppProfileRequest request =
@@ -2113,8 +2304,11 @@ public final OperationFuture updateAppProf
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // 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/java/docs/setup#configure_endpoints_for_the_client_library
    * try (BaseBigtableInstanceAdminClient baseBigtableInstanceAdminClient =
    *     BaseBigtableInstanceAdminClient.create()) {
    *   UpdateAppProfileRequest request =
@@ -2141,8 +2335,11 @@ public final UnaryCallable updateAppProfileC
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // 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/java/docs/setup#configure_endpoints_for_the_client_library
    * try (BaseBigtableInstanceAdminClient baseBigtableInstanceAdminClient =
    *     BaseBigtableInstanceAdminClient.create()) {
    *   AppProfileName name = AppProfileName.of("[PROJECT]", "[INSTANCE]", "[APP_PROFILE]");
@@ -2167,8 +2364,11 @@ public final void deleteAppProfile(AppProfileName name) {
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // 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/java/docs/setup#configure_endpoints_for_the_client_library
    * try (BaseBigtableInstanceAdminClient baseBigtableInstanceAdminClient =
    *     BaseBigtableInstanceAdminClient.create()) {
    *   String name = AppProfileName.of("[PROJECT]", "[INSTANCE]", "[APP_PROFILE]").toString();
@@ -2192,8 +2392,11 @@ public final void deleteAppProfile(String name) {
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // 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/java/docs/setup#configure_endpoints_for_the_client_library
    * try (BaseBigtableInstanceAdminClient baseBigtableInstanceAdminClient =
    *     BaseBigtableInstanceAdminClient.create()) {
    *   DeleteAppProfileRequest request =
@@ -2219,8 +2422,11 @@ public final void deleteAppProfile(DeleteAppProfileRequest request) {
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // 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/java/docs/setup#configure_endpoints_for_the_client_library
    * try (BaseBigtableInstanceAdminClient baseBigtableInstanceAdminClient =
    *     BaseBigtableInstanceAdminClient.create()) {
    *   DeleteAppProfileRequest request =
@@ -2247,8 +2453,11 @@ public final UnaryCallable deleteAppProfileCalla
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // 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/java/docs/setup#configure_endpoints_for_the_client_library
    * try (BaseBigtableInstanceAdminClient baseBigtableInstanceAdminClient =
    *     BaseBigtableInstanceAdminClient.create()) {
    *   ResourceName resource = InstanceName.of("[PROJECT]", "[INSTANCE]");
@@ -2276,8 +2485,11 @@ public final Policy getIamPolicy(ResourceName resource) {
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // 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/java/docs/setup#configure_endpoints_for_the_client_library
    * try (BaseBigtableInstanceAdminClient baseBigtableInstanceAdminClient =
    *     BaseBigtableInstanceAdminClient.create()) {
    *   String resource = AppProfileName.of("[PROJECT]", "[INSTANCE]", "[APP_PROFILE]").toString();
@@ -2302,8 +2514,11 @@ public final Policy getIamPolicy(String resource) {
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // 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/java/docs/setup#configure_endpoints_for_the_client_library
    * try (BaseBigtableInstanceAdminClient baseBigtableInstanceAdminClient =
    *     BaseBigtableInstanceAdminClient.create()) {
    *   GetIamPolicyRequest request =
@@ -2330,8 +2545,11 @@ public final Policy getIamPolicy(GetIamPolicyRequest request) {
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // 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/java/docs/setup#configure_endpoints_for_the_client_library
    * try (BaseBigtableInstanceAdminClient baseBigtableInstanceAdminClient =
    *     BaseBigtableInstanceAdminClient.create()) {
    *   GetIamPolicyRequest request =
@@ -2357,8 +2575,11 @@ public final UnaryCallable getIamPolicyCallable() {
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // 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/java/docs/setup#configure_endpoints_for_the_client_library
    * try (BaseBigtableInstanceAdminClient baseBigtableInstanceAdminClient =
    *     BaseBigtableInstanceAdminClient.create()) {
    *   ResourceName resource = InstanceName.of("[PROJECT]", "[INSTANCE]");
@@ -2390,8 +2611,11 @@ public final Policy setIamPolicy(ResourceName resource, Policy policy) {
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // 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/java/docs/setup#configure_endpoints_for_the_client_library
    * try (BaseBigtableInstanceAdminClient baseBigtableInstanceAdminClient =
    *     BaseBigtableInstanceAdminClient.create()) {
    *   String resource = AppProfileName.of("[PROJECT]", "[INSTANCE]", "[APP_PROFILE]").toString();
@@ -2420,8 +2644,11 @@ public final Policy setIamPolicy(String resource, Policy policy) {
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // 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/java/docs/setup#configure_endpoints_for_the_client_library
    * try (BaseBigtableInstanceAdminClient baseBigtableInstanceAdminClient =
    *     BaseBigtableInstanceAdminClient.create()) {
    *   SetIamPolicyRequest request =
@@ -2448,8 +2675,11 @@ public final Policy setIamPolicy(SetIamPolicyRequest request) {
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // 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/java/docs/setup#configure_endpoints_for_the_client_library
    * try (BaseBigtableInstanceAdminClient baseBigtableInstanceAdminClient =
    *     BaseBigtableInstanceAdminClient.create()) {
    *   SetIamPolicyRequest request =
@@ -2476,8 +2706,11 @@ public final UnaryCallable setIamPolicyCallable() {
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // 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/java/docs/setup#configure_endpoints_for_the_client_library
    * try (BaseBigtableInstanceAdminClient baseBigtableInstanceAdminClient =
    *     BaseBigtableInstanceAdminClient.create()) {
    *   ResourceName resource = InstanceName.of("[PROJECT]", "[INSTANCE]");
@@ -2511,8 +2744,11 @@ public final TestIamPermissionsResponse testIamPermissions(
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // 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/java/docs/setup#configure_endpoints_for_the_client_library
    * try (BaseBigtableInstanceAdminClient baseBigtableInstanceAdminClient =
    *     BaseBigtableInstanceAdminClient.create()) {
    *   String resource = AppProfileName.of("[PROJECT]", "[INSTANCE]", "[APP_PROFILE]").toString();
@@ -2546,8 +2782,11 @@ public final TestIamPermissionsResponse testIamPermissions(
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // 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/java/docs/setup#configure_endpoints_for_the_client_library
    * try (BaseBigtableInstanceAdminClient baseBigtableInstanceAdminClient =
    *     BaseBigtableInstanceAdminClient.create()) {
    *   TestIamPermissionsRequest request =
@@ -2574,8 +2813,11 @@ public final TestIamPermissionsResponse testIamPermissions(TestIamPermissionsReq
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // 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/java/docs/setup#configure_endpoints_for_the_client_library
    * try (BaseBigtableInstanceAdminClient baseBigtableInstanceAdminClient =
    *     BaseBigtableInstanceAdminClient.create()) {
    *   TestIamPermissionsRequest request =
@@ -2603,8 +2845,11 @@ public final TestIamPermissionsResponse testIamPermissions(TestIamPermissionsReq
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // 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/java/docs/setup#configure_endpoints_for_the_client_library
    * try (BaseBigtableInstanceAdminClient baseBigtableInstanceAdminClient =
    *     BaseBigtableInstanceAdminClient.create()) {
    *   ClusterName parent = ClusterName.of("[PROJECT]", "[INSTANCE]", "[CLUSTER]");
@@ -2635,8 +2880,11 @@ public final ListHotTabletsPagedResponse listHotTablets(ClusterName parent) {
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // 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/java/docs/setup#configure_endpoints_for_the_client_library
    * try (BaseBigtableInstanceAdminClient baseBigtableInstanceAdminClient =
    *     BaseBigtableInstanceAdminClient.create()) {
    *   String parent = ClusterName.of("[PROJECT]", "[INSTANCE]", "[CLUSTER]").toString();
@@ -2664,8 +2912,11 @@ public final ListHotTabletsPagedResponse listHotTablets(String parent) {
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // 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/java/docs/setup#configure_endpoints_for_the_client_library
    * try (BaseBigtableInstanceAdminClient baseBigtableInstanceAdminClient =
    *     BaseBigtableInstanceAdminClient.create()) {
    *   ListHotTabletsRequest request =
@@ -2698,8 +2949,11 @@ public final ListHotTabletsPagedResponse listHotTablets(ListHotTabletsRequest re
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // 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/java/docs/setup#configure_endpoints_for_the_client_library
    * try (BaseBigtableInstanceAdminClient baseBigtableInstanceAdminClient =
    *     BaseBigtableInstanceAdminClient.create()) {
    *   ListHotTabletsRequest request =
@@ -2732,8 +2986,11 @@ public final ListHotTabletsPagedResponse listHotTablets(ListHotTabletsRequest re
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // 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/java/docs/setup#configure_endpoints_for_the_client_library
    * try (BaseBigtableInstanceAdminClient baseBigtableInstanceAdminClient =
    *     BaseBigtableInstanceAdminClient.create()) {
    *   ListHotTabletsRequest request =
diff --git a/google-cloud-bigtable/src/main/java/com/google/cloud/bigtable/admin/v2/BaseBigtableTableAdminClient.java b/google-cloud-bigtable/src/main/java/com/google/cloud/bigtable/admin/v2/BaseBigtableTableAdminClient.java
index bc52bde120..fd44fb0843 100644
--- a/google-cloud-bigtable/src/main/java/com/google/cloud/bigtable/admin/v2/BaseBigtableTableAdminClient.java
+++ b/google-cloud-bigtable/src/main/java/com/google/cloud/bigtable/admin/v2/BaseBigtableTableAdminClient.java
@@ -66,6 +66,8 @@
 import com.google.bigtable.admin.v2.UndeleteTableMetadata;
 import com.google.bigtable.admin.v2.UndeleteTableRequest;
 import com.google.bigtable.admin.v2.UpdateBackupRequest;
+import com.google.bigtable.admin.v2.UpdateTableMetadata;
+import com.google.bigtable.admin.v2.UpdateTableRequest;
 import com.google.cloud.bigtable.admin.v2.stub.BigtableTableAdminStub;
 import com.google.cloud.bigtable.admin.v2.stub.BigtableTableAdminStubSettings;
 import com.google.common.util.concurrent.MoreExecutors;
@@ -156,8 +158,11 @@ public final OperationsClient getOperationsClient() {
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // 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/java/docs/setup#configure_endpoints_for_the_client_library
    * try (BaseBigtableTableAdminClient baseBigtableTableAdminClient =
    *     BaseBigtableTableAdminClient.create()) {
    *   InstanceName parent = InstanceName.of("[PROJECT]", "[INSTANCE]");
@@ -193,8 +198,11 @@ public final Table createTable(InstanceName parent, String tableId, Table table)
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // 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/java/docs/setup#configure_endpoints_for_the_client_library
    * try (BaseBigtableTableAdminClient baseBigtableTableAdminClient =
    *     BaseBigtableTableAdminClient.create()) {
    *   String parent = InstanceName.of("[PROJECT]", "[INSTANCE]").toString();
@@ -230,8 +238,11 @@ public final Table createTable(String parent, String tableId, Table table) {
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // 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/java/docs/setup#configure_endpoints_for_the_client_library
    * try (BaseBigtableTableAdminClient baseBigtableTableAdminClient =
    *     BaseBigtableTableAdminClient.create()) {
    *   CreateTableRequest request =
@@ -260,8 +271,11 @@ public final Table createTable(CreateTableRequest request) {
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // 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/java/docs/setup#configure_endpoints_for_the_client_library
    * try (BaseBigtableTableAdminClient baseBigtableTableAdminClient =
    *     BaseBigtableTableAdminClient.create()) {
    *   CreateTableRequest request =
@@ -295,8 +309,11 @@ public final UnaryCallable createTableCallable() {
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // 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/java/docs/setup#configure_endpoints_for_the_client_library
    * try (BaseBigtableTableAdminClient baseBigtableTableAdminClient =
    *     BaseBigtableTableAdminClient.create()) {
    *   InstanceName parent = InstanceName.of("[PROJECT]", "[INSTANCE]");
@@ -343,8 +360,11 @@ public final OperationFuture createTable
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // 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/java/docs/setup#configure_endpoints_for_the_client_library
    * try (BaseBigtableTableAdminClient baseBigtableTableAdminClient =
    *     BaseBigtableTableAdminClient.create()) {
    *   InstanceName parent = InstanceName.of("[PROJECT]", "[INSTANCE]");
@@ -391,8 +411,11 @@ public final OperationFuture createTable
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // 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/java/docs/setup#configure_endpoints_for_the_client_library
    * try (BaseBigtableTableAdminClient baseBigtableTableAdminClient =
    *     BaseBigtableTableAdminClient.create()) {
    *   String parent = InstanceName.of("[PROJECT]", "[INSTANCE]").toString();
@@ -439,8 +462,11 @@ public final OperationFuture createTable
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // 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/java/docs/setup#configure_endpoints_for_the_client_library
    * try (BaseBigtableTableAdminClient baseBigtableTableAdminClient =
    *     BaseBigtableTableAdminClient.create()) {
    *   String parent = InstanceName.of("[PROJECT]", "[INSTANCE]").toString();
@@ -487,8 +513,11 @@ public final OperationFuture createTable
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // 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/java/docs/setup#configure_endpoints_for_the_client_library
    * try (BaseBigtableTableAdminClient baseBigtableTableAdminClient =
    *     BaseBigtableTableAdminClient.create()) {
    *   CreateTableFromSnapshotRequest request =
@@ -523,8 +552,11 @@ public final OperationFuture createTable
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // 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/java/docs/setup#configure_endpoints_for_the_client_library
    * try (BaseBigtableTableAdminClient baseBigtableTableAdminClient =
    *     BaseBigtableTableAdminClient.create()) {
    *   CreateTableFromSnapshotRequest request =
@@ -562,8 +594,11 @@ public final OperationFuture createTable
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // 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/java/docs/setup#configure_endpoints_for_the_client_library
    * try (BaseBigtableTableAdminClient baseBigtableTableAdminClient =
    *     BaseBigtableTableAdminClient.create()) {
    *   CreateTableFromSnapshotRequest request =
@@ -592,8 +627,11 @@ public final OperationFuture createTable
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // 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/java/docs/setup#configure_endpoints_for_the_client_library
    * try (BaseBigtableTableAdminClient baseBigtableTableAdminClient =
    *     BaseBigtableTableAdminClient.create()) {
    *   InstanceName parent = InstanceName.of("[PROJECT]", "[INSTANCE]");
@@ -620,8 +658,11 @@ public final ListTablesPagedResponse listTables(InstanceName parent) {
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // 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/java/docs/setup#configure_endpoints_for_the_client_library
    * try (BaseBigtableTableAdminClient baseBigtableTableAdminClient =
    *     BaseBigtableTableAdminClient.create()) {
    *   String parent = InstanceName.of("[PROJECT]", "[INSTANCE]").toString();
@@ -647,8 +688,11 @@ public final ListTablesPagedResponse listTables(String parent) {
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // 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/java/docs/setup#configure_endpoints_for_the_client_library
    * try (BaseBigtableTableAdminClient baseBigtableTableAdminClient =
    *     BaseBigtableTableAdminClient.create()) {
    *   ListTablesRequest request =
@@ -677,8 +721,11 @@ public final ListTablesPagedResponse listTables(ListTablesRequest request) {
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // 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/java/docs/setup#configure_endpoints_for_the_client_library
    * try (BaseBigtableTableAdminClient baseBigtableTableAdminClient =
    *     BaseBigtableTableAdminClient.create()) {
    *   ListTablesRequest request =
@@ -707,8 +754,11 @@ public final UnaryCallable listTable
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // 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/java/docs/setup#configure_endpoints_for_the_client_library
    * try (BaseBigtableTableAdminClient baseBigtableTableAdminClient =
    *     BaseBigtableTableAdminClient.create()) {
    *   ListTablesRequest request =
@@ -744,8 +794,11 @@ public final UnaryCallable listTablesCall
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // 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/java/docs/setup#configure_endpoints_for_the_client_library
    * try (BaseBigtableTableAdminClient baseBigtableTableAdminClient =
    *     BaseBigtableTableAdminClient.create()) {
    *   TableName name = TableName.of("[PROJECT]", "[INSTANCE]", "[TABLE]");
@@ -770,8 +823,11 @@ public final Table getTable(TableName name) {
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // 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/java/docs/setup#configure_endpoints_for_the_client_library
    * try (BaseBigtableTableAdminClient baseBigtableTableAdminClient =
    *     BaseBigtableTableAdminClient.create()) {
    *   String name = TableName.of("[PROJECT]", "[INSTANCE]", "[TABLE]").toString();
@@ -795,8 +851,11 @@ public final Table getTable(String name) {
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // 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/java/docs/setup#configure_endpoints_for_the_client_library
    * try (BaseBigtableTableAdminClient baseBigtableTableAdminClient =
    *     BaseBigtableTableAdminClient.create()) {
    *   GetTableRequest request =
@@ -821,8 +880,11 @@ public final Table getTable(GetTableRequest request) {
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // 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/java/docs/setup#configure_endpoints_for_the_client_library
    * try (BaseBigtableTableAdminClient baseBigtableTableAdminClient =
    *     BaseBigtableTableAdminClient.create()) {
    *   GetTableRequest request =
@@ -839,6 +901,135 @@ public final UnaryCallable getTableCallable() {
     return stub.getTableCallable();
   }
 
+  // AUTO-GENERATED DOCUMENTATION AND METHOD.
+  /**
+   * Updates a specified table.
+   *
+   * 

Sample code: + * + *

{@code
+   * // 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/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (BaseBigtableTableAdminClient baseBigtableTableAdminClient =
+   *     BaseBigtableTableAdminClient.create()) {
+   *   Table table = Table.newBuilder().build();
+   *   FieldMask updateMask = FieldMask.newBuilder().build();
+   *   Table response = baseBigtableTableAdminClient.updateTableAsync(table, updateMask).get();
+   * }
+   * }
+ * + * @param table Required. The table to update. The table's `name` field is used to identify the + * table to update. + * @param updateMask Required. The list of fields to update. A mask specifying which fields (e.g. + * `deletion_protection`) in the `table` field should be updated. This mask is relative to the + * `table` field, not to the request message. The wildcard (*) path is currently not + * supported. Currently UpdateTable is only supported for the following field: * + * `deletion_protection` If `column_families` is set in `update_mask`, it will return an + * UNIMPLEMENTED error. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final OperationFuture updateTableAsync( + Table table, FieldMask updateMask) { + UpdateTableRequest request = + UpdateTableRequest.newBuilder().setTable(table).setUpdateMask(updateMask).build(); + return updateTableAsync(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Updates a specified table. + * + *

Sample code: + * + *

{@code
+   * // 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/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (BaseBigtableTableAdminClient baseBigtableTableAdminClient =
+   *     BaseBigtableTableAdminClient.create()) {
+   *   UpdateTableRequest request =
+   *       UpdateTableRequest.newBuilder()
+   *           .setTable(Table.newBuilder().build())
+   *           .setUpdateMask(FieldMask.newBuilder().build())
+   *           .build();
+   *   Table response = baseBigtableTableAdminClient.updateTableAsync(request).get();
+   * }
+   * }
+ * + * @param request The request object containing all of the parameters for the API call. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final OperationFuture updateTableAsync( + UpdateTableRequest request) { + return updateTableOperationCallable().futureCall(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Updates a specified table. + * + *

Sample code: + * + *

{@code
+   * // 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/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (BaseBigtableTableAdminClient baseBigtableTableAdminClient =
+   *     BaseBigtableTableAdminClient.create()) {
+   *   UpdateTableRequest request =
+   *       UpdateTableRequest.newBuilder()
+   *           .setTable(Table.newBuilder().build())
+   *           .setUpdateMask(FieldMask.newBuilder().build())
+   *           .build();
+   *   OperationFuture future =
+   *       baseBigtableTableAdminClient.updateTableOperationCallable().futureCall(request);
+   *   // Do something.
+   *   Table response = future.get();
+   * }
+   * }
+ */ + public final OperationCallable + updateTableOperationCallable() { + return stub.updateTableOperationCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Updates a specified table. + * + *

Sample code: + * + *

{@code
+   * // 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/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (BaseBigtableTableAdminClient baseBigtableTableAdminClient =
+   *     BaseBigtableTableAdminClient.create()) {
+   *   UpdateTableRequest request =
+   *       UpdateTableRequest.newBuilder()
+   *           .setTable(Table.newBuilder().build())
+   *           .setUpdateMask(FieldMask.newBuilder().build())
+   *           .build();
+   *   ApiFuture future =
+   *       baseBigtableTableAdminClient.updateTableCallable().futureCall(request);
+   *   // Do something.
+   *   Operation response = future.get();
+   * }
+   * }
+ */ + public final UnaryCallable updateTableCallable() { + return stub.updateTableCallable(); + } + // AUTO-GENERATED DOCUMENTATION AND METHOD. /** * Permanently deletes a specified table and all of its data. @@ -846,8 +1037,11 @@ public final UnaryCallable getTableCallable() { *

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // 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/java/docs/setup#configure_endpoints_for_the_client_library
    * try (BaseBigtableTableAdminClient baseBigtableTableAdminClient =
    *     BaseBigtableTableAdminClient.create()) {
    *   TableName name = TableName.of("[PROJECT]", "[INSTANCE]", "[TABLE]");
@@ -872,8 +1066,11 @@ public final void deleteTable(TableName name) {
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // 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/java/docs/setup#configure_endpoints_for_the_client_library
    * try (BaseBigtableTableAdminClient baseBigtableTableAdminClient =
    *     BaseBigtableTableAdminClient.create()) {
    *   String name = TableName.of("[PROJECT]", "[INSTANCE]", "[TABLE]").toString();
@@ -897,8 +1094,11 @@ public final void deleteTable(String name) {
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // 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/java/docs/setup#configure_endpoints_for_the_client_library
    * try (BaseBigtableTableAdminClient baseBigtableTableAdminClient =
    *     BaseBigtableTableAdminClient.create()) {
    *   DeleteTableRequest request =
@@ -923,8 +1123,11 @@ public final void deleteTable(DeleteTableRequest request) {
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // 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/java/docs/setup#configure_endpoints_for_the_client_library
    * try (BaseBigtableTableAdminClient baseBigtableTableAdminClient =
    *     BaseBigtableTableAdminClient.create()) {
    *   DeleteTableRequest request =
@@ -949,8 +1152,11 @@ public final UnaryCallable deleteTableCallable() {
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // 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/java/docs/setup#configure_endpoints_for_the_client_library
    * try (BaseBigtableTableAdminClient baseBigtableTableAdminClient =
    *     BaseBigtableTableAdminClient.create()) {
    *   TableName name = TableName.of("[PROJECT]", "[INSTANCE]", "[TABLE]");
@@ -975,8 +1181,11 @@ public final OperationFuture undeleteTableAsync(Ta
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // 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/java/docs/setup#configure_endpoints_for_the_client_library
    * try (BaseBigtableTableAdminClient baseBigtableTableAdminClient =
    *     BaseBigtableTableAdminClient.create()) {
    *   String name = TableName.of("[PROJECT]", "[INSTANCE]", "[TABLE]").toString();
@@ -1000,8 +1209,11 @@ public final OperationFuture undeleteTableAsync(St
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // 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/java/docs/setup#configure_endpoints_for_the_client_library
    * try (BaseBigtableTableAdminClient baseBigtableTableAdminClient =
    *     BaseBigtableTableAdminClient.create()) {
    *   UndeleteTableRequest request =
@@ -1027,8 +1239,11 @@ public final OperationFuture undeleteTableAsync(
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // 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/java/docs/setup#configure_endpoints_for_the_client_library
    * try (BaseBigtableTableAdminClient baseBigtableTableAdminClient =
    *     BaseBigtableTableAdminClient.create()) {
    *   UndeleteTableRequest request =
@@ -1054,8 +1269,11 @@ public final OperationFuture undeleteTableAsync(
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // 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/java/docs/setup#configure_endpoints_for_the_client_library
    * try (BaseBigtableTableAdminClient baseBigtableTableAdminClient =
    *     BaseBigtableTableAdminClient.create()) {
    *   UndeleteTableRequest request =
@@ -1082,8 +1300,11 @@ public final UnaryCallable undeleteTableCallabl
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // 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/java/docs/setup#configure_endpoints_for_the_client_library
    * try (BaseBigtableTableAdminClient baseBigtableTableAdminClient =
    *     BaseBigtableTableAdminClient.create()) {
    *   TableName name = TableName.of("[PROJECT]", "[INSTANCE]", "[TABLE]");
@@ -1118,8 +1339,11 @@ public final Table modifyColumnFamilies(
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // 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/java/docs/setup#configure_endpoints_for_the_client_library
    * try (BaseBigtableTableAdminClient baseBigtableTableAdminClient =
    *     BaseBigtableTableAdminClient.create()) {
    *   String name = TableName.of("[PROJECT]", "[INSTANCE]", "[TABLE]").toString();
@@ -1154,8 +1378,11 @@ public final Table modifyColumnFamilies(
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // 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/java/docs/setup#configure_endpoints_for_the_client_library
    * try (BaseBigtableTableAdminClient baseBigtableTableAdminClient =
    *     BaseBigtableTableAdminClient.create()) {
    *   ModifyColumnFamiliesRequest request =
@@ -1183,8 +1410,11 @@ public final Table modifyColumnFamilies(ModifyColumnFamiliesRequest request) {
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // 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/java/docs/setup#configure_endpoints_for_the_client_library
    * try (BaseBigtableTableAdminClient baseBigtableTableAdminClient =
    *     BaseBigtableTableAdminClient.create()) {
    *   ModifyColumnFamiliesRequest request =
@@ -1211,8 +1441,11 @@ public final UnaryCallable modifyColumnFamil
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // 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/java/docs/setup#configure_endpoints_for_the_client_library
    * try (BaseBigtableTableAdminClient baseBigtableTableAdminClient =
    *     BaseBigtableTableAdminClient.create()) {
    *   DropRowRangeRequest request =
@@ -1238,8 +1471,11 @@ public final void dropRowRange(DropRowRangeRequest request) {
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // 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/java/docs/setup#configure_endpoints_for_the_client_library
    * try (BaseBigtableTableAdminClient baseBigtableTableAdminClient =
    *     BaseBigtableTableAdminClient.create()) {
    *   DropRowRangeRequest request =
@@ -1266,8 +1502,11 @@ public final UnaryCallable dropRowRangeCallable() {
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // 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/java/docs/setup#configure_endpoints_for_the_client_library
    * try (BaseBigtableTableAdminClient baseBigtableTableAdminClient =
    *     BaseBigtableTableAdminClient.create()) {
    *   TableName name = TableName.of("[PROJECT]", "[INSTANCE]", "[TABLE]");
@@ -1297,8 +1536,11 @@ public final GenerateConsistencyTokenResponse generateConsistencyToken(TableName
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // 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/java/docs/setup#configure_endpoints_for_the_client_library
    * try (BaseBigtableTableAdminClient baseBigtableTableAdminClient =
    *     BaseBigtableTableAdminClient.create()) {
    *   String name = TableName.of("[PROJECT]", "[INSTANCE]", "[TABLE]").toString();
@@ -1326,8 +1568,11 @@ public final GenerateConsistencyTokenResponse generateConsistencyToken(String na
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // 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/java/docs/setup#configure_endpoints_for_the_client_library
    * try (BaseBigtableTableAdminClient baseBigtableTableAdminClient =
    *     BaseBigtableTableAdminClient.create()) {
    *   GenerateConsistencyTokenRequest request =
@@ -1356,8 +1601,11 @@ public final GenerateConsistencyTokenResponse generateConsistencyToken(
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // 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/java/docs/setup#configure_endpoints_for_the_client_library
    * try (BaseBigtableTableAdminClient baseBigtableTableAdminClient =
    *     BaseBigtableTableAdminClient.create()) {
    *   GenerateConsistencyTokenRequest request =
@@ -1384,8 +1632,11 @@ public final GenerateConsistencyTokenResponse generateConsistencyToken(
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // 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/java/docs/setup#configure_endpoints_for_the_client_library
    * try (BaseBigtableTableAdminClient baseBigtableTableAdminClient =
    *     BaseBigtableTableAdminClient.create()) {
    *   TableName name = TableName.of("[PROJECT]", "[INSTANCE]", "[TABLE]");
@@ -1418,8 +1669,11 @@ public final CheckConsistencyResponse checkConsistency(TableName name, String co
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // 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/java/docs/setup#configure_endpoints_for_the_client_library
    * try (BaseBigtableTableAdminClient baseBigtableTableAdminClient =
    *     BaseBigtableTableAdminClient.create()) {
    *   String name = TableName.of("[PROJECT]", "[INSTANCE]", "[TABLE]").toString();
@@ -1452,8 +1706,11 @@ public final CheckConsistencyResponse checkConsistency(String name, String consi
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // 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/java/docs/setup#configure_endpoints_for_the_client_library
    * try (BaseBigtableTableAdminClient baseBigtableTableAdminClient =
    *     BaseBigtableTableAdminClient.create()) {
    *   CheckConsistencyRequest request =
@@ -1480,8 +1737,11 @@ public final CheckConsistencyResponse checkConsistency(CheckConsistencyRequest r
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // 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/java/docs/setup#configure_endpoints_for_the_client_library
    * try (BaseBigtableTableAdminClient baseBigtableTableAdminClient =
    *     BaseBigtableTableAdminClient.create()) {
    *   CheckConsistencyRequest request =
@@ -1514,8 +1774,11 @@ public final CheckConsistencyResponse checkConsistency(CheckConsistencyRequest r
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // 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/java/docs/setup#configure_endpoints_for_the_client_library
    * try (BaseBigtableTableAdminClient baseBigtableTableAdminClient =
    *     BaseBigtableTableAdminClient.create()) {
    *   TableName name = TableName.of("[PROJECT]", "[INSTANCE]", "[TABLE]");
@@ -1564,8 +1827,11 @@ public final OperationFuture snapshotTableAsync
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // 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/java/docs/setup#configure_endpoints_for_the_client_library
    * try (BaseBigtableTableAdminClient baseBigtableTableAdminClient =
    *     BaseBigtableTableAdminClient.create()) {
    *   TableName name = TableName.of("[PROJECT]", "[INSTANCE]", "[TABLE]");
@@ -1614,8 +1880,11 @@ public final OperationFuture snapshotTableAsync
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // 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/java/docs/setup#configure_endpoints_for_the_client_library
    * try (BaseBigtableTableAdminClient baseBigtableTableAdminClient =
    *     BaseBigtableTableAdminClient.create()) {
    *   String name = TableName.of("[PROJECT]", "[INSTANCE]", "[TABLE]").toString();
@@ -1664,8 +1933,11 @@ public final OperationFuture snapshotTableAsync
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // 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/java/docs/setup#configure_endpoints_for_the_client_library
    * try (BaseBigtableTableAdminClient baseBigtableTableAdminClient =
    *     BaseBigtableTableAdminClient.create()) {
    *   String name = TableName.of("[PROJECT]", "[INSTANCE]", "[TABLE]").toString();
@@ -1714,8 +1986,11 @@ public final OperationFuture snapshotTableAsync
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // 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/java/docs/setup#configure_endpoints_for_the_client_library
    * try (BaseBigtableTableAdminClient baseBigtableTableAdminClient =
    *     BaseBigtableTableAdminClient.create()) {
    *   SnapshotTableRequest request =
@@ -1751,8 +2026,11 @@ public final OperationFuture snapshotTableAsync
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // 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/java/docs/setup#configure_endpoints_for_the_client_library
    * try (BaseBigtableTableAdminClient baseBigtableTableAdminClient =
    *     BaseBigtableTableAdminClient.create()) {
    *   SnapshotTableRequest request =
@@ -1788,8 +2066,11 @@ public final OperationFuture snapshotTableAsync
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // 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/java/docs/setup#configure_endpoints_for_the_client_library
    * try (BaseBigtableTableAdminClient baseBigtableTableAdminClient =
    *     BaseBigtableTableAdminClient.create()) {
    *   SnapshotTableRequest request =
@@ -1823,8 +2104,11 @@ public final UnaryCallable snapshotTableCallabl
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // 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/java/docs/setup#configure_endpoints_for_the_client_library
    * try (BaseBigtableTableAdminClient baseBigtableTableAdminClient =
    *     BaseBigtableTableAdminClient.create()) {
    *   SnapshotName name = SnapshotName.of("[PROJECT]", "[INSTANCE]", "[CLUSTER]", "[SNAPSHOT]");
@@ -1854,8 +2138,11 @@ public final Snapshot getSnapshot(SnapshotName name) {
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // 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/java/docs/setup#configure_endpoints_for_the_client_library
    * try (BaseBigtableTableAdminClient baseBigtableTableAdminClient =
    *     BaseBigtableTableAdminClient.create()) {
    *   String name =
@@ -1885,8 +2172,11 @@ public final Snapshot getSnapshot(String name) {
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // 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/java/docs/setup#configure_endpoints_for_the_client_library
    * try (BaseBigtableTableAdminClient baseBigtableTableAdminClient =
    *     BaseBigtableTableAdminClient.create()) {
    *   GetSnapshotRequest request =
@@ -1917,8 +2207,11 @@ public final Snapshot getSnapshot(GetSnapshotRequest request) {
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // 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/java/docs/setup#configure_endpoints_for_the_client_library
    * try (BaseBigtableTableAdminClient baseBigtableTableAdminClient =
    *     BaseBigtableTableAdminClient.create()) {
    *   GetSnapshotRequest request =
@@ -1949,8 +2242,11 @@ public final UnaryCallable getSnapshotCallable() {
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // 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/java/docs/setup#configure_endpoints_for_the_client_library
    * try (BaseBigtableTableAdminClient baseBigtableTableAdminClient =
    *     BaseBigtableTableAdminClient.create()) {
    *   ClusterName parent = ClusterName.of("[PROJECT]", "[INSTANCE]", "[CLUSTER]");
@@ -1986,8 +2282,11 @@ public final ListSnapshotsPagedResponse listSnapshots(ClusterName parent) {
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // 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/java/docs/setup#configure_endpoints_for_the_client_library
    * try (BaseBigtableTableAdminClient baseBigtableTableAdminClient =
    *     BaseBigtableTableAdminClient.create()) {
    *   String parent = ClusterName.of("[PROJECT]", "[INSTANCE]", "[CLUSTER]").toString();
@@ -2020,8 +2319,11 @@ public final ListSnapshotsPagedResponse listSnapshots(String parent) {
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // 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/java/docs/setup#configure_endpoints_for_the_client_library
    * try (BaseBigtableTableAdminClient baseBigtableTableAdminClient =
    *     BaseBigtableTableAdminClient.create()) {
    *   ListSnapshotsRequest request =
@@ -2055,8 +2357,11 @@ public final ListSnapshotsPagedResponse listSnapshots(ListSnapshotsRequest reque
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // 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/java/docs/setup#configure_endpoints_for_the_client_library
    * try (BaseBigtableTableAdminClient baseBigtableTableAdminClient =
    *     BaseBigtableTableAdminClient.create()) {
    *   ListSnapshotsRequest request =
@@ -2091,8 +2396,11 @@ public final ListSnapshotsPagedResponse listSnapshots(ListSnapshotsRequest reque
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // 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/java/docs/setup#configure_endpoints_for_the_client_library
    * try (BaseBigtableTableAdminClient baseBigtableTableAdminClient =
    *     BaseBigtableTableAdminClient.create()) {
    *   ListSnapshotsRequest request =
@@ -2133,8 +2441,11 @@ public final UnaryCallable listSnap
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // 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/java/docs/setup#configure_endpoints_for_the_client_library
    * try (BaseBigtableTableAdminClient baseBigtableTableAdminClient =
    *     BaseBigtableTableAdminClient.create()) {
    *   SnapshotName name = SnapshotName.of("[PROJECT]", "[INSTANCE]", "[CLUSTER]", "[SNAPSHOT]");
@@ -2164,8 +2475,11 @@ public final void deleteSnapshot(SnapshotName name) {
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // 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/java/docs/setup#configure_endpoints_for_the_client_library
    * try (BaseBigtableTableAdminClient baseBigtableTableAdminClient =
    *     BaseBigtableTableAdminClient.create()) {
    *   String name =
@@ -2195,8 +2509,11 @@ public final void deleteSnapshot(String name) {
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // 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/java/docs/setup#configure_endpoints_for_the_client_library
    * try (BaseBigtableTableAdminClient baseBigtableTableAdminClient =
    *     BaseBigtableTableAdminClient.create()) {
    *   DeleteSnapshotRequest request =
@@ -2227,8 +2544,11 @@ public final void deleteSnapshot(DeleteSnapshotRequest request) {
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // 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/java/docs/setup#configure_endpoints_for_the_client_library
    * try (BaseBigtableTableAdminClient baseBigtableTableAdminClient =
    *     BaseBigtableTableAdminClient.create()) {
    *   DeleteSnapshotRequest request =
@@ -2260,8 +2580,11 @@ public final UnaryCallable deleteSnapshotCallable(
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // 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/java/docs/setup#configure_endpoints_for_the_client_library
    * try (BaseBigtableTableAdminClient baseBigtableTableAdminClient =
    *     BaseBigtableTableAdminClient.create()) {
    *   ClusterName parent = ClusterName.of("[PROJECT]", "[INSTANCE]", "[CLUSTER]");
@@ -2308,8 +2631,11 @@ public final OperationFuture createBackupAsync(
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // 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/java/docs/setup#configure_endpoints_for_the_client_library
    * try (BaseBigtableTableAdminClient baseBigtableTableAdminClient =
    *     BaseBigtableTableAdminClient.create()) {
    *   String parent = ClusterName.of("[PROJECT]", "[INSTANCE]", "[CLUSTER]").toString();
@@ -2356,8 +2682,11 @@ public final OperationFuture createBackupAsync(
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // 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/java/docs/setup#configure_endpoints_for_the_client_library
    * try (BaseBigtableTableAdminClient baseBigtableTableAdminClient =
    *     BaseBigtableTableAdminClient.create()) {
    *   CreateBackupRequest request =
@@ -2391,8 +2720,11 @@ public final OperationFuture createBackupAsync(
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // 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/java/docs/setup#configure_endpoints_for_the_client_library
    * try (BaseBigtableTableAdminClient baseBigtableTableAdminClient =
    *     BaseBigtableTableAdminClient.create()) {
    *   CreateBackupRequest request =
@@ -2426,8 +2758,11 @@ public final OperationFuture createBackupAsync(
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // 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/java/docs/setup#configure_endpoints_for_the_client_library
    * try (BaseBigtableTableAdminClient baseBigtableTableAdminClient =
    *     BaseBigtableTableAdminClient.create()) {
    *   CreateBackupRequest request =
@@ -2454,8 +2789,11 @@ public final UnaryCallable createBackupCallable(
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // 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/java/docs/setup#configure_endpoints_for_the_client_library
    * try (BaseBigtableTableAdminClient baseBigtableTableAdminClient =
    *     BaseBigtableTableAdminClient.create()) {
    *   BackupName name = BackupName.of("[PROJECT]", "[INSTANCE]", "[CLUSTER]", "[BACKUP]");
@@ -2480,8 +2818,11 @@ public final Backup getBackup(BackupName name) {
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // 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/java/docs/setup#configure_endpoints_for_the_client_library
    * try (BaseBigtableTableAdminClient baseBigtableTableAdminClient =
    *     BaseBigtableTableAdminClient.create()) {
    *   String name = BackupName.of("[PROJECT]", "[INSTANCE]", "[CLUSTER]", "[BACKUP]").toString();
@@ -2505,8 +2846,11 @@ public final Backup getBackup(String name) {
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // 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/java/docs/setup#configure_endpoints_for_the_client_library
    * try (BaseBigtableTableAdminClient baseBigtableTableAdminClient =
    *     BaseBigtableTableAdminClient.create()) {
    *   GetBackupRequest request =
@@ -2531,8 +2875,11 @@ public final Backup getBackup(GetBackupRequest request) {
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // 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/java/docs/setup#configure_endpoints_for_the_client_library
    * try (BaseBigtableTableAdminClient baseBigtableTableAdminClient =
    *     BaseBigtableTableAdminClient.create()) {
    *   GetBackupRequest request =
@@ -2557,8 +2904,11 @@ public final UnaryCallable getBackupCallable() {
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // 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/java/docs/setup#configure_endpoints_for_the_client_library
    * try (BaseBigtableTableAdminClient baseBigtableTableAdminClient =
    *     BaseBigtableTableAdminClient.create()) {
    *   Backup backup = Backup.newBuilder().build();
@@ -2589,8 +2939,11 @@ public final Backup updateBackup(Backup backup, FieldMask updateMask) {
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // 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/java/docs/setup#configure_endpoints_for_the_client_library
    * try (BaseBigtableTableAdminClient baseBigtableTableAdminClient =
    *     BaseBigtableTableAdminClient.create()) {
    *   UpdateBackupRequest request =
@@ -2616,8 +2969,11 @@ public final Backup updateBackup(UpdateBackupRequest request) {
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // 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/java/docs/setup#configure_endpoints_for_the_client_library
    * try (BaseBigtableTableAdminClient baseBigtableTableAdminClient =
    *     BaseBigtableTableAdminClient.create()) {
    *   UpdateBackupRequest request =
@@ -2643,8 +2999,11 @@ public final UnaryCallable updateBackupCallable() {
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // 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/java/docs/setup#configure_endpoints_for_the_client_library
    * try (BaseBigtableTableAdminClient baseBigtableTableAdminClient =
    *     BaseBigtableTableAdminClient.create()) {
    *   BackupName name = BackupName.of("[PROJECT]", "[INSTANCE]", "[CLUSTER]", "[BACKUP]");
@@ -2669,8 +3028,11 @@ public final void deleteBackup(BackupName name) {
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // 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/java/docs/setup#configure_endpoints_for_the_client_library
    * try (BaseBigtableTableAdminClient baseBigtableTableAdminClient =
    *     BaseBigtableTableAdminClient.create()) {
    *   String name = BackupName.of("[PROJECT]", "[INSTANCE]", "[CLUSTER]", "[BACKUP]").toString();
@@ -2694,8 +3056,11 @@ public final void deleteBackup(String name) {
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // 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/java/docs/setup#configure_endpoints_for_the_client_library
    * try (BaseBigtableTableAdminClient baseBigtableTableAdminClient =
    *     BaseBigtableTableAdminClient.create()) {
    *   DeleteBackupRequest request =
@@ -2720,8 +3085,11 @@ public final void deleteBackup(DeleteBackupRequest request) {
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // 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/java/docs/setup#configure_endpoints_for_the_client_library
    * try (BaseBigtableTableAdminClient baseBigtableTableAdminClient =
    *     BaseBigtableTableAdminClient.create()) {
    *   DeleteBackupRequest request =
@@ -2746,8 +3114,11 @@ public final UnaryCallable deleteBackupCallable() {
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // 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/java/docs/setup#configure_endpoints_for_the_client_library
    * try (BaseBigtableTableAdminClient baseBigtableTableAdminClient =
    *     BaseBigtableTableAdminClient.create()) {
    *   ClusterName parent = ClusterName.of("[PROJECT]", "[INSTANCE]", "[CLUSTER]");
@@ -2778,8 +3149,11 @@ public final ListBackupsPagedResponse listBackups(ClusterName parent) {
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // 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/java/docs/setup#configure_endpoints_for_the_client_library
    * try (BaseBigtableTableAdminClient baseBigtableTableAdminClient =
    *     BaseBigtableTableAdminClient.create()) {
    *   String parent = ClusterName.of("[PROJECT]", "[INSTANCE]", "[CLUSTER]").toString();
@@ -2807,8 +3181,11 @@ public final ListBackupsPagedResponse listBackups(String parent) {
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // 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/java/docs/setup#configure_endpoints_for_the_client_library
    * try (BaseBigtableTableAdminClient baseBigtableTableAdminClient =
    *     BaseBigtableTableAdminClient.create()) {
    *   ListBackupsRequest request =
@@ -2839,8 +3216,11 @@ public final ListBackupsPagedResponse listBackups(ListBackupsRequest request) {
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // 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/java/docs/setup#configure_endpoints_for_the_client_library
    * try (BaseBigtableTableAdminClient baseBigtableTableAdminClient =
    *     BaseBigtableTableAdminClient.create()) {
    *   ListBackupsRequest request =
@@ -2872,8 +3252,11 @@ public final ListBackupsPagedResponse listBackups(ListBackupsRequest request) {
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // 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/java/docs/setup#configure_endpoints_for_the_client_library
    * try (BaseBigtableTableAdminClient baseBigtableTableAdminClient =
    *     BaseBigtableTableAdminClient.create()) {
    *   ListBackupsRequest request =
@@ -2917,8 +3300,11 @@ public final UnaryCallable listBackupsC
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // 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/java/docs/setup#configure_endpoints_for_the_client_library
    * try (BaseBigtableTableAdminClient baseBigtableTableAdminClient =
    *     BaseBigtableTableAdminClient.create()) {
    *   RestoreTableRequest request =
@@ -2951,8 +3337,11 @@ public final OperationFuture restoreTableAsync(
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // 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/java/docs/setup#configure_endpoints_for_the_client_library
    * try (BaseBigtableTableAdminClient baseBigtableTableAdminClient =
    *     BaseBigtableTableAdminClient.create()) {
    *   RestoreTableRequest request =
@@ -2985,8 +3374,11 @@ public final OperationFuture restoreTableAsync(
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // 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/java/docs/setup#configure_endpoints_for_the_client_library
    * try (BaseBigtableTableAdminClient baseBigtableTableAdminClient =
    *     BaseBigtableTableAdminClient.create()) {
    *   RestoreTableRequest request =
@@ -3013,8 +3405,11 @@ public final UnaryCallable restoreTableCallable(
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // 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/java/docs/setup#configure_endpoints_for_the_client_library
    * try (BaseBigtableTableAdminClient baseBigtableTableAdminClient =
    *     BaseBigtableTableAdminClient.create()) {
    *   ResourceName resource = BackupName.of("[PROJECT]", "[INSTANCE]", "[CLUSTER]", "[BACKUP]");
@@ -3042,8 +3437,11 @@ public final Policy getIamPolicy(ResourceName resource) {
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // 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/java/docs/setup#configure_endpoints_for_the_client_library
    * try (BaseBigtableTableAdminClient baseBigtableTableAdminClient =
    *     BaseBigtableTableAdminClient.create()) {
    *   String resource = AppProfileName.of("[PROJECT]", "[INSTANCE]", "[APP_PROFILE]").toString();
@@ -3068,8 +3466,11 @@ public final Policy getIamPolicy(String resource) {
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // 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/java/docs/setup#configure_endpoints_for_the_client_library
    * try (BaseBigtableTableAdminClient baseBigtableTableAdminClient =
    *     BaseBigtableTableAdminClient.create()) {
    *   GetIamPolicyRequest request =
@@ -3097,8 +3498,11 @@ public final Policy getIamPolicy(GetIamPolicyRequest request) {
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // 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/java/docs/setup#configure_endpoints_for_the_client_library
    * try (BaseBigtableTableAdminClient baseBigtableTableAdminClient =
    *     BaseBigtableTableAdminClient.create()) {
    *   GetIamPolicyRequest request =
@@ -3125,8 +3529,11 @@ public final UnaryCallable getIamPolicyCallable() {
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // 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/java/docs/setup#configure_endpoints_for_the_client_library
    * try (BaseBigtableTableAdminClient baseBigtableTableAdminClient =
    *     BaseBigtableTableAdminClient.create()) {
    *   ResourceName resource = BackupName.of("[PROJECT]", "[INSTANCE]", "[CLUSTER]", "[BACKUP]");
@@ -3158,8 +3565,11 @@ public final Policy setIamPolicy(ResourceName resource, Policy policy) {
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // 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/java/docs/setup#configure_endpoints_for_the_client_library
    * try (BaseBigtableTableAdminClient baseBigtableTableAdminClient =
    *     BaseBigtableTableAdminClient.create()) {
    *   String resource = AppProfileName.of("[PROJECT]", "[INSTANCE]", "[APP_PROFILE]").toString();
@@ -3188,8 +3598,11 @@ public final Policy setIamPolicy(String resource, Policy policy) {
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // 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/java/docs/setup#configure_endpoints_for_the_client_library
    * try (BaseBigtableTableAdminClient baseBigtableTableAdminClient =
    *     BaseBigtableTableAdminClient.create()) {
    *   SetIamPolicyRequest request =
@@ -3217,8 +3630,11 @@ public final Policy setIamPolicy(SetIamPolicyRequest request) {
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // 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/java/docs/setup#configure_endpoints_for_the_client_library
    * try (BaseBigtableTableAdminClient baseBigtableTableAdminClient =
    *     BaseBigtableTableAdminClient.create()) {
    *   SetIamPolicyRequest request =
@@ -3246,8 +3662,11 @@ public final UnaryCallable setIamPolicyCallable() {
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // 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/java/docs/setup#configure_endpoints_for_the_client_library
    * try (BaseBigtableTableAdminClient baseBigtableTableAdminClient =
    *     BaseBigtableTableAdminClient.create()) {
    *   ResourceName resource = BackupName.of("[PROJECT]", "[INSTANCE]", "[CLUSTER]", "[BACKUP]");
@@ -3281,8 +3700,11 @@ public final TestIamPermissionsResponse testIamPermissions(
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // 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/java/docs/setup#configure_endpoints_for_the_client_library
    * try (BaseBigtableTableAdminClient baseBigtableTableAdminClient =
    *     BaseBigtableTableAdminClient.create()) {
    *   String resource = AppProfileName.of("[PROJECT]", "[INSTANCE]", "[APP_PROFILE]").toString();
@@ -3316,8 +3738,11 @@ public final TestIamPermissionsResponse testIamPermissions(
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // 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/java/docs/setup#configure_endpoints_for_the_client_library
    * try (BaseBigtableTableAdminClient baseBigtableTableAdminClient =
    *     BaseBigtableTableAdminClient.create()) {
    *   TestIamPermissionsRequest request =
@@ -3345,8 +3770,11 @@ public final TestIamPermissionsResponse testIamPermissions(TestIamPermissionsReq
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // 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/java/docs/setup#configure_endpoints_for_the_client_library
    * try (BaseBigtableTableAdminClient baseBigtableTableAdminClient =
    *     BaseBigtableTableAdminClient.create()) {
    *   TestIamPermissionsRequest request =
diff --git a/google-cloud-bigtable/src/main/java/com/google/cloud/bigtable/admin/v2/BaseBigtableTableAdminSettings.java b/google-cloud-bigtable/src/main/java/com/google/cloud/bigtable/admin/v2/BaseBigtableTableAdminSettings.java
index 97cc6bb5d6..7f353a0d68 100644
--- a/google-cloud-bigtable/src/main/java/com/google/cloud/bigtable/admin/v2/BaseBigtableTableAdminSettings.java
+++ b/google-cloud-bigtable/src/main/java/com/google/cloud/bigtable/admin/v2/BaseBigtableTableAdminSettings.java
@@ -66,6 +66,8 @@
 import com.google.bigtable.admin.v2.UndeleteTableMetadata;
 import com.google.bigtable.admin.v2.UndeleteTableRequest;
 import com.google.bigtable.admin.v2.UpdateBackupRequest;
+import com.google.bigtable.admin.v2.UpdateTableMetadata;
+import com.google.bigtable.admin.v2.UpdateTableRequest;
 import com.google.cloud.bigtable.admin.v2.stub.BigtableTableAdminStubSettings;
 import com.google.iam.v1.GetIamPolicyRequest;
 import com.google.iam.v1.Policy;
@@ -114,6 +116,17 @@ public UnaryCallSettings getTableSettings() {
     return ((BigtableTableAdminStubSettings) getStubSettings()).getTableSettings();
   }
 
+  /** Returns the object with the settings used for calls to updateTable. */
+  public UnaryCallSettings updateTableSettings() {
+    return ((BigtableTableAdminStubSettings) getStubSettings()).updateTableSettings();
+  }
+
+  /** Returns the object with the settings used for calls to updateTable. */
+  public OperationCallSettings
+      updateTableOperationSettings() {
+    return ((BigtableTableAdminStubSettings) getStubSettings()).updateTableOperationSettings();
+  }
+
   /** Returns the object with the settings used for calls to deleteTable. */
   public UnaryCallSettings deleteTableSettings() {
     return ((BigtableTableAdminStubSettings) getStubSettings()).deleteTableSettings();
@@ -365,6 +378,17 @@ public UnaryCallSettings.Builder getTableSettings() {
       return getStubSettingsBuilder().getTableSettings();
     }
 
+    /** Returns the builder for the settings used for calls to updateTable. */
+    public UnaryCallSettings.Builder updateTableSettings() {
+      return getStubSettingsBuilder().updateTableSettings();
+    }
+
+    /** Returns the builder for the settings used for calls to updateTable. */
+    public OperationCallSettings.Builder
+        updateTableOperationSettings() {
+      return getStubSettingsBuilder().updateTableOperationSettings();
+    }
+
     /** Returns the builder for the settings used for calls to deleteTable. */
     public UnaryCallSettings.Builder deleteTableSettings() {
       return getStubSettingsBuilder().deleteTableSettings();
diff --git a/google-cloud-bigtable/src/main/java/com/google/cloud/bigtable/admin/v2/BigtableTableAdminSettings.java b/google-cloud-bigtable/src/main/java/com/google/cloud/bigtable/admin/v2/BigtableTableAdminSettings.java
index 2d7f1d5803..ce05f0a2d8 100644
--- a/google-cloud-bigtable/src/main/java/com/google/cloud/bigtable/admin/v2/BigtableTableAdminSettings.java
+++ b/google-cloud-bigtable/src/main/java/com/google/cloud/bigtable/admin/v2/BigtableTableAdminSettings.java
@@ -122,6 +122,8 @@ public String toString() {
         .add("stubSettings", stubSettings)
         .add("undeleteTableSettings", stubSettings.undeleteTableSettings())
         .add("undeleteTableOperationSettings", stubSettings.undeleteTableOperationSettings())
+        .add("updateTableSettings", stubSettings.updateTableSettings())
+        .add("updateTableOperationSettings", stubSettings.updateTableOperationSettings())
         .toString();
   }
 
diff --git a/google-cloud-bigtable/src/main/java/com/google/cloud/bigtable/admin/v2/gapic_metadata.json b/google-cloud-bigtable/src/main/java/com/google/cloud/bigtable/admin/v2/gapic_metadata.json
index fbaa5e3bea..bda1f8b016 100644
--- a/google-cloud-bigtable/src/main/java/com/google/cloud/bigtable/admin/v2/gapic_metadata.json
+++ b/google-cloud-bigtable/src/main/java/com/google/cloud/bigtable/admin/v2/gapic_metadata.json
@@ -150,6 +150,9 @@
             },
             "UpdateBackup": {
               "methods": ["updateBackup", "updateBackup", "updateBackupCallable"]
+            },
+            "UpdateTable": {
+              "methods": ["updateTableAsync", "updateTableAsync", "updateTableOperationCallable", "updateTableCallable"]
             }
           }
         }
diff --git a/google-cloud-bigtable/src/main/java/com/google/cloud/bigtable/admin/v2/models/PartialListClustersException.java b/google-cloud-bigtable/src/main/java/com/google/cloud/bigtable/admin/v2/models/PartialListClustersException.java
index 7b95983225..f04bdf326e 100644
--- a/google-cloud-bigtable/src/main/java/com/google/cloud/bigtable/admin/v2/models/PartialListClustersException.java
+++ b/google-cloud-bigtable/src/main/java/com/google/cloud/bigtable/admin/v2/models/PartialListClustersException.java
@@ -33,7 +33,7 @@ public class PartialListClustersException extends RuntimeException {
    */
   @InternalApi
   public PartialListClustersException(List unavailableZones, List clusters) {
-    super("Failed to list all instances, some zones where unavailable");
+    super("Failed to list all clusters, some zones were unavailable: " + unavailableZones);
     this.unavailableZones = ImmutableList.copyOf(unavailableZones);
     this.clusters = ImmutableList.copyOf(clusters);
   }
diff --git a/google-cloud-bigtable/src/main/java/com/google/cloud/bigtable/admin/v2/models/PartialListInstancesException.java b/google-cloud-bigtable/src/main/java/com/google/cloud/bigtable/admin/v2/models/PartialListInstancesException.java
index d4d5d4e992..a24d66fb27 100644
--- a/google-cloud-bigtable/src/main/java/com/google/cloud/bigtable/admin/v2/models/PartialListInstancesException.java
+++ b/google-cloud-bigtable/src/main/java/com/google/cloud/bigtable/admin/v2/models/PartialListInstancesException.java
@@ -31,7 +31,7 @@ public class PartialListInstancesException extends RuntimeException {
   @InternalApi
   public PartialListInstancesException(
       @Nonnull List unavailableZones, @Nonnull List instances) {
-    super("Failed to list all instances, some zones where unavailable");
+    super("Failed to list all instances, some zones were unavailable: " + unavailableZones);
 
     this.unavailableZones = ImmutableList.copyOf(unavailableZones);
     this.instances = ImmutableList.copyOf(instances);
diff --git a/google-cloud-bigtable/src/main/java/com/google/cloud/bigtable/admin/v2/models/RestoreTableRequest.java b/google-cloud-bigtable/src/main/java/com/google/cloud/bigtable/admin/v2/models/RestoreTableRequest.java
index 0547ebae01..b801b0db3b 100644
--- a/google-cloud-bigtable/src/main/java/com/google/cloud/bigtable/admin/v2/models/RestoreTableRequest.java
+++ b/google-cloud-bigtable/src/main/java/com/google/cloud/bigtable/admin/v2/models/RestoreTableRequest.java
@@ -29,37 +29,57 @@ public final class RestoreTableRequest {
   private final String sourceBackupId;
   private final String sourceClusterId;
   private final String sourceInstanceId;
+  private final String sourceProjectId;
 
   /**
    * Create a {@link RestoreTableRequest} object. It assumes the source backup locates in the same
-   * instance as the destination table. To restore a table from a backup in another instance, use
-   * {@link #of(String, String, String) of} method.
+   * instance and project as the destination table. To restore a table from a backup in another
+   * instance, use {@link #of(String, String, String) of} method. To restore a table from a backup
+   * in another project, use {@link #of(String, String, String, String) of} method.
    */
   public static RestoreTableRequest of(String sourceClusterId, String sourceBackupId) {
-    RestoreTableRequest request = new RestoreTableRequest(null, sourceClusterId, sourceBackupId);
+    RestoreTableRequest request =
+        new RestoreTableRequest(null, sourceClusterId, sourceBackupId, null);
     return request;
   }
 
   /**
-   * Create a {@link RestoreTableRequest} object. The source backup could locate in a the same or a
-   * different instance.
+   * Create a {@link RestoreTableRequest} object. The source backup could locate in the same or a
+   * different instance but the same project as the destination table. To restore a table from a
+   * backup in another project, use {@link #of(String, String, String, String) of} method.
    */
   public static RestoreTableRequest of(
       String sourceInstanceId, String sourceClusterId, String sourceBackupId) {
     RestoreTableRequest request =
-        new RestoreTableRequest(sourceInstanceId, sourceClusterId, sourceBackupId);
+        new RestoreTableRequest(sourceInstanceId, sourceClusterId, sourceBackupId, null);
+    return request;
+  }
+
+  /**
+   * Create a {@link RestoreTableRequest} object. The source backup could locate in the same or a
+   * different instance and/or project.
+   */
+  public static RestoreTableRequest of(
+      String sourceInstanceId,
+      String sourceClusterId,
+      String sourceBackupId,
+      String sourceProjectId) {
+    RestoreTableRequest request =
+        new RestoreTableRequest(sourceInstanceId, sourceClusterId, sourceBackupId, sourceProjectId);
     return request;
   }
 
   private RestoreTableRequest(
       @Nullable String sourceInstanceId,
       @Nonnull String sourceClusterId,
-      @Nonnull String sourceBackupId) {
+      @Nonnull String sourceBackupId,
+      @Nullable String sourceProjectId) {
     Preconditions.checkNotNull(sourceClusterId);
     Preconditions.checkNotNull(sourceBackupId);
     this.sourceBackupId = sourceBackupId;
     this.sourceInstanceId = sourceInstanceId;
     this.sourceClusterId = sourceClusterId;
+    this.sourceProjectId = sourceProjectId;
   }
 
   public RestoreTableRequest setTableId(String tableId) {
@@ -80,13 +100,18 @@ public boolean equals(Object o) {
     return Objects.equal(requestBuilder.getTableId(), that.requestBuilder.getTableId())
         && Objects.equal(sourceInstanceId, that.sourceInstanceId)
         && Objects.equal(sourceClusterId, that.sourceClusterId)
-        && Objects.equal(sourceBackupId, that.sourceBackupId);
+        && Objects.equal(sourceBackupId, that.sourceBackupId)
+        && Objects.equal(sourceProjectId, that.sourceProjectId);
   }
 
   @Override
   public int hashCode() {
     return Objects.hashCode(
-        requestBuilder.getTableId(), sourceInstanceId, sourceClusterId, sourceBackupId);
+        requestBuilder.getTableId(),
+        sourceInstanceId,
+        sourceClusterId,
+        sourceBackupId,
+        sourceProjectId);
   }
 
   @InternalApi
@@ -99,7 +124,7 @@ public com.google.bigtable.admin.v2.RestoreTableRequest toProto(
         .setParent(NameUtil.formatInstanceName(projectId, instanceId))
         .setBackup(
             NameUtil.formatBackupName(
-                projectId,
+                sourceProjectId == null ? projectId : sourceProjectId,
                 sourceInstanceId == null ? instanceId : sourceInstanceId,
                 sourceClusterId,
                 sourceBackupId))
diff --git a/google-cloud-bigtable/src/main/java/com/google/cloud/bigtable/admin/v2/stub/BigtableInstanceAdminStubSettings.java b/google-cloud-bigtable/src/main/java/com/google/cloud/bigtable/admin/v2/stub/BigtableInstanceAdminStubSettings.java
index 5d6102f321..028d244292 100644
--- a/google-cloud-bigtable/src/main/java/com/google/cloud/bigtable/admin/v2/stub/BigtableInstanceAdminStubSettings.java
+++ b/google-cloud-bigtable/src/main/java/com/google/cloud/bigtable/admin/v2/stub/BigtableInstanceAdminStubSettings.java
@@ -109,8 +109,11 @@
  * 

For example, to set the total timeout of getInstance to 30 seconds: * *

{@code
- * // This snippet has been automatically generated for illustrative purposes only.
- * // It may require modifications to work in your environment.
+ * // 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/java/docs/setup#configure_endpoints_for_the_client_library
  * BigtableInstanceAdminStubSettings.Builder baseBigtableInstanceAdminSettingsBuilder =
  *     BigtableInstanceAdminStubSettings.newBuilder();
  * baseBigtableInstanceAdminSettingsBuilder
diff --git a/google-cloud-bigtable/src/main/java/com/google/cloud/bigtable/admin/v2/stub/BigtableTableAdminStub.java b/google-cloud-bigtable/src/main/java/com/google/cloud/bigtable/admin/v2/stub/BigtableTableAdminStub.java
index d278228522..5f4bcd05a6 100644
--- a/google-cloud-bigtable/src/main/java/com/google/cloud/bigtable/admin/v2/stub/BigtableTableAdminStub.java
+++ b/google-cloud-bigtable/src/main/java/com/google/cloud/bigtable/admin/v2/stub/BigtableTableAdminStub.java
@@ -57,6 +57,8 @@
 import com.google.bigtable.admin.v2.UndeleteTableMetadata;
 import com.google.bigtable.admin.v2.UndeleteTableRequest;
 import com.google.bigtable.admin.v2.UpdateBackupRequest;
+import com.google.bigtable.admin.v2.UpdateTableMetadata;
+import com.google.bigtable.admin.v2.UpdateTableRequest;
 import com.google.iam.v1.GetIamPolicyRequest;
 import com.google.iam.v1.Policy;
 import com.google.iam.v1.SetIamPolicyRequest;
@@ -104,6 +106,15 @@ public UnaryCallable getTableCallable() {
     throw new UnsupportedOperationException("Not implemented: getTableCallable()");
   }
 
+  public OperationCallable
+      updateTableOperationCallable() {
+    throw new UnsupportedOperationException("Not implemented: updateTableOperationCallable()");
+  }
+
+  public UnaryCallable updateTableCallable() {
+    throw new UnsupportedOperationException("Not implemented: updateTableCallable()");
+  }
+
   public UnaryCallable deleteTableCallable() {
     throw new UnsupportedOperationException("Not implemented: deleteTableCallable()");
   }
diff --git a/google-cloud-bigtable/src/main/java/com/google/cloud/bigtable/admin/v2/stub/BigtableTableAdminStubSettings.java b/google-cloud-bigtable/src/main/java/com/google/cloud/bigtable/admin/v2/stub/BigtableTableAdminStubSettings.java
index 6d750a5d35..ede9ad10c9 100644
--- a/google-cloud-bigtable/src/main/java/com/google/cloud/bigtable/admin/v2/stub/BigtableTableAdminStubSettings.java
+++ b/google-cloud-bigtable/src/main/java/com/google/cloud/bigtable/admin/v2/stub/BigtableTableAdminStubSettings.java
@@ -79,6 +79,8 @@
 import com.google.bigtable.admin.v2.UndeleteTableMetadata;
 import com.google.bigtable.admin.v2.UndeleteTableRequest;
 import com.google.bigtable.admin.v2.UpdateBackupRequest;
+import com.google.bigtable.admin.v2.UpdateTableMetadata;
+import com.google.bigtable.admin.v2.UpdateTableRequest;
 import com.google.common.collect.ImmutableList;
 import com.google.common.collect.ImmutableMap;
 import com.google.common.collect.ImmutableSet;
@@ -113,8 +115,11 @@
  * 

For example, to set the total timeout of createTable to 30 seconds: * *

{@code
- * // This snippet has been automatically generated for illustrative purposes only.
- * // It may require modifications to work in your environment.
+ * // 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/java/docs/setup#configure_endpoints_for_the_client_library
  * BigtableTableAdminStubSettings.Builder baseBigtableTableAdminSettingsBuilder =
  *     BigtableTableAdminStubSettings.newBuilder();
  * baseBigtableTableAdminSettingsBuilder
@@ -152,6 +157,9 @@ public class BigtableTableAdminStubSettings extends StubSettings
       listTablesSettings;
   private final UnaryCallSettings getTableSettings;
+  private final UnaryCallSettings updateTableSettings;
+  private final OperationCallSettings
+      updateTableOperationSettings;
   private final UnaryCallSettings deleteTableSettings;
   private final UnaryCallSettings undeleteTableSettings;
   private final OperationCallSettings
@@ -374,6 +382,17 @@ public UnaryCallSettings getTableSettings() {
     return getTableSettings;
   }
 
+  /** Returns the object with the settings used for calls to updateTable. */
+  public UnaryCallSettings updateTableSettings() {
+    return updateTableSettings;
+  }
+
+  /** Returns the object with the settings used for calls to updateTable. */
+  public OperationCallSettings
+      updateTableOperationSettings() {
+    return updateTableOperationSettings;
+  }
+
   /** Returns the object with the settings used for calls to deleteTable. */
   public UnaryCallSettings deleteTableSettings() {
     return deleteTableSettings;
@@ -579,6 +598,8 @@ protected BigtableTableAdminStubSettings(Builder settingsBuilder) throws IOExcep
         settingsBuilder.createTableFromSnapshotOperationSettings().build();
     listTablesSettings = settingsBuilder.listTablesSettings().build();
     getTableSettings = settingsBuilder.getTableSettings().build();
+    updateTableSettings = settingsBuilder.updateTableSettings().build();
+    updateTableOperationSettings = settingsBuilder.updateTableOperationSettings().build();
     deleteTableSettings = settingsBuilder.deleteTableSettings().build();
     undeleteTableSettings = settingsBuilder.undeleteTableSettings().build();
     undeleteTableOperationSettings = settingsBuilder.undeleteTableOperationSettings().build();
@@ -618,6 +639,9 @@ public static class Builder
             ListTablesRequest, ListTablesResponse, ListTablesPagedResponse>
         listTablesSettings;
     private final UnaryCallSettings.Builder getTableSettings;
+    private final UnaryCallSettings.Builder updateTableSettings;
+    private final OperationCallSettings.Builder
+        updateTableOperationSettings;
     private final UnaryCallSettings.Builder deleteTableSettings;
     private final UnaryCallSettings.Builder undeleteTableSettings;
     private final OperationCallSettings.Builder
@@ -749,6 +773,8 @@ protected Builder(ClientContext clientContext) {
       createTableFromSnapshotOperationSettings = OperationCallSettings.newBuilder();
       listTablesSettings = PagedCallSettings.newBuilder(LIST_TABLES_PAGE_STR_FACT);
       getTableSettings = UnaryCallSettings.newUnaryCallSettingsBuilder();
+      updateTableSettings = UnaryCallSettings.newUnaryCallSettingsBuilder();
+      updateTableOperationSettings = OperationCallSettings.newBuilder();
       deleteTableSettings = UnaryCallSettings.newUnaryCallSettingsBuilder();
       undeleteTableSettings = UnaryCallSettings.newUnaryCallSettingsBuilder();
       undeleteTableOperationSettings = OperationCallSettings.newBuilder();
@@ -779,6 +805,7 @@ protected Builder(ClientContext clientContext) {
               createTableFromSnapshotSettings,
               listTablesSettings,
               getTableSettings,
+              updateTableSettings,
               deleteTableSettings,
               undeleteTableSettings,
               modifyColumnFamiliesSettings,
@@ -810,6 +837,8 @@ protected Builder(BigtableTableAdminStubSettings settings) {
           settings.createTableFromSnapshotOperationSettings.toBuilder();
       listTablesSettings = settings.listTablesSettings.toBuilder();
       getTableSettings = settings.getTableSettings.toBuilder();
+      updateTableSettings = settings.updateTableSettings.toBuilder();
+      updateTableOperationSettings = settings.updateTableOperationSettings.toBuilder();
       deleteTableSettings = settings.deleteTableSettings.toBuilder();
       undeleteTableSettings = settings.undeleteTableSettings.toBuilder();
       undeleteTableOperationSettings = settings.undeleteTableOperationSettings.toBuilder();
@@ -840,6 +869,7 @@ protected Builder(BigtableTableAdminStubSettings settings) {
               createTableFromSnapshotSettings,
               listTablesSettings,
               getTableSettings,
+              updateTableSettings,
               deleteTableSettings,
               undeleteTableSettings,
               modifyColumnFamiliesSettings,
@@ -895,6 +925,11 @@ private static Builder initDefaults(Builder builder) {
           .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("retry_policy_2_codes"))
           .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("retry_policy_2_params"));
 
+      builder
+          .updateTableSettings()
+          .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("no_retry_codes"))
+          .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("no_retry_params"));
+
       builder
           .deleteTableSettings()
           .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("no_retry_1_codes"))
@@ -1015,6 +1050,29 @@ private static Builder initDefaults(Builder builder) {
                       .setTotalTimeout(Duration.ofMillis(3600000L))
                       .build()));
 
+      builder
+          .updateTableOperationSettings()
+          .setInitialCallSettings(
+              UnaryCallSettings.newUnaryCallSettingsBuilder()
+                  .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("no_retry_codes"))
+                  .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("no_retry_params"))
+                  .build())
+          .setResponseTransformer(
+              ProtoOperationTransformers.ResponseTransformer.create(Table.class))
+          .setMetadataTransformer(
+              ProtoOperationTransformers.MetadataTransformer.create(UpdateTableMetadata.class))
+          .setPollingAlgorithm(
+              OperationTimedPollAlgorithm.create(
+                  RetrySettings.newBuilder()
+                      .setInitialRetryDelay(Duration.ofMillis(5000L))
+                      .setRetryDelayMultiplier(1.5)
+                      .setMaxRetryDelay(Duration.ofMillis(45000L))
+                      .setInitialRpcTimeout(Duration.ZERO)
+                      .setRpcTimeoutMultiplier(1.0)
+                      .setMaxRpcTimeout(Duration.ZERO)
+                      .setTotalTimeout(Duration.ofMillis(300000L))
+                      .build()));
+
       builder
           .undeleteTableOperationSettings()
           .setInitialCallSettings(
@@ -1160,6 +1218,19 @@ public UnaryCallSettings.Builder getTableSettings() {
       return getTableSettings;
     }
 
+    /** Returns the builder for the settings used for calls to updateTable. */
+    public UnaryCallSettings.Builder updateTableSettings() {
+      return updateTableSettings;
+    }
+
+    /** Returns the builder for the settings used for calls to updateTable. */
+    @BetaApi(
+        "The surface for use by generated code is not stable yet and may change in the future.")
+    public OperationCallSettings.Builder
+        updateTableOperationSettings() {
+      return updateTableOperationSettings;
+    }
+
     /** Returns the builder for the settings used for calls to deleteTable. */
     public UnaryCallSettings.Builder deleteTableSettings() {
       return deleteTableSettings;
diff --git a/google-cloud-bigtable/src/main/java/com/google/cloud/bigtable/admin/v2/stub/GrpcBigtableTableAdminStub.java b/google-cloud-bigtable/src/main/java/com/google/cloud/bigtable/admin/v2/stub/GrpcBigtableTableAdminStub.java
index f75f5fe399..c6be2b72b9 100644
--- a/google-cloud-bigtable/src/main/java/com/google/cloud/bigtable/admin/v2/stub/GrpcBigtableTableAdminStub.java
+++ b/google-cloud-bigtable/src/main/java/com/google/cloud/bigtable/admin/v2/stub/GrpcBigtableTableAdminStub.java
@@ -61,6 +61,8 @@
 import com.google.bigtable.admin.v2.UndeleteTableMetadata;
 import com.google.bigtable.admin.v2.UndeleteTableRequest;
 import com.google.bigtable.admin.v2.UpdateBackupRequest;
+import com.google.bigtable.admin.v2.UpdateTableMetadata;
+import com.google.bigtable.admin.v2.UpdateTableRequest;
 import com.google.common.collect.ImmutableMap;
 import com.google.iam.v1.GetIamPolicyRequest;
 import com.google.iam.v1.Policy;
@@ -117,6 +119,14 @@ public class GrpcBigtableTableAdminStub extends BigtableTableAdminStub {
           .setResponseMarshaller(ProtoUtils.marshaller(Table.getDefaultInstance()))
           .build();
 
+  private static final MethodDescriptor updateTableMethodDescriptor =
+      MethodDescriptor.newBuilder()
+          .setType(MethodDescriptor.MethodType.UNARY)
+          .setFullMethodName("google.bigtable.admin.v2.BigtableTableAdmin/UpdateTable")
+          .setRequestMarshaller(ProtoUtils.marshaller(UpdateTableRequest.getDefaultInstance()))
+          .setResponseMarshaller(ProtoUtils.marshaller(Operation.getDefaultInstance()))
+          .build();
+
   private static final MethodDescriptor deleteTableMethodDescriptor =
       MethodDescriptor.newBuilder()
           .setType(MethodDescriptor.MethodType.UNARY)
@@ -305,6 +315,9 @@ public class GrpcBigtableTableAdminStub extends BigtableTableAdminStub {
   private final UnaryCallable listTablesCallable;
   private final UnaryCallable listTablesPagedCallable;
   private final UnaryCallable getTableCallable;
+  private final UnaryCallable updateTableCallable;
+  private final OperationCallable
+      updateTableOperationCallable;
   private final UnaryCallable deleteTableCallable;
   private final UnaryCallable undeleteTableCallable;
   private final OperationCallable
@@ -425,6 +438,16 @@ protected GrpcBigtableTableAdminStub(
                   return params.build();
                 })
             .build();
+    GrpcCallSettings updateTableTransportSettings =
+        GrpcCallSettings.newBuilder()
+            .setMethodDescriptor(updateTableMethodDescriptor)
+            .setParamsExtractor(
+                request -> {
+                  ImmutableMap.Builder params = ImmutableMap.builder();
+                  params.put("table.name", String.valueOf(request.getTable().getName()));
+                  return params.build();
+                })
+            .build();
     GrpcCallSettings deleteTableTransportSettings =
         GrpcCallSettings.newBuilder()
             .setMethodDescriptor(deleteTableMethodDescriptor)
@@ -643,6 +666,15 @@ protected GrpcBigtableTableAdminStub(
     this.getTableCallable =
         callableFactory.createUnaryCallable(
             getTableTransportSettings, settings.getTableSettings(), clientContext);
+    this.updateTableCallable =
+        callableFactory.createUnaryCallable(
+            updateTableTransportSettings, settings.updateTableSettings(), clientContext);
+    this.updateTableOperationCallable =
+        callableFactory.createOperationCallable(
+            updateTableTransportSettings,
+            settings.updateTableOperationSettings(),
+            clientContext,
+            operationsStub);
     this.deleteTableCallable =
         callableFactory.createUnaryCallable(
             deleteTableTransportSettings, settings.deleteTableSettings(), clientContext);
@@ -777,6 +809,17 @@ public UnaryCallable getTableCallable() {
     return getTableCallable;
   }
 
+  @Override
+  public UnaryCallable updateTableCallable() {
+    return updateTableCallable;
+  }
+
+  @Override
+  public OperationCallable
+      updateTableOperationCallable() {
+    return updateTableOperationCallable;
+  }
+
   @Override
   public UnaryCallable deleteTableCallable() {
     return deleteTableCallable;
diff --git a/google-cloud-bigtable/src/main/java/com/google/cloud/bigtable/data/v2/internal/RowMergerUtil.java b/google-cloud-bigtable/src/main/java/com/google/cloud/bigtable/data/v2/internal/RowMergerUtil.java
new file mode 100644
index 0000000000..9fbc356d53
--- /dev/null
+++ b/google-cloud-bigtable/src/main/java/com/google/cloud/bigtable/data/v2/internal/RowMergerUtil.java
@@ -0,0 +1,55 @@
+/*
+ * Copyright 2022 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.
+ */
+package com.google.cloud.bigtable.data.v2.internal;
+
+import com.google.api.core.InternalApi;
+import com.google.bigtable.v2.ReadRowsResponse;
+import com.google.cloud.bigtable.data.v2.models.DefaultRowAdapter;
+import com.google.cloud.bigtable.data.v2.models.Row;
+import com.google.cloud.bigtable.data.v2.models.RowAdapter.RowBuilder;
+import com.google.cloud.bigtable.data.v2.stub.readrows.RowMerger;
+import java.util.ArrayList;
+import java.util.List;
+
+@InternalApi("For internal google use only")
+public class RowMergerUtil implements AutoCloseable {
+  private final RowMerger merger;
+
+  public RowMergerUtil() {
+    RowBuilder rowBuilder = new DefaultRowAdapter().createRowBuilder();
+    merger = new RowMerger<>(rowBuilder);
+  }
+
+  @Override
+  public void close() {
+    if (merger.hasPartialFrame()) {
+      throw new IllegalStateException("Tried to close merger with unmerged partial data");
+    }
+  }
+
+  public List parseReadRowsResponses(Iterable responses) {
+    List rows = new ArrayList<>();
+
+    for (ReadRowsResponse response : responses) {
+      merger.push(response);
+      while (merger.hasFullFrame()) {
+        rows.add(merger.pop());
+      }
+    }
+
+    return rows;
+  }
+}
diff --git a/google-cloud-bigtable/src/main/java/com/google/cloud/bigtable/data/v2/models/DefaultRowAdapter.java b/google-cloud-bigtable/src/main/java/com/google/cloud/bigtable/data/v2/models/DefaultRowAdapter.java
index 279ebf6407..2ff139081c 100644
--- a/google-cloud-bigtable/src/main/java/com/google/cloud/bigtable/data/v2/models/DefaultRowAdapter.java
+++ b/google-cloud-bigtable/src/main/java/com/google/cloud/bigtable/data/v2/models/DefaultRowAdapter.java
@@ -75,7 +75,8 @@ public Row createRowFromProto(com.google.bigtable.v2.Row row) {
     return builder.finishRow();
   }
 
-  /** {@inheritDoc} */
+  /** Internal implementation detail for {@link DefaultRowAdapter}. */
+  @InternalApi()
   public class DefaultRowBuilder implements RowBuilder {
     private ByteString currentKey;
     private TreeMap> cellsByFamily;
diff --git a/google-cloud-bigtable/src/main/java/com/google/cloud/bigtable/data/v2/models/Mutation.java b/google-cloud-bigtable/src/main/java/com/google/cloud/bigtable/data/v2/models/Mutation.java
index 326d78cfe0..6c1402685d 100644
--- a/google-cloud-bigtable/src/main/java/com/google/cloud/bigtable/data/v2/models/Mutation.java
+++ b/google-cloud-bigtable/src/main/java/com/google/cloud/bigtable/data/v2/models/Mutation.java
@@ -87,6 +87,19 @@ public static Mutation fromProtoUnsafe(List pro
     return mutation;
   }
 
+  /**
+   * Wraps the List of protobuf {@link com.google.bigtable.v2.Mutation}. This methods, like {@link
+   * #createUnsafe()}, allows setCell operation to use server side timestamp. This is dangerous
+   * because mutations will no longer be idempotent, which might cause multiple duplicate values to
+   * be stored in Bigtable. This option should only be used for advanced usecases with extreme care.
+   */
+  @BetaApi
+  public static Mutation fromProtoUnsafe(Iterable protos) {
+    Mutation mutation = new Mutation(true);
+    mutation.mutations.addAll(protos);
+    return mutation;
+  }
+
   /**
    * Constructs a row mutation from an existing protobuf object.
    *
diff --git a/google-cloud-bigtable/src/main/java/com/google/cloud/bigtable/data/v2/models/Query.java b/google-cloud-bigtable/src/main/java/com/google/cloud/bigtable/data/v2/models/Query.java
index 986a0ca1a5..271ffe3adf 100644
--- a/google-cloud-bigtable/src/main/java/com/google/cloud/bigtable/data/v2/models/Query.java
+++ b/google-cloud-bigtable/src/main/java/com/google/cloud/bigtable/data/v2/models/Query.java
@@ -15,6 +15,7 @@
  */
 package com.google.cloud.bigtable.data.v2.models;
 
+import com.google.api.core.BetaApi;
 import com.google.api.core.InternalApi;
 import com.google.bigtable.v2.ReadRowsRequest;
 import com.google.bigtable.v2.RowFilter;
@@ -248,6 +249,29 @@ public List shard(SortedSet splitPoints) {
     return shards;
   }
 
+  /**
+   * Create a query paginator that'll split the query into smaller chunks.
+   *
+   * 

Example usage: + * + *

{@code
+   * Query query = Query.create(...).range("a", "z");
+   * Query.QueryPaginator paginator = query.createQueryPaginator(100);
+   * ByteString lastSeenRowKey = ByteString.EMPTY;
+   * do {
+   *     List rows = client.readRowsCallable().all().call(paginator.getNextQuery());
+   *     for (Row row : rows) {
+   *        // do some processing
+   *        lastSeenRow = row;
+   *     }
+   * } while (paginator.advance(lastSeenRowKey));
+   * }
+ */ + @BetaApi("This surface is stable yet it might be removed in the future.") + public QueryPaginator createPaginator(int pageSize) { + return new QueryPaginator(this, pageSize); + } + /** Get the minimal range that encloses all of the row keys and ranges in this Query. */ public ByteStringRange getBound() { return RowSetUtil.getBound(builder.getRows()); @@ -297,6 +321,73 @@ private static ByteString wrapKey(String key) { return ByteString.copyFromUtf8(key); } + /** + * A Query Paginator that will split a query into small chunks. See {@link + * Query#createPaginator(int)} for example usage. + */ + @BetaApi("This surface is stable yet it might be removed in the future.") + public static class QueryPaginator { + + private final boolean hasOverallLimit; + private long remainingRows; + private Query query; + private final int pageSize; + private ByteString prevSplitPoint; + + QueryPaginator(@Nonnull Query query, int pageSize) { + this.hasOverallLimit = query.builder.getRowsLimit() > 0; + this.remainingRows = query.builder.getRowsLimit(); + this.query = query.limit(pageSize); + if (hasOverallLimit) { + remainingRows -= pageSize; + } + this.pageSize = pageSize; + this.prevSplitPoint = ByteString.EMPTY; + } + + /** Return the next query. */ + public Query getNextQuery() { + return query; + } + + /** + * Construct the next query. Return true if there are more queries to return. False if we've + * read everything. + */ + public boolean advance(@Nonnull ByteString lastSeenRowKey) { + Preconditions.checkNotNull( + lastSeenRowKey, "lastSeenRowKey cannot be null, use ByteString.EMPTY instead."); + // Full table scans don't have ranges or limits. Running the query again will return an empty + // list when we reach the end of the table. lastSeenRowKey won't be updated in this case, and + // we can break out of the loop. + if (lastSeenRowKey.equals(prevSplitPoint)) { + return false; + } + this.prevSplitPoint = lastSeenRowKey; + + // Set the query limit. If the original limit is set, return false if the new + // limit is <= 0 to avoid returning more rows than intended. + if (hasOverallLimit && remainingRows <= 0) { + return false; + } + if (hasOverallLimit) { + query.limit(Math.min(this.pageSize, remainingRows)); + remainingRows -= pageSize; + } else { + query.limit(pageSize); + } + + // Split the row ranges / row keys. Return false if there's nothing + // left on the right of the split point. + RowSetUtil.Split split = RowSetUtil.split(query.builder.getRows(), lastSeenRowKey); + if (split.getRight() == null) { + return false; + } + query.builder.setRows(split.getRight()); + return true; + } + } + @Override public boolean equals(Object o) { if (this == o) { diff --git a/google-cloud-bigtable/src/main/java/com/google/cloud/bigtable/data/v2/models/RowMutationEntry.java b/google-cloud-bigtable/src/main/java/com/google/cloud/bigtable/data/v2/models/RowMutationEntry.java index 9239b30497..63ffe708a5 100644 --- a/google-cloud-bigtable/src/main/java/com/google/cloud/bigtable/data/v2/models/RowMutationEntry.java +++ b/google-cloud-bigtable/src/main/java/com/google/cloud/bigtable/data/v2/models/RowMutationEntry.java @@ -15,6 +15,7 @@ */ package com.google.cloud.bigtable.data.v2.models; +import com.google.api.core.BetaApi; import com.google.api.core.InternalApi; import com.google.bigtable.v2.MutateRowsRequest; import com.google.common.base.Preconditions; @@ -54,6 +55,13 @@ public static RowMutationEntry create(@Nonnull ByteString key) { return new RowMutationEntry(key, Mutation.create()); } + /** Creates a new instance from existing mutation. */ + @BetaApi + public static RowMutationEntry createFromMutationUnsafe( + @Nonnull ByteString key, @Nonnull Mutation mutation) { + return new RowMutationEntry(key, mutation); + } + /** * Creates new instance of mutation builder which allows server timestamp for setCell operations. * diff --git a/google-cloud-bigtable/src/main/java/com/google/cloud/bigtable/data/v2/stub/ConvertStreamExceptionCallable.java b/google-cloud-bigtable/src/main/java/com/google/cloud/bigtable/data/v2/stub/ConvertExceptionCallable.java similarity index 76% rename from google-cloud-bigtable/src/main/java/com/google/cloud/bigtable/data/v2/stub/ConvertStreamExceptionCallable.java rename to google-cloud-bigtable/src/main/java/com/google/cloud/bigtable/data/v2/stub/ConvertExceptionCallable.java index 0358fe3a69..9c4359ef99 100644 --- a/google-cloud-bigtable/src/main/java/com/google/cloud/bigtable/data/v2/stub/ConvertStreamExceptionCallable.java +++ b/google-cloud-bigtable/src/main/java/com/google/cloud/bigtable/data/v2/stub/ConvertExceptionCallable.java @@ -25,50 +25,50 @@ /** * This callable converts the "Received rst stream" exception into a retryable {@link ApiException}. */ -final class ConvertStreamExceptionCallable +final class ConvertExceptionCallable extends ServerStreamingCallable { private final ServerStreamingCallable innerCallable; - public ConvertStreamExceptionCallable( - ServerStreamingCallable innerCallable) { + public ConvertExceptionCallable(ServerStreamingCallable innerCallable) { this.innerCallable = innerCallable; } @Override public void call( RequestT request, ResponseObserver responseObserver, ApiCallContext context) { - ConvertStreamExceptionResponseObserver observer = - new ConvertStreamExceptionResponseObserver<>(responseObserver); + ConvertExceptionResponseObserver observer = + new ConvertExceptionResponseObserver<>(responseObserver); innerCallable.call(request, observer, context); } - private class ConvertStreamExceptionResponseObserver - implements ResponseObserver { + private class ConvertExceptionResponseObserver + extends SafeResponseObserver { private final ResponseObserver outerObserver; - ConvertStreamExceptionResponseObserver(ResponseObserver outerObserver) { + ConvertExceptionResponseObserver(ResponseObserver outerObserver) { + super(outerObserver); this.outerObserver = outerObserver; } @Override - public void onStart(StreamController controller) { + protected void onStartImpl(StreamController controller) { outerObserver.onStart(controller); } @Override - public void onResponse(ResponseT response) { + protected void onResponseImpl(ResponseT response) { outerObserver.onResponse(response); } @Override - public void onError(Throwable t) { + protected void onErrorImpl(Throwable t) { outerObserver.onError(convertException(t)); } @Override - public void onComplete() { + protected void onCompleteImpl() { outerObserver.onComplete(); } } diff --git a/google-cloud-bigtable/src/main/java/com/google/cloud/bigtable/data/v2/stub/EnhancedBigtableStub.java b/google-cloud-bigtable/src/main/java/com/google/cloud/bigtable/data/v2/stub/EnhancedBigtableStub.java index 66c20e4033..0c0d011213 100644 --- a/google-cloud-bigtable/src/main/java/com/google/cloud/bigtable/data/v2/stub/EnhancedBigtableStub.java +++ b/google-cloud-bigtable/src/main/java/com/google/cloud/bigtable/data/v2/stub/EnhancedBigtableStub.java @@ -445,7 +445,7 @@ public Map extract(ReadRowsRequest readRowsRequest) { // should be treated similar to UNAVAILABLE. However, this exception has an INTERNAL error code // which by default is not retryable. Convert the exception so it can be retried in the client. ServerStreamingCallable convertException = - new ConvertStreamExceptionCallable<>(withStatsHeaders); + new ConvertExceptionCallable<>(withStatsHeaders); ServerStreamingCallable merging = new RowMergingCallable<>(convertException, rowAdapter); @@ -740,7 +740,7 @@ public Map extract(MutateRowsRequest mutateRowsRequest) { // should be treated similar to UNAVAILABLE. However, this exception has an INTERNAL error code // which by default is not retryable. Convert the exception so it can be retried in the client. ServerStreamingCallable convertException = - new ConvertStreamExceptionCallable<>(withStatsHeaders); + new ConvertExceptionCallable<>(withStatsHeaders); RetryAlgorithm retryAlgorithm = new RetryAlgorithm<>( @@ -892,7 +892,7 @@ public Map extract( // exception has an INTERNAL error code which by default is not retryable. Convert the exception // so it can be retried in the client. ServerStreamingCallable convertException = - new ConvertStreamExceptionCallable<>(withStatsHeaders); + new ConvertExceptionCallable<>(withStatsHeaders); // Copy idle timeout settings for watchdog. ServerStreamingCallSettings innerSettings = @@ -964,7 +964,7 @@ public Map extract( // INTERNAL error code which by default is not retryable. Convert the exception it can be // retried in the client. ServerStreamingCallable convertException = - new ConvertStreamExceptionCallable<>(withStatsHeaders); + new ConvertExceptionCallable<>(withStatsHeaders); ServerStreamingCallable merging = new ChangeStreamRecordMergingCallable<>(convertException, changeStreamRecordAdapter); diff --git a/google-cloud-bigtable/src/main/java/com/google/cloud/bigtable/data/v2/stub/SafeResponseObserver.java b/google-cloud-bigtable/src/main/java/com/google/cloud/bigtable/data/v2/stub/SafeResponseObserver.java new file mode 100644 index 0000000000..7c65bdf95a --- /dev/null +++ b/google-cloud-bigtable/src/main/java/com/google/cloud/bigtable/data/v2/stub/SafeResponseObserver.java @@ -0,0 +1,123 @@ +/* + * Copyright 2022 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. + */ +package com.google.cloud.bigtable.data.v2.stub; + +import com.google.api.core.InternalApi; +import com.google.api.gax.rpc.ResponseObserver; +import com.google.api.gax.rpc.StreamController; +import java.util.concurrent.atomic.AtomicBoolean; +import java.util.logging.Level; +import java.util.logging.Logger; + +/** + * Base implementation of {@link ResponseObserver} that checks the state and catches all the + * throwables. + */ +@InternalApi +public abstract class SafeResponseObserver implements ResponseObserver { + + private static final Logger LOGGER = Logger.getLogger(SafeResponseObserver.class.getName()); + private AtomicBoolean isStarted = new AtomicBoolean(false); + private AtomicBoolean isClosed = new AtomicBoolean(false); + private StreamController streamController; + private ResponseObserver outerObserver; + + public SafeResponseObserver(ResponseObserver outerObserver) { + this.outerObserver = outerObserver; + } + + @Override + public final void onStart(StreamController streamController) { + if (!isStarted.compareAndSet(false, true)) { + throw new IllegalStateException("A stream is already started"); + } + + this.streamController = streamController; + try { + onStartImpl(streamController); + } catch (Throwable t) { + if (!isClosed.compareAndSet(false, true)) { + logException("Tried to cancel a closed stream"); + return; + } + streamController.cancel(); + outerObserver.onError(t); + } + } + + @Override + public final void onResponse(ResponseT response) { + if (isClosed.get()) { + logException("Received a response after the stream is closed"); + return; + } + try { + onResponseImpl(response); + } catch (Throwable t1) { + try { + if (!isClosed.compareAndSet(false, true)) { + logException("Tried to cancel a closed stream"); + return; + } + streamController.cancel(); + } catch (Throwable t2) { + t1.addSuppressed(t2); + } + outerObserver.onError(t1); + } + } + + @Override + public final void onError(Throwable throwable) { + if (!isClosed.compareAndSet(false, true)) { + logException("Received error after the stream is closed"); + return; + } + + try { + onErrorImpl(throwable); + } catch (Throwable t) { + throwable.addSuppressed(t); + outerObserver.onError(throwable); + } + } + + @Override + public final void onComplete() { + if (!isClosed.compareAndSet(false, true)) { + logException("Tried to double close the stream"); + return; + } + + try { + onCompleteImpl(); + } catch (Throwable t) { + outerObserver.onError(t); + } + } + + private void logException(String message) { + LOGGER.log(Level.WARNING, message, new IllegalStateException(message)); + } + + protected abstract void onStartImpl(StreamController streamController); + + protected abstract void onResponseImpl(ResponseT response); + + protected abstract void onErrorImpl(Throwable throwable); + + protected abstract void onCompleteImpl(); +} diff --git a/google-cloud-bigtable/src/main/java/com/google/cloud/bigtable/data/v2/stub/metrics/BigtableTracerStreamingCallable.java b/google-cloud-bigtable/src/main/java/com/google/cloud/bigtable/data/v2/stub/metrics/BigtableTracerStreamingCallable.java index c7f09c4db1..17c968c60f 100644 --- a/google-cloud-bigtable/src/main/java/com/google/cloud/bigtable/data/v2/stub/metrics/BigtableTracerStreamingCallable.java +++ b/google-cloud-bigtable/src/main/java/com/google/cloud/bigtable/data/v2/stub/metrics/BigtableTracerStreamingCallable.java @@ -21,11 +21,9 @@ import com.google.api.gax.rpc.ResponseObserver; import com.google.api.gax.rpc.ServerStreamingCallable; import com.google.api.gax.rpc.StreamController; -import com.google.bigtable.v2.ResponseParams; +import com.google.cloud.bigtable.data.v2.stub.SafeResponseObserver; import com.google.common.base.Preconditions; import com.google.common.base.Stopwatch; -import com.google.protobuf.InvalidProtocolBufferException; -import io.grpc.Metadata; import java.util.concurrent.TimeUnit; import javax.annotation.Nonnull; @@ -68,7 +66,7 @@ public void call( } } - private class BigtableTracerResponseObserver implements ResponseObserver { + private class BigtableTracerResponseObserver extends SafeResponseObserver { private final BigtableTracer tracer; private final ResponseObserver outerObserver; @@ -78,81 +76,35 @@ private class BigtableTracerResponseObserver implements ResponseObser ResponseObserver observer, BigtableTracer tracer, GrpcResponseMetadata metadata) { + super(observer); + this.tracer = tracer; this.outerObserver = observer; this.responseMetadata = metadata; } @Override - public void onStart(final StreamController controller) { + protected void onStartImpl(final StreamController controller) { TracedStreamController tracedController = new TracedStreamController(controller, tracer); outerObserver.onStart(tracedController); } @Override - public void onResponse(ResponseT response) { + protected void onResponseImpl(ResponseT response) { Stopwatch stopwatch = Stopwatch.createStarted(); outerObserver.onResponse(response); tracer.afterResponse(stopwatch.elapsed(TimeUnit.MILLISECONDS)); } @Override - public void onError(Throwable t) { - // server-timing metric will be added through GrpcResponseMetadata#onHeaders(Metadata), - // so it's not checking trailing metadata here. - Metadata metadata = responseMetadata.getMetadata(); - Long latency = Util.getGfeLatency(metadata); - tracer.recordGfeMetadata(latency, t); - try { - // Check both headers and trailers because in different environments the metadata - // could be returned in headers or trailers - if (metadata != null) { - byte[] trailers = metadata.get(Util.METADATA_KEY); - if (trailers == null) { - Metadata trailingMetadata = responseMetadata.getTrailingMetadata(); - if (trailingMetadata != null) { - trailers = trailingMetadata.get(Util.METADATA_KEY); - } - } - // If the response is terminated abnormally and we didn't get location information in - // trailers or headers, skip setting the locations - if (trailers != null) { - ResponseParams decodedTrailers = ResponseParams.parseFrom(trailers); - tracer.setLocations(decodedTrailers.getZoneId(), decodedTrailers.getClusterId()); - } - } - } catch (InvalidProtocolBufferException e) { - } - + protected void onErrorImpl(Throwable t) { + Util.recordMetricsFromMetadata(responseMetadata, tracer, t); outerObserver.onError(t); } @Override - public void onComplete() { - Metadata metadata = responseMetadata.getMetadata(); - Long latency = Util.getGfeLatency(metadata); - tracer.recordGfeMetadata(latency, null); - try { - // Check both headers and trailers because in different environments the metadata - // could be returned in headers or trailers - if (metadata != null) { - byte[] trailers = metadata.get(Util.METADATA_KEY); - if (trailers == null) { - Metadata trailingMetadata = responseMetadata.getTrailingMetadata(); - if (trailingMetadata != null) { - trailers = trailingMetadata.get(Util.METADATA_KEY); - } - } - // If the response is terminated abnormally and we didn't get location information in - // trailers or headers, skip setting the locations - if (trailers != null) { - ResponseParams decodedTrailers = ResponseParams.parseFrom(trailers); - tracer.setLocations(decodedTrailers.getZoneId(), decodedTrailers.getClusterId()); - } - } - } catch (InvalidProtocolBufferException e) { - } - + protected void onCompleteImpl() { + Util.recordMetricsFromMetadata(responseMetadata, tracer, null); outerObserver.onComplete(); } } diff --git a/google-cloud-bigtable/src/main/java/com/google/cloud/bigtable/data/v2/stub/metrics/BigtableTracerUnaryCallable.java b/google-cloud-bigtable/src/main/java/com/google/cloud/bigtable/data/v2/stub/metrics/BigtableTracerUnaryCallable.java index 50d24ecbaf..4b73a34797 100644 --- a/google-cloud-bigtable/src/main/java/com/google/cloud/bigtable/data/v2/stub/metrics/BigtableTracerUnaryCallable.java +++ b/google-cloud-bigtable/src/main/java/com/google/cloud/bigtable/data/v2/stub/metrics/BigtableTracerUnaryCallable.java @@ -22,11 +22,8 @@ import com.google.api.gax.grpc.GrpcResponseMetadata; import com.google.api.gax.rpc.ApiCallContext; import com.google.api.gax.rpc.UnaryCallable; -import com.google.bigtable.v2.ResponseParams; import com.google.common.base.Preconditions; import com.google.common.util.concurrent.MoreExecutors; -import com.google.protobuf.InvalidProtocolBufferException; -import io.grpc.Metadata; import javax.annotation.Nonnull; /** @@ -79,56 +76,12 @@ class BigtableTracerUnaryCallback implements ApiFutureCallback 1) { + recorder.putRetryCount(attemptCount - 1); + } // serverLatencyTimer should already be stopped in recordAttemptCompletion recorder.putOperationLatencies(operationLatency); @@ -256,6 +266,14 @@ private void recordAttemptCompletion(@Nullable Throwable status) { serverLatencyTimerIsRunning = false; } } + + // Patch the status until it's fixed in gax. When an attempt failed, + // it'll throw a ServerStreamingAttemptException. Unwrap the exception + // so it could get processed by extractStatus + if (status instanceof ServerStreamingAttemptException) { + status = status.getCause(); + } + recorder.putAttemptLatencies(attemptTimer.elapsed(TimeUnit.MILLISECONDS)); recorder.recordAttempt(Util.extractStatus(status), tableId, zone, cluster); } diff --git a/google-cloud-bigtable/src/main/java/com/google/cloud/bigtable/data/v2/stub/metrics/MetricsTracer.java b/google-cloud-bigtable/src/main/java/com/google/cloud/bigtable/data/v2/stub/metrics/MetricsTracer.java index 3c63b1b5f7..3b6b1b40ae 100644 --- a/google-cloud-bigtable/src/main/java/com/google/cloud/bigtable/data/v2/stub/metrics/MetricsTracer.java +++ b/google-cloud-bigtable/src/main/java/com/google/cloud/bigtable/data/v2/stub/metrics/MetricsTracer.java @@ -15,6 +15,7 @@ */ package com.google.cloud.bigtable.data.v2.stub.metrics; +import com.google.api.gax.retrying.ServerStreamingAttemptException; import com.google.api.gax.tracing.ApiTracerFactory.OperationType; import com.google.api.gax.tracing.SpanName; import com.google.common.base.Stopwatch; @@ -166,6 +167,13 @@ private void recordAttemptCompletion(@Nullable Throwable throwable) { RpcMeasureConstants.BIGTABLE_ATTEMPT_LATENCY, attemptTimer.elapsed(TimeUnit.MILLISECONDS)); + // Patch the throwable until it's fixed in gax. When an attempt failed, + // it'll throw a ServerStreamingAttemptException. Unwrap the exception + // so it could get processed by extractStatus + if (throwable instanceof ServerStreamingAttemptException) { + throwable = throwable.getCause(); + } + TagContextBuilder tagCtx = newTagCtxBuilder() .putLocal( diff --git a/google-cloud-bigtable/src/main/java/com/google/cloud/bigtable/data/v2/stub/metrics/Util.java b/google-cloud-bigtable/src/main/java/com/google/cloud/bigtable/data/v2/stub/metrics/Util.java index 0e356ebaf9..5b045f15ef 100644 --- a/google-cloud-bigtable/src/main/java/com/google/cloud/bigtable/data/v2/stub/metrics/Util.java +++ b/google-cloud-bigtable/src/main/java/com/google/cloud/bigtable/data/v2/stub/metrics/Util.java @@ -16,6 +16,7 @@ package com.google.cloud.bigtable.data.v2.stub.metrics; import com.google.api.core.InternalApi; +import com.google.api.gax.grpc.GrpcResponseMetadata; import com.google.api.gax.rpc.ApiCallContext; import com.google.api.gax.rpc.ApiException; import com.google.api.gax.rpc.StatusCode; @@ -25,10 +26,12 @@ import com.google.bigtable.v2.MutateRowsRequest; import com.google.bigtable.v2.ReadModifyWriteRowRequest; import com.google.bigtable.v2.ReadRowsRequest; +import com.google.bigtable.v2.ResponseParams; import com.google.bigtable.v2.SampleRowKeysRequest; import com.google.bigtable.v2.TableName; import com.google.common.base.Strings; import com.google.common.collect.ImmutableMap; +import com.google.protobuf.InvalidProtocolBufferException; import io.grpc.Metadata; import io.grpc.Status; import io.grpc.StatusException; @@ -57,7 +60,7 @@ public class Util { private static final Metadata.Key SERVER_TIMING_HEADER_KEY = Metadata.Key.of("server-timing", Metadata.ASCII_STRING_MARSHALLER); private static final Pattern SERVER_TIMING_HEADER_PATTERN = Pattern.compile(".*dur=(?\\d+)"); - static final Metadata.Key METADATA_KEY = + static final Metadata.Key LOCATION_METADATA_KEY = Metadata.Key.of("x-goog-ext-425905942-bin", Metadata.BINARY_BYTE_MARSHALLER); /** Convert an exception into a value that can be used to create an OpenCensus tag value. */ @@ -136,16 +139,62 @@ static Map> createStatsHeaders(ApiCallContext apiCallContex return headers.build(); } - static Long getGfeLatency(Metadata metadata) { - if (metadata != null && metadata.get(SERVER_TIMING_HEADER_KEY) != null) { - String serverTiming = metadata.get(SERVER_TIMING_HEADER_KEY); - Matcher matcher = SERVER_TIMING_HEADER_PATTERN.matcher(serverTiming); - // this should always be true - if (matcher.find()) { - long latency = Long.valueOf(matcher.group("dur")); - return latency; + private static Long getGfeLatency(@Nullable Metadata metadata) { + if (metadata == null) { + return null; + } + String serverTiming = metadata.get(SERVER_TIMING_HEADER_KEY); + if (serverTiming == null) { + return null; + } + Matcher matcher = SERVER_TIMING_HEADER_PATTERN.matcher(serverTiming); + // this should always be true + if (matcher.find()) { + long latency = Long.valueOf(matcher.group("dur")); + return latency; + } + return null; + } + + private static ResponseParams getResponseParams(@Nullable Metadata metadata) { + if (metadata == null) { + return null; + } + byte[] responseParams = metadata.get(Util.LOCATION_METADATA_KEY); + if (responseParams != null) { + try { + return ResponseParams.parseFrom(responseParams); + } catch (InvalidProtocolBufferException e) { } } return null; } + + static void recordMetricsFromMetadata( + GrpcResponseMetadata responseMetadata, BigtableTracer tracer, Throwable throwable) { + Metadata metadata = responseMetadata.getMetadata(); + + // Get the response params from the metadata. Check both headers and trailers + // because in different environments the metadata could be returned in headers or trailers + @Nullable ResponseParams responseParams = getResponseParams(responseMetadata.getMetadata()); + if (responseParams == null) { + responseParams = getResponseParams(responseMetadata.getTrailingMetadata()); + } + // Set tracer locations if response params is not null + if (responseParams != null) { + tracer.setLocations(responseParams.getZoneId(), responseParams.getClusterId()); + } + + // server-timing metric will be added through GrpcResponseMetadata#onHeaders(Metadata), + // so it's not checking trailing metadata here. + @Nullable Long latency = getGfeLatency(metadata); + // For direct path, we won't see GFE server-timing header. However, if we received the + // location info, we know that there isn't a connectivity issue. Set the latency to + // 0 so gfe missing header won't get incremented. + if (responseParams != null && latency == null) { + latency = 0L; + } + // Record gfe metrics + tracer.recordGfeMetadata(latency, throwable); + } } diff --git a/google-cloud-bigtable/src/main/java/com/google/cloud/bigtable/data/v2/stub/readrows/FilterMarkerRowsCallable.java b/google-cloud-bigtable/src/main/java/com/google/cloud/bigtable/data/v2/stub/readrows/FilterMarkerRowsCallable.java index 57f987fb7c..181006b6c3 100644 --- a/google-cloud-bigtable/src/main/java/com/google/cloud/bigtable/data/v2/stub/readrows/FilterMarkerRowsCallable.java +++ b/google-cloud-bigtable/src/main/java/com/google/cloud/bigtable/data/v2/stub/readrows/FilterMarkerRowsCallable.java @@ -22,6 +22,7 @@ import com.google.api.gax.rpc.StreamController; import com.google.bigtable.v2.ReadRowsRequest; import com.google.cloud.bigtable.data.v2.models.RowAdapter; +import com.google.cloud.bigtable.data.v2.stub.SafeResponseObserver; /** * Remove the special marker rows generated by {@link RowMergingCallable}. @@ -47,17 +48,18 @@ public void call( innerCallable.call(request, innerObserver, context); } - private class FilteringResponseObserver implements ResponseObserver { + private class FilteringResponseObserver extends SafeResponseObserver { private final ResponseObserver outerObserver; private StreamController innerController; private boolean autoFlowControl = true; FilteringResponseObserver(ResponseObserver outerObserver) { + super(outerObserver); this.outerObserver = outerObserver; } @Override - public void onStart(final StreamController controller) { + protected void onStartImpl(final StreamController controller) { innerController = controller; outerObserver.onStart( @@ -81,7 +83,7 @@ public void request(int count) { } @Override - public void onResponse(RowT response) { + protected void onResponseImpl(RowT response) { if (rowAdapter.isScanMarkerRow(response)) { if (!autoFlowControl) { innerController.request(1); @@ -92,12 +94,12 @@ public void onResponse(RowT response) { } @Override - public void onError(Throwable t) { + protected void onErrorImpl(Throwable t) { outerObserver.onError(t); } @Override - public void onComplete() { + protected void onCompleteImpl() { outerObserver.onComplete(); } } diff --git a/google-cloud-bigtable/src/main/java/com/google/cloud/bigtable/gaxx/reframing/ReframingResponseObserver.java b/google-cloud-bigtable/src/main/java/com/google/cloud/bigtable/gaxx/reframing/ReframingResponseObserver.java index c46eb55ff9..6f2440fff7 100644 --- a/google-cloud-bigtable/src/main/java/com/google/cloud/bigtable/gaxx/reframing/ReframingResponseObserver.java +++ b/google-cloud-bigtable/src/main/java/com/google/cloud/bigtable/gaxx/reframing/ReframingResponseObserver.java @@ -17,8 +17,8 @@ import com.google.api.core.InternalApi; import com.google.api.gax.rpc.ResponseObserver; -import com.google.api.gax.rpc.StateCheckingResponseObserver; import com.google.api.gax.rpc.StreamController; +import com.google.cloud.bigtable.data.v2.stub.SafeResponseObserver; import com.google.common.base.Preconditions; import com.google.common.math.IntMath; import java.util.concurrent.CancellationException; @@ -56,8 +56,7 @@ * }
*/ @InternalApi -public class ReframingResponseObserver - extends StateCheckingResponseObserver { +public class ReframingResponseObserver extends SafeResponseObserver { // Used as a nonblocking mutex for deliver(). // 0 means unlocked // 1 means locked without contention @@ -97,6 +96,7 @@ public class ReframingResponseObserver public ReframingResponseObserver( ResponseObserver observer, Reframer reframer) { + super(observer); this.outerResponseObserver = observer; this.reframer = reframer; } diff --git a/google-cloud-bigtable/src/test/java/com/google/cloud/bigtable/admin/v2/BaseBigtableInstanceAdminClientTest.java b/google-cloud-bigtable/src/test/java/com/google/cloud/bigtable/admin/v2/BaseBigtableInstanceAdminClientTest.java index 26cbcf77cd..9717021f5d 100644 --- a/google-cloud-bigtable/src/test/java/com/google/cloud/bigtable/admin/v2/BaseBigtableInstanceAdminClientTest.java +++ b/google-cloud-bigtable/src/test/java/com/google/cloud/bigtable/admin/v2/BaseBigtableInstanceAdminClientTest.java @@ -137,6 +137,7 @@ public void createInstanceTest() throws Exception { .setDisplayName("displayName1714148973") .putAllLabels(new HashMap()) .setCreateTime(Timestamp.newBuilder().build()) + .setSatisfiesPzs(true) .build(); Operation resultOperation = Operation.newBuilder() @@ -196,6 +197,7 @@ public void createInstanceTest2() throws Exception { .setDisplayName("displayName1714148973") .putAllLabels(new HashMap()) .setCreateTime(Timestamp.newBuilder().build()) + .setSatisfiesPzs(true) .build(); Operation resultOperation = Operation.newBuilder() @@ -255,6 +257,7 @@ public void getInstanceTest() throws Exception { .setDisplayName("displayName1714148973") .putAllLabels(new HashMap()) .setCreateTime(Timestamp.newBuilder().build()) + .setSatisfiesPzs(true) .build(); mockBigtableInstanceAdmin.addResponse(expectedResponse); @@ -296,6 +299,7 @@ public void getInstanceTest2() throws Exception { .setDisplayName("displayName1714148973") .putAllLabels(new HashMap()) .setCreateTime(Timestamp.newBuilder().build()) + .setSatisfiesPzs(true) .build(); mockBigtableInstanceAdmin.addResponse(expectedResponse); @@ -417,6 +421,7 @@ public void updateInstanceTest() throws Exception { .setDisplayName("displayName1714148973") .putAllLabels(new HashMap()) .setCreateTime(Timestamp.newBuilder().build()) + .setSatisfiesPzs(true) .build(); mockBigtableInstanceAdmin.addResponse(expectedResponse); @@ -426,6 +431,7 @@ public void updateInstanceTest() throws Exception { .setDisplayName("displayName1714148973") .putAllLabels(new HashMap()) .setCreateTime(Timestamp.newBuilder().build()) + .setSatisfiesPzs(true) .build(); Instance actualResponse = client.updateInstance(request); @@ -441,6 +447,7 @@ public void updateInstanceTest() throws Exception { Assert.assertEquals(request.getType(), actualRequest.getType()); Assert.assertEquals(request.getLabelsMap(), actualRequest.getLabelsMap()); Assert.assertEquals(request.getCreateTime(), actualRequest.getCreateTime()); + Assert.assertEquals(request.getSatisfiesPzs(), actualRequest.getSatisfiesPzs()); Assert.assertTrue( channelProvider.isHeaderSent( ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), @@ -459,6 +466,7 @@ public void updateInstanceExceptionTest() throws Exception { .setDisplayName("displayName1714148973") .putAllLabels(new HashMap()) .setCreateTime(Timestamp.newBuilder().build()) + .setSatisfiesPzs(true) .build(); client.updateInstance(request); Assert.fail("No exception raised"); @@ -475,6 +483,7 @@ public void partialUpdateInstanceTest() throws Exception { .setDisplayName("displayName1714148973") .putAllLabels(new HashMap()) .setCreateTime(Timestamp.newBuilder().build()) + .setSatisfiesPzs(true) .build(); Operation resultOperation = Operation.newBuilder() diff --git a/google-cloud-bigtable/src/test/java/com/google/cloud/bigtable/admin/v2/BaseBigtableTableAdminClientTest.java b/google-cloud-bigtable/src/test/java/com/google/cloud/bigtable/admin/v2/BaseBigtableTableAdminClientTest.java index e0ee12fa12..6a79402f73 100644 --- a/google-cloud-bigtable/src/test/java/com/google/cloud/bigtable/admin/v2/BaseBigtableTableAdminClientTest.java +++ b/google-cloud-bigtable/src/test/java/com/google/cloud/bigtable/admin/v2/BaseBigtableTableAdminClientTest.java @@ -65,6 +65,7 @@ import com.google.bigtable.admin.v2.TableName; import com.google.bigtable.admin.v2.UndeleteTableRequest; import com.google.bigtable.admin.v2.UpdateBackupRequest; +import com.google.bigtable.admin.v2.UpdateTableRequest; import com.google.common.collect.Lists; import com.google.iam.v1.AuditConfig; import com.google.iam.v1.Binding; @@ -142,6 +143,7 @@ public void createTableTest() throws Exception { .putAllClusterStates(new HashMap()) .putAllColumnFamilies(new HashMap()) .setRestoreInfo(RestoreInfo.newBuilder().build()) + .setDeletionProtection(true) .build(); mockBigtableTableAdmin.addResponse(expectedResponse); @@ -189,6 +191,7 @@ public void createTableTest2() throws Exception { .putAllClusterStates(new HashMap()) .putAllColumnFamilies(new HashMap()) .setRestoreInfo(RestoreInfo.newBuilder().build()) + .setDeletionProtection(true) .build(); mockBigtableTableAdmin.addResponse(expectedResponse); @@ -236,6 +239,7 @@ public void createTableFromSnapshotTest() throws Exception { .putAllClusterStates(new HashMap()) .putAllColumnFamilies(new HashMap()) .setRestoreInfo(RestoreInfo.newBuilder().build()) + .setDeletionProtection(true) .build(); Operation resultOperation = Operation.newBuilder() @@ -295,6 +299,7 @@ public void createTableFromSnapshotTest2() throws Exception { .putAllClusterStates(new HashMap()) .putAllColumnFamilies(new HashMap()) .setRestoreInfo(RestoreInfo.newBuilder().build()) + .setDeletionProtection(true) .build(); Operation resultOperation = Operation.newBuilder() @@ -352,6 +357,7 @@ public void createTableFromSnapshotTest3() throws Exception { .putAllClusterStates(new HashMap()) .putAllColumnFamilies(new HashMap()) .setRestoreInfo(RestoreInfo.newBuilder().build()) + .setDeletionProtection(true) .build(); Operation resultOperation = Operation.newBuilder() @@ -411,6 +417,7 @@ public void createTableFromSnapshotTest4() throws Exception { .putAllClusterStates(new HashMap()) .putAllColumnFamilies(new HashMap()) .setRestoreInfo(RestoreInfo.newBuilder().build()) + .setDeletionProtection(true) .build(); Operation resultOperation = Operation.newBuilder() @@ -556,6 +563,7 @@ public void getTableTest() throws Exception { .putAllClusterStates(new HashMap()) .putAllColumnFamilies(new HashMap()) .setRestoreInfo(RestoreInfo.newBuilder().build()) + .setDeletionProtection(true) .build(); mockBigtableTableAdmin.addResponse(expectedResponse); @@ -597,6 +605,7 @@ public void getTableTest2() throws Exception { .putAllClusterStates(new HashMap()) .putAllColumnFamilies(new HashMap()) .setRestoreInfo(RestoreInfo.newBuilder().build()) + .setDeletionProtection(true) .build(); mockBigtableTableAdmin.addResponse(expectedResponse); @@ -630,6 +639,59 @@ public void getTableExceptionTest2() throws Exception { } } + @Test + public void updateTableTest() throws Exception { + Table expectedResponse = + Table.newBuilder() + .setName(TableName.of("[PROJECT]", "[INSTANCE]", "[TABLE]").toString()) + .putAllClusterStates(new HashMap()) + .putAllColumnFamilies(new HashMap()) + .setRestoreInfo(RestoreInfo.newBuilder().build()) + .setDeletionProtection(true) + .build(); + Operation resultOperation = + Operation.newBuilder() + .setName("updateTableTest") + .setDone(true) + .setResponse(Any.pack(expectedResponse)) + .build(); + mockBigtableTableAdmin.addResponse(resultOperation); + + Table table = Table.newBuilder().build(); + FieldMask updateMask = FieldMask.newBuilder().build(); + + Table actualResponse = client.updateTableAsync(table, updateMask).get(); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockBigtableTableAdmin.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + UpdateTableRequest actualRequest = ((UpdateTableRequest) actualRequests.get(0)); + + Assert.assertEquals(table, actualRequest.getTable()); + Assert.assertEquals(updateMask, actualRequest.getUpdateMask()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void updateTableExceptionTest() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockBigtableTableAdmin.addException(exception); + + try { + Table table = Table.newBuilder().build(); + FieldMask updateMask = FieldMask.newBuilder().build(); + client.updateTableAsync(table, updateMask).get(); + Assert.fail("No exception raised"); + } catch (ExecutionException e) { + Assert.assertEquals(InvalidArgumentException.class, e.getCause().getClass()); + InvalidArgumentException apiException = ((InvalidArgumentException) e.getCause()); + Assert.assertEquals(StatusCode.Code.INVALID_ARGUMENT, apiException.getStatusCode().getCode()); + } + } + @Test public void deleteTableTest() throws Exception { Empty expectedResponse = Empty.newBuilder().build(); @@ -706,6 +768,7 @@ public void undeleteTableTest() throws Exception { .putAllClusterStates(new HashMap()) .putAllColumnFamilies(new HashMap()) .setRestoreInfo(RestoreInfo.newBuilder().build()) + .setDeletionProtection(true) .build(); Operation resultOperation = Operation.newBuilder() @@ -755,6 +818,7 @@ public void undeleteTableTest2() throws Exception { .putAllClusterStates(new HashMap()) .putAllColumnFamilies(new HashMap()) .setRestoreInfo(RestoreInfo.newBuilder().build()) + .setDeletionProtection(true) .build(); Operation resultOperation = Operation.newBuilder() @@ -804,6 +868,7 @@ public void modifyColumnFamiliesTest() throws Exception { .putAllClusterStates(new HashMap()) .putAllColumnFamilies(new HashMap()) .setRestoreInfo(RestoreInfo.newBuilder().build()) + .setDeletionProtection(true) .build(); mockBigtableTableAdmin.addResponse(expectedResponse); @@ -849,6 +914,7 @@ public void modifyColumnFamiliesTest2() throws Exception { .putAllClusterStates(new HashMap()) .putAllColumnFamilies(new HashMap()) .setRestoreInfo(RestoreInfo.newBuilder().build()) + .setDeletionProtection(true) .build(); mockBigtableTableAdmin.addResponse(expectedResponse); @@ -1992,6 +2058,7 @@ public void restoreTableTest() throws Exception { .putAllClusterStates(new HashMap()) .putAllColumnFamilies(new HashMap()) .setRestoreInfo(RestoreInfo.newBuilder().build()) + .setDeletionProtection(true) .build(); Operation resultOperation = Operation.newBuilder() diff --git a/google-cloud-bigtable/src/test/java/com/google/cloud/bigtable/admin/v2/BigtableTableAdminClientTests.java b/google-cloud-bigtable/src/test/java/com/google/cloud/bigtable/admin/v2/BigtableTableAdminClientTests.java index f3d2261869..a5ada34be5 100644 --- a/google-cloud-bigtable/src/test/java/com/google/cloud/bigtable/admin/v2/BigtableTableAdminClientTests.java +++ b/google-cloud-bigtable/src/test/java/com/google/cloud/bigtable/admin/v2/BigtableTableAdminClientTests.java @@ -613,6 +613,54 @@ public void testRestoreTable() throws ExecutionException, InterruptedException { assertThat(actualResult.getTable().getId()).isEqualTo(TABLE_ID); } + @Test + public void testRestoreTableCrossProject() throws ExecutionException, InterruptedException { + // Setup + Mockito.when(mockStub.restoreTableOperationCallable()) + .thenReturn(mockRestoreTableOperationCallable); + + Timestamp startTime = Timestamp.newBuilder().setSeconds(1234).build(); + Timestamp endTime = Timestamp.newBuilder().setSeconds(5678).build(); + String operationName = "my-operation"; + + // Use existing adminClient as destination project: + String dstProjectId = PROJECT_ID; + String dstInstanceId = INSTANCE_ID; + String dstTableName = TABLE_NAME; + + // Create RestoreTableRequest from different source project: + String srcProjectId = "src-project"; + String srcInstanceId = "src-instance"; + String srcClusterId = "src-cluster"; + + RestoreTableRequest req = + RestoreTableRequest.of(srcInstanceId, srcClusterId, BACKUP_ID, srcProjectId) + .setTableId(TABLE_ID); + mockOperationResult( + mockRestoreTableOperationCallable, + req.toProto(dstProjectId, dstInstanceId), + com.google.bigtable.admin.v2.Table.newBuilder().setName(dstTableName).build(), + RestoreTableMetadata.newBuilder() + .setName(dstTableName) + .setOptimizeTableOperationName(operationName) + .setSourceType(RestoreSourceType.BACKUP) + .setBackupInfo( + BackupInfo.newBuilder() + .setBackup(BACKUP_ID) + .setSourceTable(NameUtil.formatTableName(srcProjectId, srcInstanceId, TABLE_ID)) + .setStartTime(startTime) + .setEndTime(endTime) + .build()) + .build()); + + // Execute + RestoredTableResult actualResult = adminClient.restoreTable(req); + + // Verify + assertThat(actualResult.getTable().getId()).isEqualTo(TABLE_ID); + assertThat(actualResult.getTable().getInstanceId()).isEqualTo(dstInstanceId); + } + @Test public void testDeleteBackup() { // Setup diff --git a/google-cloud-bigtable/src/test/java/com/google/cloud/bigtable/admin/v2/BigtableTableAdminSettingsTest.java b/google-cloud-bigtable/src/test/java/com/google/cloud/bigtable/admin/v2/BigtableTableAdminSettingsTest.java index 28038d1db4..1aacb7f606 100644 --- a/google-cloud-bigtable/src/test/java/com/google/cloud/bigtable/admin/v2/BigtableTableAdminSettingsTest.java +++ b/google-cloud-bigtable/src/test/java/com/google/cloud/bigtable/admin/v2/BigtableTableAdminSettingsTest.java @@ -134,7 +134,9 @@ public void testStubSettings() throws IOException { "restoreTableSettings", "restoreTableOperationSettings", "undeleteTableSettings", - "undeleteTableOperationSettings" + "undeleteTableOperationSettings", + "updateTableSettings", + "updateTableOperationSettings" }; @Test @@ -184,6 +186,6 @@ void checkToString(BigtableTableAdminSettings settings) { for (String subSettings : SETTINGS_LIST) { assertThat(toString).contains(subSettings + "="); } - assertThat(toString.contains(settings.getStubSettings().toString())); + assertThat(toString).contains(settings.getStubSettings().toString()); } } diff --git a/google-cloud-bigtable/src/test/java/com/google/cloud/bigtable/admin/v2/MockBigtableTableAdminImpl.java b/google-cloud-bigtable/src/test/java/com/google/cloud/bigtable/admin/v2/MockBigtableTableAdminImpl.java index f33b96aea4..211197811a 100644 --- a/google-cloud-bigtable/src/test/java/com/google/cloud/bigtable/admin/v2/MockBigtableTableAdminImpl.java +++ b/google-cloud-bigtable/src/test/java/com/google/cloud/bigtable/admin/v2/MockBigtableTableAdminImpl.java @@ -46,6 +46,7 @@ import com.google.bigtable.admin.v2.Table; import com.google.bigtable.admin.v2.UndeleteTableRequest; import com.google.bigtable.admin.v2.UpdateBackupRequest; +import com.google.bigtable.admin.v2.UpdateTableRequest; import com.google.iam.v1.GetIamPolicyRequest; import com.google.iam.v1.Policy; import com.google.iam.v1.SetIamPolicyRequest; @@ -175,6 +176,26 @@ public void getTable(GetTableRequest request, StreamObserver responseObse } } + @Override + public void updateTable(UpdateTableRequest request, StreamObserver responseObserver) { + Object response = responses.poll(); + if (response instanceof Operation) { + requests.add(request); + responseObserver.onNext(((Operation) response)); + responseObserver.onCompleted(); + } else if (response instanceof Exception) { + responseObserver.onError(((Exception) response)); + } else { + responseObserver.onError( + new IllegalArgumentException( + String.format( + "Unrecognized response type %s for method UpdateTable, expected %s or %s", + response == null ? "null" : response.getClass().getName(), + Operation.class.getName(), + Exception.class.getName()))); + } + } + @Override public void deleteTable(DeleteTableRequest request, StreamObserver responseObserver) { Object response = responses.poll(); diff --git a/google-cloud-bigtable/src/test/java/com/google/cloud/bigtable/admin/v2/models/RestoreTableRequestTest.java b/google-cloud-bigtable/src/test/java/com/google/cloud/bigtable/admin/v2/models/RestoreTableRequestTest.java index 232902f585..30a2274c7e 100644 --- a/google-cloud-bigtable/src/test/java/com/google/cloud/bigtable/admin/v2/models/RestoreTableRequestTest.java +++ b/google-cloud-bigtable/src/test/java/com/google/cloud/bigtable/admin/v2/models/RestoreTableRequestTest.java @@ -31,6 +31,7 @@ public class RestoreTableRequestTest { private static final String INSTANCE_ID = "my-instance"; private static final String CLUSTER_ID = "my-cluster"; private static final String SOURCE_INSTANCE_ID = "source-instance-id"; + private static final String SOURCE_PROJECT_ID = "source-project-id"; @Test public void testToProto() { @@ -61,6 +62,23 @@ public void testToProtoCrossInstance() { assertThat(request.toProto(PROJECT_ID, INSTANCE_ID)).isEqualTo(requestProto); } + @Test + public void testToProtoCrossProject() { + RestoreTableRequest request = + RestoreTableRequest.of(SOURCE_INSTANCE_ID, CLUSTER_ID, BACKUP_ID, SOURCE_PROJECT_ID) + .setTableId(TABLE_ID); + + com.google.bigtable.admin.v2.RestoreTableRequest requestProto = + com.google.bigtable.admin.v2.RestoreTableRequest.newBuilder() + .setParent(NameUtil.formatInstanceName(PROJECT_ID, INSTANCE_ID)) + .setBackup( + NameUtil.formatBackupName( + SOURCE_PROJECT_ID, SOURCE_INSTANCE_ID, CLUSTER_ID, BACKUP_ID)) + .setTableId(TABLE_ID) + .build(); + assertThat(request.toProto(PROJECT_ID, INSTANCE_ID)).isEqualTo(requestProto); + } + @Test public void testEquality() { RestoreTableRequest request = @@ -88,6 +106,24 @@ public void testEqualityCrossInstance() { .setTableId("another-table")); } + @Test + public void testEqualityCrossProject() { + RestoreTableRequest request = + RestoreTableRequest.of(SOURCE_INSTANCE_ID, CLUSTER_ID, BACKUP_ID, SOURCE_PROJECT_ID) + .setTableId(TABLE_ID); + + assertThat(request) + .isEqualTo( + RestoreTableRequest.of(SOURCE_INSTANCE_ID, CLUSTER_ID, BACKUP_ID, SOURCE_PROJECT_ID) + .setTableId(TABLE_ID)); + assertThat(request) + .isNotEqualTo(RestoreTableRequest.of(CLUSTER_ID, BACKUP_ID).setTableId(TABLE_ID)); + assertThat(request) + .isNotEqualTo( + RestoreTableRequest.of(SOURCE_INSTANCE_ID, CLUSTER_ID, BACKUP_ID, SOURCE_PROJECT_ID) + .setTableId("another-table")); + } + @Test public void testHashCode() { RestoreTableRequest request = @@ -117,4 +153,24 @@ public void testHashCodeCrossInstance() { .setTableId("another-table") .hashCode()); } + + @Test + public void testHashCodeCrossProject() { + RestoreTableRequest request = + RestoreTableRequest.of(SOURCE_INSTANCE_ID, CLUSTER_ID, BACKUP_ID, SOURCE_PROJECT_ID) + .setTableId(TABLE_ID); + assertThat(request.hashCode()) + .isEqualTo( + RestoreTableRequest.of(SOURCE_INSTANCE_ID, CLUSTER_ID, BACKUP_ID, SOURCE_PROJECT_ID) + .setTableId(TABLE_ID) + .hashCode()); + assertThat(request.hashCode()) + .isNotEqualTo( + RestoreTableRequest.of(CLUSTER_ID, BACKUP_ID).setTableId(TABLE_ID).hashCode()); + assertThat(request.hashCode()) + .isNotEqualTo( + RestoreTableRequest.of(SOURCE_INSTANCE_ID, CLUSTER_ID, BACKUP_ID, SOURCE_PROJECT_ID) + .setTableId("another-table") + .hashCode()); + } } diff --git a/google-cloud-bigtable/src/test/java/com/google/cloud/bigtable/data/v2/internal/RowMergerUtilTest.java b/google-cloud-bigtable/src/test/java/com/google/cloud/bigtable/data/v2/internal/RowMergerUtilTest.java new file mode 100644 index 0000000000..a734ea068a --- /dev/null +++ b/google-cloud-bigtable/src/test/java/com/google/cloud/bigtable/data/v2/internal/RowMergerUtilTest.java @@ -0,0 +1,148 @@ +/* + * Copyright 2022 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. + */ +package com.google.cloud.bigtable.data.v2.internal; + +import static com.google.common.truth.Truth.assertThat; + +import com.google.bigtable.v2.ReadRowsResponse; +import com.google.bigtable.v2.ReadRowsResponse.CellChunk; +import com.google.cloud.bigtable.data.v2.models.Row; +import com.google.cloud.bigtable.data.v2.models.RowCell; +import com.google.common.collect.ImmutableList; +import com.google.protobuf.ByteString; +import com.google.protobuf.BytesValue; +import com.google.protobuf.StringValue; +import java.util.List; +import junit.framework.TestCase; +import org.junit.Assert; +import org.junit.Test; +import org.junit.runner.RunWith; +import org.junit.runners.JUnit4; + +@RunWith(JUnit4.class) +public class RowMergerUtilTest extends TestCase { + + @Test + public void testEmpty() { + try (RowMergerUtil util = new RowMergerUtil()) {} + + try (RowMergerUtil util = new RowMergerUtil()) { + util.parseReadRowsResponses(ImmutableList.of()); + } + } + + @Test + public void testSingle() { + List responses = + ImmutableList.of( + ReadRowsResponse.newBuilder() + .addChunks( + CellChunk.newBuilder() + .setRowKey(ByteString.copyFromUtf8("key")) + .setFamilyName(StringValue.newBuilder().setValue("family")) + .setQualifier( + BytesValue.newBuilder().setValue(ByteString.copyFromUtf8("qualifier"))) + .setTimestampMicros(1000) + .setValue(ByteString.copyFromUtf8("value")) + .setCommitRow(true)) + .build()); + try (RowMergerUtil util = new RowMergerUtil()) { + List rows = util.parseReadRowsResponses(responses); + assertThat(rows) + .containsExactly( + Row.create( + ByteString.copyFromUtf8("key"), + ImmutableList.of( + RowCell.create( + "family", + ByteString.copyFromUtf8("qualifier"), + 1000, + ImmutableList.of(), + ByteString.copyFromUtf8("value"))))); + } + } + + @Test + public void testMultiple() { + List responses = + ImmutableList.of( + ReadRowsResponse.newBuilder() + .addChunks( + CellChunk.newBuilder() + .setRowKey(ByteString.copyFromUtf8("key")) + .setFamilyName(StringValue.newBuilder().setValue("family")) + .setQualifier( + BytesValue.newBuilder().setValue(ByteString.copyFromUtf8("qualifier"))) + .setTimestampMicros(1000) + .setValue(ByteString.copyFromUtf8("value")) + .setCommitRow(true)) + .build(), + ReadRowsResponse.newBuilder() + .addChunks( + CellChunk.newBuilder() + .setRowKey(ByteString.copyFromUtf8("key2")) + .setFamilyName(StringValue.newBuilder().setValue("family")) + .setQualifier( + BytesValue.newBuilder().setValue(ByteString.copyFromUtf8("qualifier"))) + .setTimestampMicros(1000) + .setValue(ByteString.copyFromUtf8("value")) + .setCommitRow(true)) + .build()); + try (RowMergerUtil util = new RowMergerUtil()) { + assertThat(util.parseReadRowsResponses(responses)) + .containsExactly( + Row.create( + ByteString.copyFromUtf8("key"), + ImmutableList.of( + RowCell.create( + "family", + ByteString.copyFromUtf8("qualifier"), + 1000, + ImmutableList.of(), + ByteString.copyFromUtf8("value")))), + Row.create( + ByteString.copyFromUtf8("key2"), + ImmutableList.of( + RowCell.create( + "family", + ByteString.copyFromUtf8("qualifier"), + 1000, + ImmutableList.of(), + ByteString.copyFromUtf8("value"))))); + } + } + + @Test + public void testPartial() { + List responses = + ImmutableList.of( + ReadRowsResponse.newBuilder() + .addChunks( + CellChunk.newBuilder() + .setRowKey(ByteString.copyFromUtf8("key")) + .setFamilyName(StringValue.newBuilder().setValue("family")) + .setQualifier( + BytesValue.newBuilder().setValue(ByteString.copyFromUtf8("qualifier"))) + .setTimestampMicros(1000) + .setValue(ByteString.copyFromUtf8("value")) + .setCommitRow(false)) + .build()); + + RowMergerUtil util = new RowMergerUtil(); + util.parseReadRowsResponses(responses); + Assert.assertThrows(IllegalStateException.class, util::close); + } +} diff --git a/google-cloud-bigtable/src/test/java/com/google/cloud/bigtable/data/v2/it/BuiltinMetricsIT.java b/google-cloud-bigtable/src/test/java/com/google/cloud/bigtable/data/v2/it/BuiltinMetricsIT.java index 76c2adfb52..e55f3a160d 100644 --- a/google-cloud-bigtable/src/test/java/com/google/cloud/bigtable/data/v2/it/BuiltinMetricsIT.java +++ b/google-cloud-bigtable/src/test/java/com/google/cloud/bigtable/data/v2/it/BuiltinMetricsIT.java @@ -48,10 +48,9 @@ public class BuiltinMetricsIT { public static String[] VIEWS = { "operation_latencies", - "retry_count", "attempt_latencies", "connectivity_error_count", - "application_latencies" + "application_blocking_latencies" }; @BeforeClass @@ -125,9 +124,9 @@ public void testBuiltinMetrics() throws Exception { // Verify that metrics are published for ReadRows request metricFilter = String.format( - "metric.type=\"bigtable.googleapis.com/client/operation_latencies\" " + "metric.type=\"bigtable.googleapis.com/client/%s\" " + "AND resource.labels.instance=\"%s\" AND metric.labels.method=\"Bigtable.ReadRows\"", - testEnvRule.env().getInstanceId()); + view, testEnvRule.env().getInstanceId()); requestBuilder.setFilter(metricFilter); response = metricClient.listTimeSeriesCallable().call(requestBuilder.build()); assertThat(response.getTimeSeriesCount()).isGreaterThan(0); diff --git a/google-cloud-bigtable/src/test/java/com/google/cloud/bigtable/data/v2/models/QueryTest.java b/google-cloud-bigtable/src/test/java/com/google/cloud/bigtable/data/v2/models/QueryTest.java index ccb0441c71..655aeda688 100644 --- a/google-cloud-bigtable/src/test/java/com/google/cloud/bigtable/data/v2/models/QueryTest.java +++ b/google-cloud-bigtable/src/test/java/com/google/cloud/bigtable/data/v2/models/QueryTest.java @@ -327,4 +327,182 @@ public void testClone() { assertThat(clonedReq).isEqualTo(query); assertThat(clonedReq.toProto(requestContext)).isEqualTo(request); } + + @Test + public void testQueryPaginatorRangeLimitReached() { + int chunkSize = 10, limit = 15; + Query query = Query.create(TABLE_ID).range("a", "z").limit(limit); + Query.QueryPaginator paginator = query.createPaginator(chunkSize); + + Query nextQuery = paginator.getNextQuery(); + + Builder expectedProto = + expectedProtoBuilder() + .setRows( + RowSet.newBuilder() + .addRowRanges( + RowRange.newBuilder() + .setStartKeyClosed(ByteString.copyFromUtf8("a")) + .setEndKeyOpen(ByteString.copyFromUtf8("z")) + .build())) + .setRowsLimit(chunkSize); + assertThat(nextQuery.toProto(requestContext)).isEqualTo(expectedProto.build()); + + assertThat(paginator.advance(ByteString.copyFromUtf8("c"))).isTrue(); + int expectedLimit = limit - chunkSize; + nextQuery = paginator.getNextQuery(); + expectedProto = + expectedProtoBuilder() + .setRows( + RowSet.newBuilder() + .addRowRanges( + RowRange.newBuilder() + .setStartKeyOpen(ByteString.copyFromUtf8("c")) + .setEndKeyOpen(ByteString.copyFromUtf8("z")) + .build())) + .setRowsLimit(expectedLimit); + assertThat(nextQuery.toProto(requestContext)).isEqualTo(expectedProto.build()); + + assertThat(paginator.advance(ByteString.copyFromUtf8("d"))).isFalse(); + } + + @Test + public void testQueryPaginatorRangeLimitMultiplyOfChunkSize() { + int chunkSize = 10, limit = 20; + Query query = Query.create(TABLE_ID).range("a", "z").limit(limit); + Query.QueryPaginator paginator = query.createPaginator(chunkSize); + + Query nextQuery = paginator.getNextQuery(); + + Builder expectedProto = + expectedProtoBuilder() + .setRows( + RowSet.newBuilder() + .addRowRanges( + RowRange.newBuilder() + .setStartKeyClosed(ByteString.copyFromUtf8("a")) + .setEndKeyOpen(ByteString.copyFromUtf8("z")) + .build())) + .setRowsLimit(chunkSize); + assertThat(nextQuery.toProto(requestContext)).isEqualTo(expectedProto.build()); + + assertThat(paginator.advance(ByteString.copyFromUtf8("c"))).isTrue(); + int expectedLimit = limit - chunkSize; + nextQuery = paginator.getNextQuery(); + expectedProto = + expectedProtoBuilder() + .setRows( + RowSet.newBuilder() + .addRowRanges( + RowRange.newBuilder() + .setStartKeyOpen(ByteString.copyFromUtf8("c")) + .setEndKeyOpen(ByteString.copyFromUtf8("z")) + .build())) + .setRowsLimit(expectedLimit); + assertThat(nextQuery.toProto(requestContext)).isEqualTo(expectedProto.build()); + + assertThat(paginator.advance(ByteString.copyFromUtf8("d"))).isFalse(); + } + + @Test + public void testQueryPaginatorRagneNoLimit() { + int chunkSize = 10; + Query query = Query.create(TABLE_ID).range("a", "z"); + Query.QueryPaginator paginator = query.createPaginator(chunkSize); + + Query nextQuery = paginator.getNextQuery(); + + Builder expectedProto = + expectedProtoBuilder() + .setRows( + RowSet.newBuilder() + .addRowRanges( + RowRange.newBuilder() + .setStartKeyClosed(ByteString.copyFromUtf8("a")) + .setEndKeyOpen(ByteString.copyFromUtf8("z")) + .build())) + .setRowsLimit(chunkSize); + assertThat(nextQuery.toProto(requestContext)).isEqualTo(expectedProto.build()); + + assertThat(paginator.advance(ByteString.copyFromUtf8("c"))).isTrue(); + nextQuery = paginator.getNextQuery(); + expectedProto + .setRows( + RowSet.newBuilder() + .addRowRanges( + RowRange.newBuilder() + .setStartKeyOpen(ByteString.copyFromUtf8("c")) + .setEndKeyOpen(ByteString.copyFromUtf8("z")) + .build())) + .setRowsLimit(chunkSize); + assertThat(nextQuery.toProto(requestContext)).isEqualTo(expectedProto.build()); + + assertThat(paginator.advance(ByteString.copyFromUtf8("z"))).isFalse(); + } + + @Test + public void testQueryPaginatorRowsNoLimit() { + int chunkSize = 10; + Query query = Query.create(TABLE_ID).rowKey("a").rowKey("b").rowKey("c"); + + Query.QueryPaginator paginator = query.createPaginator(chunkSize); + + Query nextQuery = paginator.getNextQuery(); + + ReadRowsRequest.Builder expectedProto = expectedProtoBuilder(); + expectedProto + .getRowsBuilder() + .addRowKeys(ByteString.copyFromUtf8("a")) + .addRowKeys(ByteString.copyFromUtf8("b")) + .addRowKeys(ByteString.copyFromUtf8("c")); + expectedProto.setRowsLimit(chunkSize); + + assertThat(nextQuery.toProto(requestContext)).isEqualTo(expectedProto.build()); + + paginator.advance(ByteString.copyFromUtf8("b")); + nextQuery = paginator.getNextQuery(); + expectedProto = expectedProtoBuilder(); + expectedProto.getRowsBuilder().addRowKeys(ByteString.copyFromUtf8("c")); + expectedProto.setRowsLimit(chunkSize); + + assertThat(nextQuery.toProto(requestContext)).isEqualTo(expectedProto.build()); + + assertThat(paginator.advance(ByteString.copyFromUtf8("c"))).isFalse(); + } + + @Test + public void testQueryPaginatorFullTableScan() { + int chunkSize = 10; + Query query = Query.create(TABLE_ID); + Query.QueryPaginator queryPaginator = query.createPaginator(chunkSize); + + ReadRowsRequest.Builder expectedProto = expectedProtoBuilder().setRowsLimit(chunkSize); + assertThat(queryPaginator.getNextQuery().toProto(requestContext)) + .isEqualTo(expectedProto.build()); + + assertThat(queryPaginator.advance(ByteString.copyFromUtf8("a"))).isTrue(); + expectedProto + .setRows( + RowSet.newBuilder() + .addRowRanges( + RowRange.newBuilder().setStartKeyOpen(ByteString.copyFromUtf8("a")).build())) + .setRowsLimit(chunkSize); + assertThat(queryPaginator.getNextQuery().toProto(requestContext)) + .isEqualTo(expectedProto.build()); + + assertThat(queryPaginator.advance(ByteString.copyFromUtf8("a"))).isFalse(); + } + + @Test + public void testQueryPaginatorEmptyTable() { + int chunkSize = 10; + Query query = Query.create(TABLE_ID); + Query.QueryPaginator queryPaginator = query.createPaginator(chunkSize); + + ReadRowsRequest.Builder expectedProto = expectedProtoBuilder().setRowsLimit(chunkSize); + assertThat(queryPaginator.getNextQuery().toProto(requestContext)) + .isEqualTo(expectedProto.build()); + + assertThat(queryPaginator.advance(ByteString.EMPTY)).isFalse(); + } } diff --git a/google-cloud-bigtable/src/test/java/com/google/cloud/bigtable/data/v2/stub/ConvertStreamExceptionCallableTest.java b/google-cloud-bigtable/src/test/java/com/google/cloud/bigtable/data/v2/stub/ConvertExceptionCallableTest.java similarity index 92% rename from google-cloud-bigtable/src/test/java/com/google/cloud/bigtable/data/v2/stub/ConvertStreamExceptionCallableTest.java rename to google-cloud-bigtable/src/test/java/com/google/cloud/bigtable/data/v2/stub/ConvertExceptionCallableTest.java index 8f08e15b23..534d341914 100644 --- a/google-cloud-bigtable/src/test/java/com/google/cloud/bigtable/data/v2/stub/ConvertStreamExceptionCallableTest.java +++ b/google-cloud-bigtable/src/test/java/com/google/cloud/bigtable/data/v2/stub/ConvertExceptionCallableTest.java @@ -31,7 +31,7 @@ import org.junit.runners.JUnit4; @RunWith(JUnit4.class) -public class ConvertStreamExceptionCallableTest { +public class ConvertExceptionCallableTest { @Test public void rstStreamExceptionConvertedToRetryableTest() { @@ -45,8 +45,8 @@ public void rstStreamExceptionConvertedToRetryableTest() { assertFalse(originalException.isRetryable()); SettableExceptionCallable settableExceptionCallable = new SettableExceptionCallable<>(originalException); - ConvertStreamExceptionCallable convertStreamExceptionCallable = - new ConvertStreamExceptionCallable<>(settableExceptionCallable); + ConvertExceptionCallable convertStreamExceptionCallable = + new ConvertExceptionCallable<>(settableExceptionCallable); Throwable actualError = null; try { diff --git a/google-cloud-bigtable/src/test/java/com/google/cloud/bigtable/data/v2/stub/metrics/BuiltinMetricsTracerTest.java b/google-cloud-bigtable/src/test/java/com/google/cloud/bigtable/data/v2/stub/metrics/BuiltinMetricsTracerTest.java index d64570488a..a2c6d417b3 100644 --- a/google-cloud-bigtable/src/test/java/com/google/cloud/bigtable/data/v2/stub/metrics/BuiltinMetricsTracerTest.java +++ b/google-cloud-bigtable/src/test/java/com/google/cloud/bigtable/data/v2/stub/metrics/BuiltinMetricsTracerTest.java @@ -25,13 +25,19 @@ import com.google.api.client.util.Lists; import com.google.api.core.SettableApiFuture; +import com.google.api.gax.batching.Batcher; +import com.google.api.gax.batching.BatchingSettings; +import com.google.api.gax.batching.FlowControlSettings; import com.google.api.gax.rpc.ClientContext; +import com.google.api.gax.rpc.NotFoundException; import com.google.api.gax.rpc.ResponseObserver; import com.google.api.gax.rpc.StreamController; import com.google.api.gax.tracing.SpanName; import com.google.bigtable.v2.BigtableGrpc; import com.google.bigtable.v2.MutateRowRequest; import com.google.bigtable.v2.MutateRowResponse; +import com.google.bigtable.v2.MutateRowsRequest; +import com.google.bigtable.v2.MutateRowsResponse; import com.google.bigtable.v2.ReadRowsRequest; import com.google.bigtable.v2.ReadRowsResponse; import com.google.bigtable.v2.ResponseParams; @@ -40,6 +46,7 @@ import com.google.cloud.bigtable.data.v2.models.Query; import com.google.cloud.bigtable.data.v2.models.Row; import com.google.cloud.bigtable.data.v2.models.RowMutation; +import com.google.cloud.bigtable.data.v2.models.RowMutationEntry; import com.google.cloud.bigtable.data.v2.stub.EnhancedBigtableStub; import com.google.cloud.bigtable.data.v2.stub.EnhancedBigtableStubSettings; import com.google.cloud.bigtable.stats.StatsRecorderWrapper; @@ -66,6 +73,7 @@ import java.util.concurrent.atomic.AtomicBoolean; import java.util.concurrent.atomic.AtomicInteger; import org.junit.After; +import org.junit.Assert; import org.junit.Before; import org.junit.Rule; import org.junit.Test; @@ -85,6 +93,8 @@ public class BuiltinMetricsTracerTest { private static final String INSTANCE_ID = "fake-instance"; private static final String APP_PROFILE_ID = "default"; private static final String TABLE_ID = "fake-table"; + + private static final String BAD_TABLE_ID = "non-exist-table"; private static final String ZONE = "us-west-1"; private static final String CLUSTER = "cluster-0"; private static final long FAKE_SERVER_TIMING = 50; @@ -106,6 +116,8 @@ public class BuiltinMetricsTracerTest { @Captor private ArgumentCaptor zone; @Captor private ArgumentCaptor cluster; + private int batchElementCount = 2; + @Before public void setUp() throws Exception { // Add an interceptor to add server-timing in headers @@ -127,7 +139,7 @@ public void sendHeaders(Metadata headers) { ResponseParams params = ResponseParams.newBuilder().setZoneId(ZONE).setClusterId(CLUSTER).build(); byte[] byteArray = params.toByteArray(); - headers.put(Util.METADATA_KEY, byteArray); + headers.put(Util.LOCATION_METADATA_KEY, byteArray); super.sendHeaders(headers); } @@ -150,6 +162,22 @@ public void sendHeaders(Metadata headers) { .mutateRowSettings() .retrySettings() .setInitialRetryDelay(Duration.ofMillis(200)); + + stubSettingsBuilder + .bulkMutateRowsSettings() + .setBatchingSettings( + // Each batch has 2 mutations, batch has 1 in-flight request, disable auto flush by + // setting the delay to 1 hour. + BatchingSettings.newBuilder() + .setElementCountThreshold((long) batchElementCount) + .setRequestByteThreshold(1000L) + .setDelayThreshold(Duration.ofHours(1)) + .setFlowControlSettings( + FlowControlSettings.newBuilder() + .setMaxOutstandingElementCount((long) batchElementCount) + .setMaxOutstandingRequestBytes(1000L) + .build()) + .build()); stubSettingsBuilder.setTracerFactory(mockFactory); EnhancedBigtableStubSettings stubSettings = stubSettingsBuilder.build(); @@ -163,7 +191,7 @@ public void tearDown() { } @Test - public void testOperationLatencies() { + public void testReadRowsOperationLatencies() { when(mockFactory.newTracer(any(), any(), any())) .thenAnswer( (Answer) @@ -179,8 +207,15 @@ public void testOperationLatencies() { long elapsed = stopwatch.elapsed(TimeUnit.MILLISECONDS); verify(statsRecorderWrapper).putOperationLatencies(operationLatency.capture()); + // verify record operation is only called once + verify(statsRecorderWrapper) + .recordOperation(status.capture(), tableId.capture(), zone.capture(), cluster.capture()); assertThat(operationLatency.getValue()).isIn(Range.closed(SERVER_LATENCY, elapsed)); + assertThat(status.getAllValues()).containsExactly("OK"); + assertThat(tableId.getAllValues()).containsExactly(TABLE_ID); + assertThat(zone.getAllValues()).containsExactly(ZONE); + assertThat(cluster.getAllValues()).containsExactly(CLUSTER); } @Test @@ -198,6 +233,10 @@ public void testGfeMetrics() { Lists.newArrayList(stub.readRowsCallable().call(Query.create(TABLE_ID))); + // Verify record attempt are called multiple times + verify(statsRecorderWrapper, times(fakeService.getAttemptCounter().get())) + .recordAttempt(status.capture(), tableId.capture(), zone.capture(), cluster.capture()); + // The request was retried and gfe latency is only recorded in the retry attempt verify(statsRecorderWrapper).putGfeLatencies(gfeLatency.capture()); assertThat(gfeLatency.getValue()).isEqualTo(FAKE_SERVER_TIMING); @@ -206,6 +245,11 @@ public void testGfeMetrics() { verify(statsRecorderWrapper, times(fakeService.getAttemptCounter().get())) .putGfeMissingHeaders(gfeMissingHeaders.capture()); assertThat(gfeMissingHeaders.getValue()).isEqualTo(1); + + assertThat(status.getAllValues()).containsExactly("UNAVAILABLE", "OK"); + assertThat(tableId.getAllValues()).containsExactly(TABLE_ID, TABLE_ID); + assertThat(zone.getAllValues()).containsExactly("global", ZONE); + assertThat(cluster.getAllValues()).containsExactly("unspecified", CLUSTER); } @Test @@ -255,6 +299,8 @@ public void onComplete() { verify(statsRecorderWrapper).putApplicationLatencies(applicationLatency.capture()); verify(statsRecorderWrapper).putOperationLatencies(operationLatency.capture()); + verify(statsRecorderWrapper) + .recordOperation(status.capture(), tableId.capture(), zone.capture(), cluster.capture()); assertThat(counter.get()).isEqualTo(fakeService.getResponseCounter().get()); assertThat(applicationLatency.getValue()).isAtLeast(APPLICATION_LATENCY * counter.get()); @@ -287,6 +333,8 @@ public void testReadRowsApplicationLatencyWithManualFlowControl() throws Excepti verify(statsRecorderWrapper).putApplicationLatencies(applicationLatency.capture()); verify(statsRecorderWrapper).putOperationLatencies(operationLatency.capture()); + verify(statsRecorderWrapper) + .recordOperation(status.capture(), tableId.capture(), zone.capture(), cluster.capture()); // For manual flow control, the last application latency shouldn't count, because at that point // the server already sent back all the responses. @@ -313,16 +361,18 @@ public void testRetryCount() { stub.mutateRowCallable() .call(RowMutation.create(TABLE_ID, "random-row").setCell("cf", "q", "value")); - // onOperationComplete() is called in TracerFinisher which will be called after the mutateRow - // call is returned. So there's a race between when the call returns and when the putRetryCount - // is called in onOperationCompletion(). - verify(statsRecorderWrapper, timeout(20)).putRetryCount(retryCount.capture()); + // In TracedUnaryCallable, we create a future and add a TraceFinisher to the callback. Main + // thread is blocked on waiting for the future to be completed. When onComplete is called on + // the grpc thread, the future is completed, however we might not have enough time for + // TraceFinisher to run. Add a 1 second time out to wait for the callback. This shouldn't have + // any impact on production code. + verify(statsRecorderWrapper, timeout(1000)).putRetryCount(retryCount.capture()); assertThat(retryCount.getValue()).isEqualTo(fakeService.getAttemptCounter().get() - 1); } @Test - public void testMutateRowAttempts() { + public void testMutateRowAttemptsTagValues() { when(mockFactory.newTracer(any(), any(), any())) .thenReturn( new BuiltinMetricsTracer( @@ -341,6 +391,84 @@ public void testMutateRowAttempts() { assertThat(zone.getAllValues()).containsExactly("global", "global", ZONE); assertThat(cluster.getAllValues()).containsExactly("unspecified", "unspecified", CLUSTER); assertThat(status.getAllValues()).containsExactly("UNAVAILABLE", "UNAVAILABLE", "OK"); + assertThat(tableId.getAllValues()).containsExactly(TABLE_ID, TABLE_ID, TABLE_ID); + } + + @Test + public void testReadRowsAttemptsTagValues() { + when(mockFactory.newTracer(any(), any(), any())) + .thenReturn( + new BuiltinMetricsTracer( + OperationType.ServerStreaming, + SpanName.of("Bigtable", "ReadRows"), + statsRecorderWrapper)); + + Lists.newArrayList(stub.readRowsCallable().call(Query.create("fake-table")).iterator()); + + // Set a timeout to reduce flakiness of this test. BasicRetryingFuture will set + // attempt succeeded and set the response which will call complete() in AbstractFuture which + // calls releaseWaiters(). onOperationComplete() is called in TracerFinisher which will be + // called after the mutateRow call is returned. So there's a race between when the call returns + // and when the record() is called in onOperationCompletion(). + verify(statsRecorderWrapper, timeout(50).times(fakeService.getAttemptCounter().get())) + .recordAttempt(status.capture(), tableId.capture(), zone.capture(), cluster.capture()); + assertThat(zone.getAllValues()).containsExactly("global", ZONE); + assertThat(cluster.getAllValues()).containsExactly("unspecified", CLUSTER); + assertThat(status.getAllValues()).containsExactly("UNAVAILABLE", "OK"); + } + + @Test + public void testClientBlockingLatencies() throws InterruptedException { + when(mockFactory.newTracer(any(), any(), any())) + .thenReturn( + new BuiltinMetricsTracer( + OperationType.Unary, SpanName.of("Bigtable", "MutateRows"), statsRecorderWrapper)); + try (Batcher batcher = stub.newMutateRowsBatcher(TABLE_ID, null)) { + for (int i = 0; i < 6; i++) { + batcher.add(RowMutationEntry.create("key").setCell("f", "q", "v")); + } + + int expectedNumRequests = 6 / batchElementCount; + ArgumentCaptor throttledTime = ArgumentCaptor.forClass(Long.class); + verify(statsRecorderWrapper, times(expectedNumRequests)) + .putBatchRequestThrottled(throttledTime.capture()); + + // Adding the first 2 elements should not get throttled since the batch is empty + assertThat(throttledTime.getAllValues().get(0)).isEqualTo(0); + // After the first request is sent, batcher will block on add because of the server latency. + // Blocking latency should be around server latency. + assertThat(throttledTime.getAllValues().get(1)).isAtLeast(SERVER_LATENCY - 10); + assertThat(throttledTime.getAllValues().get(2)).isAtLeast(SERVER_LATENCY - 10); + } + } + + @Test + public void testPermanentFailure() { + when(mockFactory.newTracer(any(), any(), any())) + .thenReturn( + new BuiltinMetricsTracer( + OperationType.ServerStreaming, + SpanName.of("Bigtable", "ReadRows"), + statsRecorderWrapper)); + + try { + Lists.newArrayList(stub.readRowsCallable().call(Query.create(BAD_TABLE_ID)).iterator()); + Assert.fail("Request should throw not found error"); + } catch (NotFoundException e) { + } + + ArgumentCaptor attemptLatency = ArgumentCaptor.forClass(Long.class); + ArgumentCaptor operationLatency = ArgumentCaptor.forClass(Long.class); + + verify(statsRecorderWrapper, timeout(50)).putAttemptLatencies(attemptLatency.capture()); + verify(statsRecorderWrapper, timeout(50)).putOperationLatencies(operationLatency.capture()); + verify(statsRecorderWrapper, timeout(50)) + .recordAttempt(status.capture(), tableId.capture(), zone.capture(), cluster.capture()); + + assertThat(status.getValue()).isEqualTo("NOT_FOUND"); + assertThat(tableId.getValue()).isEqualTo(BAD_TABLE_ID); + assertThat(cluster.getValue()).isEqualTo("unspecified"); + assertThat(zone.getValue()).isEqualTo("global"); } private static class FakeService extends BigtableGrpc.BigtableImplBase { @@ -373,6 +501,10 @@ static List createFakeResponse() { @Override public void readRows( ReadRowsRequest request, StreamObserver responseObserver) { + if (request.getTableName().contains(BAD_TABLE_ID)) { + responseObserver.onError(new StatusRuntimeException(Status.NOT_FOUND)); + return; + } final AtomicBoolean done = new AtomicBoolean(); final ServerCallStreamObserver target = (ServerCallStreamObserver) responseObserver; @@ -411,6 +543,17 @@ public void mutateRow( responseObserver.onCompleted(); } + @Override + public void mutateRows( + MutateRowsRequest request, StreamObserver responseObserver) { + try { + Thread.sleep(SERVER_LATENCY); + } catch (InterruptedException e) { + } + responseObserver.onNext(MutateRowsResponse.getDefaultInstance()); + responseObserver.onCompleted(); + } + public AtomicInteger getAttemptCounter() { return attemptCounter; } diff --git a/grpc-google-cloud-bigtable-admin-v2/pom.xml b/grpc-google-cloud-bigtable-admin-v2/pom.xml index 7845df6ba4..717bb9fd44 100644 --- a/grpc-google-cloud-bigtable-admin-v2/pom.xml +++ b/grpc-google-cloud-bigtable-admin-v2/pom.xml @@ -4,13 +4,13 @@ 4.0.0 com.google.api.grpc grpc-google-cloud-bigtable-admin-v2 - 2.11.2-SNAPSHOT + 2.17.1-SNAPSHOT grpc-google-cloud-bigtable-admin-v2 GRPC library for grpc-google-cloud-bigtable-admin-v2 com.google.cloud google-cloud-bigtable-parent - 2.11.2-SNAPSHOT + 2.17.1-SNAPSHOT @@ -18,14 +18,14 @@ com.google.cloud google-cloud-bigtable-deps-bom - 2.11.2-SNAPSHOT + 2.17.1-SNAPSHOT pom import com.google.cloud google-cloud-bigtable-bom - 2.11.2-SNAPSHOT + 2.17.1-SNAPSHOT pom import diff --git a/grpc-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/BigtableTableAdminGrpc.java b/grpc-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/BigtableTableAdminGrpc.java index 69de131981..b4d101214c 100644 --- a/grpc-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/BigtableTableAdminGrpc.java +++ b/grpc-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/BigtableTableAdminGrpc.java @@ -216,6 +216,48 @@ private BigtableTableAdminGrpc() {} return getGetTableMethod; } + private static volatile io.grpc.MethodDescriptor< + com.google.bigtable.admin.v2.UpdateTableRequest, com.google.longrunning.Operation> + getUpdateTableMethod; + + @io.grpc.stub.annotations.RpcMethod( + fullMethodName = SERVICE_NAME + '/' + "UpdateTable", + requestType = com.google.bigtable.admin.v2.UpdateTableRequest.class, + responseType = com.google.longrunning.Operation.class, + methodType = io.grpc.MethodDescriptor.MethodType.UNARY) + public static io.grpc.MethodDescriptor< + com.google.bigtable.admin.v2.UpdateTableRequest, com.google.longrunning.Operation> + getUpdateTableMethod() { + io.grpc.MethodDescriptor< + com.google.bigtable.admin.v2.UpdateTableRequest, com.google.longrunning.Operation> + getUpdateTableMethod; + if ((getUpdateTableMethod = BigtableTableAdminGrpc.getUpdateTableMethod) == null) { + synchronized (BigtableTableAdminGrpc.class) { + if ((getUpdateTableMethod = BigtableTableAdminGrpc.getUpdateTableMethod) == null) { + BigtableTableAdminGrpc.getUpdateTableMethod = + getUpdateTableMethod = + io.grpc.MethodDescriptor + . + newBuilder() + .setType(io.grpc.MethodDescriptor.MethodType.UNARY) + .setFullMethodName(generateFullMethodName(SERVICE_NAME, "UpdateTable")) + .setSampledToLocalTracing(true) + .setRequestMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.bigtable.admin.v2.UpdateTableRequest.getDefaultInstance())) + .setResponseMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.longrunning.Operation.getDefaultInstance())) + .setSchemaDescriptor( + new BigtableTableAdminMethodDescriptorSupplier("UpdateTable")) + .build(); + } + } + } + return getUpdateTableMethod; + } + private static volatile io.grpc.MethodDescriptor< com.google.bigtable.admin.v2.DeleteTableRequest, com.google.protobuf.Empty> getDeleteTableMethod; @@ -1164,6 +1206,20 @@ public void getTable( io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall(getGetTableMethod(), responseObserver); } + /** + * + * + *
+     * Updates a specified table.
+     * 
+ */ + public void updateTable( + com.google.bigtable.admin.v2.UpdateTableRequest request, + io.grpc.stub.StreamObserver responseObserver) { + io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall( + getUpdateTableMethod(), responseObserver); + } + /** * * @@ -1510,6 +1566,12 @@ public final io.grpc.ServerServiceDefinition bindService() { new MethodHandlers< com.google.bigtable.admin.v2.GetTableRequest, com.google.bigtable.admin.v2.Table>(this, METHODID_GET_TABLE))) + .addMethod( + getUpdateTableMethod(), + io.grpc.stub.ServerCalls.asyncUnaryCall( + new MethodHandlers< + com.google.bigtable.admin.v2.UpdateTableRequest, + com.google.longrunning.Operation>(this, METHODID_UPDATE_TABLE))) .addMethod( getDeleteTableMethod(), io.grpc.stub.ServerCalls.asyncUnaryCall( @@ -1723,6 +1785,22 @@ public void getTable( getChannel().newCall(getGetTableMethod(), getCallOptions()), request, responseObserver); } + /** + * + * + *
+     * Updates a specified table.
+     * 
+ */ + public void updateTable( + com.google.bigtable.admin.v2.UpdateTableRequest request, + io.grpc.stub.StreamObserver responseObserver) { + io.grpc.stub.ClientCalls.asyncUnaryCall( + getChannel().newCall(getUpdateTableMethod(), getCallOptions()), + request, + responseObserver); + } + /** * * @@ -2162,6 +2240,19 @@ public com.google.bigtable.admin.v2.Table getTable( getChannel(), getGetTableMethod(), getCallOptions(), request); } + /** + * + * + *
+     * Updates a specified table.
+     * 
+ */ + public com.google.longrunning.Operation updateTable( + com.google.bigtable.admin.v2.UpdateTableRequest request) { + return io.grpc.stub.ClientCalls.blockingUnaryCall( + getChannel(), getUpdateTableMethod(), getCallOptions(), request); + } + /** * * @@ -2540,6 +2631,19 @@ protected BigtableTableAdminFutureStub build( getChannel().newCall(getGetTableMethod(), getCallOptions()), request); } + /** + * + * + *
+     * Updates a specified table.
+     * 
+ */ + public com.google.common.util.concurrent.ListenableFuture + updateTable(com.google.bigtable.admin.v2.UpdateTableRequest request) { + return io.grpc.stub.ClientCalls.futureUnaryCall( + getChannel().newCall(getUpdateTableMethod(), getCallOptions()), request); + } + /** * * @@ -2847,25 +2951,26 @@ protected BigtableTableAdminFutureStub build( private static final int METHODID_CREATE_TABLE_FROM_SNAPSHOT = 1; private static final int METHODID_LIST_TABLES = 2; private static final int METHODID_GET_TABLE = 3; - private static final int METHODID_DELETE_TABLE = 4; - private static final int METHODID_UNDELETE_TABLE = 5; - private static final int METHODID_MODIFY_COLUMN_FAMILIES = 6; - private static final int METHODID_DROP_ROW_RANGE = 7; - private static final int METHODID_GENERATE_CONSISTENCY_TOKEN = 8; - private static final int METHODID_CHECK_CONSISTENCY = 9; - private static final int METHODID_SNAPSHOT_TABLE = 10; - private static final int METHODID_GET_SNAPSHOT = 11; - private static final int METHODID_LIST_SNAPSHOTS = 12; - private static final int METHODID_DELETE_SNAPSHOT = 13; - private static final int METHODID_CREATE_BACKUP = 14; - private static final int METHODID_GET_BACKUP = 15; - private static final int METHODID_UPDATE_BACKUP = 16; - private static final int METHODID_DELETE_BACKUP = 17; - private static final int METHODID_LIST_BACKUPS = 18; - private static final int METHODID_RESTORE_TABLE = 19; - private static final int METHODID_GET_IAM_POLICY = 20; - private static final int METHODID_SET_IAM_POLICY = 21; - private static final int METHODID_TEST_IAM_PERMISSIONS = 22; + private static final int METHODID_UPDATE_TABLE = 4; + private static final int METHODID_DELETE_TABLE = 5; + private static final int METHODID_UNDELETE_TABLE = 6; + private static final int METHODID_MODIFY_COLUMN_FAMILIES = 7; + private static final int METHODID_DROP_ROW_RANGE = 8; + private static final int METHODID_GENERATE_CONSISTENCY_TOKEN = 9; + private static final int METHODID_CHECK_CONSISTENCY = 10; + private static final int METHODID_SNAPSHOT_TABLE = 11; + private static final int METHODID_GET_SNAPSHOT = 12; + private static final int METHODID_LIST_SNAPSHOTS = 13; + private static final int METHODID_DELETE_SNAPSHOT = 14; + private static final int METHODID_CREATE_BACKUP = 15; + private static final int METHODID_GET_BACKUP = 16; + private static final int METHODID_UPDATE_BACKUP = 17; + private static final int METHODID_DELETE_BACKUP = 18; + private static final int METHODID_LIST_BACKUPS = 19; + private static final int METHODID_RESTORE_TABLE = 20; + private static final int METHODID_GET_IAM_POLICY = 21; + private static final int METHODID_SET_IAM_POLICY = 22; + private static final int METHODID_TEST_IAM_PERMISSIONS = 23; private static final class MethodHandlers implements io.grpc.stub.ServerCalls.UnaryMethod, @@ -2905,6 +3010,11 @@ public void invoke(Req request, io.grpc.stub.StreamObserver responseObserv (com.google.bigtable.admin.v2.GetTableRequest) request, (io.grpc.stub.StreamObserver) responseObserver); break; + case METHODID_UPDATE_TABLE: + serviceImpl.updateTable( + (com.google.bigtable.admin.v2.UpdateTableRequest) request, + (io.grpc.stub.StreamObserver) responseObserver); + break; case METHODID_DELETE_TABLE: serviceImpl.deleteTable( (com.google.bigtable.admin.v2.DeleteTableRequest) request, @@ -3075,6 +3185,7 @@ public static io.grpc.ServiceDescriptor getServiceDescriptor() { .addMethod(getCreateTableFromSnapshotMethod()) .addMethod(getListTablesMethod()) .addMethod(getGetTableMethod()) + .addMethod(getUpdateTableMethod()) .addMethod(getDeleteTableMethod()) .addMethod(getUndeleteTableMethod()) .addMethod(getModifyColumnFamiliesMethod()) diff --git a/grpc-google-cloud-bigtable-v2/pom.xml b/grpc-google-cloud-bigtable-v2/pom.xml index 7bd61241d7..19bc2d8a8f 100644 --- a/grpc-google-cloud-bigtable-v2/pom.xml +++ b/grpc-google-cloud-bigtable-v2/pom.xml @@ -4,13 +4,13 @@ 4.0.0 com.google.api.grpc grpc-google-cloud-bigtable-v2 - 2.11.2-SNAPSHOT + 2.17.1-SNAPSHOT grpc-google-cloud-bigtable-v2 GRPC library for grpc-google-cloud-bigtable-v2 com.google.cloud google-cloud-bigtable-parent - 2.11.2-SNAPSHOT + 2.17.1-SNAPSHOT @@ -18,14 +18,14 @@ com.google.cloud google-cloud-bigtable-deps-bom - 2.11.2-SNAPSHOT + 2.17.1-SNAPSHOT pom import com.google.cloud google-cloud-bigtable-bom - 2.11.2-SNAPSHOT + 2.17.1-SNAPSHOT pom import diff --git a/pom.xml b/pom.xml index 2333898f24..6f0221a3d7 100644 --- a/pom.xml +++ b/pom.xml @@ -4,7 +4,7 @@ google-cloud-bigtable-parent pom - 2.11.2-SNAPSHOT + 2.17.1-SNAPSHOT Google Cloud Bigtable Parent https://github.com/googleapis/java-bigtable @@ -14,7 +14,7 @@ com.google.cloud google-cloud-shared-config - 1.5.3 + 1.5.5 @@ -153,27 +153,27 @@ com.google.api.grpc proto-google-cloud-bigtable-v2 - 2.11.2-SNAPSHOT + 2.17.1-SNAPSHOT com.google.api.grpc proto-google-cloud-bigtable-admin-v2 - 2.11.2-SNAPSHOT + 2.17.1-SNAPSHOT com.google.api.grpc grpc-google-cloud-bigtable-v2 - 2.11.2-SNAPSHOT + 2.17.1-SNAPSHOT com.google.api.grpc grpc-google-cloud-bigtable-admin-v2 - 2.11.2-SNAPSHOT + 2.17.1-SNAPSHOT com.google.cloud google-cloud-bigtable - 2.11.2-SNAPSHOT + 2.17.1-SNAPSHOT @@ -207,7 +207,7 @@ org.mockito mockito-core - 4.7.0 + 4.9.0 diff --git a/proto-google-cloud-bigtable-admin-v2/pom.xml b/proto-google-cloud-bigtable-admin-v2/pom.xml index 721dee46f3..afc2a59e79 100644 --- a/proto-google-cloud-bigtable-admin-v2/pom.xml +++ b/proto-google-cloud-bigtable-admin-v2/pom.xml @@ -4,13 +4,13 @@ 4.0.0 com.google.api.grpc proto-google-cloud-bigtable-admin-v2 - 2.11.2-SNAPSHOT + 2.17.1-SNAPSHOT proto-google-cloud-bigtable-admin-v2 PROTO library for proto-google-cloud-bigtable-admin-v2 com.google.cloud google-cloud-bigtable-parent - 2.11.2-SNAPSHOT + 2.17.1-SNAPSHOT @@ -18,14 +18,14 @@ com.google.cloud google-cloud-bigtable-deps-bom - 2.11.2-SNAPSHOT + 2.17.1-SNAPSHOT pom import com.google.cloud google-cloud-bigtable-bom - 2.11.2-SNAPSHOT + 2.17.1-SNAPSHOT pom import diff --git a/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/AppProfile.java b/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/AppProfile.java index c984c1b601..b8dd885f7a 100644 --- a/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/AppProfile.java +++ b/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/AppProfile.java @@ -55,110 +55,6 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - private AppProfile( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - java.lang.String s = input.readStringRequireUtf8(); - - name_ = s; - break; - } - case 18: - { - java.lang.String s = input.readStringRequireUtf8(); - - etag_ = s; - break; - } - case 26: - { - java.lang.String s = input.readStringRequireUtf8(); - - description_ = s; - break; - } - case 42: - { - com.google.bigtable.admin.v2.AppProfile.MultiClusterRoutingUseAny.Builder subBuilder = - null; - if (routingPolicyCase_ == 5) { - subBuilder = - ((com.google.bigtable.admin.v2.AppProfile.MultiClusterRoutingUseAny) - routingPolicy_) - .toBuilder(); - } - routingPolicy_ = - input.readMessage( - com.google.bigtable.admin.v2.AppProfile.MultiClusterRoutingUseAny.parser(), - extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom( - (com.google.bigtable.admin.v2.AppProfile.MultiClusterRoutingUseAny) - routingPolicy_); - routingPolicy_ = subBuilder.buildPartial(); - } - routingPolicyCase_ = 5; - break; - } - case 50: - { - com.google.bigtable.admin.v2.AppProfile.SingleClusterRouting.Builder subBuilder = - null; - if (routingPolicyCase_ == 6) { - subBuilder = - ((com.google.bigtable.admin.v2.AppProfile.SingleClusterRouting) routingPolicy_) - .toBuilder(); - } - routingPolicy_ = - input.readMessage( - com.google.bigtable.admin.v2.AppProfile.SingleClusterRouting.parser(), - extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom( - (com.google.bigtable.admin.v2.AppProfile.SingleClusterRouting) routingPolicy_); - routingPolicy_ = subBuilder.buildPartial(); - } - routingPolicyCase_ = 6; - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.bigtable.admin.v2.InstanceProto .internal_static_google_bigtable_admin_v2_AppProfile_descriptor; @@ -272,59 +168,6 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - private MultiClusterRoutingUseAny( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - int mutable_bitField0_ = 0; - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - java.lang.String s = input.readStringRequireUtf8(); - if (!((mutable_bitField0_ & 0x00000001) != 0)) { - clusterIds_ = new com.google.protobuf.LazyStringArrayList(); - mutable_bitField0_ |= 0x00000001; - } - clusterIds_.add(s); - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); - } finally { - if (((mutable_bitField0_ & 0x00000001) != 0)) { - clusterIds_ = clusterIds_.getUnmodifiableView(); - } - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.bigtable.admin.v2.InstanceProto .internal_static_google_bigtable_admin_v2_AppProfile_MultiClusterRoutingUseAny_descriptor; @@ -422,7 +265,7 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io for (int i = 0; i < clusterIds_.size(); i++) { com.google.protobuf.GeneratedMessageV3.writeString(output, 1, clusterIds_.getRaw(i)); } - unknownFields.writeTo(output); + getUnknownFields().writeTo(output); } @java.lang.Override @@ -439,7 +282,7 @@ public int getSerializedSize() { size += dataSize; size += 1 * getClusterIdsList().size(); } - size += unknownFields.getSerializedSize(); + size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @@ -456,7 +299,7 @@ public boolean equals(final java.lang.Object obj) { (com.google.bigtable.admin.v2.AppProfile.MultiClusterRoutingUseAny) obj; if (!getClusterIdsList().equals(other.getClusterIdsList())) return false; - if (!unknownFields.equals(other.unknownFields)) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -471,7 +314,7 @@ public int hashCode() { hash = (37 * hash) + CLUSTER_IDS_FIELD_NUMBER; hash = (53 * hash) + getClusterIdsList().hashCode(); } - hash = (29 * hash) + unknownFields.hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } @@ -609,17 +452,10 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { // Construct using // com.google.bigtable.admin.v2.AppProfile.MultiClusterRoutingUseAny.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } + private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} } @java.lang.Override @@ -727,7 +563,7 @@ public Builder mergeFrom( } onChanged(); } - this.mergeUnknownFields(other.unknownFields); + this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @@ -742,19 +578,38 @@ public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - com.google.bigtable.admin.v2.AppProfile.MultiClusterRoutingUseAny parsedMessage = null; + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + java.lang.String s = input.readStringRequireUtf8(); + ensureClusterIdsIsMutable(); + clusterIds_.add(s); + break; + } // case 10 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = - (com.google.bigtable.admin.v2.AppProfile.MultiClusterRoutingUseAny) - e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } + onChanged(); + } // finally return this; } @@ -972,7 +827,19 @@ public MultiClusterRoutingUseAny parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new MultiClusterRoutingUseAny(input, extensionRegistry); + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException() + .setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); } }; @@ -1073,57 +940,6 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - private SingleClusterRouting( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - java.lang.String s = input.readStringRequireUtf8(); - - clusterId_ = s; - break; - } - case 16: - { - allowTransactionalWrites_ = input.readBool(); - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.bigtable.admin.v2.InstanceProto .internal_static_google_bigtable_admin_v2_AppProfile_SingleClusterRouting_descriptor; @@ -1228,7 +1044,7 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io if (allowTransactionalWrites_ != false) { output.writeBool(2, allowTransactionalWrites_); } - unknownFields.writeTo(output); + getUnknownFields().writeTo(output); } @java.lang.Override @@ -1243,7 +1059,7 @@ public int getSerializedSize() { if (allowTransactionalWrites_ != false) { size += com.google.protobuf.CodedOutputStream.computeBoolSize(2, allowTransactionalWrites_); } - size += unknownFields.getSerializedSize(); + size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @@ -1261,7 +1077,7 @@ public boolean equals(final java.lang.Object obj) { if (!getClusterId().equals(other.getClusterId())) return false; if (getAllowTransactionalWrites() != other.getAllowTransactionalWrites()) return false; - if (!unknownFields.equals(other.unknownFields)) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -1276,7 +1092,7 @@ public int hashCode() { hash = (53 * hash) + getClusterId().hashCode(); hash = (37 * hash) + ALLOW_TRANSACTIONAL_WRITES_FIELD_NUMBER; hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean(getAllowTransactionalWrites()); - hash = (29 * hash) + unknownFields.hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } @@ -1410,17 +1226,10 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { } // Construct using com.google.bigtable.admin.v2.AppProfile.SingleClusterRouting.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } + private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} } @java.lang.Override @@ -1520,7 +1329,7 @@ public Builder mergeFrom(com.google.bigtable.admin.v2.AppProfile.SingleClusterRo if (other.getAllowTransactionalWrites() != false) { setAllowTransactionalWrites(other.getAllowTransactionalWrites()); } - this.mergeUnknownFields(other.unknownFields); + this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @@ -1535,19 +1344,43 @@ public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - com.google.bigtable.admin.v2.AppProfile.SingleClusterRouting parsedMessage = null; + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + clusterId_ = input.readStringRequireUtf8(); + + break; + } // case 10 + case 16: + { + allowTransactionalWrites_ = input.readBool(); + + break; + } // case 16 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = - (com.google.bigtable.admin.v2.AppProfile.SingleClusterRouting) - e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } + onChanged(); + } // finally return this; } @@ -1750,7 +1583,19 @@ public SingleClusterRouting parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new SingleClusterRouting(input, extensionRegistry); + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException() + .setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); } }; @@ -2125,7 +1970,7 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io output.writeMessage( 6, (com.google.bigtable.admin.v2.AppProfile.SingleClusterRouting) routingPolicy_); } - unknownFields.writeTo(output); + getUnknownFields().writeTo(output); } @java.lang.Override @@ -2154,7 +1999,7 @@ public int getSerializedSize() { com.google.protobuf.CodedOutputStream.computeMessageSize( 6, (com.google.bigtable.admin.v2.AppProfile.SingleClusterRouting) routingPolicy_); } - size += unknownFields.getSerializedSize(); + size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @@ -2184,7 +2029,7 @@ public boolean equals(final java.lang.Object obj) { case 0: default: } - if (!unknownFields.equals(other.unknownFields)) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -2213,7 +2058,7 @@ public int hashCode() { case 0: default: } - hash = (29 * hash) + unknownFields.hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } @@ -2343,17 +2188,10 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { } // Construct using com.google.bigtable.admin.v2.AppProfile.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } + private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} } @java.lang.Override @@ -2365,6 +2203,12 @@ public Builder clear() { description_ = ""; + if (multiClusterRoutingUseAnyBuilder_ != null) { + multiClusterRoutingUseAnyBuilder_.clear(); + } + if (singleClusterRoutingBuilder_ != null) { + singleClusterRoutingBuilder_.clear(); + } routingPolicyCase_ = 0; routingPolicy_ = null; return this; @@ -2489,7 +2333,7 @@ public Builder mergeFrom(com.google.bigtable.admin.v2.AppProfile other) { break; } } - this.mergeUnknownFields(other.unknownFields); + this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @@ -2504,17 +2348,63 @@ public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - com.google.bigtable.admin.v2.AppProfile parsedMessage = null; + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + name_ = input.readStringRequireUtf8(); + + break; + } // case 10 + case 18: + { + etag_ = input.readStringRequireUtf8(); + + break; + } // case 18 + case 26: + { + description_ = input.readStringRequireUtf8(); + + break; + } // case 26 + case 42: + { + input.readMessage( + getMultiClusterRoutingUseAnyFieldBuilder().getBuilder(), extensionRegistry); + routingPolicyCase_ = 5; + break; + } // case 42 + case 50: + { + input.readMessage( + getSingleClusterRoutingFieldBuilder().getBuilder(), extensionRegistry); + routingPolicyCase_ = 6; + break; + } // case 50 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.bigtable.admin.v2.AppProfile) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } + onChanged(); + } // finally return this; } @@ -3389,7 +3279,18 @@ public AppProfile parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new AppProfile(input, extensionRegistry); + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); } }; diff --git a/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/AutoscalingLimits.java b/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/AutoscalingLimits.java index 3e88d33d78..d6130f49e9 100644 --- a/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/AutoscalingLimits.java +++ b/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/AutoscalingLimits.java @@ -50,55 +50,6 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - private AutoscalingLimits( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 8: - { - minServeNodes_ = input.readInt32(); - break; - } - case 16: - { - maxServeNodes_ = input.readInt32(); - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.bigtable.admin.v2.InstanceProto .internal_static_google_bigtable_admin_v2_AutoscalingLimits_descriptor; @@ -170,7 +121,7 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io if (maxServeNodes_ != 0) { output.writeInt32(2, maxServeNodes_); } - unknownFields.writeTo(output); + getUnknownFields().writeTo(output); } @java.lang.Override @@ -185,7 +136,7 @@ public int getSerializedSize() { if (maxServeNodes_ != 0) { size += com.google.protobuf.CodedOutputStream.computeInt32Size(2, maxServeNodes_); } - size += unknownFields.getSerializedSize(); + size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @@ -203,7 +154,7 @@ public boolean equals(final java.lang.Object obj) { if (getMinServeNodes() != other.getMinServeNodes()) return false; if (getMaxServeNodes() != other.getMaxServeNodes()) return false; - if (!unknownFields.equals(other.unknownFields)) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -218,7 +169,7 @@ public int hashCode() { hash = (53 * hash) + getMinServeNodes(); hash = (37 * hash) + MAX_SERVE_NODES_FIELD_NUMBER; hash = (53 * hash) + getMaxServeNodes(); - hash = (29 * hash) + unknownFields.hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } @@ -347,17 +298,10 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { } // Construct using com.google.bigtable.admin.v2.AutoscalingLimits.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } + private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} } @java.lang.Override @@ -451,7 +395,7 @@ public Builder mergeFrom(com.google.bigtable.admin.v2.AutoscalingLimits other) { if (other.getMaxServeNodes() != 0) { setMaxServeNodes(other.getMaxServeNodes()); } - this.mergeUnknownFields(other.unknownFields); + this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @@ -466,17 +410,43 @@ public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - com.google.bigtable.admin.v2.AutoscalingLimits parsedMessage = null; + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 8: + { + minServeNodes_ = input.readInt32(); + + break; + } // case 8 + case 16: + { + maxServeNodes_ = input.readInt32(); + + break; + } // case 16 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.bigtable.admin.v2.AutoscalingLimits) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } + onChanged(); + } // finally return this; } @@ -616,7 +586,18 @@ public AutoscalingLimits parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new AutoscalingLimits(input, extensionRegistry); + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); } }; diff --git a/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/AutoscalingTargets.java b/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/AutoscalingTargets.java index c0d6cb0b8c..d7c4351c78 100644 --- a/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/AutoscalingTargets.java +++ b/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/AutoscalingTargets.java @@ -50,55 +50,6 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - private AutoscalingTargets( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 16: - { - cpuUtilizationPercent_ = input.readInt32(); - break; - } - case 24: - { - storageUtilizationGibPerNode_ = input.readInt32(); - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.bigtable.admin.v2.InstanceProto .internal_static_google_bigtable_admin_v2_AutoscalingTargets_descriptor; @@ -178,7 +129,7 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io if (storageUtilizationGibPerNode_ != 0) { output.writeInt32(3, storageUtilizationGibPerNode_); } - unknownFields.writeTo(output); + getUnknownFields().writeTo(output); } @java.lang.Override @@ -194,7 +145,7 @@ public int getSerializedSize() { size += com.google.protobuf.CodedOutputStream.computeInt32Size(3, storageUtilizationGibPerNode_); } - size += unknownFields.getSerializedSize(); + size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @@ -212,7 +163,7 @@ public boolean equals(final java.lang.Object obj) { if (getCpuUtilizationPercent() != other.getCpuUtilizationPercent()) return false; if (getStorageUtilizationGibPerNode() != other.getStorageUtilizationGibPerNode()) return false; - if (!unknownFields.equals(other.unknownFields)) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -227,7 +178,7 @@ public int hashCode() { hash = (53 * hash) + getCpuUtilizationPercent(); hash = (37 * hash) + STORAGE_UTILIZATION_GIB_PER_NODE_FIELD_NUMBER; hash = (53 * hash) + getStorageUtilizationGibPerNode(); - hash = (29 * hash) + unknownFields.hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } @@ -356,17 +307,10 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { } // Construct using com.google.bigtable.admin.v2.AutoscalingTargets.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } + private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} } @java.lang.Override @@ -461,7 +405,7 @@ public Builder mergeFrom(com.google.bigtable.admin.v2.AutoscalingTargets other) if (other.getStorageUtilizationGibPerNode() != 0) { setStorageUtilizationGibPerNode(other.getStorageUtilizationGibPerNode()); } - this.mergeUnknownFields(other.unknownFields); + this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @@ -476,17 +420,43 @@ public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - com.google.bigtable.admin.v2.AutoscalingTargets parsedMessage = null; + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 16: + { + cpuUtilizationPercent_ = input.readInt32(); + + break; + } // case 16 + case 24: + { + storageUtilizationGibPerNode_ = input.readInt32(); + + break; + } // case 24 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.bigtable.admin.v2.AutoscalingTargets) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } + onChanged(); + } // finally return this; } @@ -650,7 +620,18 @@ public AutoscalingTargets parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new AutoscalingTargets(input, extensionRegistry); + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); } }; diff --git a/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/Backup.java b/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/Backup.java index b68fe55e1b..95df3f17d8 100644 --- a/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/Backup.java +++ b/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/Backup.java @@ -54,132 +54,6 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - private Backup( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - java.lang.String s = input.readStringRequireUtf8(); - - name_ = s; - break; - } - case 18: - { - java.lang.String s = input.readStringRequireUtf8(); - - sourceTable_ = s; - break; - } - case 26: - { - com.google.protobuf.Timestamp.Builder subBuilder = null; - if (expireTime_ != null) { - subBuilder = expireTime_.toBuilder(); - } - expireTime_ = - input.readMessage(com.google.protobuf.Timestamp.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(expireTime_); - expireTime_ = subBuilder.buildPartial(); - } - - break; - } - case 34: - { - com.google.protobuf.Timestamp.Builder subBuilder = null; - if (startTime_ != null) { - subBuilder = startTime_.toBuilder(); - } - startTime_ = - input.readMessage(com.google.protobuf.Timestamp.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(startTime_); - startTime_ = subBuilder.buildPartial(); - } - - break; - } - case 42: - { - com.google.protobuf.Timestamp.Builder subBuilder = null; - if (endTime_ != null) { - subBuilder = endTime_.toBuilder(); - } - endTime_ = - input.readMessage(com.google.protobuf.Timestamp.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(endTime_); - endTime_ = subBuilder.buildPartial(); - } - - break; - } - case 48: - { - sizeBytes_ = input.readInt64(); - break; - } - case 56: - { - int rawValue = input.readEnum(); - - state_ = rawValue; - break; - } - case 74: - { - com.google.bigtable.admin.v2.EncryptionInfo.Builder subBuilder = null; - if (encryptionInfo_ != null) { - subBuilder = encryptionInfo_.toBuilder(); - } - encryptionInfo_ = - input.readMessage( - com.google.bigtable.admin.v2.EncryptionInfo.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(encryptionInfo_); - encryptionInfo_ = subBuilder.buildPartial(); - } - - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.bigtable.admin.v2.TableProto .internal_static_google_bigtable_admin_v2_Backup_descriptor; @@ -797,7 +671,7 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io if (encryptionInfo_ != null) { output.writeMessage(9, getEncryptionInfo()); } - unknownFields.writeTo(output); + getUnknownFields().writeTo(output); } @java.lang.Override @@ -830,7 +704,7 @@ public int getSerializedSize() { if (encryptionInfo_ != null) { size += com.google.protobuf.CodedOutputStream.computeMessageSize(9, getEncryptionInfo()); } - size += unknownFields.getSerializedSize(); + size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @@ -865,7 +739,7 @@ public boolean equals(final java.lang.Object obj) { if (hasEncryptionInfo()) { if (!getEncryptionInfo().equals(other.getEncryptionInfo())) return false; } - if (!unknownFields.equals(other.unknownFields)) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -900,7 +774,7 @@ public int hashCode() { hash = (37 * hash) + ENCRYPTION_INFO_FIELD_NUMBER; hash = (53 * hash) + getEncryptionInfo().hashCode(); } - hash = (29 * hash) + unknownFields.hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } @@ -1028,17 +902,10 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { } // Construct using com.google.bigtable.admin.v2.Backup.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } + private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} } @java.lang.Override @@ -1201,7 +1068,7 @@ public Builder mergeFrom(com.google.bigtable.admin.v2.Backup other) { if (other.hasEncryptionInfo()) { mergeEncryptionInfo(other.getEncryptionInfo()); } - this.mergeUnknownFields(other.unknownFields); + this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @@ -1216,17 +1083,79 @@ public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - com.google.bigtable.admin.v2.Backup parsedMessage = null; + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + name_ = input.readStringRequireUtf8(); + + break; + } // case 10 + case 18: + { + sourceTable_ = input.readStringRequireUtf8(); + + break; + } // case 18 + case 26: + { + input.readMessage(getExpireTimeFieldBuilder().getBuilder(), extensionRegistry); + + break; + } // case 26 + case 34: + { + input.readMessage(getStartTimeFieldBuilder().getBuilder(), extensionRegistry); + + break; + } // case 34 + case 42: + { + input.readMessage(getEndTimeFieldBuilder().getBuilder(), extensionRegistry); + + break; + } // case 42 + case 48: + { + sizeBytes_ = input.readInt64(); + + break; + } // case 48 + case 56: + { + state_ = input.readEnum(); + + break; + } // case 56 + case 74: + { + input.readMessage(getEncryptionInfoFieldBuilder().getBuilder(), extensionRegistry); + + break; + } // case 74 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.bigtable.admin.v2.Backup) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } + onChanged(); + } // finally return this; } @@ -2531,7 +2460,18 @@ public Backup parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new Backup(input, extensionRegistry); + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); } }; diff --git a/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/BackupInfo.java b/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/BackupInfo.java index c962305cc2..e06a057291 100644 --- a/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/BackupInfo.java +++ b/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/BackupInfo.java @@ -53,89 +53,6 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - private BackupInfo( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - java.lang.String s = input.readStringRequireUtf8(); - - backup_ = s; - break; - } - case 18: - { - com.google.protobuf.Timestamp.Builder subBuilder = null; - if (startTime_ != null) { - subBuilder = startTime_.toBuilder(); - } - startTime_ = - input.readMessage(com.google.protobuf.Timestamp.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(startTime_); - startTime_ = subBuilder.buildPartial(); - } - - break; - } - case 26: - { - com.google.protobuf.Timestamp.Builder subBuilder = null; - if (endTime_ != null) { - subBuilder = endTime_.toBuilder(); - } - endTime_ = - input.readMessage(com.google.protobuf.Timestamp.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(endTime_); - endTime_ = subBuilder.buildPartial(); - } - - break; - } - case 34: - { - java.lang.String s = input.readStringRequireUtf8(); - - sourceTable_ = s; - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.bigtable.admin.v2.TableProto .internal_static_google_bigtable_admin_v2_BackupInfo_descriptor; @@ -379,7 +296,7 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(sourceTable_)) { com.google.protobuf.GeneratedMessageV3.writeString(output, 4, sourceTable_); } - unknownFields.writeTo(output); + getUnknownFields().writeTo(output); } @java.lang.Override @@ -400,7 +317,7 @@ public int getSerializedSize() { if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(sourceTable_)) { size += com.google.protobuf.GeneratedMessageV3.computeStringSize(4, sourceTable_); } - size += unknownFields.getSerializedSize(); + size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @@ -425,7 +342,7 @@ public boolean equals(final java.lang.Object obj) { if (!getEndTime().equals(other.getEndTime())) return false; } if (!getSourceTable().equals(other.getSourceTable())) return false; - if (!unknownFields.equals(other.unknownFields)) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -448,7 +365,7 @@ public int hashCode() { } hash = (37 * hash) + SOURCE_TABLE_FIELD_NUMBER; hash = (53 * hash) + getSourceTable().hashCode(); - hash = (29 * hash) + unknownFields.hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } @@ -577,17 +494,10 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { } // Construct using com.google.bigtable.admin.v2.BackupInfo.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } + private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} } @java.lang.Override @@ -711,7 +621,7 @@ public Builder mergeFrom(com.google.bigtable.admin.v2.BackupInfo other) { sourceTable_ = other.sourceTable_; onChanged(); } - this.mergeUnknownFields(other.unknownFields); + this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @@ -726,17 +636,55 @@ public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - com.google.bigtable.admin.v2.BackupInfo parsedMessage = null; + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + backup_ = input.readStringRequireUtf8(); + + break; + } // case 10 + case 18: + { + input.readMessage(getStartTimeFieldBuilder().getBuilder(), extensionRegistry); + + break; + } // case 18 + case 26: + { + input.readMessage(getEndTimeFieldBuilder().getBuilder(), extensionRegistry); + + break; + } // case 26 + case 34: + { + sourceTable_ = input.readStringRequireUtf8(); + + break; + } // case 34 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.bigtable.admin.v2.BackupInfo) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } + onChanged(); + } // finally return this; } @@ -1378,7 +1326,18 @@ public BackupInfo parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new BackupInfo(input, extensionRegistry); + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); } }; diff --git a/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/BigtableTableAdminProto.java b/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/BigtableTableAdminProto.java index 082eaffde9..7fe2354129 100644 --- a/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/BigtableTableAdminProto.java +++ b/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/BigtableTableAdminProto.java @@ -67,6 +67,14 @@ public static void registerAllExtensions(com.google.protobuf.ExtensionRegistry r internal_static_google_bigtable_admin_v2_GetTableRequest_descriptor; static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internal_static_google_bigtable_admin_v2_GetTableRequest_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_bigtable_admin_v2_UpdateTableRequest_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_bigtable_admin_v2_UpdateTableRequest_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_bigtable_admin_v2_UpdateTableMetadata_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_bigtable_admin_v2_UpdateTableMetadata_fieldAccessorTable; static final com.google.protobuf.Descriptors.Descriptor internal_static_google_bigtable_admin_v2_DeleteTableRequest_descriptor; static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable @@ -220,209 +228,220 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "leRequest\0228\n\004name\030\001 \001(\tB*\340A\002\372A$\n\"bigtabl" + "eadmin.googleapis.com/Table\0222\n\004view\030\002 \001(" + "\0162$.google.bigtable.admin.v2.Table.View\"" - + "N\n\022DeleteTableRequest\0228\n\004name\030\001 \001(\tB*\340A\002" - + "\372A$\n\"bigtableadmin.googleapis.com/Table\"" - + "P\n\024UndeleteTableRequest\0228\n\004name\030\001 \001(\tB*\340" - + "A\002\372A$\n\"bigtableadmin.googleapis.com/Tabl" - + "e\"\203\001\n\025UndeleteTableMetadata\022\014\n\004name\030\001 \001(" - + "\t\022.\n\nstart_time\030\002 \001(\0132\032.google.protobuf." - + "Timestamp\022,\n\010end_time\030\003 \001(\0132\032.google.pro" - + "tobuf.Timestamp\"\337\002\n\033ModifyColumnFamilies" - + "Request\0228\n\004name\030\001 \001(\tB*\340A\002\372A$\n\"bigtablea" - + "dmin.googleapis.com/Table\022^\n\rmodificatio" - + "ns\030\002 \003(\0132B.google.bigtable.admin.v2.Modi" - + "fyColumnFamiliesRequest.ModificationB\003\340A" - + "\002\032\245\001\n\014Modification\022\n\n\002id\030\001 \001(\t\0228\n\006create" - + "\030\002 \001(\0132&.google.bigtable.admin.v2.Column" - + "FamilyH\000\0228\n\006update\030\003 \001(\0132&.google.bigtab" - + "le.admin.v2.ColumnFamilyH\000\022\016\n\004drop\030\004 \001(\010" - + "H\000B\005\n\003mod\"[\n\037GenerateConsistencyTokenReq" + + "\177\n\022UpdateTableRequest\0223\n\005table\030\001 \001(\0132\037.g" + + "oogle.bigtable.admin.v2.TableB\003\340A\002\0224\n\013up" + + "date_mask\030\002 \001(\0132\032.google.protobuf.FieldM" + + "askB\003\340A\002\"\201\001\n\023UpdateTableMetadata\022\014\n\004name" + + "\030\001 \001(\t\022.\n\nstart_time\030\002 \001(\0132\032.google.prot" + + "obuf.Timestamp\022,\n\010end_time\030\003 \001(\0132\032.googl" + + "e.protobuf.Timestamp\"N\n\022DeleteTableReque" + + "st\0228\n\004name\030\001 \001(\tB*\340A\002\372A$\n\"bigtableadmin." + + "googleapis.com/Table\"P\n\024UndeleteTableReq" + "uest\0228\n\004name\030\001 \001(\tB*\340A\002\372A$\n\"bigtableadmi" - + "n.googleapis.com/Table\"=\n GenerateConsis" - + "tencyTokenResponse\022\031\n\021consistency_token\030" - + "\001 \001(\t\"s\n\027CheckConsistencyRequest\0228\n\004name" - + "\030\001 \001(\tB*\340A\002\372A$\n\"bigtableadmin.googleapis" - + ".com/Table\022\036\n\021consistency_token\030\002 \001(\tB\003\340" - + "A\002\".\n\030CheckConsistencyResponse\022\022\n\nconsis" - + "tent\030\001 \001(\010\"\346\001\n\024SnapshotTableRequest\0228\n\004n" - + "ame\030\001 \001(\tB*\340A\002\372A$\n\"bigtableadmin.googlea" - + "pis.com/Table\022=\n\007cluster\030\002 \001(\tB,\340A\002\372A&\n$" - + "bigtableadmin.googleapis.com/Cluster\022\030\n\013" - + "snapshot_id\030\003 \001(\tB\003\340A\002\022&\n\003ttl\030\004 \001(\0132\031.go" - + "ogle.protobuf.Duration\022\023\n\013description\030\005 " - + "\001(\t\"Q\n\022GetSnapshotRequest\022;\n\004name\030\001 \001(\tB" - + "-\340A\002\372A\'\n%bigtableadmin.googleapis.com/Sn" - + "apshot\"{\n\024ListSnapshotsRequest\022<\n\006parent" - + "\030\001 \001(\tB,\340A\002\372A&\n$bigtableadmin.googleapis" - + ".com/Cluster\022\021\n\tpage_size\030\002 \001(\005\022\022\n\npage_" - + "token\030\003 \001(\t\"g\n\025ListSnapshotsResponse\0225\n\t" - + "snapshots\030\001 \003(\0132\".google.bigtable.admin." - + "v2.Snapshot\022\027\n\017next_page_token\030\002 \001(\t\"T\n\025" - + "DeleteSnapshotRequest\022;\n\004name\030\001 \001(\tB-\340A\002" - + "\372A\'\n%bigtableadmin.googleapis.com/Snapsh" - + "ot\"\304\001\n\025SnapshotTableMetadata\022H\n\020original" - + "_request\030\001 \001(\0132..google.bigtable.admin.v" - + "2.SnapshotTableRequest\0220\n\014request_time\030\002" + + "n.googleapis.com/Table\"\203\001\n\025UndeleteTable" + + "Metadata\022\014\n\004name\030\001 \001(\t\022.\n\nstart_time\030\002 \001" + + "(\0132\032.google.protobuf.Timestamp\022,\n\010end_ti" + + "me\030\003 \001(\0132\032.google.protobuf.Timestamp\"\337\002\n" + + "\033ModifyColumnFamiliesRequest\0228\n\004name\030\001 \001" + + "(\tB*\340A\002\372A$\n\"bigtableadmin.googleapis.com" + + "/Table\022^\n\rmodifications\030\002 \003(\0132B.google.b" + + "igtable.admin.v2.ModifyColumnFamiliesReq" + + "uest.ModificationB\003\340A\002\032\245\001\n\014Modification\022" + + "\n\n\002id\030\001 \001(\t\0228\n\006create\030\002 \001(\0132&.google.big" + + "table.admin.v2.ColumnFamilyH\000\0228\n\006update\030" + + "\003 \001(\0132&.google.bigtable.admin.v2.ColumnF" + + "amilyH\000\022\016\n\004drop\030\004 \001(\010H\000B\005\n\003mod\"[\n\037Genera" + + "teConsistencyTokenRequest\0228\n\004name\030\001 \001(\tB" + + "*\340A\002\372A$\n\"bigtableadmin.googleapis.com/Ta" + + "ble\"=\n GenerateConsistencyTokenResponse\022" + + "\031\n\021consistency_token\030\001 \001(\t\"s\n\027CheckConsi" + + "stencyRequest\0228\n\004name\030\001 \001(\tB*\340A\002\372A$\n\"big" + + "tableadmin.googleapis.com/Table\022\036\n\021consi" + + "stency_token\030\002 \001(\tB\003\340A\002\".\n\030CheckConsiste" + + "ncyResponse\022\022\n\nconsistent\030\001 \001(\010\"\346\001\n\024Snap" + + "shotTableRequest\0228\n\004name\030\001 \001(\tB*\340A\002\372A$\n\"" + + "bigtableadmin.googleapis.com/Table\022=\n\007cl" + + "uster\030\002 \001(\tB,\340A\002\372A&\n$bigtableadmin.googl" + + "eapis.com/Cluster\022\030\n\013snapshot_id\030\003 \001(\tB\003" + + "\340A\002\022&\n\003ttl\030\004 \001(\0132\031.google.protobuf.Durat" + + "ion\022\023\n\013description\030\005 \001(\t\"Q\n\022GetSnapshotR" + + "equest\022;\n\004name\030\001 \001(\tB-\340A\002\372A\'\n%bigtablead" + + "min.googleapis.com/Snapshot\"{\n\024ListSnaps" + + "hotsRequest\022<\n\006parent\030\001 \001(\tB,\340A\002\372A&\n$big" + + "tableadmin.googleapis.com/Cluster\022\021\n\tpag" + + "e_size\030\002 \001(\005\022\022\n\npage_token\030\003 \001(\t\"g\n\025List" + + "SnapshotsResponse\0225\n\tsnapshots\030\001 \003(\0132\".g" + + "oogle.bigtable.admin.v2.Snapshot\022\027\n\017next" + + "_page_token\030\002 \001(\t\"T\n\025DeleteSnapshotReque" + + "st\022;\n\004name\030\001 \001(\tB-\340A\002\372A\'\n%bigtableadmin." + + "googleapis.com/Snapshot\"\304\001\n\025SnapshotTabl" + + "eMetadata\022H\n\020original_request\030\001 \001(\0132..go" + + "ogle.bigtable.admin.v2.SnapshotTableRequ" + + "est\0220\n\014request_time\030\002 \001(\0132\032.google.proto" + + "buf.Timestamp\022/\n\013finish_time\030\003 \001(\0132\032.goo" + + "gle.protobuf.Timestamp\"\330\001\n\037CreateTableFr" + + "omSnapshotMetadata\022R\n\020original_request\030\001" + + " \001(\01328.google.bigtable.admin.v2.CreateTa" + + "bleFromSnapshotRequest\0220\n\014request_time\030\002" + " \001(\0132\032.google.protobuf.Timestamp\022/\n\013fini" + "sh_time\030\003 \001(\0132\032.google.protobuf.Timestam" - + "p\"\330\001\n\037CreateTableFromSnapshotMetadata\022R\n" - + "\020original_request\030\001 \001(\01328.google.bigtabl" - + "e.admin.v2.CreateTableFromSnapshotReques" - + "t\0220\n\014request_time\030\002 \001(\0132\032.google.protobu" - + "f.Timestamp\022/\n\013finish_time\030\003 \001(\0132\032.googl" - + "e.protobuf.Timestamp\"\242\001\n\023CreateBackupReq" - + "uest\022<\n\006parent\030\001 \001(\tB,\340A\002\372A&\n$bigtablead" - + "min.googleapis.com/Cluster\022\026\n\tbackup_id\030" - + "\002 \001(\tB\003\340A\002\0225\n\006backup\030\003 \001(\0132 .google.bigt" - + "able.admin.v2.BackupB\003\340A\002\"\230\001\n\024CreateBack" - + "upMetadata\022\014\n\004name\030\001 \001(\t\022\024\n\014source_table" - + "\030\002 \001(\t\022.\n\nstart_time\030\003 \001(\0132\032.google.prot" - + "obuf.Timestamp\022,\n\010end_time\030\004 \001(\0132\032.googl" - + "e.protobuf.Timestamp\"\202\001\n\023UpdateBackupReq" - + "uest\0225\n\006backup\030\001 \001(\0132 .google.bigtable.a" - + "dmin.v2.BackupB\003\340A\002\0224\n\013update_mask\030\002 \001(\013" - + "2\032.google.protobuf.FieldMaskB\003\340A\002\"M\n\020Get" - + "BackupRequest\0229\n\004name\030\001 \001(\tB+\340A\002\372A%\n#big" - + "tableadmin.googleapis.com/Backup\"P\n\023Dele" - + "teBackupRequest\0229\n\004name\030\001 \001(\tB+\340A\002\372A%\n#b" - + "igtableadmin.googleapis.com/Backup\"\233\001\n\022L" - + "istBackupsRequest\022<\n\006parent\030\001 \001(\tB,\340A\002\372A" - + "&\n$bigtableadmin.googleapis.com/Cluster\022" - + "\016\n\006filter\030\002 \001(\t\022\020\n\010order_by\030\003 \001(\t\022\021\n\tpag" - + "e_size\030\004 \001(\005\022\022\n\npage_token\030\005 \001(\t\"a\n\023List" - + "BackupsResponse\0221\n\007backups\030\001 \003(\0132 .googl" - + "e.bigtable.admin.v2.Backup\022\027\n\017next_page_" - + "token\030\002 \001(\t2\341&\n\022BigtableTableAdmin\022\253\001\n\013C" - + "reateTable\022,.google.bigtable.admin.v2.Cr" - + "eateTableRequest\032\037.google.bigtable.admin" - + ".v2.Table\"M\202\323\344\223\002/\"*/v2/{parent=projects/" - + "*/instances/*}/tables:\001*\332A\025parent,table_" - + "id,table\022\212\002\n\027CreateTableFromSnapshot\0228.g" - + "oogle.bigtable.admin.v2.CreateTableFromS" - + "napshotRequest\032\035.google.longrunning.Oper" - + "ation\"\225\001\202\323\344\223\002B\"=/v2/{parent=projects/*/i" - + "nstances/*}/tables:createFromSnapshot:\001*" - + "\332A\037parent,table_id,source_snapshot\312A(\n\005T" - + "able\022\037CreateTableFromSnapshotMetadata\022\244\001" - + "\n\nListTables\022+.google.bigtable.admin.v2." - + "ListTablesRequest\032,.google.bigtable.admi" - + "n.v2.ListTablesResponse\";\202\323\344\223\002,\022*/v2/{pa" - + "rent=projects/*/instances/*}/tables\332A\006pa" - + "rent\022\221\001\n\010GetTable\022).google.bigtable.admi" - + "n.v2.GetTableRequest\032\037.google.bigtable.a" - + "dmin.v2.Table\"9\202\323\344\223\002,\022*/v2/{name=project" - + "s/*/instances/*/tables/*}\332A\004name\022\216\001\n\013Del" - + "eteTable\022,.google.bigtable.admin.v2.Dele" - + "teTableRequest\032\026.google.protobuf.Empty\"9" - + "\202\323\344\223\002,**/v2/{name=projects/*/instances/*" - + "/tables/*}\332A\004name\022\306\001\n\rUndeleteTable\022..go" - + "ogle.bigtable.admin.v2.UndeleteTableRequ" - + "est\032\035.google.longrunning.Operation\"f\202\323\344\223" - + "\0028\"3/v2/{name=projects/*/instances/*/tab" - + "les/*}:undelete:\001*\332A\004name\312A\036\n\005Table\022\025Und" - + "eleteTableMetadata\022\317\001\n\024ModifyColumnFamil" - + "ies\0225.google.bigtable.admin.v2.ModifyCol" - + "umnFamiliesRequest\032\037.google.bigtable.adm" - + "in.v2.Table\"_\202\323\344\223\002D\"?/v2/{name=projects/" - + "*/instances/*/tables/*}:modifyColumnFami" - + "lies:\001*\332A\022name,modifications\022\231\001\n\014DropRow" - + "Range\022-.google.bigtable.admin.v2.DropRow" - + "RangeRequest\032\026.google.protobuf.Empty\"B\202\323" - + "\344\223\002<\"7/v2/{name=projects/*/instances/*/t" - + "ables/*}:dropRowRange:\001*\022\350\001\n\030GenerateCon" - + "sistencyToken\0229.google.bigtable.admin.v2" - + ".GenerateConsistencyTokenRequest\032:.googl" - + "e.bigtable.admin.v2.GenerateConsistencyT" - + "okenResponse\"U\202\323\344\223\002H\"C/v2/{name=projects" - + "/*/instances/*/tables/*}:generateConsist" - + "encyToken:\001*\332A\004name\022\332\001\n\020CheckConsistency" - + "\0221.google.bigtable.admin.v2.CheckConsist" - + "encyRequest\0322.google.bigtable.admin.v2.C" - + "heckConsistencyResponse\"_\202\323\344\223\002@\";/v2/{na" - + "me=projects/*/instances/*/tables/*}:chec" - + "kConsistency:\001*\332A\026name,consistency_token" - + "\022\352\001\n\rSnapshotTable\022..google.bigtable.adm" - + "in.v2.SnapshotTableRequest\032\035.google.long" - + "running.Operation\"\211\001\202\323\344\223\0028\"3/v2/{name=pr" - + "ojects/*/instances/*/tables/*}:snapshot:" - + "\001*\332A$name,cluster,snapshot_id,descriptio" - + "n\312A!\n\010Snapshot\022\025SnapshotTableMetadata\022\250\001" - + "\n\013GetSnapshot\022,.google.bigtable.admin.v2" - + ".GetSnapshotRequest\032\".google.bigtable.ad" - + "min.v2.Snapshot\"G\202\323\344\223\002:\0228/v2/{name=proje" - + "cts/*/instances/*/clusters/*/snapshots/*" - + "}\332A\004name\022\273\001\n\rListSnapshots\022..google.bigt" - + "able.admin.v2.ListSnapshotsRequest\032/.goo" - + "gle.bigtable.admin.v2.ListSnapshotsRespo" - + "nse\"I\202\323\344\223\002:\0228/v2/{parent=projects/*/inst" - + "ances/*/clusters/*}/snapshots\332A\006parent\022\242" - + "\001\n\016DeleteSnapshot\022/.google.bigtable.admi" - + "n.v2.DeleteSnapshotRequest\032\026.google.prot" - + "obuf.Empty\"G\202\323\344\223\002:*8/v2/{name=projects/*" - + "/instances/*/clusters/*/snapshots/*}\332A\004n" - + "ame\022\340\001\n\014CreateBackup\022-.google.bigtable.a" - + "dmin.v2.CreateBackupRequest\032\035.google.lon" - + "grunning.Operation\"\201\001\202\323\344\223\002@\"6/v2/{parent" - + "=projects/*/instances/*/clusters/*}/back" - + "ups:\006backup\332A\027parent,backup_id,backup\312A\036" - + "\n\006Backup\022\024CreateBackupMetadata\022\240\001\n\tGetBa" - + "ckup\022*.google.bigtable.admin.v2.GetBacku" - + "pRequest\032 .google.bigtable.admin.v2.Back" - + "up\"E\202\323\344\223\0028\0226/v2/{name=projects/*/instanc" - + "es/*/clusters/*/backups/*}\332A\004name\022\303\001\n\014Up" - + "dateBackup\022-.google.bigtable.admin.v2.Up" - + "dateBackupRequest\032 .google.bigtable.admi" - + "n.v2.Backup\"b\202\323\344\223\002G2=/v2/{backup.name=pr" - + "ojects/*/instances/*/clusters/*/backups/" - + "*}:\006backup\332A\022backup,update_mask\022\234\001\n\014Dele" - + "teBackup\022-.google.bigtable.admin.v2.Dele" - + "teBackupRequest\032\026.google.protobuf.Empty\"" - + "E\202\323\344\223\0028*6/v2/{name=projects/*/instances/" - + "*/clusters/*/backups/*}\332A\004name\022\263\001\n\013ListB" - + "ackups\022,.google.bigtable.admin.v2.ListBa" - + "ckupsRequest\032-.google.bigtable.admin.v2." - + "ListBackupsResponse\"G\202\323\344\223\0028\0226/v2/{parent" - + "=projects/*/instances/*/clusters/*}/back" - + "ups\332A\006parent\022\273\001\n\014RestoreTable\022-.google.b" - + "igtable.admin.v2.RestoreTableRequest\032\035.g" - + "oogle.longrunning.Operation\"]\202\323\344\223\0027\"2/v2" + + "p\"\242\001\n\023CreateBackupRequest\022<\n\006parent\030\001 \001(" + + "\tB,\340A\002\372A&\n$bigtableadmin.googleapis.com/" + + "Cluster\022\026\n\tbackup_id\030\002 \001(\tB\003\340A\002\0225\n\006backu" + + "p\030\003 \001(\0132 .google.bigtable.admin.v2.Backu" + + "pB\003\340A\002\"\230\001\n\024CreateBackupMetadata\022\014\n\004name\030" + + "\001 \001(\t\022\024\n\014source_table\030\002 \001(\t\022.\n\nstart_tim" + + "e\030\003 \001(\0132\032.google.protobuf.Timestamp\022,\n\010e" + + "nd_time\030\004 \001(\0132\032.google.protobuf.Timestam" + + "p\"\202\001\n\023UpdateBackupRequest\0225\n\006backup\030\001 \001(" + + "\0132 .google.bigtable.admin.v2.BackupB\003\340A\002" + + "\0224\n\013update_mask\030\002 \001(\0132\032.google.protobuf." + + "FieldMaskB\003\340A\002\"M\n\020GetBackupRequest\0229\n\004na" + + "me\030\001 \001(\tB+\340A\002\372A%\n#bigtableadmin.googleap" + + "is.com/Backup\"P\n\023DeleteBackupRequest\0229\n\004" + + "name\030\001 \001(\tB+\340A\002\372A%\n#bigtableadmin.google" + + "apis.com/Backup\"\233\001\n\022ListBackupsRequest\022<" + + "\n\006parent\030\001 \001(\tB,\340A\002\372A&\n$bigtableadmin.go" + + "ogleapis.com/Cluster\022\016\n\006filter\030\002 \001(\t\022\020\n\010" + + "order_by\030\003 \001(\t\022\021\n\tpage_size\030\004 \001(\005\022\022\n\npag" + + "e_token\030\005 \001(\t\"a\n\023ListBackupsResponse\0221\n\007" + + "backups\030\001 \003(\0132 .google.bigtable.admin.v2" + + ".Backup\022\027\n\017next_page_token\030\002 \001(\t2\262(\n\022Big" + + "tableTableAdmin\022\253\001\n\013CreateTable\022,.google" + + ".bigtable.admin.v2.CreateTableRequest\032\037." + + "google.bigtable.admin.v2.Table\"M\202\323\344\223\002/\"*" + + "/v2/{parent=projects/*/instances/*}/tabl" + + "es:\001*\332A\025parent,table_id,table\022\212\002\n\027Create" + + "TableFromSnapshot\0228.google.bigtable.admi" + + "n.v2.CreateTableFromSnapshotRequest\032\035.go" + + "ogle.longrunning.Operation\"\225\001\202\323\344\223\002B\"=/v2" + "/{parent=projects/*/instances/*}/tables:" - + "restore:\001*\312A\035\n\005Table\022\024RestoreTableMetada" - + "ta\022\354\001\n\014GetIamPolicy\022\".google.iam.v1.GetI" - + "amPolicyRequest\032\025.google.iam.v1.Policy\"\240" - + "\001\202\323\344\223\002\216\001\";/v2/{resource=projects/*/insta" - + "nces/*/tables/*}:getIamPolicy:\001*ZL\"G/v2/" - + "{resource=projects/*/instances/*/cluster" - + "s/*/backups/*}:getIamPolicy:\001*\332A\010resourc" - + "e\022\363\001\n\014SetIamPolicy\022\".google.iam.v1.SetIa" - + "mPolicyRequest\032\025.google.iam.v1.Policy\"\247\001" - + "\202\323\344\223\002\216\001\";/v2/{resource=projects/*/instan" - + "ces/*/tables/*}:setIamPolicy:\001*ZL\"G/v2/{" - + "resource=projects/*/instances/*/clusters" - + "/*/backups/*}:setIamPolicy:\001*\332A\017resource" - + ",policy\022\244\002\n\022TestIamPermissions\022(.google." - + "iam.v1.TestIamPermissionsRequest\032).googl" - + "e.iam.v1.TestIamPermissionsResponse\"\270\001\202\323" - + "\344\223\002\232\001\"A/v2/{resource=projects/*/instance" - + "s/*/tables/*}:testIamPermissions:\001*ZR\"M/" - + "v2/{resource=projects/*/instances/*/clus" - + "ters/*/backups/*}:testIamPermissions:\001*\332" - + "A\024resource,permissions\032\336\002\312A\034bigtableadmi" - + "n.googleapis.com\322A\273\002https://www.googleap" - + "is.com/auth/bigtable.admin,https://www.g" - + "oogleapis.com/auth/bigtable.admin.table," - + "https://www.googleapis.com/auth/cloud-bi" - + "gtable.admin,https://www.googleapis.com/" - + "auth/cloud-bigtable.admin.table,https://" - + "www.googleapis.com/auth/cloud-platform,h" - + "ttps://www.googleapis.com/auth/cloud-pla" - + "tform.read-onlyB\337\001\n\034com.google.bigtable." - + "admin.v2B\027BigtableTableAdminProtoP\001Z=goo" - + "gle.golang.org/genproto/googleapis/bigta" - + "ble/admin/v2;admin\252\002\036Google.Cloud.Bigtab" - + "le.Admin.V2\312\002\036Google\\Cloud\\Bigtable\\Admi" - + "n\\V2\352\002\"Google::Cloud::Bigtable::Admin::V" - + "2b\006proto3" + + "createFromSnapshot:\001*\332A\037parent,table_id," + + "source_snapshot\312A(\n\005Table\022\037CreateTableFr" + + "omSnapshotMetadata\022\244\001\n\nListTables\022+.goog" + + "le.bigtable.admin.v2.ListTablesRequest\032," + + ".google.bigtable.admin.v2.ListTablesResp" + + "onse\";\202\323\344\223\002,\022*/v2/{parent=projects/*/ins" + + "tances/*}/tables\332A\006parent\022\221\001\n\010GetTable\022)" + + ".google.bigtable.admin.v2.GetTableReques" + + "t\032\037.google.bigtable.admin.v2.Table\"9\202\323\344\223" + + "\002,\022*/v2/{name=projects/*/instances/*/tab" + + "les/*}\332A\004name\022\316\001\n\013UpdateTable\022,.google.b" + + "igtable.admin.v2.UpdateTableRequest\032\035.go" + + "ogle.longrunning.Operation\"r\202\323\344\223\002920/v2/" + + "{table.name=projects/*/instances/*/table" + + "s/*}:\005table\332A\021table,update_mask\312A\034\n\005Tabl" + + "e\022\023UpdateTableMetadata\022\216\001\n\013DeleteTable\022," + + ".google.bigtable.admin.v2.DeleteTableReq" + + "uest\032\026.google.protobuf.Empty\"9\202\323\344\223\002,**/v" + + "2/{name=projects/*/instances/*/tables/*}" + + "\332A\004name\022\306\001\n\rUndeleteTable\022..google.bigta" + + "ble.admin.v2.UndeleteTableRequest\032\035.goog" + + "le.longrunning.Operation\"f\202\323\344\223\0028\"3/v2/{n" + + "ame=projects/*/instances/*/tables/*}:und" + + "elete:\001*\332A\004name\312A\036\n\005Table\022\025UndeleteTable" + + "Metadata\022\317\001\n\024ModifyColumnFamilies\0225.goog" + + "le.bigtable.admin.v2.ModifyColumnFamilie" + + "sRequest\032\037.google.bigtable.admin.v2.Tabl" + + "e\"_\202\323\344\223\002D\"?/v2/{name=projects/*/instance" + + "s/*/tables/*}:modifyColumnFamilies:\001*\332A\022" + + "name,modifications\022\231\001\n\014DropRowRange\022-.go" + + "ogle.bigtable.admin.v2.DropRowRangeReque" + + "st\032\026.google.protobuf.Empty\"B\202\323\344\223\002<\"7/v2/" + + "{name=projects/*/instances/*/tables/*}:d" + + "ropRowRange:\001*\022\350\001\n\030GenerateConsistencyTo" + + "ken\0229.google.bigtable.admin.v2.GenerateC" + + "onsistencyTokenRequest\032:.google.bigtable" + + ".admin.v2.GenerateConsistencyTokenRespon" + + "se\"U\202\323\344\223\002H\"C/v2/{name=projects/*/instanc" + + "es/*/tables/*}:generateConsistencyToken:" + + "\001*\332A\004name\022\332\001\n\020CheckConsistency\0221.google." + + "bigtable.admin.v2.CheckConsistencyReques" + + "t\0322.google.bigtable.admin.v2.CheckConsis" + + "tencyResponse\"_\202\323\344\223\002@\";/v2/{name=project" + + "s/*/instances/*/tables/*}:checkConsisten" + + "cy:\001*\332A\026name,consistency_token\022\352\001\n\rSnaps" + + "hotTable\022..google.bigtable.admin.v2.Snap" + + "shotTableRequest\032\035.google.longrunning.Op" + + "eration\"\211\001\202\323\344\223\0028\"3/v2/{name=projects/*/i" + + "nstances/*/tables/*}:snapshot:\001*\332A$name," + + "cluster,snapshot_id,description\312A!\n\010Snap" + + "shot\022\025SnapshotTableMetadata\022\250\001\n\013GetSnaps" + + "hot\022,.google.bigtable.admin.v2.GetSnapsh" + + "otRequest\032\".google.bigtable.admin.v2.Sna" + + "pshot\"G\202\323\344\223\002:\0228/v2/{name=projects/*/inst" + + "ances/*/clusters/*/snapshots/*}\332A\004name\022\273" + + "\001\n\rListSnapshots\022..google.bigtable.admin" + + ".v2.ListSnapshotsRequest\032/.google.bigtab" + + "le.admin.v2.ListSnapshotsResponse\"I\202\323\344\223\002" + + ":\0228/v2/{parent=projects/*/instances/*/cl" + + "usters/*}/snapshots\332A\006parent\022\242\001\n\016DeleteS" + + "napshot\022/.google.bigtable.admin.v2.Delet" + + "eSnapshotRequest\032\026.google.protobuf.Empty" + + "\"G\202\323\344\223\002:*8/v2/{name=projects/*/instances" + + "/*/clusters/*/snapshots/*}\332A\004name\022\340\001\n\014Cr" + + "eateBackup\022-.google.bigtable.admin.v2.Cr" + + "eateBackupRequest\032\035.google.longrunning.O" + + "peration\"\201\001\202\323\344\223\002@\"6/v2/{parent=projects/" + + "*/instances/*/clusters/*}/backups:\006backu" + + "p\332A\027parent,backup_id,backup\312A\036\n\006Backup\022\024" + + "CreateBackupMetadata\022\240\001\n\tGetBackup\022*.goo" + + "gle.bigtable.admin.v2.GetBackupRequest\032 " + + ".google.bigtable.admin.v2.Backup\"E\202\323\344\223\0028" + + "\0226/v2/{name=projects/*/instances/*/clust" + + "ers/*/backups/*}\332A\004name\022\303\001\n\014UpdateBackup" + + "\022-.google.bigtable.admin.v2.UpdateBackup" + + "Request\032 .google.bigtable.admin.v2.Backu" + + "p\"b\202\323\344\223\002G2=/v2/{backup.name=projects/*/i" + + "nstances/*/clusters/*/backups/*}:\006backup" + + "\332A\022backup,update_mask\022\234\001\n\014DeleteBackup\022-" + + ".google.bigtable.admin.v2.DeleteBackupRe" + + "quest\032\026.google.protobuf.Empty\"E\202\323\344\223\0028*6/" + + "v2/{name=projects/*/instances/*/clusters" + + "/*/backups/*}\332A\004name\022\263\001\n\013ListBackups\022,.g" + + "oogle.bigtable.admin.v2.ListBackupsReque" + + "st\032-.google.bigtable.admin.v2.ListBackup" + + "sResponse\"G\202\323\344\223\0028\0226/v2/{parent=projects/" + + "*/instances/*/clusters/*}/backups\332A\006pare" + + "nt\022\273\001\n\014RestoreTable\022-.google.bigtable.ad" + + "min.v2.RestoreTableRequest\032\035.google.long" + + "running.Operation\"]\202\323\344\223\0027\"2/v2/{parent=p" + + "rojects/*/instances/*}/tables:restore:\001*" + + "\312A\035\n\005Table\022\024RestoreTableMetadata\022\354\001\n\014Get" + + "IamPolicy\022\".google.iam.v1.GetIamPolicyRe" + + "quest\032\025.google.iam.v1.Policy\"\240\001\202\323\344\223\002\216\001\";" + + "/v2/{resource=projects/*/instances/*/tab" + + "les/*}:getIamPolicy:\001*ZL\"G/v2/{resource=" + + "projects/*/instances/*/clusters/*/backup" + + "s/*}:getIamPolicy:\001*\332A\010resource\022\363\001\n\014SetI" + + "amPolicy\022\".google.iam.v1.SetIamPolicyReq" + + "uest\032\025.google.iam.v1.Policy\"\247\001\202\323\344\223\002\216\001\";/" + + "v2/{resource=projects/*/instances/*/tabl" + + "es/*}:setIamPolicy:\001*ZL\"G/v2/{resource=p" + + "rojects/*/instances/*/clusters/*/backups" + + "/*}:setIamPolicy:\001*\332A\017resource,policy\022\244\002" + + "\n\022TestIamPermissions\022(.google.iam.v1.Tes" + + "tIamPermissionsRequest\032).google.iam.v1.T" + + "estIamPermissionsResponse\"\270\001\202\323\344\223\002\232\001\"A/v2" + + "/{resource=projects/*/instances/*/tables" + + "/*}:testIamPermissions:\001*ZR\"M/v2/{resour" + + "ce=projects/*/instances/*/clusters/*/bac" + + "kups/*}:testIamPermissions:\001*\332A\024resource" + + ",permissions\032\336\002\312A\034bigtableadmin.googleap" + + "is.com\322A\273\002https://www.googleapis.com/aut" + + "h/bigtable.admin,https://www.googleapis." + + "com/auth/bigtable.admin.table,https://ww" + + "w.googleapis.com/auth/cloud-bigtable.adm" + + "in,https://www.googleapis.com/auth/cloud" + + "-bigtable.admin.table,https://www.google" + + "apis.com/auth/cloud-platform,https://www" + + ".googleapis.com/auth/cloud-platform.read" + + "-onlyB\337\001\n\034com.google.bigtable.admin.v2B\027" + + "BigtableTableAdminProtoP\001Z=google.golang" + + ".org/genproto/googleapis/bigtable/admin/" + + "v2;admin\252\002\036Google.Cloud.Bigtable.Admin.V" + + "2\312\002\036Google\\Cloud\\Bigtable\\Admin\\V2\352\002\"Goo" + + "gle::Cloud::Bigtable::Admin::V2b\006proto3" }; descriptor = com.google.protobuf.Descriptors.FileDescriptor.internalBuildGeneratedFileFrom( @@ -529,8 +548,24 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { new java.lang.String[] { "Name", "View", }); - internal_static_google_bigtable_admin_v2_DeleteTableRequest_descriptor = + internal_static_google_bigtable_admin_v2_UpdateTableRequest_descriptor = getDescriptor().getMessageTypes().get(9); + internal_static_google_bigtable_admin_v2_UpdateTableRequest_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_bigtable_admin_v2_UpdateTableRequest_descriptor, + new java.lang.String[] { + "Table", "UpdateMask", + }); + internal_static_google_bigtable_admin_v2_UpdateTableMetadata_descriptor = + getDescriptor().getMessageTypes().get(10); + internal_static_google_bigtable_admin_v2_UpdateTableMetadata_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_bigtable_admin_v2_UpdateTableMetadata_descriptor, + new java.lang.String[] { + "Name", "StartTime", "EndTime", + }); + internal_static_google_bigtable_admin_v2_DeleteTableRequest_descriptor = + getDescriptor().getMessageTypes().get(11); internal_static_google_bigtable_admin_v2_DeleteTableRequest_fieldAccessorTable = new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( internal_static_google_bigtable_admin_v2_DeleteTableRequest_descriptor, @@ -538,7 +573,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "Name", }); internal_static_google_bigtable_admin_v2_UndeleteTableRequest_descriptor = - getDescriptor().getMessageTypes().get(10); + getDescriptor().getMessageTypes().get(12); internal_static_google_bigtable_admin_v2_UndeleteTableRequest_fieldAccessorTable = new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( internal_static_google_bigtable_admin_v2_UndeleteTableRequest_descriptor, @@ -546,7 +581,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "Name", }); internal_static_google_bigtable_admin_v2_UndeleteTableMetadata_descriptor = - getDescriptor().getMessageTypes().get(11); + getDescriptor().getMessageTypes().get(13); internal_static_google_bigtable_admin_v2_UndeleteTableMetadata_fieldAccessorTable = new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( internal_static_google_bigtable_admin_v2_UndeleteTableMetadata_descriptor, @@ -554,7 +589,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "Name", "StartTime", "EndTime", }); internal_static_google_bigtable_admin_v2_ModifyColumnFamiliesRequest_descriptor = - getDescriptor().getMessageTypes().get(12); + getDescriptor().getMessageTypes().get(14); internal_static_google_bigtable_admin_v2_ModifyColumnFamiliesRequest_fieldAccessorTable = new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( internal_static_google_bigtable_admin_v2_ModifyColumnFamiliesRequest_descriptor, @@ -572,7 +607,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "Id", "Create", "Update", "Drop", "Mod", }); internal_static_google_bigtable_admin_v2_GenerateConsistencyTokenRequest_descriptor = - getDescriptor().getMessageTypes().get(13); + getDescriptor().getMessageTypes().get(15); internal_static_google_bigtable_admin_v2_GenerateConsistencyTokenRequest_fieldAccessorTable = new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( internal_static_google_bigtable_admin_v2_GenerateConsistencyTokenRequest_descriptor, @@ -580,7 +615,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "Name", }); internal_static_google_bigtable_admin_v2_GenerateConsistencyTokenResponse_descriptor = - getDescriptor().getMessageTypes().get(14); + getDescriptor().getMessageTypes().get(16); internal_static_google_bigtable_admin_v2_GenerateConsistencyTokenResponse_fieldAccessorTable = new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( internal_static_google_bigtable_admin_v2_GenerateConsistencyTokenResponse_descriptor, @@ -588,7 +623,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "ConsistencyToken", }); internal_static_google_bigtable_admin_v2_CheckConsistencyRequest_descriptor = - getDescriptor().getMessageTypes().get(15); + getDescriptor().getMessageTypes().get(17); internal_static_google_bigtable_admin_v2_CheckConsistencyRequest_fieldAccessorTable = new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( internal_static_google_bigtable_admin_v2_CheckConsistencyRequest_descriptor, @@ -596,7 +631,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "Name", "ConsistencyToken", }); internal_static_google_bigtable_admin_v2_CheckConsistencyResponse_descriptor = - getDescriptor().getMessageTypes().get(16); + getDescriptor().getMessageTypes().get(18); internal_static_google_bigtable_admin_v2_CheckConsistencyResponse_fieldAccessorTable = new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( internal_static_google_bigtable_admin_v2_CheckConsistencyResponse_descriptor, @@ -604,7 +639,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "Consistent", }); internal_static_google_bigtable_admin_v2_SnapshotTableRequest_descriptor = - getDescriptor().getMessageTypes().get(17); + getDescriptor().getMessageTypes().get(19); internal_static_google_bigtable_admin_v2_SnapshotTableRequest_fieldAccessorTable = new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( internal_static_google_bigtable_admin_v2_SnapshotTableRequest_descriptor, @@ -612,7 +647,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "Name", "Cluster", "SnapshotId", "Ttl", "Description", }); internal_static_google_bigtable_admin_v2_GetSnapshotRequest_descriptor = - getDescriptor().getMessageTypes().get(18); + getDescriptor().getMessageTypes().get(20); internal_static_google_bigtable_admin_v2_GetSnapshotRequest_fieldAccessorTable = new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( internal_static_google_bigtable_admin_v2_GetSnapshotRequest_descriptor, @@ -620,7 +655,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "Name", }); internal_static_google_bigtable_admin_v2_ListSnapshotsRequest_descriptor = - getDescriptor().getMessageTypes().get(19); + getDescriptor().getMessageTypes().get(21); internal_static_google_bigtable_admin_v2_ListSnapshotsRequest_fieldAccessorTable = new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( internal_static_google_bigtable_admin_v2_ListSnapshotsRequest_descriptor, @@ -628,7 +663,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "Parent", "PageSize", "PageToken", }); internal_static_google_bigtable_admin_v2_ListSnapshotsResponse_descriptor = - getDescriptor().getMessageTypes().get(20); + getDescriptor().getMessageTypes().get(22); internal_static_google_bigtable_admin_v2_ListSnapshotsResponse_fieldAccessorTable = new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( internal_static_google_bigtable_admin_v2_ListSnapshotsResponse_descriptor, @@ -636,7 +671,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "Snapshots", "NextPageToken", }); internal_static_google_bigtable_admin_v2_DeleteSnapshotRequest_descriptor = - getDescriptor().getMessageTypes().get(21); + getDescriptor().getMessageTypes().get(23); internal_static_google_bigtable_admin_v2_DeleteSnapshotRequest_fieldAccessorTable = new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( internal_static_google_bigtable_admin_v2_DeleteSnapshotRequest_descriptor, @@ -644,7 +679,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "Name", }); internal_static_google_bigtable_admin_v2_SnapshotTableMetadata_descriptor = - getDescriptor().getMessageTypes().get(22); + getDescriptor().getMessageTypes().get(24); internal_static_google_bigtable_admin_v2_SnapshotTableMetadata_fieldAccessorTable = new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( internal_static_google_bigtable_admin_v2_SnapshotTableMetadata_descriptor, @@ -652,7 +687,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "OriginalRequest", "RequestTime", "FinishTime", }); internal_static_google_bigtable_admin_v2_CreateTableFromSnapshotMetadata_descriptor = - getDescriptor().getMessageTypes().get(23); + getDescriptor().getMessageTypes().get(25); internal_static_google_bigtable_admin_v2_CreateTableFromSnapshotMetadata_fieldAccessorTable = new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( internal_static_google_bigtable_admin_v2_CreateTableFromSnapshotMetadata_descriptor, @@ -660,7 +695,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "OriginalRequest", "RequestTime", "FinishTime", }); internal_static_google_bigtable_admin_v2_CreateBackupRequest_descriptor = - getDescriptor().getMessageTypes().get(24); + getDescriptor().getMessageTypes().get(26); internal_static_google_bigtable_admin_v2_CreateBackupRequest_fieldAccessorTable = new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( internal_static_google_bigtable_admin_v2_CreateBackupRequest_descriptor, @@ -668,7 +703,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "Parent", "BackupId", "Backup", }); internal_static_google_bigtable_admin_v2_CreateBackupMetadata_descriptor = - getDescriptor().getMessageTypes().get(25); + getDescriptor().getMessageTypes().get(27); internal_static_google_bigtable_admin_v2_CreateBackupMetadata_fieldAccessorTable = new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( internal_static_google_bigtable_admin_v2_CreateBackupMetadata_descriptor, @@ -676,7 +711,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "Name", "SourceTable", "StartTime", "EndTime", }); internal_static_google_bigtable_admin_v2_UpdateBackupRequest_descriptor = - getDescriptor().getMessageTypes().get(26); + getDescriptor().getMessageTypes().get(28); internal_static_google_bigtable_admin_v2_UpdateBackupRequest_fieldAccessorTable = new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( internal_static_google_bigtable_admin_v2_UpdateBackupRequest_descriptor, @@ -684,7 +719,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "Backup", "UpdateMask", }); internal_static_google_bigtable_admin_v2_GetBackupRequest_descriptor = - getDescriptor().getMessageTypes().get(27); + getDescriptor().getMessageTypes().get(29); internal_static_google_bigtable_admin_v2_GetBackupRequest_fieldAccessorTable = new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( internal_static_google_bigtable_admin_v2_GetBackupRequest_descriptor, @@ -692,7 +727,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "Name", }); internal_static_google_bigtable_admin_v2_DeleteBackupRequest_descriptor = - getDescriptor().getMessageTypes().get(28); + getDescriptor().getMessageTypes().get(30); internal_static_google_bigtable_admin_v2_DeleteBackupRequest_fieldAccessorTable = new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( internal_static_google_bigtable_admin_v2_DeleteBackupRequest_descriptor, @@ -700,7 +735,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "Name", }); internal_static_google_bigtable_admin_v2_ListBackupsRequest_descriptor = - getDescriptor().getMessageTypes().get(29); + getDescriptor().getMessageTypes().get(31); internal_static_google_bigtable_admin_v2_ListBackupsRequest_fieldAccessorTable = new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( internal_static_google_bigtable_admin_v2_ListBackupsRequest_descriptor, @@ -708,7 +743,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "Parent", "Filter", "OrderBy", "PageSize", "PageToken", }); internal_static_google_bigtable_admin_v2_ListBackupsResponse_descriptor = - getDescriptor().getMessageTypes().get(30); + getDescriptor().getMessageTypes().get(32); internal_static_google_bigtable_admin_v2_ListBackupsResponse_fieldAccessorTable = new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( internal_static_google_bigtable_admin_v2_ListBackupsResponse_descriptor, diff --git a/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/CheckConsistencyRequest.java b/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/CheckConsistencyRequest.java index f2b472ad5d..000ecfa098 100644 --- a/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/CheckConsistencyRequest.java +++ b/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/CheckConsistencyRequest.java @@ -54,59 +54,6 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - private CheckConsistencyRequest( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - java.lang.String s = input.readStringRequireUtf8(); - - name_ = s; - break; - } - case 18: - { - java.lang.String s = input.readStringRequireUtf8(); - - consistencyToken_ = s; - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.bigtable.admin.v2.BigtableTableAdminProto .internal_static_google_bigtable_admin_v2_CheckConsistencyRequest_descriptor; @@ -248,7 +195,7 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(consistencyToken_)) { com.google.protobuf.GeneratedMessageV3.writeString(output, 2, consistencyToken_); } - unknownFields.writeTo(output); + getUnknownFields().writeTo(output); } @java.lang.Override @@ -263,7 +210,7 @@ public int getSerializedSize() { if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(consistencyToken_)) { size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, consistencyToken_); } - size += unknownFields.getSerializedSize(); + size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @@ -281,7 +228,7 @@ public boolean equals(final java.lang.Object obj) { if (!getName().equals(other.getName())) return false; if (!getConsistencyToken().equals(other.getConsistencyToken())) return false; - if (!unknownFields.equals(other.unknownFields)) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -296,7 +243,7 @@ public int hashCode() { hash = (53 * hash) + getName().hashCode(); hash = (37 * hash) + CONSISTENCY_TOKEN_FIELD_NUMBER; hash = (53 * hash) + getConsistencyToken().hashCode(); - hash = (29 * hash) + unknownFields.hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } @@ -426,17 +373,10 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { } // Construct using com.google.bigtable.admin.v2.CheckConsistencyRequest.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } + private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} } @java.lang.Override @@ -533,7 +473,7 @@ public Builder mergeFrom(com.google.bigtable.admin.v2.CheckConsistencyRequest ot consistencyToken_ = other.consistencyToken_; onChanged(); } - this.mergeUnknownFields(other.unknownFields); + this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @@ -548,18 +488,43 @@ public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - com.google.bigtable.admin.v2.CheckConsistencyRequest parsedMessage = null; + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + name_ = input.readStringRequireUtf8(); + + break; + } // case 10 + case 18: + { + consistencyToken_ = input.readStringRequireUtf8(); + + break; + } // case 18 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = - (com.google.bigtable.admin.v2.CheckConsistencyRequest) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } + onChanged(); + } // finally return this; } @@ -827,7 +792,18 @@ public CheckConsistencyRequest parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new CheckConsistencyRequest(input, extensionRegistry); + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); } }; diff --git a/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/CheckConsistencyResponse.java b/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/CheckConsistencyResponse.java index 889537e892..1a074ebc66 100644 --- a/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/CheckConsistencyResponse.java +++ b/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/CheckConsistencyResponse.java @@ -51,50 +51,6 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - private CheckConsistencyResponse( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 8: - { - consistent_ = input.readBool(); - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.bigtable.admin.v2.BigtableTableAdminProto .internal_static_google_bigtable_admin_v2_CheckConsistencyResponse_descriptor; @@ -146,7 +102,7 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io if (consistent_ != false) { output.writeBool(1, consistent_); } - unknownFields.writeTo(output); + getUnknownFields().writeTo(output); } @java.lang.Override @@ -158,7 +114,7 @@ public int getSerializedSize() { if (consistent_ != false) { size += com.google.protobuf.CodedOutputStream.computeBoolSize(1, consistent_); } - size += unknownFields.getSerializedSize(); + size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @@ -175,7 +131,7 @@ public boolean equals(final java.lang.Object obj) { (com.google.bigtable.admin.v2.CheckConsistencyResponse) obj; if (getConsistent() != other.getConsistent()) return false; - if (!unknownFields.equals(other.unknownFields)) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -188,7 +144,7 @@ public int hashCode() { hash = (19 * hash) + getDescriptor().hashCode(); hash = (37 * hash) + CONSISTENT_FIELD_NUMBER; hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean(getConsistent()); - hash = (29 * hash) + unknownFields.hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } @@ -319,17 +275,10 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { } // Construct using com.google.bigtable.admin.v2.CheckConsistencyResponse.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } + private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} } @java.lang.Override @@ -418,7 +367,7 @@ public Builder mergeFrom(com.google.bigtable.admin.v2.CheckConsistencyResponse o if (other.getConsistent() != false) { setConsistent(other.getConsistent()); } - this.mergeUnknownFields(other.unknownFields); + this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @@ -433,18 +382,37 @@ public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - com.google.bigtable.admin.v2.CheckConsistencyResponse parsedMessage = null; + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 8: + { + consistent_ = input.readBool(); + + break; + } // case 8 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = - (com.google.bigtable.admin.v2.CheckConsistencyResponse) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } + onChanged(); + } // finally return this; } @@ -535,7 +503,18 @@ public CheckConsistencyResponse parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new CheckConsistencyResponse(input, extensionRegistry); + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); } }; diff --git a/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/Cluster.java b/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/Cluster.java index 47788cac38..f4f95f51a8 100644 --- a/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/Cluster.java +++ b/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/Cluster.java @@ -57,113 +57,6 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - private Cluster( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - java.lang.String s = input.readStringRequireUtf8(); - - name_ = s; - break; - } - case 18: - { - java.lang.String s = input.readStringRequireUtf8(); - - location_ = s; - break; - } - case 24: - { - int rawValue = input.readEnum(); - - state_ = rawValue; - break; - } - case 32: - { - serveNodes_ = input.readInt32(); - break; - } - case 40: - { - int rawValue = input.readEnum(); - - defaultStorageType_ = rawValue; - break; - } - case 50: - { - com.google.bigtable.admin.v2.Cluster.EncryptionConfig.Builder subBuilder = null; - if (encryptionConfig_ != null) { - subBuilder = encryptionConfig_.toBuilder(); - } - encryptionConfig_ = - input.readMessage( - com.google.bigtable.admin.v2.Cluster.EncryptionConfig.parser(), - extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(encryptionConfig_); - encryptionConfig_ = subBuilder.buildPartial(); - } - - break; - } - case 58: - { - com.google.bigtable.admin.v2.Cluster.ClusterConfig.Builder subBuilder = null; - if (configCase_ == 7) { - subBuilder = - ((com.google.bigtable.admin.v2.Cluster.ClusterConfig) config_).toBuilder(); - } - config_ = - input.readMessage( - com.google.bigtable.admin.v2.Cluster.ClusterConfig.parser(), - extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom((com.google.bigtable.admin.v2.Cluster.ClusterConfig) config_); - config_ = subBuilder.buildPartial(); - } - configCase_ = 7; - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.bigtable.admin.v2.InstanceProto .internal_static_google_bigtable_admin_v2_Cluster_descriptor; @@ -513,78 +406,6 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - private ClusterAutoscalingConfig( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - com.google.bigtable.admin.v2.AutoscalingLimits.Builder subBuilder = null; - if (autoscalingLimits_ != null) { - subBuilder = autoscalingLimits_.toBuilder(); - } - autoscalingLimits_ = - input.readMessage( - com.google.bigtable.admin.v2.AutoscalingLimits.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(autoscalingLimits_); - autoscalingLimits_ = subBuilder.buildPartial(); - } - - break; - } - case 18: - { - com.google.bigtable.admin.v2.AutoscalingTargets.Builder subBuilder = null; - if (autoscalingTargets_ != null) { - subBuilder = autoscalingTargets_.toBuilder(); - } - autoscalingTargets_ = - input.readMessage( - com.google.bigtable.admin.v2.AutoscalingTargets.parser(), - extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(autoscalingTargets_); - autoscalingTargets_ = subBuilder.buildPartial(); - } - - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.bigtable.admin.v2.InstanceProto .internal_static_google_bigtable_admin_v2_Cluster_ClusterAutoscalingConfig_descriptor; @@ -729,7 +550,7 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io if (autoscalingTargets_ != null) { output.writeMessage(2, getAutoscalingTargets()); } - unknownFields.writeTo(output); + getUnknownFields().writeTo(output); } @java.lang.Override @@ -745,7 +566,7 @@ public int getSerializedSize() { size += com.google.protobuf.CodedOutputStream.computeMessageSize(2, getAutoscalingTargets()); } - size += unknownFields.getSerializedSize(); + size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @@ -769,7 +590,7 @@ public boolean equals(final java.lang.Object obj) { if (hasAutoscalingTargets()) { if (!getAutoscalingTargets().equals(other.getAutoscalingTargets())) return false; } - if (!unknownFields.equals(other.unknownFields)) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -788,7 +609,7 @@ public int hashCode() { hash = (37 * hash) + AUTOSCALING_TARGETS_FIELD_NUMBER; hash = (53 * hash) + getAutoscalingTargets().hashCode(); } - hash = (29 * hash) + unknownFields.hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } @@ -920,17 +741,10 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { } // Construct using com.google.bigtable.admin.v2.Cluster.ClusterAutoscalingConfig.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } + private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} } @java.lang.Override @@ -1046,7 +860,7 @@ public Builder mergeFrom( if (other.hasAutoscalingTargets()) { mergeAutoscalingTargets(other.getAutoscalingTargets()); } - this.mergeUnknownFields(other.unknownFields); + this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @@ -1061,19 +875,45 @@ public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - com.google.bigtable.admin.v2.Cluster.ClusterAutoscalingConfig parsedMessage = null; + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + input.readMessage( + getAutoscalingLimitsFieldBuilder().getBuilder(), extensionRegistry); + + break; + } // case 10 + case 18: + { + input.readMessage( + getAutoscalingTargetsFieldBuilder().getBuilder(), extensionRegistry); + + break; + } // case 18 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = - (com.google.bigtable.admin.v2.Cluster.ClusterAutoscalingConfig) - e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } + onChanged(); + } // finally return this; } @@ -1524,7 +1364,19 @@ public ClusterAutoscalingConfig parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new ClusterAutoscalingConfig(input, extensionRegistry); + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException() + .setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); } }; @@ -1623,63 +1475,6 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - private ClusterConfig( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - com.google.bigtable.admin.v2.Cluster.ClusterAutoscalingConfig.Builder subBuilder = - null; - if (clusterAutoscalingConfig_ != null) { - subBuilder = clusterAutoscalingConfig_.toBuilder(); - } - clusterAutoscalingConfig_ = - input.readMessage( - com.google.bigtable.admin.v2.Cluster.ClusterAutoscalingConfig.parser(), - extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(clusterAutoscalingConfig_); - clusterAutoscalingConfig_ = subBuilder.buildPartial(); - } - - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.bigtable.admin.v2.InstanceProto .internal_static_google_bigtable_admin_v2_Cluster_ClusterConfig_descriptor; @@ -1768,7 +1563,7 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io if (clusterAutoscalingConfig_ != null) { output.writeMessage(1, getClusterAutoscalingConfig()); } - unknownFields.writeTo(output); + getUnknownFields().writeTo(output); } @java.lang.Override @@ -1782,7 +1577,7 @@ public int getSerializedSize() { com.google.protobuf.CodedOutputStream.computeMessageSize( 1, getClusterAutoscalingConfig()); } - size += unknownFields.getSerializedSize(); + size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @@ -1803,7 +1598,7 @@ public boolean equals(final java.lang.Object obj) { if (!getClusterAutoscalingConfig().equals(other.getClusterAutoscalingConfig())) return false; } - if (!unknownFields.equals(other.unknownFields)) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -1818,7 +1613,7 @@ public int hashCode() { hash = (37 * hash) + CLUSTER_AUTOSCALING_CONFIG_FIELD_NUMBER; hash = (53 * hash) + getClusterAutoscalingConfig().hashCode(); } - hash = (29 * hash) + unknownFields.hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } @@ -1949,17 +1744,10 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { } // Construct using com.google.bigtable.admin.v2.Cluster.ClusterConfig.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } + private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} } @java.lang.Override @@ -2058,7 +1846,7 @@ public Builder mergeFrom(com.google.bigtable.admin.v2.Cluster.ClusterConfig othe if (other.hasClusterAutoscalingConfig()) { mergeClusterAutoscalingConfig(other.getClusterAutoscalingConfig()); } - this.mergeUnknownFields(other.unknownFields); + this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @@ -2073,18 +1861,38 @@ public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - com.google.bigtable.admin.v2.Cluster.ClusterConfig parsedMessage = null; + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + input.readMessage( + getClusterAutoscalingConfigFieldBuilder().getBuilder(), extensionRegistry); + + break; + } // case 10 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = - (com.google.bigtable.admin.v2.Cluster.ClusterConfig) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } + onChanged(); + } // finally return this; } @@ -2332,7 +2140,19 @@ public ClusterConfig parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new ClusterConfig(input, extensionRegistry); + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException() + .setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); } }; @@ -2434,52 +2254,6 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - private EncryptionConfig( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - java.lang.String s = input.readStringRequireUtf8(); - - kmsKeyName_ = s; - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.bigtable.admin.v2.InstanceProto .internal_static_google_bigtable_admin_v2_Cluster_EncryptionConfig_descriptor; @@ -2579,7 +2353,7 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(kmsKeyName_)) { com.google.protobuf.GeneratedMessageV3.writeString(output, 1, kmsKeyName_); } - unknownFields.writeTo(output); + getUnknownFields().writeTo(output); } @java.lang.Override @@ -2591,7 +2365,7 @@ public int getSerializedSize() { if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(kmsKeyName_)) { size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, kmsKeyName_); } - size += unknownFields.getSerializedSize(); + size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @@ -2608,7 +2382,7 @@ public boolean equals(final java.lang.Object obj) { (com.google.bigtable.admin.v2.Cluster.EncryptionConfig) obj; if (!getKmsKeyName().equals(other.getKmsKeyName())) return false; - if (!unknownFields.equals(other.unknownFields)) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -2621,7 +2395,7 @@ public int hashCode() { hash = (19 * hash) + getDescriptor().hashCode(); hash = (37 * hash) + KMS_KEY_NAME_FIELD_NUMBER; hash = (53 * hash) + getKmsKeyName().hashCode(); - hash = (29 * hash) + unknownFields.hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } @@ -2754,17 +2528,10 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { } // Construct using com.google.bigtable.admin.v2.Cluster.EncryptionConfig.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } + private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} } @java.lang.Override @@ -2856,7 +2623,7 @@ public Builder mergeFrom(com.google.bigtable.admin.v2.Cluster.EncryptionConfig o kmsKeyName_ = other.kmsKeyName_; onChanged(); } - this.mergeUnknownFields(other.unknownFields); + this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @@ -2871,18 +2638,37 @@ public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - com.google.bigtable.admin.v2.Cluster.EncryptionConfig parsedMessage = null; + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + kmsKeyName_ = input.readStringRequireUtf8(); + + break; + } // case 10 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = - (com.google.bigtable.admin.v2.Cluster.EncryptionConfig) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } + onChanged(); + } // finally return this; } @@ -3070,7 +2856,19 @@ public EncryptionConfig parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new EncryptionConfig(input, extensionRegistry); + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException() + .setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); } }; @@ -3486,7 +3284,7 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io if (configCase_ == 7) { output.writeMessage(7, (com.google.bigtable.admin.v2.Cluster.ClusterConfig) config_); } - unknownFields.writeTo(output); + getUnknownFields().writeTo(output); } @java.lang.Override @@ -3519,7 +3317,7 @@ public int getSerializedSize() { com.google.protobuf.CodedOutputStream.computeMessageSize( 7, (com.google.bigtable.admin.v2.Cluster.ClusterConfig) config_); } - size += unknownFields.getSerializedSize(); + size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @@ -3551,7 +3349,7 @@ public boolean equals(final java.lang.Object obj) { case 0: default: } - if (!unknownFields.equals(other.unknownFields)) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -3584,7 +3382,7 @@ public int hashCode() { case 0: default: } - hash = (29 * hash) + unknownFields.hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } @@ -3714,17 +3512,10 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { } // Construct using com.google.bigtable.admin.v2.Cluster.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } + private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} } @java.lang.Override @@ -3738,6 +3529,9 @@ public Builder clear() { serveNodes_ = 0; + if (clusterConfigBuilder_ != null) { + clusterConfigBuilder_.clear(); + } defaultStorageType_ = 0; if (encryptionConfigBuilder_ == null) { @@ -3872,7 +3666,7 @@ public Builder mergeFrom(com.google.bigtable.admin.v2.Cluster other) { break; } } - this.mergeUnknownFields(other.unknownFields); + this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @@ -3887,17 +3681,74 @@ public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - com.google.bigtable.admin.v2.Cluster parsedMessage = null; + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + name_ = input.readStringRequireUtf8(); + + break; + } // case 10 + case 18: + { + location_ = input.readStringRequireUtf8(); + + break; + } // case 18 + case 24: + { + state_ = input.readEnum(); + + break; + } // case 24 + case 32: + { + serveNodes_ = input.readInt32(); + + break; + } // case 32 + case 40: + { + defaultStorageType_ = input.readEnum(); + + break; + } // case 40 + case 50: + { + input.readMessage( + getEncryptionConfigFieldBuilder().getBuilder(), extensionRegistry); + + break; + } // case 50 + case 58: + { + input.readMessage(getClusterConfigFieldBuilder().getBuilder(), extensionRegistry); + configCase_ = 7; + break; + } // case 58 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.bigtable.admin.v2.Cluster) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } + onChanged(); + } // finally return this; } @@ -4869,7 +4720,18 @@ public Cluster parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new Cluster(input, extensionRegistry); + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); } }; diff --git a/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/ColumnFamily.java b/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/ColumnFamily.java index 435652a733..5735bb824b 100644 --- a/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/ColumnFamily.java +++ b/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/ColumnFamily.java @@ -50,61 +50,6 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - private ColumnFamily( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - com.google.bigtable.admin.v2.GcRule.Builder subBuilder = null; - if (gcRule_ != null) { - subBuilder = gcRule_.toBuilder(); - } - gcRule_ = - input.readMessage( - com.google.bigtable.admin.v2.GcRule.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(gcRule_); - gcRule_ = subBuilder.buildPartial(); - } - - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.bigtable.admin.v2.TableProto .internal_static_google_bigtable_admin_v2_ColumnFamily_descriptor; @@ -195,7 +140,7 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io if (gcRule_ != null) { output.writeMessage(1, getGcRule()); } - unknownFields.writeTo(output); + getUnknownFields().writeTo(output); } @java.lang.Override @@ -207,7 +152,7 @@ public int getSerializedSize() { if (gcRule_ != null) { size += com.google.protobuf.CodedOutputStream.computeMessageSize(1, getGcRule()); } - size += unknownFields.getSerializedSize(); + size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @@ -227,7 +172,7 @@ public boolean equals(final java.lang.Object obj) { if (hasGcRule()) { if (!getGcRule().equals(other.getGcRule())) return false; } - if (!unknownFields.equals(other.unknownFields)) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -242,7 +187,7 @@ public int hashCode() { hash = (37 * hash) + GC_RULE_FIELD_NUMBER; hash = (53 * hash) + getGcRule().hashCode(); } - hash = (29 * hash) + unknownFields.hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } @@ -371,17 +316,10 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { } // Construct using com.google.bigtable.admin.v2.ColumnFamily.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } + private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} } @java.lang.Override @@ -477,7 +415,7 @@ public Builder mergeFrom(com.google.bigtable.admin.v2.ColumnFamily other) { if (other.hasGcRule()) { mergeGcRule(other.getGcRule()); } - this.mergeUnknownFields(other.unknownFields); + this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @@ -492,17 +430,37 @@ public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - com.google.bigtable.admin.v2.ColumnFamily parsedMessage = null; + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + input.readMessage(getGcRuleFieldBuilder().getBuilder(), extensionRegistry); + + break; + } // case 10 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.bigtable.admin.v2.ColumnFamily) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } + onChanged(); + } // finally return this; } @@ -755,7 +713,18 @@ public ColumnFamily parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new ColumnFamily(input, extensionRegistry); + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); } }; diff --git a/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/CreateAppProfileRequest.java b/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/CreateAppProfileRequest.java index f1e5f2b8c1..631369711d 100644 --- a/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/CreateAppProfileRequest.java +++ b/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/CreateAppProfileRequest.java @@ -53,80 +53,6 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - private CreateAppProfileRequest( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - java.lang.String s = input.readStringRequireUtf8(); - - parent_ = s; - break; - } - case 18: - { - java.lang.String s = input.readStringRequireUtf8(); - - appProfileId_ = s; - break; - } - case 26: - { - com.google.bigtable.admin.v2.AppProfile.Builder subBuilder = null; - if (appProfile_ != null) { - subBuilder = appProfile_.toBuilder(); - } - appProfile_ = - input.readMessage( - com.google.bigtable.admin.v2.AppProfile.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(appProfile_); - appProfile_ = subBuilder.buildPartial(); - } - - break; - } - case 32: - { - ignoreWarnings_ = input.readBool(); - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.bigtable.admin.v2.BigtableInstanceAdminProto .internal_static_google_bigtable_admin_v2_CreateAppProfileRequest_descriptor; @@ -353,7 +279,7 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io if (ignoreWarnings_ != false) { output.writeBool(4, ignoreWarnings_); } - unknownFields.writeTo(output); + getUnknownFields().writeTo(output); } @java.lang.Override @@ -374,7 +300,7 @@ public int getSerializedSize() { if (ignoreWarnings_ != false) { size += com.google.protobuf.CodedOutputStream.computeBoolSize(4, ignoreWarnings_); } - size += unknownFields.getSerializedSize(); + size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @@ -397,7 +323,7 @@ public boolean equals(final java.lang.Object obj) { if (!getAppProfile().equals(other.getAppProfile())) return false; } if (getIgnoreWarnings() != other.getIgnoreWarnings()) return false; - if (!unknownFields.equals(other.unknownFields)) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -418,7 +344,7 @@ public int hashCode() { } hash = (37 * hash) + IGNORE_WARNINGS_FIELD_NUMBER; hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean(getIgnoreWarnings()); - hash = (29 * hash) + unknownFields.hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } @@ -547,17 +473,10 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { } // Construct using com.google.bigtable.admin.v2.CreateAppProfileRequest.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } + private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} } @java.lang.Override @@ -674,7 +593,7 @@ public Builder mergeFrom(com.google.bigtable.admin.v2.CreateAppProfileRequest ot if (other.getIgnoreWarnings() != false) { setIgnoreWarnings(other.getIgnoreWarnings()); } - this.mergeUnknownFields(other.unknownFields); + this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @@ -689,18 +608,55 @@ public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - com.google.bigtable.admin.v2.CreateAppProfileRequest parsedMessage = null; + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + parent_ = input.readStringRequireUtf8(); + + break; + } // case 10 + case 18: + { + appProfileId_ = input.readStringRequireUtf8(); + + break; + } // case 18 + case 26: + { + input.readMessage(getAppProfileFieldBuilder().getBuilder(), extensionRegistry); + + break; + } // case 26 + case 32: + { + ignoreWarnings_ = input.readBool(); + + break; + } // case 32 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = - (com.google.bigtable.admin.v2.CreateAppProfileRequest) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } + onChanged(); + } // finally return this; } @@ -1242,7 +1198,18 @@ public CreateAppProfileRequest parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new CreateAppProfileRequest(input, extensionRegistry); + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); } }; diff --git a/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/CreateBackupMetadata.java b/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/CreateBackupMetadata.java index 36299f11e2..457f33ef61 100644 --- a/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/CreateBackupMetadata.java +++ b/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/CreateBackupMetadata.java @@ -54,89 +54,6 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - private CreateBackupMetadata( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - java.lang.String s = input.readStringRequireUtf8(); - - name_ = s; - break; - } - case 18: - { - java.lang.String s = input.readStringRequireUtf8(); - - sourceTable_ = s; - break; - } - case 26: - { - com.google.protobuf.Timestamp.Builder subBuilder = null; - if (startTime_ != null) { - subBuilder = startTime_.toBuilder(); - } - startTime_ = - input.readMessage(com.google.protobuf.Timestamp.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(startTime_); - startTime_ = subBuilder.buildPartial(); - } - - break; - } - case 34: - { - com.google.protobuf.Timestamp.Builder subBuilder = null; - if (endTime_ != null) { - subBuilder = endTime_.toBuilder(); - } - endTime_ = - input.readMessage(com.google.protobuf.Timestamp.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(endTime_); - endTime_ = subBuilder.buildPartial(); - } - - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.bigtable.admin.v2.BigtableTableAdminProto .internal_static_google_bigtable_admin_v2_CreateBackupMetadata_descriptor; @@ -368,7 +285,7 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io if (endTime_ != null) { output.writeMessage(4, getEndTime()); } - unknownFields.writeTo(output); + getUnknownFields().writeTo(output); } @java.lang.Override @@ -389,7 +306,7 @@ public int getSerializedSize() { if (endTime_ != null) { size += com.google.protobuf.CodedOutputStream.computeMessageSize(4, getEndTime()); } - size += unknownFields.getSerializedSize(); + size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @@ -415,7 +332,7 @@ public boolean equals(final java.lang.Object obj) { if (hasEndTime()) { if (!getEndTime().equals(other.getEndTime())) return false; } - if (!unknownFields.equals(other.unknownFields)) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -438,7 +355,7 @@ public int hashCode() { hash = (37 * hash) + END_TIME_FIELD_NUMBER; hash = (53 * hash) + getEndTime().hashCode(); } - hash = (29 * hash) + unknownFields.hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } @@ -568,17 +485,10 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { } // Construct using com.google.bigtable.admin.v2.CreateBackupMetadata.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } + private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} } @java.lang.Override @@ -703,7 +613,7 @@ public Builder mergeFrom(com.google.bigtable.admin.v2.CreateBackupMetadata other if (other.hasEndTime()) { mergeEndTime(other.getEndTime()); } - this.mergeUnknownFields(other.unknownFields); + this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @@ -718,18 +628,55 @@ public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - com.google.bigtable.admin.v2.CreateBackupMetadata parsedMessage = null; + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + name_ = input.readStringRequireUtf8(); + + break; + } // case 10 + case 18: + { + sourceTable_ = input.readStringRequireUtf8(); + + break; + } // case 18 + case 26: + { + input.readMessage(getStartTimeFieldBuilder().getBuilder(), extensionRegistry); + + break; + } // case 26 + case 34: + { + input.readMessage(getEndTimeFieldBuilder().getBuilder(), extensionRegistry); + + break; + } // case 34 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = - (com.google.bigtable.admin.v2.CreateBackupMetadata) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } + onChanged(); + } // finally return this; } @@ -1335,7 +1282,18 @@ public CreateBackupMetadata parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new CreateBackupMetadata(input, extensionRegistry); + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); } }; diff --git a/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/CreateBackupRequest.java b/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/CreateBackupRequest.java index 7bf7bd2419..a897824bcd 100644 --- a/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/CreateBackupRequest.java +++ b/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/CreateBackupRequest.java @@ -53,75 +53,6 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - private CreateBackupRequest( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - java.lang.String s = input.readStringRequireUtf8(); - - parent_ = s; - break; - } - case 18: - { - java.lang.String s = input.readStringRequireUtf8(); - - backupId_ = s; - break; - } - case 26: - { - com.google.bigtable.admin.v2.Backup.Builder subBuilder = null; - if (backup_ != null) { - subBuilder = backup_.toBuilder(); - } - backup_ = - input.readMessage( - com.google.bigtable.admin.v2.Backup.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(backup_); - backup_ = subBuilder.buildPartial(); - } - - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.bigtable.admin.v2.BigtableTableAdminProto .internal_static_google_bigtable_admin_v2_CreateBackupRequest_descriptor; @@ -325,7 +256,7 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io if (backup_ != null) { output.writeMessage(3, getBackup()); } - unknownFields.writeTo(output); + getUnknownFields().writeTo(output); } @java.lang.Override @@ -343,7 +274,7 @@ public int getSerializedSize() { if (backup_ != null) { size += com.google.protobuf.CodedOutputStream.computeMessageSize(3, getBackup()); } - size += unknownFields.getSerializedSize(); + size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @@ -365,7 +296,7 @@ public boolean equals(final java.lang.Object obj) { if (hasBackup()) { if (!getBackup().equals(other.getBackup())) return false; } - if (!unknownFields.equals(other.unknownFields)) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -384,7 +315,7 @@ public int hashCode() { hash = (37 * hash) + BACKUP_FIELD_NUMBER; hash = (53 * hash) + getBackup().hashCode(); } - hash = (29 * hash) + unknownFields.hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } @@ -513,17 +444,10 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { } // Construct using com.google.bigtable.admin.v2.CreateBackupRequest.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } + private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} } @java.lang.Override @@ -634,7 +558,7 @@ public Builder mergeFrom(com.google.bigtable.admin.v2.CreateBackupRequest other) if (other.hasBackup()) { mergeBackup(other.getBackup()); } - this.mergeUnknownFields(other.unknownFields); + this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @@ -649,17 +573,49 @@ public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - com.google.bigtable.admin.v2.CreateBackupRequest parsedMessage = null; + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + parent_ = input.readStringRequireUtf8(); + + break; + } // case 10 + case 18: + { + backupId_ = input.readStringRequireUtf8(); + + break; + } // case 18 + case 26: + { + input.readMessage(getBackupFieldBuilder().getBuilder(), extensionRegistry); + + break; + } // case 26 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.bigtable.admin.v2.CreateBackupRequest) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } + onChanged(); + } // finally return this; } @@ -1142,7 +1098,18 @@ public CreateBackupRequest parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new CreateBackupRequest(input, extensionRegistry); + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); } }; diff --git a/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/CreateClusterMetadata.java b/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/CreateClusterMetadata.java index a0e0c63691..13c30f5d4a 100644 --- a/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/CreateClusterMetadata.java +++ b/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/CreateClusterMetadata.java @@ -50,110 +50,6 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - private CreateClusterMetadata( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - int mutable_bitField0_ = 0; - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - com.google.bigtable.admin.v2.CreateClusterRequest.Builder subBuilder = null; - if (originalRequest_ != null) { - subBuilder = originalRequest_.toBuilder(); - } - originalRequest_ = - input.readMessage( - com.google.bigtable.admin.v2.CreateClusterRequest.parser(), - extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(originalRequest_); - originalRequest_ = subBuilder.buildPartial(); - } - - break; - } - case 18: - { - com.google.protobuf.Timestamp.Builder subBuilder = null; - if (requestTime_ != null) { - subBuilder = requestTime_.toBuilder(); - } - requestTime_ = - input.readMessage(com.google.protobuf.Timestamp.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(requestTime_); - requestTime_ = subBuilder.buildPartial(); - } - - break; - } - case 26: - { - com.google.protobuf.Timestamp.Builder subBuilder = null; - if (finishTime_ != null) { - subBuilder = finishTime_.toBuilder(); - } - finishTime_ = - input.readMessage(com.google.protobuf.Timestamp.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(finishTime_); - finishTime_ = subBuilder.buildPartial(); - } - - break; - } - case 34: - { - if (!((mutable_bitField0_ & 0x00000001) != 0)) { - tables_ = - com.google.protobuf.MapField.newMapField(TablesDefaultEntryHolder.defaultEntry); - mutable_bitField0_ |= 0x00000001; - } - com.google.protobuf.MapEntry< - java.lang.String, - com.google.bigtable.admin.v2.CreateClusterMetadata.TableProgress> - tables__ = - input.readMessage( - TablesDefaultEntryHolder.defaultEntry.getParserForType(), - extensionRegistry); - tables_.getMutableMap().put(tables__.getKey(), tables__.getValue()); - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.bigtable.admin.v2.BigtableInstanceAdminProto .internal_static_google_bigtable_admin_v2_CreateClusterMetadata_descriptor; @@ -260,62 +156,6 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - private TableProgress( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 16: - { - estimatedSizeBytes_ = input.readInt64(); - break; - } - case 24: - { - estimatedCopiedBytes_ = input.readInt64(); - break; - } - case 32: - { - int rawValue = input.readEnum(); - - state_ = rawValue; - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.bigtable.admin.v2.BigtableInstanceAdminProto .internal_static_google_bigtable_admin_v2_CreateClusterMetadata_TableProgress_descriptor; @@ -604,7 +444,7 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io .getNumber()) { output.writeEnum(4, state_); } - unknownFields.writeTo(output); + getUnknownFields().writeTo(output); } @java.lang.Override @@ -625,7 +465,7 @@ public int getSerializedSize() { .getNumber()) { size += com.google.protobuf.CodedOutputStream.computeEnumSize(4, state_); } - size += unknownFields.getSerializedSize(); + size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @@ -644,7 +484,7 @@ public boolean equals(final java.lang.Object obj) { if (getEstimatedSizeBytes() != other.getEstimatedSizeBytes()) return false; if (getEstimatedCopiedBytes() != other.getEstimatedCopiedBytes()) return false; if (state_ != other.state_) return false; - if (!unknownFields.equals(other.unknownFields)) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -661,7 +501,7 @@ public int hashCode() { hash = (53 * hash) + com.google.protobuf.Internal.hashLong(getEstimatedCopiedBytes()); hash = (37 * hash) + STATE_FIELD_NUMBER; hash = (53 * hash) + state_; - hash = (29 * hash) + unknownFields.hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } @@ -795,17 +635,10 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { // Construct using // com.google.bigtable.admin.v2.CreateClusterMetadata.TableProgress.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } + private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} } @java.lang.Override @@ -913,7 +746,7 @@ public Builder mergeFrom( if (other.state_ != 0) { setStateValue(other.getStateValue()); } - this.mergeUnknownFields(other.unknownFields); + this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @@ -928,19 +761,49 @@ public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - com.google.bigtable.admin.v2.CreateClusterMetadata.TableProgress parsedMessage = null; + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 16: + { + estimatedSizeBytes_ = input.readInt64(); + + break; + } // case 16 + case 24: + { + estimatedCopiedBytes_ = input.readInt64(); + + break; + } // case 24 + case 32: + { + state_ = input.readEnum(); + + break; + } // case 32 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = - (com.google.bigtable.admin.v2.CreateClusterMetadata.TableProgress) - e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } + onChanged(); + } // finally return this; } @@ -1153,7 +1016,19 @@ public TableProgress parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new TableProgress(input, extensionRegistry); + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException() + .setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); } }; @@ -1489,7 +1364,7 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io } com.google.protobuf.GeneratedMessageV3.serializeStringMapTo( output, internalGetTables(), TablesDefaultEntryHolder.defaultEntry, 4); - unknownFields.writeTo(output); + getUnknownFields().writeTo(output); } @java.lang.Override @@ -1520,7 +1395,7 @@ public int getSerializedSize() { .build(); size += com.google.protobuf.CodedOutputStream.computeMessageSize(4, tables__); } - size += unknownFields.getSerializedSize(); + size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @@ -1549,7 +1424,7 @@ public boolean equals(final java.lang.Object obj) { if (!getFinishTime().equals(other.getFinishTime())) return false; } if (!internalGetTables().equals(other.internalGetTables())) return false; - if (!unknownFields.equals(other.unknownFields)) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -1576,7 +1451,7 @@ public int hashCode() { hash = (37 * hash) + TABLES_FIELD_NUMBER; hash = (53 * hash) + internalGetTables().hashCode(); } - hash = (29 * hash) + unknownFields.hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } @@ -1725,17 +1600,10 @@ protected com.google.protobuf.MapField internalGetMutableMapField(int number) { } // Construct using com.google.bigtable.admin.v2.CreateClusterMetadata.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } + private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} } @java.lang.Override @@ -1865,7 +1733,7 @@ public Builder mergeFrom(com.google.bigtable.admin.v2.CreateClusterMetadata othe mergeFinishTime(other.getFinishTime()); } internalGetMutableTables().mergeFrom(other.internalGetTables()); - this.mergeUnknownFields(other.unknownFields); + this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @@ -1880,18 +1748,63 @@ public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - com.google.bigtable.admin.v2.CreateClusterMetadata parsedMessage = null; + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + input.readMessage(getOriginalRequestFieldBuilder().getBuilder(), extensionRegistry); + + break; + } // case 10 + case 18: + { + input.readMessage(getRequestTimeFieldBuilder().getBuilder(), extensionRegistry); + + break; + } // case 18 + case 26: + { + input.readMessage(getFinishTimeFieldBuilder().getBuilder(), extensionRegistry); + + break; + } // case 26 + case 34: + { + com.google.protobuf.MapEntry< + java.lang.String, + com.google.bigtable.admin.v2.CreateClusterMetadata.TableProgress> + tables__ = + input.readMessage( + TablesDefaultEntryHolder.defaultEntry.getParserForType(), + extensionRegistry); + internalGetMutableTables() + .getMutableMap() + .put(tables__.getKey(), tables__.getValue()); + break; + } // case 34 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = - (com.google.bigtable.admin.v2.CreateClusterMetadata) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } + onChanged(); + } // finally return this; } @@ -2720,7 +2633,18 @@ public CreateClusterMetadata parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new CreateClusterMetadata(input, extensionRegistry); + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); } }; diff --git a/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/CreateClusterRequest.java b/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/CreateClusterRequest.java index 47e620f52d..f6666ab297 100644 --- a/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/CreateClusterRequest.java +++ b/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/CreateClusterRequest.java @@ -53,75 +53,6 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - private CreateClusterRequest( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - java.lang.String s = input.readStringRequireUtf8(); - - parent_ = s; - break; - } - case 18: - { - java.lang.String s = input.readStringRequireUtf8(); - - clusterId_ = s; - break; - } - case 26: - { - com.google.bigtable.admin.v2.Cluster.Builder subBuilder = null; - if (cluster_ != null) { - subBuilder = cluster_.toBuilder(); - } - cluster_ = - input.readMessage( - com.google.bigtable.admin.v2.Cluster.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(cluster_); - cluster_ = subBuilder.buildPartial(); - } - - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.bigtable.admin.v2.BigtableInstanceAdminProto .internal_static_google_bigtable_admin_v2_CreateClusterRequest_descriptor; @@ -322,7 +253,7 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io if (cluster_ != null) { output.writeMessage(3, getCluster()); } - unknownFields.writeTo(output); + getUnknownFields().writeTo(output); } @java.lang.Override @@ -340,7 +271,7 @@ public int getSerializedSize() { if (cluster_ != null) { size += com.google.protobuf.CodedOutputStream.computeMessageSize(3, getCluster()); } - size += unknownFields.getSerializedSize(); + size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @@ -362,7 +293,7 @@ public boolean equals(final java.lang.Object obj) { if (hasCluster()) { if (!getCluster().equals(other.getCluster())) return false; } - if (!unknownFields.equals(other.unknownFields)) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -381,7 +312,7 @@ public int hashCode() { hash = (37 * hash) + CLUSTER_FIELD_NUMBER; hash = (53 * hash) + getCluster().hashCode(); } - hash = (29 * hash) + unknownFields.hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } @@ -510,17 +441,10 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { } // Construct using com.google.bigtable.admin.v2.CreateClusterRequest.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } + private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} } @java.lang.Override @@ -631,7 +555,7 @@ public Builder mergeFrom(com.google.bigtable.admin.v2.CreateClusterRequest other if (other.hasCluster()) { mergeCluster(other.getCluster()); } - this.mergeUnknownFields(other.unknownFields); + this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @@ -646,18 +570,49 @@ public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - com.google.bigtable.admin.v2.CreateClusterRequest parsedMessage = null; + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + parent_ = input.readStringRequireUtf8(); + + break; + } // case 10 + case 18: + { + clusterId_ = input.readStringRequireUtf8(); + + break; + } // case 18 + case 26: + { + input.readMessage(getClusterFieldBuilder().getBuilder(), extensionRegistry); + + break; + } // case 26 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = - (com.google.bigtable.admin.v2.CreateClusterRequest) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } + onChanged(); + } // finally return this; } @@ -1147,7 +1102,18 @@ public CreateClusterRequest parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new CreateClusterRequest(input, extensionRegistry); + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); } }; diff --git a/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/CreateInstanceMetadata.java b/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/CreateInstanceMetadata.java index 139cc8e730..75394c9779 100644 --- a/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/CreateInstanceMetadata.java +++ b/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/CreateInstanceMetadata.java @@ -50,92 +50,6 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - private CreateInstanceMetadata( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - com.google.bigtable.admin.v2.CreateInstanceRequest.Builder subBuilder = null; - if (originalRequest_ != null) { - subBuilder = originalRequest_.toBuilder(); - } - originalRequest_ = - input.readMessage( - com.google.bigtable.admin.v2.CreateInstanceRequest.parser(), - extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(originalRequest_); - originalRequest_ = subBuilder.buildPartial(); - } - - break; - } - case 18: - { - com.google.protobuf.Timestamp.Builder subBuilder = null; - if (requestTime_ != null) { - subBuilder = requestTime_.toBuilder(); - } - requestTime_ = - input.readMessage(com.google.protobuf.Timestamp.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(requestTime_); - requestTime_ = subBuilder.buildPartial(); - } - - break; - } - case 26: - { - com.google.protobuf.Timestamp.Builder subBuilder = null; - if (finishTime_ != null) { - subBuilder = finishTime_.toBuilder(); - } - finishTime_ = - input.readMessage(com.google.protobuf.Timestamp.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(finishTime_); - finishTime_ = subBuilder.buildPartial(); - } - - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.bigtable.admin.v2.BigtableInstanceAdminProto .internal_static_google_bigtable_admin_v2_CreateInstanceMetadata_descriptor; @@ -314,7 +228,7 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io if (finishTime_ != null) { output.writeMessage(3, getFinishTime()); } - unknownFields.writeTo(output); + getUnknownFields().writeTo(output); } @java.lang.Override @@ -332,7 +246,7 @@ public int getSerializedSize() { if (finishTime_ != null) { size += com.google.protobuf.CodedOutputStream.computeMessageSize(3, getFinishTime()); } - size += unknownFields.getSerializedSize(); + size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @@ -360,7 +274,7 @@ public boolean equals(final java.lang.Object obj) { if (hasFinishTime()) { if (!getFinishTime().equals(other.getFinishTime())) return false; } - if (!unknownFields.equals(other.unknownFields)) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -383,7 +297,7 @@ public int hashCode() { hash = (37 * hash) + FINISH_TIME_FIELD_NUMBER; hash = (53 * hash) + getFinishTime().hashCode(); } - hash = (29 * hash) + unknownFields.hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } @@ -512,17 +426,10 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { } // Construct using com.google.bigtable.admin.v2.CreateInstanceMetadata.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } + private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} } @java.lang.Override @@ -647,7 +554,7 @@ public Builder mergeFrom(com.google.bigtable.admin.v2.CreateInstanceMetadata oth if (other.hasFinishTime()) { mergeFinishTime(other.getFinishTime()); } - this.mergeUnknownFields(other.unknownFields); + this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @@ -662,18 +569,49 @@ public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - com.google.bigtable.admin.v2.CreateInstanceMetadata parsedMessage = null; + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + input.readMessage(getOriginalRequestFieldBuilder().getBuilder(), extensionRegistry); + + break; + } // case 10 + case 18: + { + input.readMessage(getRequestTimeFieldBuilder().getBuilder(), extensionRegistry); + + break; + } // case 18 + case 26: + { + input.readMessage(getFinishTimeFieldBuilder().getBuilder(), extensionRegistry); + + break; + } // case 26 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = - (com.google.bigtable.admin.v2.CreateInstanceMetadata) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } + onChanged(); + } // finally return this; } @@ -1264,7 +1202,18 @@ public CreateInstanceMetadata parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new CreateInstanceMetadata(input, extensionRegistry); + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); } }; diff --git a/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/CreateInstanceRequest.java b/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/CreateInstanceRequest.java index 6cb701b30b..0b74c6577f 100644 --- a/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/CreateInstanceRequest.java +++ b/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/CreateInstanceRequest.java @@ -53,92 +53,6 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - private CreateInstanceRequest( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - int mutable_bitField0_ = 0; - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - java.lang.String s = input.readStringRequireUtf8(); - - parent_ = s; - break; - } - case 18: - { - java.lang.String s = input.readStringRequireUtf8(); - - instanceId_ = s; - break; - } - case 26: - { - com.google.bigtable.admin.v2.Instance.Builder subBuilder = null; - if (instance_ != null) { - subBuilder = instance_.toBuilder(); - } - instance_ = - input.readMessage( - com.google.bigtable.admin.v2.Instance.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(instance_); - instance_ = subBuilder.buildPartial(); - } - - break; - } - case 34: - { - if (!((mutable_bitField0_ & 0x00000001) != 0)) { - clusters_ = - com.google.protobuf.MapField.newMapField( - ClustersDefaultEntryHolder.defaultEntry); - mutable_bitField0_ |= 0x00000001; - } - com.google.protobuf.MapEntry - clusters__ = - input.readMessage( - ClustersDefaultEntryHolder.defaultEntry.getParserForType(), - extensionRegistry); - clusters_.getMutableMap().put(clusters__.getKey(), clusters__.getValue()); - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.bigtable.admin.v2.BigtableInstanceAdminProto .internal_static_google_bigtable_admin_v2_CreateInstanceRequest_descriptor; @@ -485,7 +399,7 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io } com.google.protobuf.GeneratedMessageV3.serializeStringMapTo( output, internalGetClusters(), ClustersDefaultEntryHolder.defaultEntry, 4); - unknownFields.writeTo(output); + getUnknownFields().writeTo(output); } @java.lang.Override @@ -514,7 +428,7 @@ public int getSerializedSize() { .build(); size += com.google.protobuf.CodedOutputStream.computeMessageSize(4, clusters__); } - size += unknownFields.getSerializedSize(); + size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @@ -537,7 +451,7 @@ public boolean equals(final java.lang.Object obj) { if (!getInstance().equals(other.getInstance())) return false; } if (!internalGetClusters().equals(other.internalGetClusters())) return false; - if (!unknownFields.equals(other.unknownFields)) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -560,7 +474,7 @@ public int hashCode() { hash = (37 * hash) + CLUSTERS_FIELD_NUMBER; hash = (53 * hash) + internalGetClusters().hashCode(); } - hash = (29 * hash) + unknownFields.hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } @@ -709,17 +623,10 @@ protected com.google.protobuf.MapField internalGetMutableMapField(int number) { } // Construct using com.google.bigtable.admin.v2.CreateInstanceRequest.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } + private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} } @java.lang.Override @@ -835,7 +742,7 @@ public Builder mergeFrom(com.google.bigtable.admin.v2.CreateInstanceRequest othe mergeInstance(other.getInstance()); } internalGetMutableClusters().mergeFrom(other.internalGetClusters()); - this.mergeUnknownFields(other.unknownFields); + this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @@ -850,18 +757,61 @@ public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - com.google.bigtable.admin.v2.CreateInstanceRequest parsedMessage = null; + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + parent_ = input.readStringRequireUtf8(); + + break; + } // case 10 + case 18: + { + instanceId_ = input.readStringRequireUtf8(); + + break; + } // case 18 + case 26: + { + input.readMessage(getInstanceFieldBuilder().getBuilder(), extensionRegistry); + + break; + } // case 26 + case 34: + { + com.google.protobuf.MapEntry + clusters__ = + input.readMessage( + ClustersDefaultEntryHolder.defaultEntry.getParserForType(), + extensionRegistry); + internalGetMutableClusters() + .getMutableMap() + .put(clusters__.getKey(), clusters__.getValue()); + break; + } // case 34 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = - (com.google.bigtable.admin.v2.CreateInstanceRequest) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } + onChanged(); + } // finally return this; } @@ -1555,7 +1505,18 @@ public CreateInstanceRequest parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new CreateInstanceRequest(input, extensionRegistry); + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); } }; diff --git a/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/CreateTableFromSnapshotMetadata.java b/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/CreateTableFromSnapshotMetadata.java index 60b0455b94..cb326cf4ce 100644 --- a/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/CreateTableFromSnapshotMetadata.java +++ b/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/CreateTableFromSnapshotMetadata.java @@ -55,92 +55,6 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - private CreateTableFromSnapshotMetadata( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - com.google.bigtable.admin.v2.CreateTableFromSnapshotRequest.Builder subBuilder = null; - if (originalRequest_ != null) { - subBuilder = originalRequest_.toBuilder(); - } - originalRequest_ = - input.readMessage( - com.google.bigtable.admin.v2.CreateTableFromSnapshotRequest.parser(), - extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(originalRequest_); - originalRequest_ = subBuilder.buildPartial(); - } - - break; - } - case 18: - { - com.google.protobuf.Timestamp.Builder subBuilder = null; - if (requestTime_ != null) { - subBuilder = requestTime_.toBuilder(); - } - requestTime_ = - input.readMessage(com.google.protobuf.Timestamp.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(requestTime_); - requestTime_ = subBuilder.buildPartial(); - } - - break; - } - case 26: - { - com.google.protobuf.Timestamp.Builder subBuilder = null; - if (finishTime_ != null) { - subBuilder = finishTime_.toBuilder(); - } - finishTime_ = - input.readMessage(com.google.protobuf.Timestamp.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(finishTime_); - finishTime_ = subBuilder.buildPartial(); - } - - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.bigtable.admin.v2.BigtableTableAdminProto .internal_static_google_bigtable_admin_v2_CreateTableFromSnapshotMetadata_descriptor; @@ -323,7 +237,7 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io if (finishTime_ != null) { output.writeMessage(3, getFinishTime()); } - unknownFields.writeTo(output); + getUnknownFields().writeTo(output); } @java.lang.Override @@ -341,7 +255,7 @@ public int getSerializedSize() { if (finishTime_ != null) { size += com.google.protobuf.CodedOutputStream.computeMessageSize(3, getFinishTime()); } - size += unknownFields.getSerializedSize(); + size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @@ -369,7 +283,7 @@ public boolean equals(final java.lang.Object obj) { if (hasFinishTime()) { if (!getFinishTime().equals(other.getFinishTime())) return false; } - if (!unknownFields.equals(other.unknownFields)) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -392,7 +306,7 @@ public int hashCode() { hash = (37 * hash) + FINISH_TIME_FIELD_NUMBER; hash = (53 * hash) + getFinishTime().hashCode(); } - hash = (29 * hash) + unknownFields.hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } @@ -526,17 +440,10 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { } // Construct using com.google.bigtable.admin.v2.CreateTableFromSnapshotMetadata.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } + private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} } @java.lang.Override @@ -663,7 +570,7 @@ public Builder mergeFrom(com.google.bigtable.admin.v2.CreateTableFromSnapshotMet if (other.hasFinishTime()) { mergeFinishTime(other.getFinishTime()); } - this.mergeUnknownFields(other.unknownFields); + this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @@ -678,18 +585,49 @@ public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - com.google.bigtable.admin.v2.CreateTableFromSnapshotMetadata parsedMessage = null; + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + input.readMessage(getOriginalRequestFieldBuilder().getBuilder(), extensionRegistry); + + break; + } // case 10 + case 18: + { + input.readMessage(getRequestTimeFieldBuilder().getBuilder(), extensionRegistry); + + break; + } // case 18 + case 26: + { + input.readMessage(getFinishTimeFieldBuilder().getBuilder(), extensionRegistry); + + break; + } // case 26 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = - (com.google.bigtable.admin.v2.CreateTableFromSnapshotMetadata) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } + onChanged(); + } // finally return this; } @@ -1294,7 +1232,18 @@ public CreateTableFromSnapshotMetadata parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new CreateTableFromSnapshotMetadata(input, extensionRegistry); + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); } }; diff --git a/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/CreateTableFromSnapshotRequest.java b/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/CreateTableFromSnapshotRequest.java index 90744b58f4..392837847b 100644 --- a/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/CreateTableFromSnapshotRequest.java +++ b/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/CreateTableFromSnapshotRequest.java @@ -60,66 +60,6 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - private CreateTableFromSnapshotRequest( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - java.lang.String s = input.readStringRequireUtf8(); - - parent_ = s; - break; - } - case 18: - { - java.lang.String s = input.readStringRequireUtf8(); - - tableId_ = s; - break; - } - case 26: - { - java.lang.String s = input.readStringRequireUtf8(); - - sourceSnapshot_ = s; - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.bigtable.admin.v2.BigtableTableAdminProto .internal_static_google_bigtable_admin_v2_CreateTableFromSnapshotRequest_descriptor; @@ -323,7 +263,7 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(sourceSnapshot_)) { com.google.protobuf.GeneratedMessageV3.writeString(output, 3, sourceSnapshot_); } - unknownFields.writeTo(output); + getUnknownFields().writeTo(output); } @java.lang.Override @@ -341,7 +281,7 @@ public int getSerializedSize() { if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(sourceSnapshot_)) { size += com.google.protobuf.GeneratedMessageV3.computeStringSize(3, sourceSnapshot_); } - size += unknownFields.getSerializedSize(); + size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @@ -360,7 +300,7 @@ public boolean equals(final java.lang.Object obj) { if (!getParent().equals(other.getParent())) return false; if (!getTableId().equals(other.getTableId())) return false; if (!getSourceSnapshot().equals(other.getSourceSnapshot())) return false; - if (!unknownFields.equals(other.unknownFields)) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -377,7 +317,7 @@ public int hashCode() { hash = (53 * hash) + getTableId().hashCode(); hash = (37 * hash) + SOURCE_SNAPSHOT_FIELD_NUMBER; hash = (53 * hash) + getSourceSnapshot().hashCode(); - hash = (29 * hash) + unknownFields.hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } @@ -512,17 +452,10 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { } // Construct using com.google.bigtable.admin.v2.CreateTableFromSnapshotRequest.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } + private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} } @java.lang.Override @@ -626,7 +559,7 @@ public Builder mergeFrom(com.google.bigtable.admin.v2.CreateTableFromSnapshotReq sourceSnapshot_ = other.sourceSnapshot_; onChanged(); } - this.mergeUnknownFields(other.unknownFields); + this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @@ -641,18 +574,49 @@ public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - com.google.bigtable.admin.v2.CreateTableFromSnapshotRequest parsedMessage = null; + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + parent_ = input.readStringRequireUtf8(); + + break; + } // case 10 + case 18: + { + tableId_ = input.readStringRequireUtf8(); + + break; + } // case 18 + case 26: + { + sourceSnapshot_ = input.readStringRequireUtf8(); + + break; + } // case 26 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = - (com.google.bigtable.admin.v2.CreateTableFromSnapshotRequest) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } + onChanged(); + } // finally return this; } @@ -1051,7 +1015,18 @@ public CreateTableFromSnapshotRequest parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new CreateTableFromSnapshotRequest(input, extensionRegistry); + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); } }; diff --git a/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/CreateTableRequest.java b/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/CreateTableRequest.java index 75d14e80fb..f5d6c6f995 100644 --- a/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/CreateTableRequest.java +++ b/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/CreateTableRequest.java @@ -55,92 +55,6 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - private CreateTableRequest( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - int mutable_bitField0_ = 0; - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - java.lang.String s = input.readStringRequireUtf8(); - - parent_ = s; - break; - } - case 18: - { - java.lang.String s = input.readStringRequireUtf8(); - - tableId_ = s; - break; - } - case 26: - { - com.google.bigtable.admin.v2.Table.Builder subBuilder = null; - if (table_ != null) { - subBuilder = table_.toBuilder(); - } - table_ = - input.readMessage(com.google.bigtable.admin.v2.Table.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(table_); - table_ = subBuilder.buildPartial(); - } - - break; - } - case 34: - { - if (!((mutable_bitField0_ & 0x00000001) != 0)) { - initialSplits_ = - new java.util.ArrayList< - com.google.bigtable.admin.v2.CreateTableRequest.Split>(); - mutable_bitField0_ |= 0x00000001; - } - initialSplits_.add( - input.readMessage( - com.google.bigtable.admin.v2.CreateTableRequest.Split.parser(), - extensionRegistry)); - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); - } finally { - if (((mutable_bitField0_ & 0x00000001) != 0)) { - initialSplits_ = java.util.Collections.unmodifiableList(initialSplits_); - } - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.bigtable.admin.v2.BigtableTableAdminProto .internal_static_google_bigtable_admin_v2_CreateTableRequest_descriptor; @@ -208,50 +122,6 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - private Split( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - key_ = input.readBytes(); - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.bigtable.admin.v2.BigtableTableAdminProto .internal_static_google_bigtable_admin_v2_CreateTableRequest_Split_descriptor; @@ -302,7 +172,7 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io if (!key_.isEmpty()) { output.writeBytes(1, key_); } - unknownFields.writeTo(output); + getUnknownFields().writeTo(output); } @java.lang.Override @@ -314,7 +184,7 @@ public int getSerializedSize() { if (!key_.isEmpty()) { size += com.google.protobuf.CodedOutputStream.computeBytesSize(1, key_); } - size += unknownFields.getSerializedSize(); + size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @@ -331,7 +201,7 @@ public boolean equals(final java.lang.Object obj) { (com.google.bigtable.admin.v2.CreateTableRequest.Split) obj; if (!getKey().equals(other.getKey())) return false; - if (!unknownFields.equals(other.unknownFields)) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -344,7 +214,7 @@ public int hashCode() { hash = (19 * hash) + getDescriptor().hashCode(); hash = (37 * hash) + KEY_FIELD_NUMBER; hash = (53 * hash) + getKey().hashCode(); - hash = (29 * hash) + unknownFields.hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } @@ -476,17 +346,10 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { } // Construct using com.google.bigtable.admin.v2.CreateTableRequest.Split.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } + private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} } @java.lang.Override @@ -577,7 +440,7 @@ public Builder mergeFrom(com.google.bigtable.admin.v2.CreateTableRequest.Split o if (other.getKey() != com.google.protobuf.ByteString.EMPTY) { setKey(other.getKey()); } - this.mergeUnknownFields(other.unknownFields); + this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @@ -592,18 +455,37 @@ public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - com.google.bigtable.admin.v2.CreateTableRequest.Split parsedMessage = null; + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + key_ = input.readBytes(); + + break; + } // case 10 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = - (com.google.bigtable.admin.v2.CreateTableRequest.Split) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } + onChanged(); + } // finally return this; } @@ -695,7 +577,19 @@ public Split parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new Split(input, extensionRegistry); + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException() + .setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); } }; @@ -1033,7 +927,7 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io for (int i = 0; i < initialSplits_.size(); i++) { output.writeMessage(4, initialSplits_.get(i)); } - unknownFields.writeTo(output); + getUnknownFields().writeTo(output); } @java.lang.Override @@ -1054,7 +948,7 @@ public int getSerializedSize() { for (int i = 0; i < initialSplits_.size(); i++) { size += com.google.protobuf.CodedOutputStream.computeMessageSize(4, initialSplits_.get(i)); } - size += unknownFields.getSerializedSize(); + size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @@ -1077,7 +971,7 @@ public boolean equals(final java.lang.Object obj) { if (!getTable().equals(other.getTable())) return false; } if (!getInitialSplitsList().equals(other.getInitialSplitsList())) return false; - if (!unknownFields.equals(other.unknownFields)) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -1100,7 +994,7 @@ public int hashCode() { hash = (37 * hash) + INITIAL_SPLITS_FIELD_NUMBER; hash = (53 * hash) + getInitialSplitsList().hashCode(); } - hash = (29 * hash) + unknownFields.hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } @@ -1230,19 +1124,10 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { } // Construct using com.google.bigtable.admin.v2.CreateTableRequest.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } + private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) { - getInitialSplitsFieldBuilder(); - } } @java.lang.Override @@ -1260,10 +1145,11 @@ public Builder clear() { } if (initialSplitsBuilder_ == null) { initialSplits_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000001); } else { + initialSplits_ = null; initialSplitsBuilder_.clear(); } + bitField0_ = (bitField0_ & ~0x00000001); return this; } @@ -1396,7 +1282,7 @@ public Builder mergeFrom(com.google.bigtable.admin.v2.CreateTableRequest other) } } } - this.mergeUnknownFields(other.unknownFields); + this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @@ -1411,17 +1297,63 @@ public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - com.google.bigtable.admin.v2.CreateTableRequest parsedMessage = null; + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + parent_ = input.readStringRequireUtf8(); + + break; + } // case 10 + case 18: + { + tableId_ = input.readStringRequireUtf8(); + + break; + } // case 18 + case 26: + { + input.readMessage(getTableFieldBuilder().getBuilder(), extensionRegistry); + + break; + } // case 26 + case 34: + { + com.google.bigtable.admin.v2.CreateTableRequest.Split m = + input.readMessage( + com.google.bigtable.admin.v2.CreateTableRequest.Split.parser(), + extensionRegistry); + if (initialSplitsBuilder_ == null) { + ensureInitialSplitsIsMutable(); + initialSplits_.add(m); + } else { + initialSplitsBuilder_.addMessage(m); + } + break; + } // case 34 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.bigtable.admin.v2.CreateTableRequest) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } + onChanged(); + } // finally return this; } @@ -2481,7 +2413,18 @@ public CreateTableRequest parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new CreateTableRequest(input, extensionRegistry); + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); } }; diff --git a/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/DeleteAppProfileRequest.java b/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/DeleteAppProfileRequest.java index b1296c96bf..4a85712a9f 100644 --- a/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/DeleteAppProfileRequest.java +++ b/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/DeleteAppProfileRequest.java @@ -52,57 +52,6 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - private DeleteAppProfileRequest( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - java.lang.String s = input.readStringRequireUtf8(); - - name_ = s; - break; - } - case 16: - { - ignoreWarnings_ = input.readBool(); - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.bigtable.admin.v2.BigtableInstanceAdminProto .internal_static_google_bigtable_admin_v2_DeleteAppProfileRequest_descriptor; @@ -211,7 +160,7 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io if (ignoreWarnings_ != false) { output.writeBool(2, ignoreWarnings_); } - unknownFields.writeTo(output); + getUnknownFields().writeTo(output); } @java.lang.Override @@ -226,7 +175,7 @@ public int getSerializedSize() { if (ignoreWarnings_ != false) { size += com.google.protobuf.CodedOutputStream.computeBoolSize(2, ignoreWarnings_); } - size += unknownFields.getSerializedSize(); + size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @@ -244,7 +193,7 @@ public boolean equals(final java.lang.Object obj) { if (!getName().equals(other.getName())) return false; if (getIgnoreWarnings() != other.getIgnoreWarnings()) return false; - if (!unknownFields.equals(other.unknownFields)) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -259,7 +208,7 @@ public int hashCode() { hash = (53 * hash) + getName().hashCode(); hash = (37 * hash) + IGNORE_WARNINGS_FIELD_NUMBER; hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean(getIgnoreWarnings()); - hash = (29 * hash) + unknownFields.hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } @@ -388,17 +337,10 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { } // Construct using com.google.bigtable.admin.v2.DeleteAppProfileRequest.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } + private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} } @java.lang.Override @@ -494,7 +436,7 @@ public Builder mergeFrom(com.google.bigtable.admin.v2.DeleteAppProfileRequest ot if (other.getIgnoreWarnings() != false) { setIgnoreWarnings(other.getIgnoreWarnings()); } - this.mergeUnknownFields(other.unknownFields); + this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @@ -509,18 +451,43 @@ public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - com.google.bigtable.admin.v2.DeleteAppProfileRequest parsedMessage = null; + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + name_ = input.readStringRequireUtf8(); + + break; + } // case 10 + case 16: + { + ignoreWarnings_ = input.readBool(); + + break; + } // case 16 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = - (com.google.bigtable.admin.v2.DeleteAppProfileRequest) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } + onChanged(); + } // finally return this; } @@ -729,7 +696,18 @@ public DeleteAppProfileRequest parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new DeleteAppProfileRequest(input, extensionRegistry); + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); } }; diff --git a/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/DeleteBackupRequest.java b/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/DeleteBackupRequest.java index 07552be8bc..332e0ce5a6 100644 --- a/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/DeleteBackupRequest.java +++ b/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/DeleteBackupRequest.java @@ -52,52 +52,6 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - private DeleteBackupRequest( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - java.lang.String s = input.readStringRequireUtf8(); - - name_ = s; - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.bigtable.admin.v2.BigtableTableAdminProto .internal_static_google_bigtable_admin_v2_DeleteBackupRequest_descriptor; @@ -187,7 +141,7 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(name_)) { com.google.protobuf.GeneratedMessageV3.writeString(output, 1, name_); } - unknownFields.writeTo(output); + getUnknownFields().writeTo(output); } @java.lang.Override @@ -199,7 +153,7 @@ public int getSerializedSize() { if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(name_)) { size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, name_); } - size += unknownFields.getSerializedSize(); + size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @@ -216,7 +170,7 @@ public boolean equals(final java.lang.Object obj) { (com.google.bigtable.admin.v2.DeleteBackupRequest) obj; if (!getName().equals(other.getName())) return false; - if (!unknownFields.equals(other.unknownFields)) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -229,7 +183,7 @@ public int hashCode() { hash = (19 * hash) + getDescriptor().hashCode(); hash = (37 * hash) + NAME_FIELD_NUMBER; hash = (53 * hash) + getName().hashCode(); - hash = (29 * hash) + unknownFields.hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } @@ -358,17 +312,10 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { } // Construct using com.google.bigtable.admin.v2.DeleteBackupRequest.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } + private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} } @java.lang.Override @@ -458,7 +405,7 @@ public Builder mergeFrom(com.google.bigtable.admin.v2.DeleteBackupRequest other) name_ = other.name_; onChanged(); } - this.mergeUnknownFields(other.unknownFields); + this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @@ -473,17 +420,37 @@ public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - com.google.bigtable.admin.v2.DeleteBackupRequest parsedMessage = null; + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + name_ = input.readStringRequireUtf8(); + + break; + } // case 10 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.bigtable.admin.v2.DeleteBackupRequest) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } + onChanged(); + } // finally return this; } @@ -645,7 +612,18 @@ public DeleteBackupRequest parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new DeleteBackupRequest(input, extensionRegistry); + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); } }; diff --git a/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/DeleteClusterRequest.java b/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/DeleteClusterRequest.java index 73720e7c2a..35c1a6a376 100644 --- a/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/DeleteClusterRequest.java +++ b/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/DeleteClusterRequest.java @@ -52,52 +52,6 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - private DeleteClusterRequest( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - java.lang.String s = input.readStringRequireUtf8(); - - name_ = s; - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.bigtable.admin.v2.BigtableInstanceAdminProto .internal_static_google_bigtable_admin_v2_DeleteClusterRequest_descriptor; @@ -185,7 +139,7 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(name_)) { com.google.protobuf.GeneratedMessageV3.writeString(output, 1, name_); } - unknownFields.writeTo(output); + getUnknownFields().writeTo(output); } @java.lang.Override @@ -197,7 +151,7 @@ public int getSerializedSize() { if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(name_)) { size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, name_); } - size += unknownFields.getSerializedSize(); + size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @@ -214,7 +168,7 @@ public boolean equals(final java.lang.Object obj) { (com.google.bigtable.admin.v2.DeleteClusterRequest) obj; if (!getName().equals(other.getName())) return false; - if (!unknownFields.equals(other.unknownFields)) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -227,7 +181,7 @@ public int hashCode() { hash = (19 * hash) + getDescriptor().hashCode(); hash = (37 * hash) + NAME_FIELD_NUMBER; hash = (53 * hash) + getName().hashCode(); - hash = (29 * hash) + unknownFields.hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } @@ -356,17 +310,10 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { } // Construct using com.google.bigtable.admin.v2.DeleteClusterRequest.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } + private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} } @java.lang.Override @@ -456,7 +403,7 @@ public Builder mergeFrom(com.google.bigtable.admin.v2.DeleteClusterRequest other name_ = other.name_; onChanged(); } - this.mergeUnknownFields(other.unknownFields); + this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @@ -471,18 +418,37 @@ public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - com.google.bigtable.admin.v2.DeleteClusterRequest parsedMessage = null; + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + name_ = input.readStringRequireUtf8(); + + break; + } // case 10 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = - (com.google.bigtable.admin.v2.DeleteClusterRequest) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } + onChanged(); + } // finally return this; } @@ -639,7 +605,18 @@ public DeleteClusterRequest parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new DeleteClusterRequest(input, extensionRegistry); + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); } }; diff --git a/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/DeleteInstanceRequest.java b/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/DeleteInstanceRequest.java index 0f24a15344..b3b6da08f2 100644 --- a/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/DeleteInstanceRequest.java +++ b/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/DeleteInstanceRequest.java @@ -52,52 +52,6 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - private DeleteInstanceRequest( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - java.lang.String s = input.readStringRequireUtf8(); - - name_ = s; - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.bigtable.admin.v2.BigtableInstanceAdminProto .internal_static_google_bigtable_admin_v2_DeleteInstanceRequest_descriptor; @@ -185,7 +139,7 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(name_)) { com.google.protobuf.GeneratedMessageV3.writeString(output, 1, name_); } - unknownFields.writeTo(output); + getUnknownFields().writeTo(output); } @java.lang.Override @@ -197,7 +151,7 @@ public int getSerializedSize() { if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(name_)) { size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, name_); } - size += unknownFields.getSerializedSize(); + size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @@ -214,7 +168,7 @@ public boolean equals(final java.lang.Object obj) { (com.google.bigtable.admin.v2.DeleteInstanceRequest) obj; if (!getName().equals(other.getName())) return false; - if (!unknownFields.equals(other.unknownFields)) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -227,7 +181,7 @@ public int hashCode() { hash = (19 * hash) + getDescriptor().hashCode(); hash = (37 * hash) + NAME_FIELD_NUMBER; hash = (53 * hash) + getName().hashCode(); - hash = (29 * hash) + unknownFields.hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } @@ -356,17 +310,10 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { } // Construct using com.google.bigtable.admin.v2.DeleteInstanceRequest.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } + private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} } @java.lang.Override @@ -456,7 +403,7 @@ public Builder mergeFrom(com.google.bigtable.admin.v2.DeleteInstanceRequest othe name_ = other.name_; onChanged(); } - this.mergeUnknownFields(other.unknownFields); + this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @@ -471,18 +418,37 @@ public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - com.google.bigtable.admin.v2.DeleteInstanceRequest parsedMessage = null; + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + name_ = input.readStringRequireUtf8(); + + break; + } // case 10 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = - (com.google.bigtable.admin.v2.DeleteInstanceRequest) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } + onChanged(); + } // finally return this; } @@ -639,7 +605,18 @@ public DeleteInstanceRequest parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new DeleteInstanceRequest(input, extensionRegistry); + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); } }; diff --git a/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/DeleteSnapshotRequest.java b/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/DeleteSnapshotRequest.java index e2eb44e36a..3f05f058f5 100644 --- a/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/DeleteSnapshotRequest.java +++ b/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/DeleteSnapshotRequest.java @@ -57,52 +57,6 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - private DeleteSnapshotRequest( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - java.lang.String s = input.readStringRequireUtf8(); - - name_ = s; - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.bigtable.admin.v2.BigtableTableAdminProto .internal_static_google_bigtable_admin_v2_DeleteSnapshotRequest_descriptor; @@ -192,7 +146,7 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(name_)) { com.google.protobuf.GeneratedMessageV3.writeString(output, 1, name_); } - unknownFields.writeTo(output); + getUnknownFields().writeTo(output); } @java.lang.Override @@ -204,7 +158,7 @@ public int getSerializedSize() { if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(name_)) { size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, name_); } - size += unknownFields.getSerializedSize(); + size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @@ -221,7 +175,7 @@ public boolean equals(final java.lang.Object obj) { (com.google.bigtable.admin.v2.DeleteSnapshotRequest) obj; if (!getName().equals(other.getName())) return false; - if (!unknownFields.equals(other.unknownFields)) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -234,7 +188,7 @@ public int hashCode() { hash = (19 * hash) + getDescriptor().hashCode(); hash = (37 * hash) + NAME_FIELD_NUMBER; hash = (53 * hash) + getName().hashCode(); - hash = (29 * hash) + unknownFields.hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } @@ -368,17 +322,10 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { } // Construct using com.google.bigtable.admin.v2.DeleteSnapshotRequest.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } + private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} } @java.lang.Override @@ -468,7 +415,7 @@ public Builder mergeFrom(com.google.bigtable.admin.v2.DeleteSnapshotRequest othe name_ = other.name_; onChanged(); } - this.mergeUnknownFields(other.unknownFields); + this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @@ -483,18 +430,37 @@ public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - com.google.bigtable.admin.v2.DeleteSnapshotRequest parsedMessage = null; + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + name_ = input.readStringRequireUtf8(); + + break; + } // case 10 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = - (com.google.bigtable.admin.v2.DeleteSnapshotRequest) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } + onChanged(); + } // finally return this; } @@ -656,7 +622,18 @@ public DeleteSnapshotRequest parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new DeleteSnapshotRequest(input, extensionRegistry); + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); } }; diff --git a/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/DeleteTableRequest.java b/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/DeleteTableRequest.java index 950c087a19..84a58dbf6a 100644 --- a/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/DeleteTableRequest.java +++ b/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/DeleteTableRequest.java @@ -53,52 +53,6 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - private DeleteTableRequest( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - java.lang.String s = input.readStringRequireUtf8(); - - name_ = s; - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.bigtable.admin.v2.BigtableTableAdminProto .internal_static_google_bigtable_admin_v2_DeleteTableRequest_descriptor; @@ -188,7 +142,7 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(name_)) { com.google.protobuf.GeneratedMessageV3.writeString(output, 1, name_); } - unknownFields.writeTo(output); + getUnknownFields().writeTo(output); } @java.lang.Override @@ -200,7 +154,7 @@ public int getSerializedSize() { if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(name_)) { size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, name_); } - size += unknownFields.getSerializedSize(); + size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @@ -217,7 +171,7 @@ public boolean equals(final java.lang.Object obj) { (com.google.bigtable.admin.v2.DeleteTableRequest) obj; if (!getName().equals(other.getName())) return false; - if (!unknownFields.equals(other.unknownFields)) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -230,7 +184,7 @@ public int hashCode() { hash = (19 * hash) + getDescriptor().hashCode(); hash = (37 * hash) + NAME_FIELD_NUMBER; hash = (53 * hash) + getName().hashCode(); - hash = (29 * hash) + unknownFields.hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } @@ -360,17 +314,10 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { } // Construct using com.google.bigtable.admin.v2.DeleteTableRequest.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } + private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} } @java.lang.Override @@ -460,7 +407,7 @@ public Builder mergeFrom(com.google.bigtable.admin.v2.DeleteTableRequest other) name_ = other.name_; onChanged(); } - this.mergeUnknownFields(other.unknownFields); + this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @@ -475,17 +422,37 @@ public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - com.google.bigtable.admin.v2.DeleteTableRequest parsedMessage = null; + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + name_ = input.readStringRequireUtf8(); + + break; + } // case 10 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.bigtable.admin.v2.DeleteTableRequest) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } + onChanged(); + } // finally return this; } @@ -647,7 +614,18 @@ public DeleteTableRequest parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new DeleteTableRequest(input, extensionRegistry); + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); } }; diff --git a/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/DropRowRangeRequest.java b/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/DropRowRangeRequest.java index 03e8fb9312..4239f2d91d 100644 --- a/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/DropRowRangeRequest.java +++ b/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/DropRowRangeRequest.java @@ -53,64 +53,6 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - private DropRowRangeRequest( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - java.lang.String s = input.readStringRequireUtf8(); - - name_ = s; - break; - } - case 18: - { - target_ = input.readBytes(); - targetCase_ = 2; - break; - } - case 24: - { - target_ = input.readBool(); - targetCase_ = 3; - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.bigtable.admin.v2.BigtableTableAdminProto .internal_static_google_bigtable_admin_v2_DropRowRangeRequest_descriptor; @@ -325,7 +267,7 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io if (targetCase_ == 3) { output.writeBool(3, (boolean) ((java.lang.Boolean) target_)); } - unknownFields.writeTo(output); + getUnknownFields().writeTo(output); } @java.lang.Override @@ -347,7 +289,7 @@ public int getSerializedSize() { com.google.protobuf.CodedOutputStream.computeBoolSize( 3, (boolean) ((java.lang.Boolean) target_)); } - size += unknownFields.getSerializedSize(); + size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @@ -375,7 +317,7 @@ public boolean equals(final java.lang.Object obj) { case 0: default: } - if (!unknownFields.equals(other.unknownFields)) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -400,7 +342,7 @@ public int hashCode() { case 0: default: } - hash = (29 * hash) + unknownFields.hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } @@ -530,17 +472,10 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { } // Construct using com.google.bigtable.admin.v2.DropRowRangeRequest.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } + private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} } @java.lang.Override @@ -655,7 +590,7 @@ public Builder mergeFrom(com.google.bigtable.admin.v2.DropRowRangeRequest other) break; } } - this.mergeUnknownFields(other.unknownFields); + this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @@ -670,17 +605,49 @@ public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - com.google.bigtable.admin.v2.DropRowRangeRequest parsedMessage = null; + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + name_ = input.readStringRequireUtf8(); + + break; + } // case 10 + case 18: + { + target_ = input.readBytes(); + targetCase_ = 2; + break; + } // case 18 + case 24: + { + target_ = input.readBool(); + targetCase_ = 3; + break; + } // case 24 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.bigtable.admin.v2.DropRowRangeRequest) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } + onChanged(); + } // finally return this; } @@ -1001,7 +968,18 @@ public DropRowRangeRequest parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new DropRowRangeRequest(input, extensionRegistry); + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); } }; diff --git a/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/EncryptionInfo.java b/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/EncryptionInfo.java index 8f60903049..d85b829aaa 100644 --- a/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/EncryptionInfo.java +++ b/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/EncryptionInfo.java @@ -56,74 +56,6 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - private EncryptionInfo( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 18: - { - java.lang.String s = input.readStringRequireUtf8(); - - kmsKeyVersion_ = s; - break; - } - case 24: - { - int rawValue = input.readEnum(); - - encryptionType_ = rawValue; - break; - } - case 34: - { - com.google.rpc.Status.Builder subBuilder = null; - if (encryptionStatus_ != null) { - subBuilder = encryptionStatus_.toBuilder(); - } - encryptionStatus_ = - input.readMessage(com.google.rpc.Status.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(encryptionStatus_); - encryptionStatus_ = subBuilder.buildPartial(); - } - - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.bigtable.admin.v2.TableProto .internal_static_google_bigtable_admin_v2_EncryptionInfo_descriptor; @@ -488,7 +420,7 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io if (encryptionStatus_ != null) { output.writeMessage(4, getEncryptionStatus()); } - unknownFields.writeTo(output); + getUnknownFields().writeTo(output); } @java.lang.Override @@ -508,7 +440,7 @@ public int getSerializedSize() { if (encryptionStatus_ != null) { size += com.google.protobuf.CodedOutputStream.computeMessageSize(4, getEncryptionStatus()); } - size += unknownFields.getSerializedSize(); + size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @@ -530,7 +462,7 @@ public boolean equals(final java.lang.Object obj) { if (!getEncryptionStatus().equals(other.getEncryptionStatus())) return false; } if (!getKmsKeyVersion().equals(other.getKmsKeyVersion())) return false; - if (!unknownFields.equals(other.unknownFields)) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -549,7 +481,7 @@ public int hashCode() { } hash = (37 * hash) + KMS_KEY_VERSION_FIELD_NUMBER; hash = (53 * hash) + getKmsKeyVersion().hashCode(); - hash = (29 * hash) + unknownFields.hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } @@ -681,17 +613,10 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { } // Construct using com.google.bigtable.admin.v2.EncryptionInfo.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } + private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} } @java.lang.Override @@ -800,7 +725,7 @@ public Builder mergeFrom(com.google.bigtable.admin.v2.EncryptionInfo other) { kmsKeyVersion_ = other.kmsKeyVersion_; onChanged(); } - this.mergeUnknownFields(other.unknownFields); + this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @@ -815,17 +740,50 @@ public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - com.google.bigtable.admin.v2.EncryptionInfo parsedMessage = null; + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 18: + { + kmsKeyVersion_ = input.readStringRequireUtf8(); + + break; + } // case 18 + case 24: + { + encryptionType_ = input.readEnum(); + + break; + } // case 24 + case 34: + { + input.readMessage( + getEncryptionStatusFieldBuilder().getBuilder(), extensionRegistry); + + break; + } // case 34 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.bigtable.admin.v2.EncryptionInfo) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } + onChanged(); + } // finally return this; } @@ -1283,7 +1241,18 @@ public EncryptionInfo parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new EncryptionInfo(input, extensionRegistry); + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); } }; diff --git a/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/GcRule.java b/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/GcRule.java index b831ff99e4..5a3866c1bf 100644 --- a/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/GcRule.java +++ b/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/GcRule.java @@ -50,97 +50,6 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - private GcRule( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 8: - { - rule_ = input.readInt32(); - ruleCase_ = 1; - break; - } - case 18: - { - com.google.protobuf.Duration.Builder subBuilder = null; - if (ruleCase_ == 2) { - subBuilder = ((com.google.protobuf.Duration) rule_).toBuilder(); - } - rule_ = input.readMessage(com.google.protobuf.Duration.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom((com.google.protobuf.Duration) rule_); - rule_ = subBuilder.buildPartial(); - } - ruleCase_ = 2; - break; - } - case 26: - { - com.google.bigtable.admin.v2.GcRule.Intersection.Builder subBuilder = null; - if (ruleCase_ == 3) { - subBuilder = ((com.google.bigtable.admin.v2.GcRule.Intersection) rule_).toBuilder(); - } - rule_ = - input.readMessage( - com.google.bigtable.admin.v2.GcRule.Intersection.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom((com.google.bigtable.admin.v2.GcRule.Intersection) rule_); - rule_ = subBuilder.buildPartial(); - } - ruleCase_ = 3; - break; - } - case 34: - { - com.google.bigtable.admin.v2.GcRule.Union.Builder subBuilder = null; - if (ruleCase_ == 4) { - subBuilder = ((com.google.bigtable.admin.v2.GcRule.Union) rule_).toBuilder(); - } - rule_ = - input.readMessage( - com.google.bigtable.admin.v2.GcRule.Union.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom((com.google.bigtable.admin.v2.GcRule.Union) rule_); - rule_ = subBuilder.buildPartial(); - } - ruleCase_ = 4; - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.bigtable.admin.v2.TableProto .internal_static_google_bigtable_admin_v2_GcRule_descriptor; @@ -246,60 +155,6 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - private Intersection( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - int mutable_bitField0_ = 0; - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - if (!((mutable_bitField0_ & 0x00000001) != 0)) { - rules_ = new java.util.ArrayList(); - mutable_bitField0_ |= 0x00000001; - } - rules_.add( - input.readMessage( - com.google.bigtable.admin.v2.GcRule.parser(), extensionRegistry)); - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); - } finally { - if (((mutable_bitField0_ & 0x00000001) != 0)) { - rules_ = java.util.Collections.unmodifiableList(rules_); - } - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.bigtable.admin.v2.TableProto .internal_static_google_bigtable_admin_v2_GcRule_Intersection_descriptor; @@ -401,7 +256,7 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io for (int i = 0; i < rules_.size(); i++) { output.writeMessage(1, rules_.get(i)); } - unknownFields.writeTo(output); + getUnknownFields().writeTo(output); } @java.lang.Override @@ -413,7 +268,7 @@ public int getSerializedSize() { for (int i = 0; i < rules_.size(); i++) { size += com.google.protobuf.CodedOutputStream.computeMessageSize(1, rules_.get(i)); } - size += unknownFields.getSerializedSize(); + size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @@ -430,7 +285,7 @@ public boolean equals(final java.lang.Object obj) { (com.google.bigtable.admin.v2.GcRule.Intersection) obj; if (!getRulesList().equals(other.getRulesList())) return false; - if (!unknownFields.equals(other.unknownFields)) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -445,7 +300,7 @@ public int hashCode() { hash = (37 * hash) + RULES_FIELD_NUMBER; hash = (53 * hash) + getRulesList().hashCode(); } - hash = (29 * hash) + unknownFields.hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } @@ -576,19 +431,10 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { } // Construct using com.google.bigtable.admin.v2.GcRule.Intersection.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } + private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) { - getRulesFieldBuilder(); - } } @java.lang.Override @@ -596,10 +442,11 @@ public Builder clear() { super.clear(); if (rulesBuilder_ == null) { rules_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000001); } else { + rules_ = null; rulesBuilder_.clear(); } + bitField0_ = (bitField0_ & ~0x00000001); return this; } @@ -716,7 +563,7 @@ public Builder mergeFrom(com.google.bigtable.admin.v2.GcRule.Intersection other) } } } - this.mergeUnknownFields(other.unknownFields); + this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @@ -731,18 +578,44 @@ public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - com.google.bigtable.admin.v2.GcRule.Intersection parsedMessage = null; + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + com.google.bigtable.admin.v2.GcRule m = + input.readMessage( + com.google.bigtable.admin.v2.GcRule.parser(), extensionRegistry); + if (rulesBuilder_ == null) { + ensureRulesIsMutable(); + rules_.add(m); + } else { + rulesBuilder_.addMessage(m); + } + break; + } // case 10 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = - (com.google.bigtable.admin.v2.GcRule.Intersection) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } + onChanged(); + } // finally return this; } @@ -1129,7 +1002,19 @@ public Intersection parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new Intersection(input, extensionRegistry); + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException() + .setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); } }; @@ -1238,60 +1123,6 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - private Union( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - int mutable_bitField0_ = 0; - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - if (!((mutable_bitField0_ & 0x00000001) != 0)) { - rules_ = new java.util.ArrayList(); - mutable_bitField0_ |= 0x00000001; - } - rules_.add( - input.readMessage( - com.google.bigtable.admin.v2.GcRule.parser(), extensionRegistry)); - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); - } finally { - if (((mutable_bitField0_ & 0x00000001) != 0)) { - rules_ = java.util.Collections.unmodifiableList(rules_); - } - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.bigtable.admin.v2.TableProto .internal_static_google_bigtable_admin_v2_GcRule_Union_descriptor; @@ -1393,7 +1224,7 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io for (int i = 0; i < rules_.size(); i++) { output.writeMessage(1, rules_.get(i)); } - unknownFields.writeTo(output); + getUnknownFields().writeTo(output); } @java.lang.Override @@ -1405,7 +1236,7 @@ public int getSerializedSize() { for (int i = 0; i < rules_.size(); i++) { size += com.google.protobuf.CodedOutputStream.computeMessageSize(1, rules_.get(i)); } - size += unknownFields.getSerializedSize(); + size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @@ -1422,7 +1253,7 @@ public boolean equals(final java.lang.Object obj) { (com.google.bigtable.admin.v2.GcRule.Union) obj; if (!getRulesList().equals(other.getRulesList())) return false; - if (!unknownFields.equals(other.unknownFields)) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -1437,7 +1268,7 @@ public int hashCode() { hash = (37 * hash) + RULES_FIELD_NUMBER; hash = (53 * hash) + getRulesList().hashCode(); } - hash = (29 * hash) + unknownFields.hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } @@ -1568,19 +1399,10 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { } // Construct using com.google.bigtable.admin.v2.GcRule.Union.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } + private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) { - getRulesFieldBuilder(); - } } @java.lang.Override @@ -1588,10 +1410,11 @@ public Builder clear() { super.clear(); if (rulesBuilder_ == null) { rules_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000001); } else { + rules_ = null; rulesBuilder_.clear(); } + bitField0_ = (bitField0_ & ~0x00000001); return this; } @@ -1707,7 +1530,7 @@ public Builder mergeFrom(com.google.bigtable.admin.v2.GcRule.Union other) { } } } - this.mergeUnknownFields(other.unknownFields); + this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @@ -1722,17 +1545,44 @@ public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - com.google.bigtable.admin.v2.GcRule.Union parsedMessage = null; + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + com.google.bigtable.admin.v2.GcRule m = + input.readMessage( + com.google.bigtable.admin.v2.GcRule.parser(), extensionRegistry); + if (rulesBuilder_ == null) { + ensureRulesIsMutable(); + rules_.add(m); + } else { + rulesBuilder_.addMessage(m); + } + break; + } // case 10 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.bigtable.admin.v2.GcRule.Union) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } + onChanged(); + } // finally return this; } @@ -2119,7 +1969,19 @@ public Union parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new Union(input, extensionRegistry); + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException() + .setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); } }; @@ -2411,7 +2273,7 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io if (ruleCase_ == 4) { output.writeMessage(4, (com.google.bigtable.admin.v2.GcRule.Union) rule_); } - unknownFields.writeTo(output); + getUnknownFields().writeTo(output); } @java.lang.Override @@ -2440,7 +2302,7 @@ public int getSerializedSize() { com.google.protobuf.CodedOutputStream.computeMessageSize( 4, (com.google.bigtable.admin.v2.GcRule.Union) rule_); } - size += unknownFields.getSerializedSize(); + size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @@ -2472,7 +2334,7 @@ public boolean equals(final java.lang.Object obj) { case 0: default: } - if (!unknownFields.equals(other.unknownFields)) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -2503,7 +2365,7 @@ public int hashCode() { case 0: default: } - hash = (29 * hash) + unknownFields.hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } @@ -2631,22 +2493,24 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { } // Construct using com.google.bigtable.admin.v2.GcRule.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } + private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} } @java.lang.Override public Builder clear() { super.clear(); + if (maxAgeBuilder_ != null) { + maxAgeBuilder_.clear(); + } + if (intersectionBuilder_ != null) { + intersectionBuilder_.clear(); + } + if (unionBuilder_ != null) { + unionBuilder_.clear(); + } ruleCase_ = 0; rule_ = null; return this; @@ -2775,7 +2639,7 @@ public Builder mergeFrom(com.google.bigtable.admin.v2.GcRule other) { break; } } - this.mergeUnknownFields(other.unknownFields); + this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @@ -2790,17 +2654,55 @@ public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - com.google.bigtable.admin.v2.GcRule parsedMessage = null; + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 8: + { + rule_ = input.readInt32(); + ruleCase_ = 1; + break; + } // case 8 + case 18: + { + input.readMessage(getMaxAgeFieldBuilder().getBuilder(), extensionRegistry); + ruleCase_ = 2; + break; + } // case 18 + case 26: + { + input.readMessage(getIntersectionFieldBuilder().getBuilder(), extensionRegistry); + ruleCase_ = 3; + break; + } // case 26 + case 34: + { + input.readMessage(getUnionFieldBuilder().getBuilder(), extensionRegistry); + ruleCase_ = 4; + break; + } // case 34 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.bigtable.admin.v2.GcRule) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } + onChanged(); + } // finally return this; } @@ -3561,7 +3463,18 @@ public GcRule parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new GcRule(input, extensionRegistry); + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); } }; diff --git a/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/GenerateConsistencyTokenRequest.java b/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/GenerateConsistencyTokenRequest.java index 0fdca334db..15ae710e62 100644 --- a/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/GenerateConsistencyTokenRequest.java +++ b/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/GenerateConsistencyTokenRequest.java @@ -54,52 +54,6 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - private GenerateConsistencyTokenRequest( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - java.lang.String s = input.readStringRequireUtf8(); - - name_ = s; - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.bigtable.admin.v2.BigtableTableAdminProto .internal_static_google_bigtable_admin_v2_GenerateConsistencyTokenRequest_descriptor; @@ -189,7 +143,7 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(name_)) { com.google.protobuf.GeneratedMessageV3.writeString(output, 1, name_); } - unknownFields.writeTo(output); + getUnknownFields().writeTo(output); } @java.lang.Override @@ -201,7 +155,7 @@ public int getSerializedSize() { if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(name_)) { size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, name_); } - size += unknownFields.getSerializedSize(); + size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @@ -218,7 +172,7 @@ public boolean equals(final java.lang.Object obj) { (com.google.bigtable.admin.v2.GenerateConsistencyTokenRequest) obj; if (!getName().equals(other.getName())) return false; - if (!unknownFields.equals(other.unknownFields)) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -231,7 +185,7 @@ public int hashCode() { hash = (19 * hash) + getDescriptor().hashCode(); hash = (37 * hash) + NAME_FIELD_NUMBER; hash = (53 * hash) + getName().hashCode(); - hash = (29 * hash) + unknownFields.hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } @@ -362,17 +316,10 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { } // Construct using com.google.bigtable.admin.v2.GenerateConsistencyTokenRequest.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } + private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} } @java.lang.Override @@ -464,7 +411,7 @@ public Builder mergeFrom(com.google.bigtable.admin.v2.GenerateConsistencyTokenRe name_ = other.name_; onChanged(); } - this.mergeUnknownFields(other.unknownFields); + this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @@ -479,18 +426,37 @@ public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - com.google.bigtable.admin.v2.GenerateConsistencyTokenRequest parsedMessage = null; + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + name_ = input.readStringRequireUtf8(); + + break; + } // case 10 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = - (com.google.bigtable.admin.v2.GenerateConsistencyTokenRequest) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } + onChanged(); + } // finally return this; } @@ -653,7 +619,18 @@ public GenerateConsistencyTokenRequest parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new GenerateConsistencyTokenRequest(input, extensionRegistry); + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); } }; diff --git a/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/GenerateConsistencyTokenResponse.java b/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/GenerateConsistencyTokenResponse.java index 7445650df5..df2c9b5536 100644 --- a/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/GenerateConsistencyTokenResponse.java +++ b/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/GenerateConsistencyTokenResponse.java @@ -54,52 +54,6 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - private GenerateConsistencyTokenResponse( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - java.lang.String s = input.readStringRequireUtf8(); - - consistencyToken_ = s; - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.bigtable.admin.v2.BigtableTableAdminProto .internal_static_google_bigtable_admin_v2_GenerateConsistencyTokenResponse_descriptor; @@ -181,7 +135,7 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(consistencyToken_)) { com.google.protobuf.GeneratedMessageV3.writeString(output, 1, consistencyToken_); } - unknownFields.writeTo(output); + getUnknownFields().writeTo(output); } @java.lang.Override @@ -193,7 +147,7 @@ public int getSerializedSize() { if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(consistencyToken_)) { size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, consistencyToken_); } - size += unknownFields.getSerializedSize(); + size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @@ -210,7 +164,7 @@ public boolean equals(final java.lang.Object obj) { (com.google.bigtable.admin.v2.GenerateConsistencyTokenResponse) obj; if (!getConsistencyToken().equals(other.getConsistencyToken())) return false; - if (!unknownFields.equals(other.unknownFields)) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -223,7 +177,7 @@ public int hashCode() { hash = (19 * hash) + getDescriptor().hashCode(); hash = (37 * hash) + CONSISTENCY_TOKEN_FIELD_NUMBER; hash = (53 * hash) + getConsistencyToken().hashCode(); - hash = (29 * hash) + unknownFields.hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } @@ -354,17 +308,10 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { } // Construct using com.google.bigtable.admin.v2.GenerateConsistencyTokenResponse.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } + private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} } @java.lang.Override @@ -456,7 +403,7 @@ public Builder mergeFrom(com.google.bigtable.admin.v2.GenerateConsistencyTokenRe consistencyToken_ = other.consistencyToken_; onChanged(); } - this.mergeUnknownFields(other.unknownFields); + this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @@ -471,19 +418,37 @@ public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - com.google.bigtable.admin.v2.GenerateConsistencyTokenResponse parsedMessage = null; + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + consistencyToken_ = input.readStringRequireUtf8(); + + break; + } // case 10 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = - (com.google.bigtable.admin.v2.GenerateConsistencyTokenResponse) - e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } + onChanged(); + } // finally return this; } @@ -626,7 +591,18 @@ public GenerateConsistencyTokenResponse parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new GenerateConsistencyTokenResponse(input, extensionRegistry); + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); } }; diff --git a/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/GetAppProfileRequest.java b/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/GetAppProfileRequest.java index cd2a40b571..82a6c7fcb5 100644 --- a/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/GetAppProfileRequest.java +++ b/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/GetAppProfileRequest.java @@ -52,52 +52,6 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - private GetAppProfileRequest( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - java.lang.String s = input.readStringRequireUtf8(); - - name_ = s; - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.bigtable.admin.v2.BigtableInstanceAdminProto .internal_static_google_bigtable_admin_v2_GetAppProfileRequest_descriptor; @@ -185,7 +139,7 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(name_)) { com.google.protobuf.GeneratedMessageV3.writeString(output, 1, name_); } - unknownFields.writeTo(output); + getUnknownFields().writeTo(output); } @java.lang.Override @@ -197,7 +151,7 @@ public int getSerializedSize() { if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(name_)) { size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, name_); } - size += unknownFields.getSerializedSize(); + size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @@ -214,7 +168,7 @@ public boolean equals(final java.lang.Object obj) { (com.google.bigtable.admin.v2.GetAppProfileRequest) obj; if (!getName().equals(other.getName())) return false; - if (!unknownFields.equals(other.unknownFields)) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -227,7 +181,7 @@ public int hashCode() { hash = (19 * hash) + getDescriptor().hashCode(); hash = (37 * hash) + NAME_FIELD_NUMBER; hash = (53 * hash) + getName().hashCode(); - hash = (29 * hash) + unknownFields.hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } @@ -356,17 +310,10 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { } // Construct using com.google.bigtable.admin.v2.GetAppProfileRequest.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } + private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} } @java.lang.Override @@ -456,7 +403,7 @@ public Builder mergeFrom(com.google.bigtable.admin.v2.GetAppProfileRequest other name_ = other.name_; onChanged(); } - this.mergeUnknownFields(other.unknownFields); + this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @@ -471,18 +418,37 @@ public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - com.google.bigtable.admin.v2.GetAppProfileRequest parsedMessage = null; + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + name_ = input.readStringRequireUtf8(); + + break; + } // case 10 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = - (com.google.bigtable.admin.v2.GetAppProfileRequest) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } + onChanged(); + } // finally return this; } @@ -639,7 +605,18 @@ public GetAppProfileRequest parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new GetAppProfileRequest(input, extensionRegistry); + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); } }; diff --git a/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/GetBackupRequest.java b/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/GetBackupRequest.java index c5c8ed2e0d..54165afb87 100644 --- a/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/GetBackupRequest.java +++ b/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/GetBackupRequest.java @@ -52,52 +52,6 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - private GetBackupRequest( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - java.lang.String s = input.readStringRequireUtf8(); - - name_ = s; - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.bigtable.admin.v2.BigtableTableAdminProto .internal_static_google_bigtable_admin_v2_GetBackupRequest_descriptor; @@ -187,7 +141,7 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(name_)) { com.google.protobuf.GeneratedMessageV3.writeString(output, 1, name_); } - unknownFields.writeTo(output); + getUnknownFields().writeTo(output); } @java.lang.Override @@ -199,7 +153,7 @@ public int getSerializedSize() { if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(name_)) { size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, name_); } - size += unknownFields.getSerializedSize(); + size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @@ -216,7 +170,7 @@ public boolean equals(final java.lang.Object obj) { (com.google.bigtable.admin.v2.GetBackupRequest) obj; if (!getName().equals(other.getName())) return false; - if (!unknownFields.equals(other.unknownFields)) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -229,7 +183,7 @@ public int hashCode() { hash = (19 * hash) + getDescriptor().hashCode(); hash = (37 * hash) + NAME_FIELD_NUMBER; hash = (53 * hash) + getName().hashCode(); - hash = (29 * hash) + unknownFields.hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } @@ -358,17 +312,10 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { } // Construct using com.google.bigtable.admin.v2.GetBackupRequest.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } + private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} } @java.lang.Override @@ -457,7 +404,7 @@ public Builder mergeFrom(com.google.bigtable.admin.v2.GetBackupRequest other) { name_ = other.name_; onChanged(); } - this.mergeUnknownFields(other.unknownFields); + this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @@ -472,17 +419,37 @@ public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - com.google.bigtable.admin.v2.GetBackupRequest parsedMessage = null; + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + name_ = input.readStringRequireUtf8(); + + break; + } // case 10 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.bigtable.admin.v2.GetBackupRequest) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } + onChanged(); + } // finally return this; } @@ -644,7 +611,18 @@ public GetBackupRequest parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new GetBackupRequest(input, extensionRegistry); + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); } }; diff --git a/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/GetClusterRequest.java b/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/GetClusterRequest.java index 67b9f1112f..6b80a8e4f9 100644 --- a/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/GetClusterRequest.java +++ b/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/GetClusterRequest.java @@ -52,52 +52,6 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - private GetClusterRequest( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - java.lang.String s = input.readStringRequireUtf8(); - - name_ = s; - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.bigtable.admin.v2.BigtableInstanceAdminProto .internal_static_google_bigtable_admin_v2_GetClusterRequest_descriptor; @@ -185,7 +139,7 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(name_)) { com.google.protobuf.GeneratedMessageV3.writeString(output, 1, name_); } - unknownFields.writeTo(output); + getUnknownFields().writeTo(output); } @java.lang.Override @@ -197,7 +151,7 @@ public int getSerializedSize() { if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(name_)) { size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, name_); } - size += unknownFields.getSerializedSize(); + size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @@ -214,7 +168,7 @@ public boolean equals(final java.lang.Object obj) { (com.google.bigtable.admin.v2.GetClusterRequest) obj; if (!getName().equals(other.getName())) return false; - if (!unknownFields.equals(other.unknownFields)) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -227,7 +181,7 @@ public int hashCode() { hash = (19 * hash) + getDescriptor().hashCode(); hash = (37 * hash) + NAME_FIELD_NUMBER; hash = (53 * hash) + getName().hashCode(); - hash = (29 * hash) + unknownFields.hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } @@ -356,17 +310,10 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { } // Construct using com.google.bigtable.admin.v2.GetClusterRequest.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } + private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} } @java.lang.Override @@ -455,7 +402,7 @@ public Builder mergeFrom(com.google.bigtable.admin.v2.GetClusterRequest other) { name_ = other.name_; onChanged(); } - this.mergeUnknownFields(other.unknownFields); + this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @@ -470,17 +417,37 @@ public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - com.google.bigtable.admin.v2.GetClusterRequest parsedMessage = null; + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + name_ = input.readStringRequireUtf8(); + + break; + } // case 10 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.bigtable.admin.v2.GetClusterRequest) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } + onChanged(); + } // finally return this; } @@ -637,7 +604,18 @@ public GetClusterRequest parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new GetClusterRequest(input, extensionRegistry); + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); } }; diff --git a/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/GetInstanceRequest.java b/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/GetInstanceRequest.java index a56669f3b9..61a4318c22 100644 --- a/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/GetInstanceRequest.java +++ b/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/GetInstanceRequest.java @@ -52,52 +52,6 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - private GetInstanceRequest( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - java.lang.String s = input.readStringRequireUtf8(); - - name_ = s; - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.bigtable.admin.v2.BigtableInstanceAdminProto .internal_static_google_bigtable_admin_v2_GetInstanceRequest_descriptor; @@ -185,7 +139,7 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(name_)) { com.google.protobuf.GeneratedMessageV3.writeString(output, 1, name_); } - unknownFields.writeTo(output); + getUnknownFields().writeTo(output); } @java.lang.Override @@ -197,7 +151,7 @@ public int getSerializedSize() { if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(name_)) { size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, name_); } - size += unknownFields.getSerializedSize(); + size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @@ -214,7 +168,7 @@ public boolean equals(final java.lang.Object obj) { (com.google.bigtable.admin.v2.GetInstanceRequest) obj; if (!getName().equals(other.getName())) return false; - if (!unknownFields.equals(other.unknownFields)) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -227,7 +181,7 @@ public int hashCode() { hash = (19 * hash) + getDescriptor().hashCode(); hash = (37 * hash) + NAME_FIELD_NUMBER; hash = (53 * hash) + getName().hashCode(); - hash = (29 * hash) + unknownFields.hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } @@ -356,17 +310,10 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { } // Construct using com.google.bigtable.admin.v2.GetInstanceRequest.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } + private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} } @java.lang.Override @@ -456,7 +403,7 @@ public Builder mergeFrom(com.google.bigtable.admin.v2.GetInstanceRequest other) name_ = other.name_; onChanged(); } - this.mergeUnknownFields(other.unknownFields); + this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @@ -471,17 +418,37 @@ public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - com.google.bigtable.admin.v2.GetInstanceRequest parsedMessage = null; + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + name_ = input.readStringRequireUtf8(); + + break; + } // case 10 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.bigtable.admin.v2.GetInstanceRequest) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } + onChanged(); + } // finally return this; } @@ -638,7 +605,18 @@ public GetInstanceRequest parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new GetInstanceRequest(input, extensionRegistry); + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); } }; diff --git a/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/GetSnapshotRequest.java b/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/GetSnapshotRequest.java index e3917838f7..831faeac60 100644 --- a/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/GetSnapshotRequest.java +++ b/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/GetSnapshotRequest.java @@ -57,52 +57,6 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - private GetSnapshotRequest( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - java.lang.String s = input.readStringRequireUtf8(); - - name_ = s; - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.bigtable.admin.v2.BigtableTableAdminProto .internal_static_google_bigtable_admin_v2_GetSnapshotRequest_descriptor; @@ -192,7 +146,7 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(name_)) { com.google.protobuf.GeneratedMessageV3.writeString(output, 1, name_); } - unknownFields.writeTo(output); + getUnknownFields().writeTo(output); } @java.lang.Override @@ -204,7 +158,7 @@ public int getSerializedSize() { if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(name_)) { size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, name_); } - size += unknownFields.getSerializedSize(); + size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @@ -221,7 +175,7 @@ public boolean equals(final java.lang.Object obj) { (com.google.bigtable.admin.v2.GetSnapshotRequest) obj; if (!getName().equals(other.getName())) return false; - if (!unknownFields.equals(other.unknownFields)) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -234,7 +188,7 @@ public int hashCode() { hash = (19 * hash) + getDescriptor().hashCode(); hash = (37 * hash) + NAME_FIELD_NUMBER; hash = (53 * hash) + getName().hashCode(); - hash = (29 * hash) + unknownFields.hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } @@ -368,17 +322,10 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { } // Construct using com.google.bigtable.admin.v2.GetSnapshotRequest.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } + private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} } @java.lang.Override @@ -468,7 +415,7 @@ public Builder mergeFrom(com.google.bigtable.admin.v2.GetSnapshotRequest other) name_ = other.name_; onChanged(); } - this.mergeUnknownFields(other.unknownFields); + this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @@ -483,17 +430,37 @@ public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - com.google.bigtable.admin.v2.GetSnapshotRequest parsedMessage = null; + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + name_ = input.readStringRequireUtf8(); + + break; + } // case 10 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.bigtable.admin.v2.GetSnapshotRequest) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } + onChanged(); + } // finally return this; } @@ -655,7 +622,18 @@ public GetSnapshotRequest parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new GetSnapshotRequest(input, extensionRegistry); + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); } }; diff --git a/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/GetTableRequest.java b/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/GetTableRequest.java index e4cb3954ad..3c2bdabb55 100644 --- a/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/GetTableRequest.java +++ b/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/GetTableRequest.java @@ -54,59 +54,6 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - private GetTableRequest( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - java.lang.String s = input.readStringRequireUtf8(); - - name_ = s; - break; - } - case 16: - { - int rawValue = input.readEnum(); - - view_ = rawValue; - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.bigtable.admin.v2.BigtableTableAdminProto .internal_static_google_bigtable_admin_v2_GetTableRequest_descriptor; @@ -237,7 +184,7 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io if (view_ != com.google.bigtable.admin.v2.Table.View.VIEW_UNSPECIFIED.getNumber()) { output.writeEnum(2, view_); } - unknownFields.writeTo(output); + getUnknownFields().writeTo(output); } @java.lang.Override @@ -252,7 +199,7 @@ public int getSerializedSize() { if (view_ != com.google.bigtable.admin.v2.Table.View.VIEW_UNSPECIFIED.getNumber()) { size += com.google.protobuf.CodedOutputStream.computeEnumSize(2, view_); } - size += unknownFields.getSerializedSize(); + size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @@ -270,7 +217,7 @@ public boolean equals(final java.lang.Object obj) { if (!getName().equals(other.getName())) return false; if (view_ != other.view_) return false; - if (!unknownFields.equals(other.unknownFields)) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -285,7 +232,7 @@ public int hashCode() { hash = (53 * hash) + getName().hashCode(); hash = (37 * hash) + VIEW_FIELD_NUMBER; hash = (53 * hash) + view_; - hash = (29 * hash) + unknownFields.hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } @@ -415,17 +362,10 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { } // Construct using com.google.bigtable.admin.v2.GetTableRequest.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } + private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} } @java.lang.Override @@ -520,7 +460,7 @@ public Builder mergeFrom(com.google.bigtable.admin.v2.GetTableRequest other) { if (other.view_ != 0) { setViewValue(other.getViewValue()); } - this.mergeUnknownFields(other.unknownFields); + this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @@ -535,17 +475,43 @@ public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - com.google.bigtable.admin.v2.GetTableRequest parsedMessage = null; + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + name_ = input.readStringRequireUtf8(); + + break; + } // case 10 + case 16: + { + view_ = input.readEnum(); + + break; + } // case 16 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.bigtable.admin.v2.GetTableRequest) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } + onChanged(); + } // finally return this; } @@ -803,7 +769,18 @@ public GetTableRequest parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new GetTableRequest(input, extensionRegistry); + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); } }; diff --git a/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/HotTablet.java b/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/HotTablet.java index e4ee556792..c8c8349c61 100644 --- a/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/HotTablet.java +++ b/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/HotTablet.java @@ -59,108 +59,6 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - private HotTablet( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - java.lang.String s = input.readStringRequireUtf8(); - - name_ = s; - break; - } - case 18: - { - java.lang.String s = input.readStringRequireUtf8(); - - tableName_ = s; - break; - } - case 26: - { - com.google.protobuf.Timestamp.Builder subBuilder = null; - if (startTime_ != null) { - subBuilder = startTime_.toBuilder(); - } - startTime_ = - input.readMessage(com.google.protobuf.Timestamp.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(startTime_); - startTime_ = subBuilder.buildPartial(); - } - - break; - } - case 34: - { - com.google.protobuf.Timestamp.Builder subBuilder = null; - if (endTime_ != null) { - subBuilder = endTime_.toBuilder(); - } - endTime_ = - input.readMessage(com.google.protobuf.Timestamp.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(endTime_); - endTime_ = subBuilder.buildPartial(); - } - - break; - } - case 42: - { - java.lang.String s = input.readStringRequireUtf8(); - - startKey_ = s; - break; - } - case 50: - { - java.lang.String s = input.readStringRequireUtf8(); - - endKey_ = s; - break; - } - case 61: - { - nodeCpuUsagePercent_ = input.readFloat(); - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.bigtable.admin.v2.InstanceProto .internal_static_google_bigtable_admin_v2_HotTablet_descriptor; @@ -530,7 +428,7 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io if (java.lang.Float.floatToRawIntBits(nodeCpuUsagePercent_) != 0) { output.writeFloat(7, nodeCpuUsagePercent_); } - unknownFields.writeTo(output); + getUnknownFields().writeTo(output); } @java.lang.Override @@ -560,7 +458,7 @@ public int getSerializedSize() { if (java.lang.Float.floatToRawIntBits(nodeCpuUsagePercent_) != 0) { size += com.google.protobuf.CodedOutputStream.computeFloatSize(7, nodeCpuUsagePercent_); } - size += unknownFields.getSerializedSize(); + size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @@ -589,7 +487,7 @@ public boolean equals(final java.lang.Object obj) { if (!getEndKey().equals(other.getEndKey())) return false; if (java.lang.Float.floatToIntBits(getNodeCpuUsagePercent()) != java.lang.Float.floatToIntBits(other.getNodeCpuUsagePercent())) return false; - if (!unknownFields.equals(other.unknownFields)) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -618,7 +516,7 @@ public int hashCode() { hash = (53 * hash) + getEndKey().hashCode(); hash = (37 * hash) + NODE_CPU_USAGE_PERCENT_FIELD_NUMBER; hash = (53 * hash) + java.lang.Float.floatToIntBits(getNodeCpuUsagePercent()); - hash = (29 * hash) + unknownFields.hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } @@ -751,17 +649,10 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { } // Construct using com.google.bigtable.admin.v2.HotTablet.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } + private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} } @java.lang.Override @@ -905,7 +796,7 @@ public Builder mergeFrom(com.google.bigtable.admin.v2.HotTablet other) { if (other.getNodeCpuUsagePercent() != 0F) { setNodeCpuUsagePercent(other.getNodeCpuUsagePercent()); } - this.mergeUnknownFields(other.unknownFields); + this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @@ -920,17 +811,73 @@ public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - com.google.bigtable.admin.v2.HotTablet parsedMessage = null; + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + name_ = input.readStringRequireUtf8(); + + break; + } // case 10 + case 18: + { + tableName_ = input.readStringRequireUtf8(); + + break; + } // case 18 + case 26: + { + input.readMessage(getStartTimeFieldBuilder().getBuilder(), extensionRegistry); + + break; + } // case 26 + case 34: + { + input.readMessage(getEndTimeFieldBuilder().getBuilder(), extensionRegistry); + + break; + } // case 34 + case 42: + { + startKey_ = input.readStringRequireUtf8(); + + break; + } // case 42 + case 50: + { + endKey_ = input.readStringRequireUtf8(); + + break; + } // case 50 + case 61: + { + nodeCpuUsagePercent_ = input.readFloat(); + + break; + } // case 61 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.bigtable.admin.v2.HotTablet) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } + onChanged(); + } // finally return this; } @@ -1837,7 +1784,18 @@ public HotTablet parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new HotTablet(input, extensionRegistry); + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); } }; diff --git a/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/Instance.java b/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/Instance.java index bc9b0a7416..67b76dd0c7 100644 --- a/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/Instance.java +++ b/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/Instance.java @@ -58,102 +58,6 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - private Instance( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - int mutable_bitField0_ = 0; - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - java.lang.String s = input.readStringRequireUtf8(); - - name_ = s; - break; - } - case 18: - { - java.lang.String s = input.readStringRequireUtf8(); - - displayName_ = s; - break; - } - case 24: - { - int rawValue = input.readEnum(); - - state_ = rawValue; - break; - } - case 32: - { - int rawValue = input.readEnum(); - - type_ = rawValue; - break; - } - case 42: - { - if (!((mutable_bitField0_ & 0x00000001) != 0)) { - labels_ = - com.google.protobuf.MapField.newMapField(LabelsDefaultEntryHolder.defaultEntry); - mutable_bitField0_ |= 0x00000001; - } - com.google.protobuf.MapEntry labels__ = - input.readMessage( - LabelsDefaultEntryHolder.defaultEntry.getParserForType(), extensionRegistry); - labels_.getMutableMap().put(labels__.getKey(), labels__.getValue()); - break; - } - case 58: - { - com.google.protobuf.Timestamp.Builder subBuilder = null; - if (createTime_ != null) { - subBuilder = createTime_.toBuilder(); - } - createTime_ = - input.readMessage(com.google.protobuf.Timestamp.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(createTime_); - createTime_ = subBuilder.buildPartial(); - } - - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.bigtable.admin.v2.InstanceProto .internal_static_google_bigtable_admin_v2_Instance_descriptor; @@ -506,6 +410,7 @@ private Type(int value) { // @@protoc_insertion_point(enum_scope:google.bigtable.admin.v2.Instance.Type) } + private int bitField0_; public static final int NAME_FIELD_NUMBER = 1; private volatile java.lang.Object name_; /** @@ -873,6 +778,39 @@ public com.google.protobuf.TimestampOrBuilder getCreateTimeOrBuilder() { return getCreateTime(); } + public static final int SATISFIES_PZS_FIELD_NUMBER = 8; + private boolean satisfiesPzs_; + /** + * + * + *
+   * Output only. Reserved for future use.
+   * 
+ * + * optional bool satisfies_pzs = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return Whether the satisfiesPzs field is set. + */ + @java.lang.Override + public boolean hasSatisfiesPzs() { + return ((bitField0_ & 0x00000001) != 0); + } + /** + * + * + *
+   * Output only. Reserved for future use.
+   * 
+ * + * optional bool satisfies_pzs = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The satisfiesPzs. + */ + @java.lang.Override + public boolean getSatisfiesPzs() { + return satisfiesPzs_; + } + private byte memoizedIsInitialized = -1; @java.lang.Override @@ -904,7 +842,10 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io if (createTime_ != null) { output.writeMessage(7, getCreateTime()); } - unknownFields.writeTo(output); + if (((bitField0_ & 0x00000001) != 0)) { + output.writeBool(8, satisfiesPzs_); + } + getUnknownFields().writeTo(output); } @java.lang.Override @@ -938,7 +879,10 @@ public int getSerializedSize() { if (createTime_ != null) { size += com.google.protobuf.CodedOutputStream.computeMessageSize(7, getCreateTime()); } - size += unknownFields.getSerializedSize(); + if (((bitField0_ & 0x00000001) != 0)) { + size += com.google.protobuf.CodedOutputStream.computeBoolSize(8, satisfiesPzs_); + } + size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @@ -962,7 +906,11 @@ public boolean equals(final java.lang.Object obj) { if (hasCreateTime()) { if (!getCreateTime().equals(other.getCreateTime())) return false; } - if (!unknownFields.equals(other.unknownFields)) return false; + if (hasSatisfiesPzs() != other.hasSatisfiesPzs()) return false; + if (hasSatisfiesPzs()) { + if (getSatisfiesPzs() != other.getSatisfiesPzs()) return false; + } + if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -989,7 +937,11 @@ public int hashCode() { hash = (37 * hash) + CREATE_TIME_FIELD_NUMBER; hash = (53 * hash) + getCreateTime().hashCode(); } - hash = (29 * hash) + unknownFields.hashCode(); + if (hasSatisfiesPzs()) { + hash = (37 * hash) + SATISFIES_PZS_FIELD_NUMBER; + hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean(getSatisfiesPzs()); + } + hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } @@ -1140,17 +1092,10 @@ protected com.google.protobuf.MapField internalGetMutableMapField(int number) { } // Construct using com.google.bigtable.admin.v2.Instance.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } + private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} } @java.lang.Override @@ -1171,6 +1116,8 @@ public Builder clear() { createTime_ = null; createTimeBuilder_ = null; } + satisfiesPzs_ = false; + bitField0_ = (bitField0_ & ~0x00000002); return this; } @@ -1199,6 +1146,7 @@ public com.google.bigtable.admin.v2.Instance buildPartial() { com.google.bigtable.admin.v2.Instance result = new com.google.bigtable.admin.v2.Instance(this); int from_bitField0_ = bitField0_; + int to_bitField0_ = 0; result.name_ = name_; result.displayName_ = displayName_; result.state_ = state_; @@ -1210,6 +1158,11 @@ public com.google.bigtable.admin.v2.Instance buildPartial() { } else { result.createTime_ = createTimeBuilder_.build(); } + if (((from_bitField0_ & 0x00000002) != 0)) { + result.satisfiesPzs_ = satisfiesPzs_; + to_bitField0_ |= 0x00000001; + } + result.bitField0_ = to_bitField0_; onBuilt(); return result; } @@ -1277,7 +1230,10 @@ public Builder mergeFrom(com.google.bigtable.admin.v2.Instance other) { if (other.hasCreateTime()) { mergeCreateTime(other.getCreateTime()); } - this.mergeUnknownFields(other.unknownFields); + if (other.hasSatisfiesPzs()) { + setSatisfiesPzs(other.getSatisfiesPzs()); + } + this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @@ -1292,17 +1248,78 @@ public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - com.google.bigtable.admin.v2.Instance parsedMessage = null; + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + name_ = input.readStringRequireUtf8(); + + break; + } // case 10 + case 18: + { + displayName_ = input.readStringRequireUtf8(); + + break; + } // case 18 + case 24: + { + state_ = input.readEnum(); + + break; + } // case 24 + case 32: + { + type_ = input.readEnum(); + + break; + } // case 32 + case 42: + { + com.google.protobuf.MapEntry labels__ = + input.readMessage( + LabelsDefaultEntryHolder.defaultEntry.getParserForType(), + extensionRegistry); + internalGetMutableLabels() + .getMutableMap() + .put(labels__.getKey(), labels__.getValue()); + break; + } // case 42 + case 58: + { + input.readMessage(getCreateTimeFieldBuilder().getBuilder(), extensionRegistry); + + break; + } // case 58 + case 64: + { + satisfiesPzs_ = input.readBool(); + bitField0_ |= 0x00000002; + break; + } // case 64 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.bigtable.admin.v2.Instance) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } + onChanged(); + } // finally return this; } @@ -2162,6 +2179,73 @@ public com.google.protobuf.TimestampOrBuilder getCreateTimeOrBuilder() { return createTimeBuilder_; } + private boolean satisfiesPzs_; + /** + * + * + *
+     * Output only. Reserved for future use.
+     * 
+ * + * optional bool satisfies_pzs = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return Whether the satisfiesPzs field is set. + */ + @java.lang.Override + public boolean hasSatisfiesPzs() { + return ((bitField0_ & 0x00000002) != 0); + } + /** + * + * + *
+     * Output only. Reserved for future use.
+     * 
+ * + * optional bool satisfies_pzs = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The satisfiesPzs. + */ + @java.lang.Override + public boolean getSatisfiesPzs() { + return satisfiesPzs_; + } + /** + * + * + *
+     * Output only. Reserved for future use.
+     * 
+ * + * optional bool satisfies_pzs = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @param value The satisfiesPzs to set. + * @return This builder for chaining. + */ + public Builder setSatisfiesPzs(boolean value) { + bitField0_ |= 0x00000002; + satisfiesPzs_ = value; + onChanged(); + return this; + } + /** + * + * + *
+     * Output only. Reserved for future use.
+     * 
+ * + * optional bool satisfies_pzs = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return This builder for chaining. + */ + public Builder clearSatisfiesPzs() { + bitField0_ = (bitField0_ & ~0x00000002); + satisfiesPzs_ = false; + onChanged(); + return this; + } + @java.lang.Override public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { return super.setUnknownFields(unknownFields); @@ -2194,7 +2278,18 @@ public Instance parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new Instance(input, extensionRegistry); + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); } }; diff --git a/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/InstanceOrBuilder.java b/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/InstanceOrBuilder.java index 8f094d8acf..103b7d8457 100644 --- a/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/InstanceOrBuilder.java +++ b/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/InstanceOrBuilder.java @@ -278,4 +278,29 @@ java.lang.String getLabelsOrDefault( * */ com.google.protobuf.TimestampOrBuilder getCreateTimeOrBuilder(); + + /** + * + * + *
+   * Output only. Reserved for future use.
+   * 
+ * + * optional bool satisfies_pzs = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return Whether the satisfiesPzs field is set. + */ + boolean hasSatisfiesPzs(); + /** + * + * + *
+   * Output only. Reserved for future use.
+   * 
+ * + * optional bool satisfies_pzs = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The satisfiesPzs. + */ + boolean getSatisfiesPzs(); } diff --git a/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/InstanceProto.java b/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/InstanceProto.java index d73caea850..2b73ddde21 100644 --- a/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/InstanceProto.java +++ b/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/InstanceProto.java @@ -89,80 +89,82 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "field_behavior.proto\032\031google/api/resourc" + "e.proto\032%google/bigtable/admin/v2/common" + ".proto\032\037google/protobuf/timestamp.proto\"" - + "\223\004\n\010Instance\022\014\n\004name\030\001 \001(\t\022\031\n\014display_na" + + "\306\004\n\010Instance\022\014\n\004name\030\001 \001(\t\022\031\n\014display_na" + "me\030\002 \001(\tB\003\340A\002\0227\n\005state\030\003 \001(\0162(.google.bi" + "gtable.admin.v2.Instance.State\0225\n\004type\030\004" + " \001(\0162\'.google.bigtable.admin.v2.Instance" + ".Type\022>\n\006labels\030\005 \003(\0132..google.bigtable." + "admin.v2.Instance.LabelsEntry\0224\n\013create_" + "time\030\007 \001(\0132\032.google.protobuf.TimestampB\003" - + "\340A\003\032-\n\013LabelsEntry\022\013\n\003key\030\001 \001(\t\022\r\n\005value" - + "\030\002 \001(\t:\0028\001\"5\n\005State\022\023\n\017STATE_NOT_KNOWN\020\000" - + "\022\t\n\005READY\020\001\022\014\n\010CREATING\020\002\"=\n\004Type\022\024\n\020TYP" - + "E_UNSPECIFIED\020\000\022\016\n\nPRODUCTION\020\001\022\017\n\013DEVEL" - + "OPMENT\020\002:S\352AP\n%bigtableadmin.googleapis." - + "com/Instance\022\'projects/{project}/instanc" - + "es/{instance}\"_\n\022AutoscalingTargets\022\037\n\027c" - + "pu_utilization_percent\030\002 \001(\005\022(\n storage_" - + "utilization_gib_per_node\030\003 \001(\005\"O\n\021Autosc" - + "alingLimits\022\034\n\017min_serve_nodes\030\001 \001(\005B\003\340A" - + "\002\022\034\n\017max_serve_nodes\030\002 \001(\005B\003\340A\002\"\321\007\n\007Clus" - + "ter\022\014\n\004name\030\001 \001(\t\022;\n\010location\030\002 \001(\tB)\340A\005" - + "\372A#\n!locations.googleapis.com/Location\022;" - + "\n\005state\030\003 \001(\0162\'.google.bigtable.admin.v2" - + ".Cluster.StateB\003\340A\003\022\023\n\013serve_nodes\030\004 \001(\005" - + "\022I\n\016cluster_config\030\007 \001(\0132/.google.bigtab" - + "le.admin.v2.Cluster.ClusterConfigH\000\022H\n\024d" - + "efault_storage_type\030\005 \001(\0162%.google.bigta" - + "ble.admin.v2.StorageTypeB\003\340A\005\022R\n\021encrypt" - + "ion_config\030\006 \001(\01322.google.bigtable.admin" - + ".v2.Cluster.EncryptionConfigB\003\340A\005\032\270\001\n\030Cl" - + "usterAutoscalingConfig\022L\n\022autoscaling_li" - + "mits\030\001 \001(\0132+.google.bigtable.admin.v2.Au" - + "toscalingLimitsB\003\340A\002\022N\n\023autoscaling_targ" - + "ets\030\002 \001(\0132,.google.bigtable.admin.v2.Aut" - + "oscalingTargetsB\003\340A\002\032o\n\rClusterConfig\022^\n" - + "\032cluster_autoscaling_config\030\001 \001(\0132:.goog" - + "le.bigtable.admin.v2.Cluster.ClusterAuto" - + "scalingConfig\032P\n\020EncryptionConfig\022<\n\014kms" - + "_key_name\030\001 \001(\tB&\372A#\n!cloudkms.googleapi" - + "s.com/CryptoKey\"Q\n\005State\022\023\n\017STATE_NOT_KN" - + "OWN\020\000\022\t\n\005READY\020\001\022\014\n\010CREATING\020\002\022\014\n\010RESIZI" - + "NG\020\003\022\014\n\010DISABLED\020\004:e\352Ab\n$bigtableadmin.g" - + "oogleapis.com/Cluster\022:projects/{project" - + "}/instances/{instance}/clusters/{cluster" - + "}B\010\n\006config\"\210\004\n\nAppProfile\022\014\n\004name\030\001 \001(\t" - + "\022\014\n\004etag\030\002 \001(\t\022\023\n\013description\030\003 \001(\t\022g\n\035m" - + "ulti_cluster_routing_use_any\030\005 \001(\0132>.goo" - + "gle.bigtable.admin.v2.AppProfile.MultiCl" - + "usterRoutingUseAnyH\000\022[\n\026single_cluster_r" - + "outing\030\006 \001(\01329.google.bigtable.admin.v2." - + "AppProfile.SingleClusterRoutingH\000\0320\n\031Mul" - + "tiClusterRoutingUseAny\022\023\n\013cluster_ids\030\001 " - + "\003(\t\032N\n\024SingleClusterRouting\022\022\n\ncluster_i" - + "d\030\001 \001(\t\022\"\n\032allow_transactional_writes\030\002 " - + "\001(\010:o\352Al\n\'bigtableadmin.googleapis.com/A" - + "ppProfile\022Aprojects/{project}/instances/" - + "{instance}/appProfiles/{app_profile}B\020\n\016" - + "routing_policy\"\210\003\n\tHotTablet\022\014\n\004name\030\001 \001" - + "(\t\022;\n\ntable_name\030\002 \001(\tB\'\372A$\n\"bigtableadm" - + "in.googleapis.com/Table\0223\n\nstart_time\030\003 " - + "\001(\0132\032.google.protobuf.TimestampB\003\340A\003\0221\n\010" - + "end_time\030\004 \001(\0132\032.google.protobuf.Timesta" - + "mpB\003\340A\003\022\021\n\tstart_key\030\005 \001(\t\022\017\n\007end_key\030\006 " - + "\001(\t\022#\n\026node_cpu_usage_percent\030\007 \001(\002B\003\340A\003" - + ":\177\352A|\n&bigtableadmin.googleapis.com/HotT" - + "ablet\022Rprojects/{project}/instances/{ins" - + "tance}/clusters/{cluster}/hotTablets/{ho" - + "t_tablet}B\320\002\n\034com.google.bigtable.admin." - + "v2B\rInstanceProtoP\001Z=google.golang.org/g" - + "enproto/googleapis/bigtable/admin/v2;adm" - + "in\252\002\036Google.Cloud.Bigtable.Admin.V2\312\002\036Go" - + "ogle\\Cloud\\Bigtable\\Admin\\V2\352\002\"Google::C" - + "loud::Bigtable::Admin::V2\352Ax\n!cloudkms.g" - + "oogleapis.com/CryptoKey\022Sprojects/{proje" - + "ct}/locations/{location}/keyRings/{key_r" - + "ing}/cryptoKeys/{crypto_key}b\006proto3" + + "\340A\003\022\037\n\rsatisfies_pzs\030\010 \001(\010B\003\340A\003H\000\210\001\001\032-\n\013" + + "LabelsEntry\022\013\n\003key\030\001 \001(\t\022\r\n\005value\030\002 \001(\t:" + + "\0028\001\"5\n\005State\022\023\n\017STATE_NOT_KNOWN\020\000\022\t\n\005REA" + + "DY\020\001\022\014\n\010CREATING\020\002\"=\n\004Type\022\024\n\020TYPE_UNSPE" + + "CIFIED\020\000\022\016\n\nPRODUCTION\020\001\022\017\n\013DEVELOPMENT\020" + + "\002:S\352AP\n%bigtableadmin.googleapis.com/Ins" + + "tance\022\'projects/{project}/instances/{ins" + + "tance}B\020\n\016_satisfies_pzs\"_\n\022AutoscalingT" + + "argets\022\037\n\027cpu_utilization_percent\030\002 \001(\005\022" + + "(\n storage_utilization_gib_per_node\030\003 \001(" + + "\005\"O\n\021AutoscalingLimits\022\034\n\017min_serve_node" + + "s\030\001 \001(\005B\003\340A\002\022\034\n\017max_serve_nodes\030\002 \001(\005B\003\340" + + "A\002\"\321\007\n\007Cluster\022\014\n\004name\030\001 \001(\t\022;\n\010location" + + "\030\002 \001(\tB)\340A\005\372A#\n!locations.googleapis.com" + + "/Location\022;\n\005state\030\003 \001(\0162\'.google.bigtab" + + "le.admin.v2.Cluster.StateB\003\340A\003\022\023\n\013serve_" + + "nodes\030\004 \001(\005\022I\n\016cluster_config\030\007 \001(\0132/.go" + + "ogle.bigtable.admin.v2.Cluster.ClusterCo" + + "nfigH\000\022H\n\024default_storage_type\030\005 \001(\0162%.g" + + "oogle.bigtable.admin.v2.StorageTypeB\003\340A\005" + + "\022R\n\021encryption_config\030\006 \001(\01322.google.big" + + "table.admin.v2.Cluster.EncryptionConfigB" + + "\003\340A\005\032\270\001\n\030ClusterAutoscalingConfig\022L\n\022aut" + + "oscaling_limits\030\001 \001(\0132+.google.bigtable." + + "admin.v2.AutoscalingLimitsB\003\340A\002\022N\n\023autos" + + "caling_targets\030\002 \001(\0132,.google.bigtable.a" + + "dmin.v2.AutoscalingTargetsB\003\340A\002\032o\n\rClust" + + "erConfig\022^\n\032cluster_autoscaling_config\030\001" + + " \001(\0132:.google.bigtable.admin.v2.Cluster." + + "ClusterAutoscalingConfig\032P\n\020EncryptionCo" + + "nfig\022<\n\014kms_key_name\030\001 \001(\tB&\372A#\n!cloudkm" + + "s.googleapis.com/CryptoKey\"Q\n\005State\022\023\n\017S" + + "TATE_NOT_KNOWN\020\000\022\t\n\005READY\020\001\022\014\n\010CREATING\020" + + "\002\022\014\n\010RESIZING\020\003\022\014\n\010DISABLED\020\004:e\352Ab\n$bigt" + + "ableadmin.googleapis.com/Cluster\022:projec" + + "ts/{project}/instances/{instance}/cluste" + + "rs/{cluster}B\010\n\006config\"\210\004\n\nAppProfile\022\014\n" + + "\004name\030\001 \001(\t\022\014\n\004etag\030\002 \001(\t\022\023\n\013description" + + "\030\003 \001(\t\022g\n\035multi_cluster_routing_use_any\030" + + "\005 \001(\0132>.google.bigtable.admin.v2.AppProf" + + "ile.MultiClusterRoutingUseAnyH\000\022[\n\026singl" + + "e_cluster_routing\030\006 \001(\01329.google.bigtabl" + + "e.admin.v2.AppProfile.SingleClusterRouti" + + "ngH\000\0320\n\031MultiClusterRoutingUseAny\022\023\n\013clu" + + "ster_ids\030\001 \003(\t\032N\n\024SingleClusterRouting\022\022" + + "\n\ncluster_id\030\001 \001(\t\022\"\n\032allow_transactiona" + + "l_writes\030\002 \001(\010:o\352Al\n\'bigtableadmin.googl" + + "eapis.com/AppProfile\022Aprojects/{project}" + + "/instances/{instance}/appProfiles/{app_p" + + "rofile}B\020\n\016routing_policy\"\210\003\n\tHotTablet\022" + + "\014\n\004name\030\001 \001(\t\022;\n\ntable_name\030\002 \001(\tB\'\372A$\n\"" + + "bigtableadmin.googleapis.com/Table\0223\n\nst" + + "art_time\030\003 \001(\0132\032.google.protobuf.Timesta" + + "mpB\003\340A\003\0221\n\010end_time\030\004 \001(\0132\032.google.proto" + + "buf.TimestampB\003\340A\003\022\021\n\tstart_key\030\005 \001(\t\022\017\n" + + "\007end_key\030\006 \001(\t\022#\n\026node_cpu_usage_percent" + + "\030\007 \001(\002B\003\340A\003:\177\352A|\n&bigtableadmin.googleap" + + "is.com/HotTablet\022Rprojects/{project}/ins" + + "tances/{instance}/clusters/{cluster}/hot" + + "Tablets/{hot_tablet}B\320\002\n\034com.google.bigt" + + "able.admin.v2B\rInstanceProtoP\001Z=google.g" + + "olang.org/genproto/googleapis/bigtable/a" + + "dmin/v2;admin\252\002\036Google.Cloud.Bigtable.Ad" + + "min.V2\312\002\036Google\\Cloud\\Bigtable\\Admin\\V2\352" + + "\002\"Google::Cloud::Bigtable::Admin::V2\352Ax\n" + + "!cloudkms.googleapis.com/CryptoKey\022Sproj" + + "ects/{project}/locations/{location}/keyR" + + "ings/{key_ring}/cryptoKeys/{crypto_key}b" + + "\006proto3" }; descriptor = com.google.protobuf.Descriptors.FileDescriptor.internalBuildGeneratedFileFrom( @@ -179,7 +181,14 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( internal_static_google_bigtable_admin_v2_Instance_descriptor, new java.lang.String[] { - "Name", "DisplayName", "State", "Type", "Labels", "CreateTime", + "Name", + "DisplayName", + "State", + "Type", + "Labels", + "CreateTime", + "SatisfiesPzs", + "SatisfiesPzs", }); internal_static_google_bigtable_admin_v2_Instance_LabelsEntry_descriptor = internal_static_google_bigtable_admin_v2_Instance_descriptor.getNestedTypes().get(0); diff --git a/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/ListAppProfilesRequest.java b/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/ListAppProfilesRequest.java index d90e401eda..492fa44099 100644 --- a/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/ListAppProfilesRequest.java +++ b/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/ListAppProfilesRequest.java @@ -53,64 +53,6 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - private ListAppProfilesRequest( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - java.lang.String s = input.readStringRequireUtf8(); - - parent_ = s; - break; - } - case 18: - { - java.lang.String s = input.readStringRequireUtf8(); - - pageToken_ = s; - break; - } - case 24: - { - pageSize_ = input.readInt32(); - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.bigtable.admin.v2.BigtableInstanceAdminProto .internal_static_google_bigtable_admin_v2_ListAppProfilesRequest_descriptor; @@ -283,7 +225,7 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io if (pageSize_ != 0) { output.writeInt32(3, pageSize_); } - unknownFields.writeTo(output); + getUnknownFields().writeTo(output); } @java.lang.Override @@ -301,7 +243,7 @@ public int getSerializedSize() { if (pageSize_ != 0) { size += com.google.protobuf.CodedOutputStream.computeInt32Size(3, pageSize_); } - size += unknownFields.getSerializedSize(); + size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @@ -320,7 +262,7 @@ public boolean equals(final java.lang.Object obj) { if (!getParent().equals(other.getParent())) return false; if (getPageSize() != other.getPageSize()) return false; if (!getPageToken().equals(other.getPageToken())) return false; - if (!unknownFields.equals(other.unknownFields)) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -337,7 +279,7 @@ public int hashCode() { hash = (53 * hash) + getPageSize(); hash = (37 * hash) + PAGE_TOKEN_FIELD_NUMBER; hash = (53 * hash) + getPageToken().hashCode(); - hash = (29 * hash) + unknownFields.hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } @@ -466,17 +408,10 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { } // Construct using com.google.bigtable.admin.v2.ListAppProfilesRequest.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } + private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} } @java.lang.Override @@ -579,7 +514,7 @@ public Builder mergeFrom(com.google.bigtable.admin.v2.ListAppProfilesRequest oth pageToken_ = other.pageToken_; onChanged(); } - this.mergeUnknownFields(other.unknownFields); + this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @@ -594,18 +529,49 @@ public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - com.google.bigtable.admin.v2.ListAppProfilesRequest parsedMessage = null; + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + parent_ = input.readStringRequireUtf8(); + + break; + } // case 10 + case 18: + { + pageToken_ = input.readStringRequireUtf8(); + + break; + } // case 18 + case 24: + { + pageSize_ = input.readInt32(); + + break; + } // case 24 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = - (com.google.bigtable.admin.v2.ListAppProfilesRequest) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } + onChanged(); + } // finally return this; } @@ -953,7 +919,18 @@ public ListAppProfilesRequest parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new ListAppProfilesRequest(input, extensionRegistry); + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); } }; diff --git a/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/ListAppProfilesResponse.java b/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/ListAppProfilesResponse.java index fe5435fbb0..42ce1fdf18 100644 --- a/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/ListAppProfilesResponse.java +++ b/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/ListAppProfilesResponse.java @@ -54,80 +54,6 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - private ListAppProfilesResponse( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - int mutable_bitField0_ = 0; - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - if (!((mutable_bitField0_ & 0x00000001) != 0)) { - appProfiles_ = new java.util.ArrayList(); - mutable_bitField0_ |= 0x00000001; - } - appProfiles_.add( - input.readMessage( - com.google.bigtable.admin.v2.AppProfile.parser(), extensionRegistry)); - break; - } - case 18: - { - java.lang.String s = input.readStringRequireUtf8(); - - nextPageToken_ = s; - break; - } - case 26: - { - java.lang.String s = input.readStringRequireUtf8(); - if (!((mutable_bitField0_ & 0x00000002) != 0)) { - failedLocations_ = new com.google.protobuf.LazyStringArrayList(); - mutable_bitField0_ |= 0x00000002; - } - failedLocations_.add(s); - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); - } finally { - if (((mutable_bitField0_ & 0x00000001) != 0)) { - appProfiles_ = java.util.Collections.unmodifiableList(appProfiles_); - } - if (((mutable_bitField0_ & 0x00000002) != 0)) { - failedLocations_ = failedLocations_.getUnmodifiableView(); - } - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.bigtable.admin.v2.BigtableInstanceAdminProto .internal_static_google_bigtable_admin_v2_ListAppProfilesResponse_descriptor; @@ -361,7 +287,7 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io for (int i = 0; i < failedLocations_.size(); i++) { com.google.protobuf.GeneratedMessageV3.writeString(output, 3, failedLocations_.getRaw(i)); } - unknownFields.writeTo(output); + getUnknownFields().writeTo(output); } @java.lang.Override @@ -384,7 +310,7 @@ public int getSerializedSize() { size += dataSize; size += 1 * getFailedLocationsList().size(); } - size += unknownFields.getSerializedSize(); + size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @@ -403,7 +329,7 @@ public boolean equals(final java.lang.Object obj) { if (!getAppProfilesList().equals(other.getAppProfilesList())) return false; if (!getNextPageToken().equals(other.getNextPageToken())) return false; if (!getFailedLocationsList().equals(other.getFailedLocationsList())) return false; - if (!unknownFields.equals(other.unknownFields)) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -424,7 +350,7 @@ public int hashCode() { hash = (37 * hash) + FAILED_LOCATIONS_FIELD_NUMBER; hash = (53 * hash) + getFailedLocationsList().hashCode(); } - hash = (29 * hash) + unknownFields.hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } @@ -553,19 +479,10 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { } // Construct using com.google.bigtable.admin.v2.ListAppProfilesResponse.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } + private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) { - getAppProfilesFieldBuilder(); - } } @java.lang.Override @@ -573,10 +490,11 @@ public Builder clear() { super.clear(); if (appProfilesBuilder_ == null) { appProfiles_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000001); } else { + appProfiles_ = null; appProfilesBuilder_.clear(); } + bitField0_ = (bitField0_ & ~0x00000001); nextPageToken_ = ""; failedLocations_ = com.google.protobuf.LazyStringArrayList.EMPTY; @@ -715,7 +633,7 @@ public Builder mergeFrom(com.google.bigtable.admin.v2.ListAppProfilesResponse ot } onChanged(); } - this.mergeUnknownFields(other.unknownFields); + this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @@ -730,18 +648,57 @@ public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - com.google.bigtable.admin.v2.ListAppProfilesResponse parsedMessage = null; + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + com.google.bigtable.admin.v2.AppProfile m = + input.readMessage( + com.google.bigtable.admin.v2.AppProfile.parser(), extensionRegistry); + if (appProfilesBuilder_ == null) { + ensureAppProfilesIsMutable(); + appProfiles_.add(m); + } else { + appProfilesBuilder_.addMessage(m); + } + break; + } // case 10 + case 18: + { + nextPageToken_ = input.readStringRequireUtf8(); + + break; + } // case 18 + case 26: + { + java.lang.String s = input.readStringRequireUtf8(); + ensureFailedLocationsIsMutable(); + failedLocations_.add(s); + break; + } // case 26 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = - (com.google.bigtable.admin.v2.ListAppProfilesResponse) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } + onChanged(); + } // finally return this; } @@ -1440,7 +1397,18 @@ public ListAppProfilesResponse parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new ListAppProfilesResponse(input, extensionRegistry); + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); } }; diff --git a/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/ListBackupsRequest.java b/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/ListBackupsRequest.java index 720bcd126a..f36e324d1c 100644 --- a/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/ListBackupsRequest.java +++ b/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/ListBackupsRequest.java @@ -55,78 +55,6 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - private ListBackupsRequest( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - java.lang.String s = input.readStringRequireUtf8(); - - parent_ = s; - break; - } - case 18: - { - java.lang.String s = input.readStringRequireUtf8(); - - filter_ = s; - break; - } - case 26: - { - java.lang.String s = input.readStringRequireUtf8(); - - orderBy_ = s; - break; - } - case 32: - { - pageSize_ = input.readInt32(); - break; - } - case 42: - { - java.lang.String s = input.readStringRequireUtf8(); - - pageToken_ = s; - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.bigtable.admin.v2.BigtableTableAdminProto .internal_static_google_bigtable_admin_v2_ListBackupsRequest_descriptor; @@ -488,7 +416,7 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(pageToken_)) { com.google.protobuf.GeneratedMessageV3.writeString(output, 5, pageToken_); } - unknownFields.writeTo(output); + getUnknownFields().writeTo(output); } @java.lang.Override @@ -512,7 +440,7 @@ public int getSerializedSize() { if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(pageToken_)) { size += com.google.protobuf.GeneratedMessageV3.computeStringSize(5, pageToken_); } - size += unknownFields.getSerializedSize(); + size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @@ -533,7 +461,7 @@ public boolean equals(final java.lang.Object obj) { if (!getOrderBy().equals(other.getOrderBy())) return false; if (getPageSize() != other.getPageSize()) return false; if (!getPageToken().equals(other.getPageToken())) return false; - if (!unknownFields.equals(other.unknownFields)) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -554,7 +482,7 @@ public int hashCode() { hash = (53 * hash) + getPageSize(); hash = (37 * hash) + PAGE_TOKEN_FIELD_NUMBER; hash = (53 * hash) + getPageToken().hashCode(); - hash = (29 * hash) + unknownFields.hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } @@ -683,17 +611,10 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { } // Construct using com.google.bigtable.admin.v2.ListBackupsRequest.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } + private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} } @java.lang.Override @@ -810,7 +731,7 @@ public Builder mergeFrom(com.google.bigtable.admin.v2.ListBackupsRequest other) pageToken_ = other.pageToken_; onChanged(); } - this.mergeUnknownFields(other.unknownFields); + this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @@ -825,17 +746,61 @@ public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - com.google.bigtable.admin.v2.ListBackupsRequest parsedMessage = null; + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + parent_ = input.readStringRequireUtf8(); + + break; + } // case 10 + case 18: + { + filter_ = input.readStringRequireUtf8(); + + break; + } // case 18 + case 26: + { + orderBy_ = input.readStringRequireUtf8(); + + break; + } // case 26 + case 32: + { + pageSize_ = input.readInt32(); + + break; + } // case 32 + case 42: + { + pageToken_ = input.readStringRequireUtf8(); + + break; + } // case 42 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.bigtable.admin.v2.ListBackupsRequest) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } + onChanged(); + } // finally return this; } @@ -1605,7 +1570,18 @@ public ListBackupsRequest parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new ListBackupsRequest(input, extensionRegistry); + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); } }; diff --git a/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/ListBackupsResponse.java b/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/ListBackupsResponse.java index 786ef99311..0e026a369c 100644 --- a/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/ListBackupsResponse.java +++ b/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/ListBackupsResponse.java @@ -53,67 +53,6 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - private ListBackupsResponse( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - int mutable_bitField0_ = 0; - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - if (!((mutable_bitField0_ & 0x00000001) != 0)) { - backups_ = new java.util.ArrayList(); - mutable_bitField0_ |= 0x00000001; - } - backups_.add( - input.readMessage( - com.google.bigtable.admin.v2.Backup.parser(), extensionRegistry)); - break; - } - case 18: - { - java.lang.String s = input.readStringRequireUtf8(); - - nextPageToken_ = s; - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); - } finally { - if (((mutable_bitField0_ & 0x00000001) != 0)) { - backups_ = java.util.Collections.unmodifiableList(backups_); - } - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.bigtable.admin.v2.BigtableTableAdminProto .internal_static_google_bigtable_admin_v2_ListBackupsResponse_descriptor; @@ -271,7 +210,7 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(nextPageToken_)) { com.google.protobuf.GeneratedMessageV3.writeString(output, 2, nextPageToken_); } - unknownFields.writeTo(output); + getUnknownFields().writeTo(output); } @java.lang.Override @@ -286,7 +225,7 @@ public int getSerializedSize() { if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(nextPageToken_)) { size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, nextPageToken_); } - size += unknownFields.getSerializedSize(); + size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @@ -304,7 +243,7 @@ public boolean equals(final java.lang.Object obj) { if (!getBackupsList().equals(other.getBackupsList())) return false; if (!getNextPageToken().equals(other.getNextPageToken())) return false; - if (!unknownFields.equals(other.unknownFields)) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -321,7 +260,7 @@ public int hashCode() { } hash = (37 * hash) + NEXT_PAGE_TOKEN_FIELD_NUMBER; hash = (53 * hash) + getNextPageToken().hashCode(); - hash = (29 * hash) + unknownFields.hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } @@ -450,19 +389,10 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { } // Construct using com.google.bigtable.admin.v2.ListBackupsResponse.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } + private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) { - getBackupsFieldBuilder(); - } } @java.lang.Override @@ -470,10 +400,11 @@ public Builder clear() { super.clear(); if (backupsBuilder_ == null) { backups_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000001); } else { + backups_ = null; backupsBuilder_.clear(); } + bitField0_ = (bitField0_ & ~0x00000001); nextPageToken_ = ""; return this; @@ -595,7 +526,7 @@ public Builder mergeFrom(com.google.bigtable.admin.v2.ListBackupsResponse other) nextPageToken_ = other.nextPageToken_; onChanged(); } - this.mergeUnknownFields(other.unknownFields); + this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @@ -610,17 +541,50 @@ public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - com.google.bigtable.admin.v2.ListBackupsResponse parsedMessage = null; + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + com.google.bigtable.admin.v2.Backup m = + input.readMessage( + com.google.bigtable.admin.v2.Backup.parser(), extensionRegistry); + if (backupsBuilder_ == null) { + ensureBackupsIsMutable(); + backups_.add(m); + } else { + backupsBuilder_.addMessage(m); + } + break; + } // case 10 + case 18: + { + nextPageToken_ = input.readStringRequireUtf8(); + + break; + } // case 18 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.bigtable.admin.v2.ListBackupsResponse) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } + onChanged(); + } // finally return this; } @@ -1122,7 +1086,18 @@ public ListBackupsResponse parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new ListBackupsResponse(input, extensionRegistry); + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); } }; diff --git a/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/ListClustersRequest.java b/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/ListClustersRequest.java index 138bb9040a..f131727426 100644 --- a/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/ListClustersRequest.java +++ b/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/ListClustersRequest.java @@ -53,59 +53,6 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - private ListClustersRequest( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - java.lang.String s = input.readStringRequireUtf8(); - - parent_ = s; - break; - } - case 18: - { - java.lang.String s = input.readStringRequireUtf8(); - - pageToken_ = s; - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.bigtable.admin.v2.BigtableInstanceAdminProto .internal_static_google_bigtable_admin_v2_ListClustersRequest_descriptor; @@ -249,7 +196,7 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(pageToken_)) { com.google.protobuf.GeneratedMessageV3.writeString(output, 2, pageToken_); } - unknownFields.writeTo(output); + getUnknownFields().writeTo(output); } @java.lang.Override @@ -264,7 +211,7 @@ public int getSerializedSize() { if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(pageToken_)) { size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, pageToken_); } - size += unknownFields.getSerializedSize(); + size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @@ -282,7 +229,7 @@ public boolean equals(final java.lang.Object obj) { if (!getParent().equals(other.getParent())) return false; if (!getPageToken().equals(other.getPageToken())) return false; - if (!unknownFields.equals(other.unknownFields)) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -297,7 +244,7 @@ public int hashCode() { hash = (53 * hash) + getParent().hashCode(); hash = (37 * hash) + PAGE_TOKEN_FIELD_NUMBER; hash = (53 * hash) + getPageToken().hashCode(); - hash = (29 * hash) + unknownFields.hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } @@ -426,17 +373,10 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { } // Construct using com.google.bigtable.admin.v2.ListClustersRequest.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } + private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} } @java.lang.Override @@ -533,7 +473,7 @@ public Builder mergeFrom(com.google.bigtable.admin.v2.ListClustersRequest other) pageToken_ = other.pageToken_; onChanged(); } - this.mergeUnknownFields(other.unknownFields); + this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @@ -548,17 +488,43 @@ public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - com.google.bigtable.admin.v2.ListClustersRequest parsedMessage = null; + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + parent_ = input.readStringRequireUtf8(); + + break; + } // case 10 + case 18: + { + pageToken_ = input.readStringRequireUtf8(); + + break; + } // case 18 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.bigtable.admin.v2.ListClustersRequest) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } + onChanged(); + } // finally return this; } @@ -831,7 +797,18 @@ public ListClustersRequest parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new ListClustersRequest(input, extensionRegistry); + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); } }; diff --git a/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/ListClustersResponse.java b/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/ListClustersResponse.java index ed1e3fadbb..4bb6580ce2 100644 --- a/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/ListClustersResponse.java +++ b/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/ListClustersResponse.java @@ -54,80 +54,6 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - private ListClustersResponse( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - int mutable_bitField0_ = 0; - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - if (!((mutable_bitField0_ & 0x00000001) != 0)) { - clusters_ = new java.util.ArrayList(); - mutable_bitField0_ |= 0x00000001; - } - clusters_.add( - input.readMessage( - com.google.bigtable.admin.v2.Cluster.parser(), extensionRegistry)); - break; - } - case 18: - { - java.lang.String s = input.readStringRequireUtf8(); - if (!((mutable_bitField0_ & 0x00000002) != 0)) { - failedLocations_ = new com.google.protobuf.LazyStringArrayList(); - mutable_bitField0_ |= 0x00000002; - } - failedLocations_.add(s); - break; - } - case 26: - { - java.lang.String s = input.readStringRequireUtf8(); - - nextPageToken_ = s; - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); - } finally { - if (((mutable_bitField0_ & 0x00000001) != 0)) { - clusters_ = java.util.Collections.unmodifiableList(clusters_); - } - if (((mutable_bitField0_ & 0x00000002) != 0)) { - failedLocations_ = failedLocations_.getUnmodifiableView(); - } - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.bigtable.admin.v2.BigtableInstanceAdminProto .internal_static_google_bigtable_admin_v2_ListClustersResponse_descriptor; @@ -361,7 +287,7 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(nextPageToken_)) { com.google.protobuf.GeneratedMessageV3.writeString(output, 3, nextPageToken_); } - unknownFields.writeTo(output); + getUnknownFields().writeTo(output); } @java.lang.Override @@ -384,7 +310,7 @@ public int getSerializedSize() { if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(nextPageToken_)) { size += com.google.protobuf.GeneratedMessageV3.computeStringSize(3, nextPageToken_); } - size += unknownFields.getSerializedSize(); + size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @@ -403,7 +329,7 @@ public boolean equals(final java.lang.Object obj) { if (!getClustersList().equals(other.getClustersList())) return false; if (!getFailedLocationsList().equals(other.getFailedLocationsList())) return false; if (!getNextPageToken().equals(other.getNextPageToken())) return false; - if (!unknownFields.equals(other.unknownFields)) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -424,7 +350,7 @@ public int hashCode() { } hash = (37 * hash) + NEXT_PAGE_TOKEN_FIELD_NUMBER; hash = (53 * hash) + getNextPageToken().hashCode(); - hash = (29 * hash) + unknownFields.hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } @@ -553,19 +479,10 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { } // Construct using com.google.bigtable.admin.v2.ListClustersResponse.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } + private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) { - getClustersFieldBuilder(); - } } @java.lang.Override @@ -573,10 +490,11 @@ public Builder clear() { super.clear(); if (clustersBuilder_ == null) { clusters_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000001); } else { + clusters_ = null; clustersBuilder_.clear(); } + bitField0_ = (bitField0_ & ~0x00000001); failedLocations_ = com.google.protobuf.LazyStringArrayList.EMPTY; bitField0_ = (bitField0_ & ~0x00000002); nextPageToken_ = ""; @@ -715,7 +633,7 @@ public Builder mergeFrom(com.google.bigtable.admin.v2.ListClustersResponse other nextPageToken_ = other.nextPageToken_; onChanged(); } - this.mergeUnknownFields(other.unknownFields); + this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @@ -730,18 +648,57 @@ public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - com.google.bigtable.admin.v2.ListClustersResponse parsedMessage = null; + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + com.google.bigtable.admin.v2.Cluster m = + input.readMessage( + com.google.bigtable.admin.v2.Cluster.parser(), extensionRegistry); + if (clustersBuilder_ == null) { + ensureClustersIsMutable(); + clusters_.add(m); + } else { + clustersBuilder_.addMessage(m); + } + break; + } // case 10 + case 18: + { + java.lang.String s = input.readStringRequireUtf8(); + ensureFailedLocationsIsMutable(); + failedLocations_.add(s); + break; + } // case 18 + case 26: + { + nextPageToken_ = input.readStringRequireUtf8(); + + break; + } // case 26 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = - (com.google.bigtable.admin.v2.ListClustersResponse) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } + onChanged(); + } // finally return this; } @@ -1437,7 +1394,18 @@ public ListClustersResponse parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new ListClustersResponse(input, extensionRegistry); + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); } }; diff --git a/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/ListHotTabletsRequest.java b/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/ListHotTabletsRequest.java index 0a010c7292..103fa0b8c7 100644 --- a/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/ListHotTabletsRequest.java +++ b/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/ListHotTabletsRequest.java @@ -53,94 +53,6 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - private ListHotTabletsRequest( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - java.lang.String s = input.readStringRequireUtf8(); - - parent_ = s; - break; - } - case 18: - { - com.google.protobuf.Timestamp.Builder subBuilder = null; - if (startTime_ != null) { - subBuilder = startTime_.toBuilder(); - } - startTime_ = - input.readMessage(com.google.protobuf.Timestamp.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(startTime_); - startTime_ = subBuilder.buildPartial(); - } - - break; - } - case 26: - { - com.google.protobuf.Timestamp.Builder subBuilder = null; - if (endTime_ != null) { - subBuilder = endTime_.toBuilder(); - } - endTime_ = - input.readMessage(com.google.protobuf.Timestamp.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(endTime_); - endTime_ = subBuilder.buildPartial(); - } - - break; - } - case 32: - { - pageSize_ = input.readInt32(); - break; - } - case 42: - { - java.lang.String s = input.readStringRequireUtf8(); - - pageToken_ = s; - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.bigtable.admin.v2.BigtableInstanceAdminProto .internal_static_google_bigtable_admin_v2_ListHotTabletsRequest_descriptor; @@ -422,7 +334,7 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(pageToken_)) { com.google.protobuf.GeneratedMessageV3.writeString(output, 5, pageToken_); } - unknownFields.writeTo(output); + getUnknownFields().writeTo(output); } @java.lang.Override @@ -446,7 +358,7 @@ public int getSerializedSize() { if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(pageToken_)) { size += com.google.protobuf.GeneratedMessageV3.computeStringSize(5, pageToken_); } - size += unknownFields.getSerializedSize(); + size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @@ -473,7 +385,7 @@ public boolean equals(final java.lang.Object obj) { } if (getPageSize() != other.getPageSize()) return false; if (!getPageToken().equals(other.getPageToken())) return false; - if (!unknownFields.equals(other.unknownFields)) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -498,7 +410,7 @@ public int hashCode() { hash = (53 * hash) + getPageSize(); hash = (37 * hash) + PAGE_TOKEN_FIELD_NUMBER; hash = (53 * hash) + getPageToken().hashCode(); - hash = (29 * hash) + unknownFields.hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } @@ -627,17 +539,10 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { } // Construct using com.google.bigtable.admin.v2.ListHotTabletsRequest.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } + private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} } @java.lang.Override @@ -768,7 +673,7 @@ public Builder mergeFrom(com.google.bigtable.admin.v2.ListHotTabletsRequest othe pageToken_ = other.pageToken_; onChanged(); } - this.mergeUnknownFields(other.unknownFields); + this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @@ -783,18 +688,61 @@ public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - com.google.bigtable.admin.v2.ListHotTabletsRequest parsedMessage = null; + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + parent_ = input.readStringRequireUtf8(); + + break; + } // case 10 + case 18: + { + input.readMessage(getStartTimeFieldBuilder().getBuilder(), extensionRegistry); + + break; + } // case 18 + case 26: + { + input.readMessage(getEndTimeFieldBuilder().getBuilder(), extensionRegistry); + + break; + } // case 26 + case 32: + { + pageSize_ = input.readInt32(); + + break; + } // case 32 + case 42: + { + pageToken_ = input.readStringRequireUtf8(); + + break; + } // case 42 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = - (com.google.bigtable.admin.v2.ListHotTabletsRequest) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } + onChanged(); + } // finally return this; } @@ -1535,7 +1483,18 @@ public ListHotTabletsRequest parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new ListHotTabletsRequest(input, extensionRegistry); + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); } }; diff --git a/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/ListHotTabletsResponse.java b/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/ListHotTabletsResponse.java index d45ef7325e..90ecf3ef7d 100644 --- a/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/ListHotTabletsResponse.java +++ b/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/ListHotTabletsResponse.java @@ -53,67 +53,6 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - private ListHotTabletsResponse( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - int mutable_bitField0_ = 0; - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - if (!((mutable_bitField0_ & 0x00000001) != 0)) { - hotTablets_ = new java.util.ArrayList(); - mutable_bitField0_ |= 0x00000001; - } - hotTablets_.add( - input.readMessage( - com.google.bigtable.admin.v2.HotTablet.parser(), extensionRegistry)); - break; - } - case 18: - { - java.lang.String s = input.readStringRequireUtf8(); - - nextPageToken_ = s; - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); - } finally { - if (((mutable_bitField0_ & 0x00000001) != 0)) { - hotTablets_ = java.util.Collections.unmodifiableList(hotTablets_); - } - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.bigtable.admin.v2.BigtableInstanceAdminProto .internal_static_google_bigtable_admin_v2_ListHotTabletsResponse_descriptor; @@ -291,7 +230,7 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(nextPageToken_)) { com.google.protobuf.GeneratedMessageV3.writeString(output, 2, nextPageToken_); } - unknownFields.writeTo(output); + getUnknownFields().writeTo(output); } @java.lang.Override @@ -306,7 +245,7 @@ public int getSerializedSize() { if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(nextPageToken_)) { size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, nextPageToken_); } - size += unknownFields.getSerializedSize(); + size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @@ -324,7 +263,7 @@ public boolean equals(final java.lang.Object obj) { if (!getHotTabletsList().equals(other.getHotTabletsList())) return false; if (!getNextPageToken().equals(other.getNextPageToken())) return false; - if (!unknownFields.equals(other.unknownFields)) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -341,7 +280,7 @@ public int hashCode() { } hash = (37 * hash) + NEXT_PAGE_TOKEN_FIELD_NUMBER; hash = (53 * hash) + getNextPageToken().hashCode(); - hash = (29 * hash) + unknownFields.hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } @@ -470,19 +409,10 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { } // Construct using com.google.bigtable.admin.v2.ListHotTabletsResponse.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } + private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) { - getHotTabletsFieldBuilder(); - } } @java.lang.Override @@ -490,10 +420,11 @@ public Builder clear() { super.clear(); if (hotTabletsBuilder_ == null) { hotTablets_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000001); } else { + hotTablets_ = null; hotTabletsBuilder_.clear(); } + bitField0_ = (bitField0_ & ~0x00000001); nextPageToken_ = ""; return this; @@ -615,7 +546,7 @@ public Builder mergeFrom(com.google.bigtable.admin.v2.ListHotTabletsResponse oth nextPageToken_ = other.nextPageToken_; onChanged(); } - this.mergeUnknownFields(other.unknownFields); + this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @@ -630,18 +561,50 @@ public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - com.google.bigtable.admin.v2.ListHotTabletsResponse parsedMessage = null; + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + com.google.bigtable.admin.v2.HotTablet m = + input.readMessage( + com.google.bigtable.admin.v2.HotTablet.parser(), extensionRegistry); + if (hotTabletsBuilder_ == null) { + ensureHotTabletsIsMutable(); + hotTablets_.add(m); + } else { + hotTabletsBuilder_.addMessage(m); + } + break; + } // case 10 + case 18: + { + nextPageToken_ = input.readStringRequireUtf8(); + + break; + } // case 18 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = - (com.google.bigtable.admin.v2.ListHotTabletsResponse) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } + onChanged(); + } // finally return this; } @@ -1216,7 +1179,18 @@ public ListHotTabletsResponse parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new ListHotTabletsResponse(input, extensionRegistry); + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); } }; diff --git a/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/ListInstancesRequest.java b/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/ListInstancesRequest.java index c95ab64bb5..a64bd54432 100644 --- a/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/ListInstancesRequest.java +++ b/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/ListInstancesRequest.java @@ -53,59 +53,6 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - private ListInstancesRequest( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - java.lang.String s = input.readStringRequireUtf8(); - - parent_ = s; - break; - } - case 18: - { - java.lang.String s = input.readStringRequireUtf8(); - - pageToken_ = s; - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.bigtable.admin.v2.BigtableInstanceAdminProto .internal_static_google_bigtable_admin_v2_ListInstancesRequest_descriptor; @@ -245,7 +192,7 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(pageToken_)) { com.google.protobuf.GeneratedMessageV3.writeString(output, 2, pageToken_); } - unknownFields.writeTo(output); + getUnknownFields().writeTo(output); } @java.lang.Override @@ -260,7 +207,7 @@ public int getSerializedSize() { if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(pageToken_)) { size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, pageToken_); } - size += unknownFields.getSerializedSize(); + size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @@ -278,7 +225,7 @@ public boolean equals(final java.lang.Object obj) { if (!getParent().equals(other.getParent())) return false; if (!getPageToken().equals(other.getPageToken())) return false; - if (!unknownFields.equals(other.unknownFields)) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -293,7 +240,7 @@ public int hashCode() { hash = (53 * hash) + getParent().hashCode(); hash = (37 * hash) + PAGE_TOKEN_FIELD_NUMBER; hash = (53 * hash) + getPageToken().hashCode(); - hash = (29 * hash) + unknownFields.hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } @@ -422,17 +369,10 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { } // Construct using com.google.bigtable.admin.v2.ListInstancesRequest.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } + private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} } @java.lang.Override @@ -529,7 +469,7 @@ public Builder mergeFrom(com.google.bigtable.admin.v2.ListInstancesRequest other pageToken_ = other.pageToken_; onChanged(); } - this.mergeUnknownFields(other.unknownFields); + this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @@ -544,18 +484,43 @@ public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - com.google.bigtable.admin.v2.ListInstancesRequest parsedMessage = null; + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + parent_ = input.readStringRequireUtf8(); + + break; + } // case 10 + case 18: + { + pageToken_ = input.readStringRequireUtf8(); + + break; + } // case 18 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = - (com.google.bigtable.admin.v2.ListInstancesRequest) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } + onChanged(); + } // finally return this; } @@ -818,7 +783,18 @@ public ListInstancesRequest parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new ListInstancesRequest(input, extensionRegistry); + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); } }; diff --git a/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/ListInstancesResponse.java b/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/ListInstancesResponse.java index a9566cd591..d02e624e85 100644 --- a/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/ListInstancesResponse.java +++ b/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/ListInstancesResponse.java @@ -54,80 +54,6 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - private ListInstancesResponse( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - int mutable_bitField0_ = 0; - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - if (!((mutable_bitField0_ & 0x00000001) != 0)) { - instances_ = new java.util.ArrayList(); - mutable_bitField0_ |= 0x00000001; - } - instances_.add( - input.readMessage( - com.google.bigtable.admin.v2.Instance.parser(), extensionRegistry)); - break; - } - case 18: - { - java.lang.String s = input.readStringRequireUtf8(); - if (!((mutable_bitField0_ & 0x00000002) != 0)) { - failedLocations_ = new com.google.protobuf.LazyStringArrayList(); - mutable_bitField0_ |= 0x00000002; - } - failedLocations_.add(s); - break; - } - case 26: - { - java.lang.String s = input.readStringRequireUtf8(); - - nextPageToken_ = s; - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); - } finally { - if (((mutable_bitField0_ & 0x00000001) != 0)) { - instances_ = java.util.Collections.unmodifiableList(instances_); - } - if (((mutable_bitField0_ & 0x00000002) != 0)) { - failedLocations_ = failedLocations_.getUnmodifiableView(); - } - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.bigtable.admin.v2.BigtableInstanceAdminProto .internal_static_google_bigtable_admin_v2_ListInstancesResponse_descriptor; @@ -365,7 +291,7 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(nextPageToken_)) { com.google.protobuf.GeneratedMessageV3.writeString(output, 3, nextPageToken_); } - unknownFields.writeTo(output); + getUnknownFields().writeTo(output); } @java.lang.Override @@ -388,7 +314,7 @@ public int getSerializedSize() { if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(nextPageToken_)) { size += com.google.protobuf.GeneratedMessageV3.computeStringSize(3, nextPageToken_); } - size += unknownFields.getSerializedSize(); + size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @@ -407,7 +333,7 @@ public boolean equals(final java.lang.Object obj) { if (!getInstancesList().equals(other.getInstancesList())) return false; if (!getFailedLocationsList().equals(other.getFailedLocationsList())) return false; if (!getNextPageToken().equals(other.getNextPageToken())) return false; - if (!unknownFields.equals(other.unknownFields)) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -428,7 +354,7 @@ public int hashCode() { } hash = (37 * hash) + NEXT_PAGE_TOKEN_FIELD_NUMBER; hash = (53 * hash) + getNextPageToken().hashCode(); - hash = (29 * hash) + unknownFields.hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } @@ -557,19 +483,10 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { } // Construct using com.google.bigtable.admin.v2.ListInstancesResponse.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } + private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) { - getInstancesFieldBuilder(); - } } @java.lang.Override @@ -577,10 +494,11 @@ public Builder clear() { super.clear(); if (instancesBuilder_ == null) { instances_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000001); } else { + instances_ = null; instancesBuilder_.clear(); } + bitField0_ = (bitField0_ & ~0x00000001); failedLocations_ = com.google.protobuf.LazyStringArrayList.EMPTY; bitField0_ = (bitField0_ & ~0x00000002); nextPageToken_ = ""; @@ -719,7 +637,7 @@ public Builder mergeFrom(com.google.bigtable.admin.v2.ListInstancesResponse othe nextPageToken_ = other.nextPageToken_; onChanged(); } - this.mergeUnknownFields(other.unknownFields); + this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @@ -734,18 +652,57 @@ public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - com.google.bigtable.admin.v2.ListInstancesResponse parsedMessage = null; + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + com.google.bigtable.admin.v2.Instance m = + input.readMessage( + com.google.bigtable.admin.v2.Instance.parser(), extensionRegistry); + if (instancesBuilder_ == null) { + ensureInstancesIsMutable(); + instances_.add(m); + } else { + instancesBuilder_.addMessage(m); + } + break; + } // case 10 + case 18: + { + java.lang.String s = input.readStringRequireUtf8(); + ensureFailedLocationsIsMutable(); + failedLocations_.add(s); + break; + } // case 18 + case 26: + { + nextPageToken_ = input.readStringRequireUtf8(); + + break; + } // case 26 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = - (com.google.bigtable.admin.v2.ListInstancesResponse) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } + onChanged(); + } // finally return this; } @@ -1450,7 +1407,18 @@ public ListInstancesResponse parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new ListInstancesResponse(input, extensionRegistry); + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); } }; diff --git a/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/ListSnapshotsRequest.java b/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/ListSnapshotsRequest.java index b46e7a6f91..3691b0075a 100644 --- a/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/ListSnapshotsRequest.java +++ b/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/ListSnapshotsRequest.java @@ -58,64 +58,6 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - private ListSnapshotsRequest( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - java.lang.String s = input.readStringRequireUtf8(); - - parent_ = s; - break; - } - case 16: - { - pageSize_ = input.readInt32(); - break; - } - case 26: - { - java.lang.String s = input.readStringRequireUtf8(); - - pageToken_ = s; - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.bigtable.admin.v2.BigtableTableAdminProto .internal_static_google_bigtable_admin_v2_ListSnapshotsRequest_descriptor; @@ -283,7 +225,7 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(pageToken_)) { com.google.protobuf.GeneratedMessageV3.writeString(output, 3, pageToken_); } - unknownFields.writeTo(output); + getUnknownFields().writeTo(output); } @java.lang.Override @@ -301,7 +243,7 @@ public int getSerializedSize() { if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(pageToken_)) { size += com.google.protobuf.GeneratedMessageV3.computeStringSize(3, pageToken_); } - size += unknownFields.getSerializedSize(); + size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @@ -320,7 +262,7 @@ public boolean equals(final java.lang.Object obj) { if (!getParent().equals(other.getParent())) return false; if (getPageSize() != other.getPageSize()) return false; if (!getPageToken().equals(other.getPageToken())) return false; - if (!unknownFields.equals(other.unknownFields)) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -337,7 +279,7 @@ public int hashCode() { hash = (53 * hash) + getPageSize(); hash = (37 * hash) + PAGE_TOKEN_FIELD_NUMBER; hash = (53 * hash) + getPageToken().hashCode(); - hash = (29 * hash) + unknownFields.hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } @@ -471,17 +413,10 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { } // Construct using com.google.bigtable.admin.v2.ListSnapshotsRequest.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } + private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} } @java.lang.Override @@ -584,7 +519,7 @@ public Builder mergeFrom(com.google.bigtable.admin.v2.ListSnapshotsRequest other pageToken_ = other.pageToken_; onChanged(); } - this.mergeUnknownFields(other.unknownFields); + this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @@ -599,18 +534,49 @@ public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - com.google.bigtable.admin.v2.ListSnapshotsRequest parsedMessage = null; + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + parent_ = input.readStringRequireUtf8(); + + break; + } // case 10 + case 16: + { + pageSize_ = input.readInt32(); + + break; + } // case 16 + case 26: + { + pageToken_ = input.readStringRequireUtf8(); + + break; + } // case 26 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = - (com.google.bigtable.admin.v2.ListSnapshotsRequest) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } + onChanged(); + } // finally return this; } @@ -943,7 +909,18 @@ public ListSnapshotsRequest parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new ListSnapshotsRequest(input, extensionRegistry); + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); } }; diff --git a/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/ListSnapshotsResponse.java b/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/ListSnapshotsResponse.java index 5646d98555..f28481e039 100644 --- a/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/ListSnapshotsResponse.java +++ b/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/ListSnapshotsResponse.java @@ -58,67 +58,6 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - private ListSnapshotsResponse( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - int mutable_bitField0_ = 0; - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - if (!((mutable_bitField0_ & 0x00000001) != 0)) { - snapshots_ = new java.util.ArrayList(); - mutable_bitField0_ |= 0x00000001; - } - snapshots_.add( - input.readMessage( - com.google.bigtable.admin.v2.Snapshot.parser(), extensionRegistry)); - break; - } - case 18: - { - java.lang.String s = input.readStringRequireUtf8(); - - nextPageToken_ = s; - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); - } finally { - if (((mutable_bitField0_ & 0x00000001) != 0)) { - snapshots_ = java.util.Collections.unmodifiableList(snapshots_); - } - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.bigtable.admin.v2.BigtableTableAdminProto .internal_static_google_bigtable_admin_v2_ListSnapshotsResponse_descriptor; @@ -276,7 +215,7 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(nextPageToken_)) { com.google.protobuf.GeneratedMessageV3.writeString(output, 2, nextPageToken_); } - unknownFields.writeTo(output); + getUnknownFields().writeTo(output); } @java.lang.Override @@ -291,7 +230,7 @@ public int getSerializedSize() { if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(nextPageToken_)) { size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, nextPageToken_); } - size += unknownFields.getSerializedSize(); + size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @@ -309,7 +248,7 @@ public boolean equals(final java.lang.Object obj) { if (!getSnapshotsList().equals(other.getSnapshotsList())) return false; if (!getNextPageToken().equals(other.getNextPageToken())) return false; - if (!unknownFields.equals(other.unknownFields)) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -326,7 +265,7 @@ public int hashCode() { } hash = (37 * hash) + NEXT_PAGE_TOKEN_FIELD_NUMBER; hash = (53 * hash) + getNextPageToken().hashCode(); - hash = (29 * hash) + unknownFields.hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } @@ -460,19 +399,10 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { } // Construct using com.google.bigtable.admin.v2.ListSnapshotsResponse.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } + private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) { - getSnapshotsFieldBuilder(); - } } @java.lang.Override @@ -480,10 +410,11 @@ public Builder clear() { super.clear(); if (snapshotsBuilder_ == null) { snapshots_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000001); } else { + snapshots_ = null; snapshotsBuilder_.clear(); } + bitField0_ = (bitField0_ & ~0x00000001); nextPageToken_ = ""; return this; @@ -605,7 +536,7 @@ public Builder mergeFrom(com.google.bigtable.admin.v2.ListSnapshotsResponse othe nextPageToken_ = other.nextPageToken_; onChanged(); } - this.mergeUnknownFields(other.unknownFields); + this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @@ -620,18 +551,50 @@ public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - com.google.bigtable.admin.v2.ListSnapshotsResponse parsedMessage = null; + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + com.google.bigtable.admin.v2.Snapshot m = + input.readMessage( + com.google.bigtable.admin.v2.Snapshot.parser(), extensionRegistry); + if (snapshotsBuilder_ == null) { + ensureSnapshotsIsMutable(); + snapshots_.add(m); + } else { + snapshotsBuilder_.addMessage(m); + } + break; + } // case 10 + case 18: + { + nextPageToken_ = input.readStringRequireUtf8(); + + break; + } // case 18 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = - (com.google.bigtable.admin.v2.ListSnapshotsResponse) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } + onChanged(); + } // finally return this; } @@ -1133,7 +1096,18 @@ public ListSnapshotsResponse parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new ListSnapshotsResponse(input, extensionRegistry); + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); } }; diff --git a/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/ListTablesRequest.java b/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/ListTablesRequest.java index 58b05c36c9..b2ff56b8e2 100644 --- a/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/ListTablesRequest.java +++ b/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/ListTablesRequest.java @@ -55,71 +55,6 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - private ListTablesRequest( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - java.lang.String s = input.readStringRequireUtf8(); - - parent_ = s; - break; - } - case 16: - { - int rawValue = input.readEnum(); - - view_ = rawValue; - break; - } - case 26: - { - java.lang.String s = input.readStringRequireUtf8(); - - pageToken_ = s; - break; - } - case 32: - { - pageSize_ = input.readInt32(); - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.bigtable.admin.v2.BigtableTableAdminProto .internal_static_google_bigtable_admin_v2_ListTablesRequest_descriptor; @@ -327,7 +262,7 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io if (pageSize_ != 0) { output.writeInt32(4, pageSize_); } - unknownFields.writeTo(output); + getUnknownFields().writeTo(output); } @java.lang.Override @@ -348,7 +283,7 @@ public int getSerializedSize() { if (pageSize_ != 0) { size += com.google.protobuf.CodedOutputStream.computeInt32Size(4, pageSize_); } - size += unknownFields.getSerializedSize(); + size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @@ -368,7 +303,7 @@ public boolean equals(final java.lang.Object obj) { if (view_ != other.view_) return false; if (getPageSize() != other.getPageSize()) return false; if (!getPageToken().equals(other.getPageToken())) return false; - if (!unknownFields.equals(other.unknownFields)) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -387,7 +322,7 @@ public int hashCode() { hash = (53 * hash) + getPageSize(); hash = (37 * hash) + PAGE_TOKEN_FIELD_NUMBER; hash = (53 * hash) + getPageToken().hashCode(); - hash = (29 * hash) + unknownFields.hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } @@ -517,17 +452,10 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { } // Construct using com.google.bigtable.admin.v2.ListTablesRequest.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } + private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} } @java.lang.Override @@ -635,7 +563,7 @@ public Builder mergeFrom(com.google.bigtable.admin.v2.ListTablesRequest other) { pageToken_ = other.pageToken_; onChanged(); } - this.mergeUnknownFields(other.unknownFields); + this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @@ -650,17 +578,55 @@ public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - com.google.bigtable.admin.v2.ListTablesRequest parsedMessage = null; + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + parent_ = input.readStringRequireUtf8(); + + break; + } // case 10 + case 16: + { + view_ = input.readEnum(); + + break; + } // case 16 + case 26: + { + pageToken_ = input.readStringRequireUtf8(); + + break; + } // case 26 + case 32: + { + pageSize_ = input.readInt32(); + + break; + } // case 32 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.bigtable.admin.v2.ListTablesRequest) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } + onChanged(); + } // finally return this; } @@ -1089,7 +1055,18 @@ public ListTablesRequest parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new ListTablesRequest(input, extensionRegistry); + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); } }; diff --git a/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/ListTablesResponse.java b/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/ListTablesResponse.java index 61d54201cf..fecfb3c893 100644 --- a/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/ListTablesResponse.java +++ b/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/ListTablesResponse.java @@ -54,67 +54,6 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - private ListTablesResponse( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - int mutable_bitField0_ = 0; - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - if (!((mutable_bitField0_ & 0x00000001) != 0)) { - tables_ = new java.util.ArrayList(); - mutable_bitField0_ |= 0x00000001; - } - tables_.add( - input.readMessage( - com.google.bigtable.admin.v2.Table.parser(), extensionRegistry)); - break; - } - case 18: - { - java.lang.String s = input.readStringRequireUtf8(); - - nextPageToken_ = s; - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); - } finally { - if (((mutable_bitField0_ & 0x00000001) != 0)) { - tables_ = java.util.Collections.unmodifiableList(tables_); - } - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.bigtable.admin.v2.BigtableTableAdminProto .internal_static_google_bigtable_admin_v2_ListTablesResponse_descriptor; @@ -272,7 +211,7 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(nextPageToken_)) { com.google.protobuf.GeneratedMessageV3.writeString(output, 2, nextPageToken_); } - unknownFields.writeTo(output); + getUnknownFields().writeTo(output); } @java.lang.Override @@ -287,7 +226,7 @@ public int getSerializedSize() { if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(nextPageToken_)) { size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, nextPageToken_); } - size += unknownFields.getSerializedSize(); + size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @@ -305,7 +244,7 @@ public boolean equals(final java.lang.Object obj) { if (!getTablesList().equals(other.getTablesList())) return false; if (!getNextPageToken().equals(other.getNextPageToken())) return false; - if (!unknownFields.equals(other.unknownFields)) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -322,7 +261,7 @@ public int hashCode() { } hash = (37 * hash) + NEXT_PAGE_TOKEN_FIELD_NUMBER; hash = (53 * hash) + getNextPageToken().hashCode(); - hash = (29 * hash) + unknownFields.hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } @@ -452,19 +391,10 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { } // Construct using com.google.bigtable.admin.v2.ListTablesResponse.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } + private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) { - getTablesFieldBuilder(); - } } @java.lang.Override @@ -472,10 +402,11 @@ public Builder clear() { super.clear(); if (tablesBuilder_ == null) { tables_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000001); } else { + tables_ = null; tablesBuilder_.clear(); } + bitField0_ = (bitField0_ & ~0x00000001); nextPageToken_ = ""; return this; @@ -597,7 +528,7 @@ public Builder mergeFrom(com.google.bigtable.admin.v2.ListTablesResponse other) nextPageToken_ = other.nextPageToken_; onChanged(); } - this.mergeUnknownFields(other.unknownFields); + this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @@ -612,17 +543,50 @@ public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - com.google.bigtable.admin.v2.ListTablesResponse parsedMessage = null; + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + com.google.bigtable.admin.v2.Table m = + input.readMessage( + com.google.bigtable.admin.v2.Table.parser(), extensionRegistry); + if (tablesBuilder_ == null) { + ensureTablesIsMutable(); + tables_.add(m); + } else { + tablesBuilder_.addMessage(m); + } + break; + } // case 10 + case 18: + { + nextPageToken_ = input.readStringRequireUtf8(); + + break; + } // case 18 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.bigtable.admin.v2.ListTablesResponse) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } + onChanged(); + } // finally return this; } @@ -1124,7 +1088,18 @@ public ListTablesResponse parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new ListTablesResponse(input, extensionRegistry); + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); } }; diff --git a/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/ModifyColumnFamiliesRequest.java b/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/ModifyColumnFamiliesRequest.java index 542fc1e0be..17266065d3 100644 --- a/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/ModifyColumnFamiliesRequest.java +++ b/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/ModifyColumnFamiliesRequest.java @@ -54,71 +54,6 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - private ModifyColumnFamiliesRequest( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - int mutable_bitField0_ = 0; - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - java.lang.String s = input.readStringRequireUtf8(); - - name_ = s; - break; - } - case 18: - { - if (!((mutable_bitField0_ & 0x00000001) != 0)) { - modifications_ = - new java.util.ArrayList< - com.google.bigtable.admin.v2.ModifyColumnFamiliesRequest.Modification>(); - mutable_bitField0_ |= 0x00000001; - } - modifications_.add( - input.readMessage( - com.google.bigtable.admin.v2.ModifyColumnFamiliesRequest.Modification - .parser(), - extensionRegistry)); - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); - } finally { - if (((mutable_bitField0_ & 0x00000001) != 0)) { - modifications_ = java.util.Collections.unmodifiableList(modifications_); - } - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.bigtable.admin.v2.BigtableTableAdminProto .internal_static_google_bigtable_admin_v2_ModifyColumnFamiliesRequest_descriptor; @@ -304,90 +239,6 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - private Modification( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - java.lang.String s = input.readStringRequireUtf8(); - - id_ = s; - break; - } - case 18: - { - com.google.bigtable.admin.v2.ColumnFamily.Builder subBuilder = null; - if (modCase_ == 2) { - subBuilder = ((com.google.bigtable.admin.v2.ColumnFamily) mod_).toBuilder(); - } - mod_ = - input.readMessage( - com.google.bigtable.admin.v2.ColumnFamily.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom((com.google.bigtable.admin.v2.ColumnFamily) mod_); - mod_ = subBuilder.buildPartial(); - } - modCase_ = 2; - break; - } - case 26: - { - com.google.bigtable.admin.v2.ColumnFamily.Builder subBuilder = null; - if (modCase_ == 3) { - subBuilder = ((com.google.bigtable.admin.v2.ColumnFamily) mod_).toBuilder(); - } - mod_ = - input.readMessage( - com.google.bigtable.admin.v2.ColumnFamily.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom((com.google.bigtable.admin.v2.ColumnFamily) mod_); - mod_ = subBuilder.buildPartial(); - } - modCase_ = 3; - break; - } - case 32: - { - mod_ = input.readBool(); - modCase_ = 4; - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.bigtable.admin.v2.BigtableTableAdminProto .internal_static_google_bigtable_admin_v2_ModifyColumnFamiliesRequest_Modification_descriptor; @@ -673,7 +524,7 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io if (modCase_ == 4) { output.writeBool(4, (boolean) ((java.lang.Boolean) mod_)); } - unknownFields.writeTo(output); + getUnknownFields().writeTo(output); } @java.lang.Override @@ -700,7 +551,7 @@ public int getSerializedSize() { com.google.protobuf.CodedOutputStream.computeBoolSize( 4, (boolean) ((java.lang.Boolean) mod_)); } - size += unknownFields.getSerializedSize(); + size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @@ -731,7 +582,7 @@ public boolean equals(final java.lang.Object obj) { case 0: default: } - if (!unknownFields.equals(other.unknownFields)) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -760,7 +611,7 @@ public int hashCode() { case 0: default: } - hash = (29 * hash) + unknownFields.hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } @@ -895,17 +746,10 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { // Construct using // com.google.bigtable.admin.v2.ModifyColumnFamiliesRequest.Modification.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } + private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} } @java.lang.Override @@ -913,6 +757,12 @@ public Builder clear() { super.clear(); id_ = ""; + if (createBuilder_ != null) { + createBuilder_.clear(); + } + if (updateBuilder_ != null) { + updateBuilder_.clear(); + } modCase_ = 0; mod_ = null; return this; @@ -1045,7 +895,7 @@ public Builder mergeFrom( break; } } - this.mergeUnknownFields(other.unknownFields); + this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @@ -1060,19 +910,55 @@ public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - com.google.bigtable.admin.v2.ModifyColumnFamiliesRequest.Modification parsedMessage = null; + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + id_ = input.readStringRequireUtf8(); + + break; + } // case 10 + case 18: + { + input.readMessage(getCreateFieldBuilder().getBuilder(), extensionRegistry); + modCase_ = 2; + break; + } // case 18 + case 26: + { + input.readMessage(getUpdateFieldBuilder().getBuilder(), extensionRegistry); + modCase_ = 3; + break; + } // case 26 + case 32: + { + mod_ = input.readBool(); + modCase_ = 4; + break; + } // case 32 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = - (com.google.bigtable.admin.v2.ModifyColumnFamiliesRequest.Modification) - e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } + onChanged(); + } // finally return this; } @@ -1741,7 +1627,19 @@ public Modification parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new Modification(input, extensionRegistry); + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException() + .setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); } }; @@ -1937,7 +1835,7 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io for (int i = 0; i < modifications_.size(); i++) { output.writeMessage(2, modifications_.get(i)); } - unknownFields.writeTo(output); + getUnknownFields().writeTo(output); } @java.lang.Override @@ -1952,7 +1850,7 @@ public int getSerializedSize() { for (int i = 0; i < modifications_.size(); i++) { size += com.google.protobuf.CodedOutputStream.computeMessageSize(2, modifications_.get(i)); } - size += unknownFields.getSerializedSize(); + size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @@ -1970,7 +1868,7 @@ public boolean equals(final java.lang.Object obj) { if (!getName().equals(other.getName())) return false; if (!getModificationsList().equals(other.getModificationsList())) return false; - if (!unknownFields.equals(other.unknownFields)) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -1987,7 +1885,7 @@ public int hashCode() { hash = (37 * hash) + MODIFICATIONS_FIELD_NUMBER; hash = (53 * hash) + getModificationsList().hashCode(); } - hash = (29 * hash) + unknownFields.hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } @@ -2118,19 +2016,10 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { } // Construct using com.google.bigtable.admin.v2.ModifyColumnFamiliesRequest.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } + private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) { - getModificationsFieldBuilder(); - } } @java.lang.Override @@ -2140,10 +2029,11 @@ public Builder clear() { if (modificationsBuilder_ == null) { modifications_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000001); } else { + modifications_ = null; modificationsBuilder_.clear(); } + bitField0_ = (bitField0_ & ~0x00000001); return this; } @@ -2263,7 +2153,7 @@ public Builder mergeFrom(com.google.bigtable.admin.v2.ModifyColumnFamiliesReques } } } - this.mergeUnknownFields(other.unknownFields); + this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @@ -2278,18 +2168,52 @@ public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - com.google.bigtable.admin.v2.ModifyColumnFamiliesRequest parsedMessage = null; + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + name_ = input.readStringRequireUtf8(); + + break; + } // case 10 + case 18: + { + com.google.bigtable.admin.v2.ModifyColumnFamiliesRequest.Modification m = + input.readMessage( + com.google.bigtable.admin.v2.ModifyColumnFamiliesRequest.Modification + .parser(), + extensionRegistry); + if (modificationsBuilder_ == null) { + ensureModificationsIsMutable(); + modifications_.add(m); + } else { + modificationsBuilder_.addMessage(m); + } + break; + } // case 18 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = - (com.google.bigtable.admin.v2.ModifyColumnFamiliesRequest) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } + onChanged(); + } // finally return this; } @@ -2923,7 +2847,18 @@ public ModifyColumnFamiliesRequest parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new ModifyColumnFamiliesRequest(input, extensionRegistry); + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); } }; diff --git a/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/OperationProgress.java b/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/OperationProgress.java index 725f0fa8c7..c8dbdfc47e 100644 --- a/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/OperationProgress.java +++ b/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/OperationProgress.java @@ -51,80 +51,6 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - private OperationProgress( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 8: - { - progressPercent_ = input.readInt32(); - break; - } - case 18: - { - com.google.protobuf.Timestamp.Builder subBuilder = null; - if (startTime_ != null) { - subBuilder = startTime_.toBuilder(); - } - startTime_ = - input.readMessage(com.google.protobuf.Timestamp.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(startTime_); - startTime_ = subBuilder.buildPartial(); - } - - break; - } - case 26: - { - com.google.protobuf.Timestamp.Builder subBuilder = null; - if (endTime_ != null) { - subBuilder = endTime_.toBuilder(); - } - endTime_ = - input.readMessage(com.google.protobuf.Timestamp.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(endTime_); - endTime_ = subBuilder.buildPartial(); - } - - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.bigtable.admin.v2.CommonProto .internal_static_google_bigtable_admin_v2_OperationProgress_descriptor; @@ -277,7 +203,7 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io if (endTime_ != null) { output.writeMessage(3, getEndTime()); } - unknownFields.writeTo(output); + getUnknownFields().writeTo(output); } @java.lang.Override @@ -295,7 +221,7 @@ public int getSerializedSize() { if (endTime_ != null) { size += com.google.protobuf.CodedOutputStream.computeMessageSize(3, getEndTime()); } - size += unknownFields.getSerializedSize(); + size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @@ -320,7 +246,7 @@ public boolean equals(final java.lang.Object obj) { if (hasEndTime()) { if (!getEndTime().equals(other.getEndTime())) return false; } - if (!unknownFields.equals(other.unknownFields)) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -341,7 +267,7 @@ public int hashCode() { hash = (37 * hash) + END_TIME_FIELD_NUMBER; hash = (53 * hash) + getEndTime().hashCode(); } - hash = (29 * hash) + unknownFields.hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } @@ -471,17 +397,10 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { } // Construct using com.google.bigtable.admin.v2.OperationProgress.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } + private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} } @java.lang.Override @@ -597,7 +516,7 @@ public Builder mergeFrom(com.google.bigtable.admin.v2.OperationProgress other) { if (other.hasEndTime()) { mergeEndTime(other.getEndTime()); } - this.mergeUnknownFields(other.unknownFields); + this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @@ -612,17 +531,49 @@ public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - com.google.bigtable.admin.v2.OperationProgress parsedMessage = null; + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 8: + { + progressPercent_ = input.readInt32(); + + break; + } // case 8 + case 18: + { + input.readMessage(getStartTimeFieldBuilder().getBuilder(), extensionRegistry); + + break; + } // case 18 + case 26: + { + input.readMessage(getEndTimeFieldBuilder().getBuilder(), extensionRegistry); + + break; + } // case 26 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.bigtable.admin.v2.OperationProgress) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } + onChanged(); + } // finally return this; } @@ -1080,7 +1031,18 @@ public OperationProgress parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new OperationProgress(input, extensionRegistry); + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); } }; diff --git a/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/OptimizeRestoredTableMetadata.java b/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/OptimizeRestoredTableMetadata.java index 87045259de..7b2c946018 100644 --- a/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/OptimizeRestoredTableMetadata.java +++ b/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/OptimizeRestoredTableMetadata.java @@ -55,68 +55,6 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - private OptimizeRestoredTableMetadata( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - java.lang.String s = input.readStringRequireUtf8(); - - name_ = s; - break; - } - case 18: - { - com.google.bigtable.admin.v2.OperationProgress.Builder subBuilder = null; - if (progress_ != null) { - subBuilder = progress_.toBuilder(); - } - progress_ = - input.readMessage( - com.google.bigtable.admin.v2.OperationProgress.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(progress_); - progress_ = subBuilder.buildPartial(); - } - - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.bigtable.admin.v2.BigtableTableAdminProto .internal_static_google_bigtable_admin_v2_OptimizeRestoredTableMetadata_descriptor; @@ -249,7 +187,7 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io if (progress_ != null) { output.writeMessage(2, getProgress()); } - unknownFields.writeTo(output); + getUnknownFields().writeTo(output); } @java.lang.Override @@ -264,7 +202,7 @@ public int getSerializedSize() { if (progress_ != null) { size += com.google.protobuf.CodedOutputStream.computeMessageSize(2, getProgress()); } - size += unknownFields.getSerializedSize(); + size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @@ -285,7 +223,7 @@ public boolean equals(final java.lang.Object obj) { if (hasProgress()) { if (!getProgress().equals(other.getProgress())) return false; } - if (!unknownFields.equals(other.unknownFields)) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -302,7 +240,7 @@ public int hashCode() { hash = (37 * hash) + PROGRESS_FIELD_NUMBER; hash = (53 * hash) + getProgress().hashCode(); } - hash = (29 * hash) + unknownFields.hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } @@ -435,17 +373,10 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { } // Construct using com.google.bigtable.admin.v2.OptimizeRestoredTableMetadata.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } + private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} } @java.lang.Override @@ -549,7 +480,7 @@ public Builder mergeFrom(com.google.bigtable.admin.v2.OptimizeRestoredTableMetad if (other.hasProgress()) { mergeProgress(other.getProgress()); } - this.mergeUnknownFields(other.unknownFields); + this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @@ -564,18 +495,43 @@ public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - com.google.bigtable.admin.v2.OptimizeRestoredTableMetadata parsedMessage = null; + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + name_ = input.readStringRequireUtf8(); + + break; + } // case 10 + case 18: + { + input.readMessage(getProgressFieldBuilder().getBuilder(), extensionRegistry); + + break; + } // case 18 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = - (com.google.bigtable.admin.v2.OptimizeRestoredTableMetadata) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } + onChanged(); + } // finally return this; } @@ -903,7 +859,18 @@ public OptimizeRestoredTableMetadata parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new OptimizeRestoredTableMetadata(input, extensionRegistry); + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); } }; diff --git a/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/PartialUpdateClusterMetadata.java b/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/PartialUpdateClusterMetadata.java index fcf723774b..6ea994b7ca 100644 --- a/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/PartialUpdateClusterMetadata.java +++ b/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/PartialUpdateClusterMetadata.java @@ -50,92 +50,6 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - private PartialUpdateClusterMetadata( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - com.google.protobuf.Timestamp.Builder subBuilder = null; - if (requestTime_ != null) { - subBuilder = requestTime_.toBuilder(); - } - requestTime_ = - input.readMessage(com.google.protobuf.Timestamp.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(requestTime_); - requestTime_ = subBuilder.buildPartial(); - } - - break; - } - case 18: - { - com.google.protobuf.Timestamp.Builder subBuilder = null; - if (finishTime_ != null) { - subBuilder = finishTime_.toBuilder(); - } - finishTime_ = - input.readMessage(com.google.protobuf.Timestamp.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(finishTime_); - finishTime_ = subBuilder.buildPartial(); - } - - break; - } - case 26: - { - com.google.bigtable.admin.v2.PartialUpdateClusterRequest.Builder subBuilder = null; - if (originalRequest_ != null) { - subBuilder = originalRequest_.toBuilder(); - } - originalRequest_ = - input.readMessage( - com.google.bigtable.admin.v2.PartialUpdateClusterRequest.parser(), - extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(originalRequest_); - originalRequest_ = subBuilder.buildPartial(); - } - - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.bigtable.admin.v2.BigtableInstanceAdminProto .internal_static_google_bigtable_admin_v2_PartialUpdateClusterMetadata_descriptor; @@ -315,7 +229,7 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io if (originalRequest_ != null) { output.writeMessage(3, getOriginalRequest()); } - unknownFields.writeTo(output); + getUnknownFields().writeTo(output); } @java.lang.Override @@ -333,7 +247,7 @@ public int getSerializedSize() { if (originalRequest_ != null) { size += com.google.protobuf.CodedOutputStream.computeMessageSize(3, getOriginalRequest()); } - size += unknownFields.getSerializedSize(); + size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @@ -361,7 +275,7 @@ public boolean equals(final java.lang.Object obj) { if (hasOriginalRequest()) { if (!getOriginalRequest().equals(other.getOriginalRequest())) return false; } - if (!unknownFields.equals(other.unknownFields)) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -384,7 +298,7 @@ public int hashCode() { hash = (37 * hash) + ORIGINAL_REQUEST_FIELD_NUMBER; hash = (53 * hash) + getOriginalRequest().hashCode(); } - hash = (29 * hash) + unknownFields.hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } @@ -514,17 +428,10 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { } // Construct using com.google.bigtable.admin.v2.PartialUpdateClusterMetadata.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } + private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} } @java.lang.Override @@ -649,7 +556,7 @@ public Builder mergeFrom(com.google.bigtable.admin.v2.PartialUpdateClusterMetada if (other.hasOriginalRequest()) { mergeOriginalRequest(other.getOriginalRequest()); } - this.mergeUnknownFields(other.unknownFields); + this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @@ -664,18 +571,49 @@ public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - com.google.bigtable.admin.v2.PartialUpdateClusterMetadata parsedMessage = null; + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + input.readMessage(getRequestTimeFieldBuilder().getBuilder(), extensionRegistry); + + break; + } // case 10 + case 18: + { + input.readMessage(getFinishTimeFieldBuilder().getBuilder(), extensionRegistry); + + break; + } // case 18 + case 26: + { + input.readMessage(getOriginalRequestFieldBuilder().getBuilder(), extensionRegistry); + + break; + } // case 26 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = - (com.google.bigtable.admin.v2.PartialUpdateClusterMetadata) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } + onChanged(); + } // finally return this; } @@ -1269,7 +1207,18 @@ public PartialUpdateClusterMetadata parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new PartialUpdateClusterMetadata(input, extensionRegistry); + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); } }; diff --git a/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/PartialUpdateClusterRequest.java b/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/PartialUpdateClusterRequest.java index 1e8447f7e3..51fab538cd 100644 --- a/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/PartialUpdateClusterRequest.java +++ b/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/PartialUpdateClusterRequest.java @@ -50,76 +50,6 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - private PartialUpdateClusterRequest( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - com.google.bigtable.admin.v2.Cluster.Builder subBuilder = null; - if (cluster_ != null) { - subBuilder = cluster_.toBuilder(); - } - cluster_ = - input.readMessage( - com.google.bigtable.admin.v2.Cluster.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(cluster_); - cluster_ = subBuilder.buildPartial(); - } - - break; - } - case 18: - { - com.google.protobuf.FieldMask.Builder subBuilder = null; - if (updateMask_ != null) { - subBuilder = updateMask_.toBuilder(); - } - updateMask_ = - input.readMessage(com.google.protobuf.FieldMask.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(updateMask_); - updateMask_ = subBuilder.buildPartial(); - } - - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.bigtable.admin.v2.BigtableInstanceAdminProto .internal_static_google_bigtable_admin_v2_PartialUpdateClusterRequest_descriptor; @@ -256,7 +186,7 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io if (updateMask_ != null) { output.writeMessage(2, getUpdateMask()); } - unknownFields.writeTo(output); + getUnknownFields().writeTo(output); } @java.lang.Override @@ -271,7 +201,7 @@ public int getSerializedSize() { if (updateMask_ != null) { size += com.google.protobuf.CodedOutputStream.computeMessageSize(2, getUpdateMask()); } - size += unknownFields.getSerializedSize(); + size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @@ -295,7 +225,7 @@ public boolean equals(final java.lang.Object obj) { if (hasUpdateMask()) { if (!getUpdateMask().equals(other.getUpdateMask())) return false; } - if (!unknownFields.equals(other.unknownFields)) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -314,7 +244,7 @@ public int hashCode() { hash = (37 * hash) + UPDATE_MASK_FIELD_NUMBER; hash = (53 * hash) + getUpdateMask().hashCode(); } - hash = (29 * hash) + unknownFields.hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } @@ -444,17 +374,10 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { } // Construct using com.google.bigtable.admin.v2.PartialUpdateClusterRequest.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } + private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} } @java.lang.Override @@ -565,7 +488,7 @@ public Builder mergeFrom(com.google.bigtable.admin.v2.PartialUpdateClusterReques if (other.hasUpdateMask()) { mergeUpdateMask(other.getUpdateMask()); } - this.mergeUnknownFields(other.unknownFields); + this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @@ -580,18 +503,43 @@ public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - com.google.bigtable.admin.v2.PartialUpdateClusterRequest parsedMessage = null; + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + input.readMessage(getClusterFieldBuilder().getBuilder(), extensionRegistry); + + break; + } // case 10 + case 18: + { + input.readMessage(getUpdateMaskFieldBuilder().getBuilder(), extensionRegistry); + + break; + } // case 18 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = - (com.google.bigtable.admin.v2.PartialUpdateClusterRequest) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } + onChanged(); + } // finally return this; } @@ -1031,7 +979,18 @@ public PartialUpdateClusterRequest parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new PartialUpdateClusterRequest(input, extensionRegistry); + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); } }; diff --git a/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/PartialUpdateInstanceRequest.java b/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/PartialUpdateInstanceRequest.java index 5e0b6d0993..c3dc82149c 100644 --- a/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/PartialUpdateInstanceRequest.java +++ b/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/PartialUpdateInstanceRequest.java @@ -50,76 +50,6 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - private PartialUpdateInstanceRequest( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - com.google.bigtable.admin.v2.Instance.Builder subBuilder = null; - if (instance_ != null) { - subBuilder = instance_.toBuilder(); - } - instance_ = - input.readMessage( - com.google.bigtable.admin.v2.Instance.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(instance_); - instance_ = subBuilder.buildPartial(); - } - - break; - } - case 18: - { - com.google.protobuf.FieldMask.Builder subBuilder = null; - if (updateMask_ != null) { - subBuilder = updateMask_.toBuilder(); - } - updateMask_ = - input.readMessage(com.google.protobuf.FieldMask.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(updateMask_); - updateMask_ = subBuilder.buildPartial(); - } - - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.bigtable.admin.v2.BigtableInstanceAdminProto .internal_static_google_bigtable_admin_v2_PartialUpdateInstanceRequest_descriptor; @@ -261,7 +191,7 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io if (updateMask_ != null) { output.writeMessage(2, getUpdateMask()); } - unknownFields.writeTo(output); + getUnknownFields().writeTo(output); } @java.lang.Override @@ -276,7 +206,7 @@ public int getSerializedSize() { if (updateMask_ != null) { size += com.google.protobuf.CodedOutputStream.computeMessageSize(2, getUpdateMask()); } - size += unknownFields.getSerializedSize(); + size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @@ -300,7 +230,7 @@ public boolean equals(final java.lang.Object obj) { if (hasUpdateMask()) { if (!getUpdateMask().equals(other.getUpdateMask())) return false; } - if (!unknownFields.equals(other.unknownFields)) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -319,7 +249,7 @@ public int hashCode() { hash = (37 * hash) + UPDATE_MASK_FIELD_NUMBER; hash = (53 * hash) + getUpdateMask().hashCode(); } - hash = (29 * hash) + unknownFields.hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } @@ -449,17 +379,10 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { } // Construct using com.google.bigtable.admin.v2.PartialUpdateInstanceRequest.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } + private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} } @java.lang.Override @@ -570,7 +493,7 @@ public Builder mergeFrom(com.google.bigtable.admin.v2.PartialUpdateInstanceReque if (other.hasUpdateMask()) { mergeUpdateMask(other.getUpdateMask()); } - this.mergeUnknownFields(other.unknownFields); + this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @@ -585,18 +508,43 @@ public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - com.google.bigtable.admin.v2.PartialUpdateInstanceRequest parsedMessage = null; + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + input.readMessage(getInstanceFieldBuilder().getBuilder(), extensionRegistry); + + break; + } // case 10 + case 18: + { + input.readMessage(getUpdateMaskFieldBuilder().getBuilder(), extensionRegistry); + + break; + } // case 18 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = - (com.google.bigtable.admin.v2.PartialUpdateInstanceRequest) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } + onChanged(); + } // finally return this; } @@ -1036,7 +984,18 @@ public PartialUpdateInstanceRequest parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new PartialUpdateInstanceRequest(input, extensionRegistry); + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); } }; diff --git a/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/RestoreInfo.java b/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/RestoreInfo.java index d0298c2329..7f12b4a44c 100644 --- a/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/RestoreInfo.java +++ b/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/RestoreInfo.java @@ -52,68 +52,6 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - private RestoreInfo( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 8: - { - int rawValue = input.readEnum(); - - sourceType_ = rawValue; - break; - } - case 18: - { - com.google.bigtable.admin.v2.BackupInfo.Builder subBuilder = null; - if (sourceInfoCase_ == 2) { - subBuilder = ((com.google.bigtable.admin.v2.BackupInfo) sourceInfo_).toBuilder(); - } - sourceInfo_ = - input.readMessage( - com.google.bigtable.admin.v2.BackupInfo.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom((com.google.bigtable.admin.v2.BackupInfo) sourceInfo_); - sourceInfo_ = subBuilder.buildPartial(); - } - sourceInfoCase_ = 2; - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.bigtable.admin.v2.TableProto .internal_static_google_bigtable_admin_v2_RestoreInfo_descriptor; @@ -285,7 +223,7 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io if (sourceInfoCase_ == 2) { output.writeMessage(2, (com.google.bigtable.admin.v2.BackupInfo) sourceInfo_); } - unknownFields.writeTo(output); + getUnknownFields().writeTo(output); } @java.lang.Override @@ -304,7 +242,7 @@ public int getSerializedSize() { com.google.protobuf.CodedOutputStream.computeMessageSize( 2, (com.google.bigtable.admin.v2.BackupInfo) sourceInfo_); } - size += unknownFields.getSerializedSize(); + size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @@ -328,7 +266,7 @@ public boolean equals(final java.lang.Object obj) { case 0: default: } - if (!unknownFields.equals(other.unknownFields)) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -349,7 +287,7 @@ public int hashCode() { case 0: default: } - hash = (29 * hash) + unknownFields.hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } @@ -478,17 +416,10 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { } // Construct using com.google.bigtable.admin.v2.RestoreInfo.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } + private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} } @java.lang.Override @@ -496,6 +427,9 @@ public Builder clear() { super.clear(); sourceType_ = 0; + if (backupInfoBuilder_ != null) { + backupInfoBuilder_.clear(); + } sourceInfoCase_ = 0; sourceInfo_ = null; return this; @@ -597,7 +531,7 @@ public Builder mergeFrom(com.google.bigtable.admin.v2.RestoreInfo other) { break; } } - this.mergeUnknownFields(other.unknownFields); + this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @@ -612,17 +546,43 @@ public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - com.google.bigtable.admin.v2.RestoreInfo parsedMessage = null; + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 8: + { + sourceType_ = input.readEnum(); + + break; + } // case 8 + case 18: + { + input.readMessage(getBackupInfoFieldBuilder().getBuilder(), extensionRegistry); + sourceInfoCase_ = 2; + break; + } // case 18 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.bigtable.admin.v2.RestoreInfo) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } + onChanged(); + } // finally return this; } @@ -981,7 +941,18 @@ public RestoreInfo parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new RestoreInfo(input, extensionRegistry); + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); } }; diff --git a/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/RestoreTableMetadata.java b/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/RestoreTableMetadata.java index 82ddb802ff..a5bda7dd29 100644 --- a/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/RestoreTableMetadata.java +++ b/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/RestoreTableMetadata.java @@ -55,98 +55,6 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - private RestoreTableMetadata( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - java.lang.String s = input.readStringRequireUtf8(); - - name_ = s; - break; - } - case 16: - { - int rawValue = input.readEnum(); - - sourceType_ = rawValue; - break; - } - case 26: - { - com.google.bigtable.admin.v2.BackupInfo.Builder subBuilder = null; - if (sourceInfoCase_ == 3) { - subBuilder = ((com.google.bigtable.admin.v2.BackupInfo) sourceInfo_).toBuilder(); - } - sourceInfo_ = - input.readMessage( - com.google.bigtable.admin.v2.BackupInfo.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom((com.google.bigtable.admin.v2.BackupInfo) sourceInfo_); - sourceInfo_ = subBuilder.buildPartial(); - } - sourceInfoCase_ = 3; - break; - } - case 34: - { - java.lang.String s = input.readStringRequireUtf8(); - - optimizeTableOperationName_ = s; - break; - } - case 42: - { - com.google.bigtable.admin.v2.OperationProgress.Builder subBuilder = null; - if (progress_ != null) { - subBuilder = progress_.toBuilder(); - } - progress_ = - input.readMessage( - com.google.bigtable.admin.v2.OperationProgress.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(progress_); - progress_ = subBuilder.buildPartial(); - } - - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.bigtable.admin.v2.BigtableTableAdminProto .internal_static_google_bigtable_admin_v2_RestoreTableMetadata_descriptor; @@ -469,7 +377,7 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io if (progress_ != null) { output.writeMessage(5, getProgress()); } - unknownFields.writeTo(output); + getUnknownFields().writeTo(output); } @java.lang.Override @@ -498,7 +406,7 @@ public int getSerializedSize() { if (progress_ != null) { size += com.google.protobuf.CodedOutputStream.computeMessageSize(5, getProgress()); } - size += unknownFields.getSerializedSize(); + size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @@ -530,7 +438,7 @@ public boolean equals(final java.lang.Object obj) { case 0: default: } - if (!unknownFields.equals(other.unknownFields)) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -559,7 +467,7 @@ public int hashCode() { case 0: default: } - hash = (29 * hash) + unknownFields.hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } @@ -689,17 +597,10 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { } // Construct using com.google.bigtable.admin.v2.RestoreTableMetadata.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } + private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} } @java.lang.Override @@ -709,6 +610,9 @@ public Builder clear() { sourceType_ = 0; + if (backupInfoBuilder_ != null) { + backupInfoBuilder_.clear(); + } optimizeTableOperationName_ = ""; if (progressBuilder_ == null) { @@ -837,7 +741,7 @@ public Builder mergeFrom(com.google.bigtable.admin.v2.RestoreTableMetadata other break; } } - this.mergeUnknownFields(other.unknownFields); + this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @@ -852,18 +756,61 @@ public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - com.google.bigtable.admin.v2.RestoreTableMetadata parsedMessage = null; + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + name_ = input.readStringRequireUtf8(); + + break; + } // case 10 + case 16: + { + sourceType_ = input.readEnum(); + + break; + } // case 16 + case 26: + { + input.readMessage(getBackupInfoFieldBuilder().getBuilder(), extensionRegistry); + sourceInfoCase_ = 3; + break; + } // case 26 + case 34: + { + optimizeTableOperationName_ = input.readStringRequireUtf8(); + + break; + } // case 34 + case 42: + { + input.readMessage(getProgressFieldBuilder().getBuilder(), extensionRegistry); + + break; + } // case 42 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = - (com.google.bigtable.admin.v2.RestoreTableMetadata) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } + onChanged(); + } // finally return this; } @@ -1592,7 +1539,18 @@ public RestoreTableMetadata parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new RestoreTableMetadata(input, extensionRegistry); + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); } }; diff --git a/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/RestoreTableRequest.java b/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/RestoreTableRequest.java index 025f82cd2f..1ca6255dcb 100644 --- a/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/RestoreTableRequest.java +++ b/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/RestoreTableRequest.java @@ -54,66 +54,6 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - private RestoreTableRequest( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - java.lang.String s = input.readStringRequireUtf8(); - - parent_ = s; - break; - } - case 18: - { - java.lang.String s = input.readStringRequireUtf8(); - - tableId_ = s; - break; - } - case 26: - { - java.lang.String s = input.readStringRequireUtf8(); - sourceCase_ = 3; - source_ = s; - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.bigtable.admin.v2.BigtableTableAdminProto .internal_static_google_bigtable_admin_v2_RestoreTableRequest_descriptor; @@ -381,7 +321,7 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io if (sourceCase_ == 3) { com.google.protobuf.GeneratedMessageV3.writeString(output, 3, source_); } - unknownFields.writeTo(output); + getUnknownFields().writeTo(output); } @java.lang.Override @@ -399,7 +339,7 @@ public int getSerializedSize() { if (sourceCase_ == 3) { size += com.google.protobuf.GeneratedMessageV3.computeStringSize(3, source_); } - size += unknownFields.getSerializedSize(); + size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @@ -425,7 +365,7 @@ public boolean equals(final java.lang.Object obj) { case 0: default: } - if (!unknownFields.equals(other.unknownFields)) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -448,7 +388,7 @@ public int hashCode() { case 0: default: } - hash = (29 * hash) + unknownFields.hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } @@ -578,17 +518,10 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { } // Construct using com.google.bigtable.admin.v2.RestoreTableRequest.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } + private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} } @java.lang.Override @@ -704,7 +637,7 @@ public Builder mergeFrom(com.google.bigtable.admin.v2.RestoreTableRequest other) break; } } - this.mergeUnknownFields(other.unknownFields); + this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @@ -719,17 +652,50 @@ public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - com.google.bigtable.admin.v2.RestoreTableRequest parsedMessage = null; + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + parent_ = input.readStringRequireUtf8(); + + break; + } // case 10 + case 18: + { + tableId_ = input.readStringRequireUtf8(); + + break; + } // case 18 + case 26: + { + java.lang.String s = input.readStringRequireUtf8(); + sourceCase_ = 3; + source_ = s; + break; + } // case 26 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.bigtable.admin.v2.RestoreTableRequest) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } + onChanged(); + } // finally return this; } @@ -1166,7 +1132,18 @@ public RestoreTableRequest parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new RestoreTableRequest(input, extensionRegistry); + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); } }; diff --git a/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/Snapshot.java b/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/Snapshot.java index ca6b5b7db4..15afea9cec 100644 --- a/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/Snapshot.java +++ b/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/Snapshot.java @@ -59,116 +59,6 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - private Snapshot( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - java.lang.String s = input.readStringRequireUtf8(); - - name_ = s; - break; - } - case 18: - { - com.google.bigtable.admin.v2.Table.Builder subBuilder = null; - if (sourceTable_ != null) { - subBuilder = sourceTable_.toBuilder(); - } - sourceTable_ = - input.readMessage(com.google.bigtable.admin.v2.Table.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(sourceTable_); - sourceTable_ = subBuilder.buildPartial(); - } - - break; - } - case 24: - { - dataSizeBytes_ = input.readInt64(); - break; - } - case 34: - { - com.google.protobuf.Timestamp.Builder subBuilder = null; - if (createTime_ != null) { - subBuilder = createTime_.toBuilder(); - } - createTime_ = - input.readMessage(com.google.protobuf.Timestamp.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(createTime_); - createTime_ = subBuilder.buildPartial(); - } - - break; - } - case 42: - { - com.google.protobuf.Timestamp.Builder subBuilder = null; - if (deleteTime_ != null) { - subBuilder = deleteTime_.toBuilder(); - } - deleteTime_ = - input.readMessage(com.google.protobuf.Timestamp.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(deleteTime_); - deleteTime_ = subBuilder.buildPartial(); - } - - break; - } - case 48: - { - int rawValue = input.readEnum(); - - state_ = rawValue; - break; - } - case 58: - { - java.lang.String s = input.readStringRequireUtf8(); - - description_ = s; - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.bigtable.admin.v2.TableProto .internal_static_google_bigtable_admin_v2_Snapshot_descriptor; @@ -685,7 +575,7 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(description_)) { com.google.protobuf.GeneratedMessageV3.writeString(output, 7, description_); } - unknownFields.writeTo(output); + getUnknownFields().writeTo(output); } @java.lang.Override @@ -715,7 +605,7 @@ public int getSerializedSize() { if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(description_)) { size += com.google.protobuf.GeneratedMessageV3.computeStringSize(7, description_); } - size += unknownFields.getSerializedSize(); + size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @@ -746,7 +636,7 @@ public boolean equals(final java.lang.Object obj) { } if (state_ != other.state_) return false; if (!getDescription().equals(other.getDescription())) return false; - if (!unknownFields.equals(other.unknownFields)) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -777,7 +667,7 @@ public int hashCode() { hash = (53 * hash) + state_; hash = (37 * hash) + DESCRIPTION_FIELD_NUMBER; hash = (53 * hash) + getDescription().hashCode(); - hash = (29 * hash) + unknownFields.hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } @@ -910,17 +800,10 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { } // Construct using com.google.bigtable.admin.v2.Snapshot.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } + private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} } @java.lang.Override @@ -1070,7 +953,7 @@ public Builder mergeFrom(com.google.bigtable.admin.v2.Snapshot other) { description_ = other.description_; onChanged(); } - this.mergeUnknownFields(other.unknownFields); + this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @@ -1085,17 +968,73 @@ public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - com.google.bigtable.admin.v2.Snapshot parsedMessage = null; + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + name_ = input.readStringRequireUtf8(); + + break; + } // case 10 + case 18: + { + input.readMessage(getSourceTableFieldBuilder().getBuilder(), extensionRegistry); + + break; + } // case 18 + case 24: + { + dataSizeBytes_ = input.readInt64(); + + break; + } // case 24 + case 34: + { + input.readMessage(getCreateTimeFieldBuilder().getBuilder(), extensionRegistry); + + break; + } // case 34 + case 42: + { + input.readMessage(getDeleteTimeFieldBuilder().getBuilder(), extensionRegistry); + + break; + } // case 42 + case 48: + { + state_ = input.readEnum(); + + break; + } // case 48 + case 58: + { + description_ = input.readStringRequireUtf8(); + + break; + } // case 58 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.bigtable.admin.v2.Snapshot) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } + onChanged(); + } // finally return this; } @@ -2074,7 +2013,18 @@ public Snapshot parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new Snapshot(input, extensionRegistry); + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); } }; diff --git a/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/SnapshotTableMetadata.java b/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/SnapshotTableMetadata.java index b54ab58fad..a789b41783 100644 --- a/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/SnapshotTableMetadata.java +++ b/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/SnapshotTableMetadata.java @@ -54,92 +54,6 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - private SnapshotTableMetadata( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - com.google.bigtable.admin.v2.SnapshotTableRequest.Builder subBuilder = null; - if (originalRequest_ != null) { - subBuilder = originalRequest_.toBuilder(); - } - originalRequest_ = - input.readMessage( - com.google.bigtable.admin.v2.SnapshotTableRequest.parser(), - extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(originalRequest_); - originalRequest_ = subBuilder.buildPartial(); - } - - break; - } - case 18: - { - com.google.protobuf.Timestamp.Builder subBuilder = null; - if (requestTime_ != null) { - subBuilder = requestTime_.toBuilder(); - } - requestTime_ = - input.readMessage(com.google.protobuf.Timestamp.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(requestTime_); - requestTime_ = subBuilder.buildPartial(); - } - - break; - } - case 26: - { - com.google.protobuf.Timestamp.Builder subBuilder = null; - if (finishTime_ != null) { - subBuilder = finishTime_.toBuilder(); - } - finishTime_ = - input.readMessage(com.google.protobuf.Timestamp.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(finishTime_); - finishTime_ = subBuilder.buildPartial(); - } - - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.bigtable.admin.v2.BigtableTableAdminProto .internal_static_google_bigtable_admin_v2_SnapshotTableMetadata_descriptor; @@ -318,7 +232,7 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io if (finishTime_ != null) { output.writeMessage(3, getFinishTime()); } - unknownFields.writeTo(output); + getUnknownFields().writeTo(output); } @java.lang.Override @@ -336,7 +250,7 @@ public int getSerializedSize() { if (finishTime_ != null) { size += com.google.protobuf.CodedOutputStream.computeMessageSize(3, getFinishTime()); } - size += unknownFields.getSerializedSize(); + size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @@ -364,7 +278,7 @@ public boolean equals(final java.lang.Object obj) { if (hasFinishTime()) { if (!getFinishTime().equals(other.getFinishTime())) return false; } - if (!unknownFields.equals(other.unknownFields)) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -387,7 +301,7 @@ public int hashCode() { hash = (37 * hash) + FINISH_TIME_FIELD_NUMBER; hash = (53 * hash) + getFinishTime().hashCode(); } - hash = (29 * hash) + unknownFields.hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } @@ -520,17 +434,10 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { } // Construct using com.google.bigtable.admin.v2.SnapshotTableMetadata.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } + private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} } @java.lang.Override @@ -655,7 +562,7 @@ public Builder mergeFrom(com.google.bigtable.admin.v2.SnapshotTableMetadata othe if (other.hasFinishTime()) { mergeFinishTime(other.getFinishTime()); } - this.mergeUnknownFields(other.unknownFields); + this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @@ -670,18 +577,49 @@ public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - com.google.bigtable.admin.v2.SnapshotTableMetadata parsedMessage = null; + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + input.readMessage(getOriginalRequestFieldBuilder().getBuilder(), extensionRegistry); + + break; + } // case 10 + case 18: + { + input.readMessage(getRequestTimeFieldBuilder().getBuilder(), extensionRegistry); + + break; + } // case 18 + case 26: + { + input.readMessage(getFinishTimeFieldBuilder().getBuilder(), extensionRegistry); + + break; + } // case 26 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = - (com.google.bigtable.admin.v2.SnapshotTableMetadata) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } + onChanged(); + } // finally return this; } @@ -1272,7 +1210,18 @@ public SnapshotTableMetadata parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new SnapshotTableMetadata(input, extensionRegistry); + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); } }; diff --git a/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/SnapshotTableRequest.java b/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/SnapshotTableRequest.java index 78d6886cc7..e759062c78 100644 --- a/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/SnapshotTableRequest.java +++ b/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/SnapshotTableRequest.java @@ -60,87 +60,6 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - private SnapshotTableRequest( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - java.lang.String s = input.readStringRequireUtf8(); - - name_ = s; - break; - } - case 18: - { - java.lang.String s = input.readStringRequireUtf8(); - - cluster_ = s; - break; - } - case 26: - { - java.lang.String s = input.readStringRequireUtf8(); - - snapshotId_ = s; - break; - } - case 34: - { - com.google.protobuf.Duration.Builder subBuilder = null; - if (ttl_ != null) { - subBuilder = ttl_.toBuilder(); - } - ttl_ = input.readMessage(com.google.protobuf.Duration.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(ttl_); - ttl_ = subBuilder.buildPartial(); - } - - break; - } - case 42: - { - java.lang.String s = input.readStringRequireUtf8(); - - description_ = s; - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.bigtable.admin.v2.BigtableTableAdminProto .internal_static_google_bigtable_admin_v2_SnapshotTableRequest_descriptor; @@ -458,7 +377,7 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(description_)) { com.google.protobuf.GeneratedMessageV3.writeString(output, 5, description_); } - unknownFields.writeTo(output); + getUnknownFields().writeTo(output); } @java.lang.Override @@ -482,7 +401,7 @@ public int getSerializedSize() { if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(description_)) { size += com.google.protobuf.GeneratedMessageV3.computeStringSize(5, description_); } - size += unknownFields.getSerializedSize(); + size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @@ -506,7 +425,7 @@ public boolean equals(final java.lang.Object obj) { if (!getTtl().equals(other.getTtl())) return false; } if (!getDescription().equals(other.getDescription())) return false; - if (!unknownFields.equals(other.unknownFields)) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -529,7 +448,7 @@ public int hashCode() { } hash = (37 * hash) + DESCRIPTION_FIELD_NUMBER; hash = (53 * hash) + getDescription().hashCode(); - hash = (29 * hash) + unknownFields.hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } @@ -663,17 +582,10 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { } // Construct using com.google.bigtable.admin.v2.SnapshotTableRequest.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } + private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} } @java.lang.Override @@ -798,7 +710,7 @@ public Builder mergeFrom(com.google.bigtable.admin.v2.SnapshotTableRequest other description_ = other.description_; onChanged(); } - this.mergeUnknownFields(other.unknownFields); + this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @@ -813,18 +725,61 @@ public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - com.google.bigtable.admin.v2.SnapshotTableRequest parsedMessage = null; + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + name_ = input.readStringRequireUtf8(); + + break; + } // case 10 + case 18: + { + cluster_ = input.readStringRequireUtf8(); + + break; + } // case 18 + case 26: + { + snapshotId_ = input.readStringRequireUtf8(); + + break; + } // case 26 + case 34: + { + input.readMessage(getTtlFieldBuilder().getBuilder(), extensionRegistry); + + break; + } // case 34 + case 42: + { + description_ = input.readStringRequireUtf8(); + + break; + } // case 42 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = - (com.google.bigtable.admin.v2.SnapshotTableRequest) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } + onChanged(); + } // finally return this; } @@ -1543,7 +1498,18 @@ public SnapshotTableRequest parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new SnapshotTableRequest(input, extensionRegistry); + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); } }; diff --git a/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/Table.java b/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/Table.java index 55f389ad07..654ce87398 100644 --- a/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/Table.java +++ b/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/Table.java @@ -54,114 +54,6 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - private Table( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - int mutable_bitField0_ = 0; - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - java.lang.String s = input.readStringRequireUtf8(); - - name_ = s; - break; - } - case 18: - { - if (!((mutable_bitField0_ & 0x00000001) != 0)) { - clusterStates_ = - com.google.protobuf.MapField.newMapField( - ClusterStatesDefaultEntryHolder.defaultEntry); - mutable_bitField0_ |= 0x00000001; - } - com.google.protobuf.MapEntry< - java.lang.String, com.google.bigtable.admin.v2.Table.ClusterState> - clusterStates__ = - input.readMessage( - ClusterStatesDefaultEntryHolder.defaultEntry.getParserForType(), - extensionRegistry); - clusterStates_ - .getMutableMap() - .put(clusterStates__.getKey(), clusterStates__.getValue()); - break; - } - case 26: - { - if (!((mutable_bitField0_ & 0x00000002) != 0)) { - columnFamilies_ = - com.google.protobuf.MapField.newMapField( - ColumnFamiliesDefaultEntryHolder.defaultEntry); - mutable_bitField0_ |= 0x00000002; - } - com.google.protobuf.MapEntry< - java.lang.String, com.google.bigtable.admin.v2.ColumnFamily> - columnFamilies__ = - input.readMessage( - ColumnFamiliesDefaultEntryHolder.defaultEntry.getParserForType(), - extensionRegistry); - columnFamilies_ - .getMutableMap() - .put(columnFamilies__.getKey(), columnFamilies__.getValue()); - break; - } - case 32: - { - int rawValue = input.readEnum(); - - granularity_ = rawValue; - break; - } - case 50: - { - com.google.bigtable.admin.v2.RestoreInfo.Builder subBuilder = null; - if (restoreInfo_ != null) { - subBuilder = restoreInfo_.toBuilder(); - } - restoreInfo_ = - input.readMessage( - com.google.bigtable.admin.v2.RestoreInfo.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(restoreInfo_); - restoreInfo_ = subBuilder.buildPartial(); - } - - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.bigtable.admin.v2.TableProto .internal_static_google_bigtable_admin_v2_Table_descriptor; @@ -707,68 +599,6 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - private ClusterState( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - int mutable_bitField0_ = 0; - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 8: - { - int rawValue = input.readEnum(); - - replicationState_ = rawValue; - break; - } - case 18: - { - if (!((mutable_bitField0_ & 0x00000001) != 0)) { - encryptionInfo_ = - new java.util.ArrayList(); - mutable_bitField0_ |= 0x00000001; - } - encryptionInfo_.add( - input.readMessage( - com.google.bigtable.admin.v2.EncryptionInfo.parser(), extensionRegistry)); - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); - } finally { - if (((mutable_bitField0_ & 0x00000001) != 0)) { - encryptionInfo_ = java.util.Collections.unmodifiableList(encryptionInfo_); - } - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.bigtable.admin.v2.TableProto .internal_static_google_bigtable_admin_v2_Table_ClusterState_descriptor; @@ -1193,7 +1023,7 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io for (int i = 0; i < encryptionInfo_.size(); i++) { output.writeMessage(2, encryptionInfo_.get(i)); } - unknownFields.writeTo(output); + getUnknownFields().writeTo(output); } @java.lang.Override @@ -1210,7 +1040,7 @@ public int getSerializedSize() { for (int i = 0; i < encryptionInfo_.size(); i++) { size += com.google.protobuf.CodedOutputStream.computeMessageSize(2, encryptionInfo_.get(i)); } - size += unknownFields.getSerializedSize(); + size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @@ -1228,7 +1058,7 @@ public boolean equals(final java.lang.Object obj) { if (replicationState_ != other.replicationState_) return false; if (!getEncryptionInfoList().equals(other.getEncryptionInfoList())) return false; - if (!unknownFields.equals(other.unknownFields)) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -1245,7 +1075,7 @@ public int hashCode() { hash = (37 * hash) + ENCRYPTION_INFO_FIELD_NUMBER; hash = (53 * hash) + getEncryptionInfoList().hashCode(); } - hash = (29 * hash) + unknownFields.hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } @@ -1376,19 +1206,10 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { } // Construct using com.google.bigtable.admin.v2.Table.ClusterState.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } + private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) { - getEncryptionInfoFieldBuilder(); - } } @java.lang.Override @@ -1398,10 +1219,11 @@ public Builder clear() { if (encryptionInfoBuilder_ == null) { encryptionInfo_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000001); } else { + encryptionInfo_ = null; encryptionInfoBuilder_.clear(); } + bitField0_ = (bitField0_ & ~0x00000001); return this; } @@ -1522,7 +1344,7 @@ public Builder mergeFrom(com.google.bigtable.admin.v2.Table.ClusterState other) } } } - this.mergeUnknownFields(other.unknownFields); + this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @@ -1537,18 +1359,50 @@ public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - com.google.bigtable.admin.v2.Table.ClusterState parsedMessage = null; + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 8: + { + replicationState_ = input.readEnum(); + + break; + } // case 8 + case 18: + { + com.google.bigtable.admin.v2.EncryptionInfo m = + input.readMessage( + com.google.bigtable.admin.v2.EncryptionInfo.parser(), extensionRegistry); + if (encryptionInfoBuilder_ == null) { + ensureEncryptionInfoIsMutable(); + encryptionInfo_.add(m); + } else { + encryptionInfoBuilder_.addMessage(m); + } + break; + } // case 18 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = - (com.google.bigtable.admin.v2.Table.ClusterState) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } + onChanged(); + } // finally return this; } @@ -2160,7 +2014,19 @@ public ClusterState parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new ClusterState(input, extensionRegistry); + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException() + .setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); } }; @@ -2587,6 +2453,29 @@ public com.google.bigtable.admin.v2.RestoreInfoOrBuilder getRestoreInfoOrBuilder return getRestoreInfo(); } + public static final int DELETION_PROTECTION_FIELD_NUMBER = 9; + private boolean deletionProtection_; + /** + * + * + *
+   * Set to true to make the table protected against data loss. i.e. deleting
+   * the following resources through Admin APIs are prohibited:
+   *   - The table.
+   *   - The column families in the table.
+   *   - The instance containing the table.
+   * Note one can still delete the data stored in the table through Data APIs.
+   * 
+ * + * bool deletion_protection = 9; + * + * @return The deletionProtection. + */ + @java.lang.Override + public boolean getDeletionProtection() { + return deletionProtection_; + } + private byte memoizedIsInitialized = -1; @java.lang.Override @@ -2616,7 +2505,10 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io if (restoreInfo_ != null) { output.writeMessage(6, getRestoreInfo()); } - unknownFields.writeTo(output); + if (deletionProtection_ != false) { + output.writeBool(9, deletionProtection_); + } + getUnknownFields().writeTo(output); } @java.lang.Override @@ -2659,7 +2551,10 @@ public int getSerializedSize() { if (restoreInfo_ != null) { size += com.google.protobuf.CodedOutputStream.computeMessageSize(6, getRestoreInfo()); } - size += unknownFields.getSerializedSize(); + if (deletionProtection_ != false) { + size += com.google.protobuf.CodedOutputStream.computeBoolSize(9, deletionProtection_); + } + size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @@ -2682,7 +2577,8 @@ public boolean equals(final java.lang.Object obj) { if (hasRestoreInfo()) { if (!getRestoreInfo().equals(other.getRestoreInfo())) return false; } - if (!unknownFields.equals(other.unknownFields)) return false; + if (getDeletionProtection() != other.getDeletionProtection()) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -2709,7 +2605,9 @@ public int hashCode() { hash = (37 * hash) + RESTORE_INFO_FIELD_NUMBER; hash = (53 * hash) + getRestoreInfo().hashCode(); } - hash = (29 * hash) + unknownFields.hashCode(); + hash = (37 * hash) + DELETION_PROTECTION_FIELD_NUMBER; + hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean(getDeletionProtection()); + hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } @@ -2862,17 +2760,10 @@ protected com.google.protobuf.MapField internalGetMutableMapField(int number) { } // Construct using com.google.bigtable.admin.v2.Table.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } + private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} } @java.lang.Override @@ -2890,6 +2781,8 @@ public Builder clear() { restoreInfo_ = null; restoreInfoBuilder_ = null; } + deletionProtection_ = false; + return this; } @@ -2928,6 +2821,7 @@ public com.google.bigtable.admin.v2.Table buildPartial() { } else { result.restoreInfo_ = restoreInfoBuilder_.build(); } + result.deletionProtection_ = deletionProtection_; onBuilt(); return result; } @@ -2989,7 +2883,10 @@ public Builder mergeFrom(com.google.bigtable.admin.v2.Table other) { if (other.hasRestoreInfo()) { mergeRestoreInfo(other.getRestoreInfo()); } - this.mergeUnknownFields(other.unknownFields); + if (other.getDeletionProtection() != false) { + setDeletionProtection(other.getDeletionProtection()); + } + this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @@ -3004,17 +2901,81 @@ public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - com.google.bigtable.admin.v2.Table parsedMessage = null; + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + name_ = input.readStringRequireUtf8(); + + break; + } // case 10 + case 18: + { + com.google.protobuf.MapEntry< + java.lang.String, com.google.bigtable.admin.v2.Table.ClusterState> + clusterStates__ = + input.readMessage( + ClusterStatesDefaultEntryHolder.defaultEntry.getParserForType(), + extensionRegistry); + internalGetMutableClusterStates() + .getMutableMap() + .put(clusterStates__.getKey(), clusterStates__.getValue()); + break; + } // case 18 + case 26: + { + com.google.protobuf.MapEntry< + java.lang.String, com.google.bigtable.admin.v2.ColumnFamily> + columnFamilies__ = + input.readMessage( + ColumnFamiliesDefaultEntryHolder.defaultEntry.getParserForType(), + extensionRegistry); + internalGetMutableColumnFamilies() + .getMutableMap() + .put(columnFamilies__.getKey(), columnFamilies__.getValue()); + break; + } // case 26 + case 32: + { + granularity_ = input.readEnum(); + + break; + } // case 32 + case 50: + { + input.readMessage(getRestoreInfoFieldBuilder().getBuilder(), extensionRegistry); + + break; + } // case 50 + case 72: + { + deletionProtection_ = input.readBool(); + + break; + } // case 72 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.bigtable.admin.v2.Table) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } + onChanged(); + } // finally return this; } @@ -3862,6 +3823,73 @@ public com.google.bigtable.admin.v2.RestoreInfoOrBuilder getRestoreInfoOrBuilder return restoreInfoBuilder_; } + private boolean deletionProtection_; + /** + * + * + *
+     * Set to true to make the table protected against data loss. i.e. deleting
+     * the following resources through Admin APIs are prohibited:
+     *   - The table.
+     *   - The column families in the table.
+     *   - The instance containing the table.
+     * Note one can still delete the data stored in the table through Data APIs.
+     * 
+ * + * bool deletion_protection = 9; + * + * @return The deletionProtection. + */ + @java.lang.Override + public boolean getDeletionProtection() { + return deletionProtection_; + } + /** + * + * + *
+     * Set to true to make the table protected against data loss. i.e. deleting
+     * the following resources through Admin APIs are prohibited:
+     *   - The table.
+     *   - The column families in the table.
+     *   - The instance containing the table.
+     * Note one can still delete the data stored in the table through Data APIs.
+     * 
+ * + * bool deletion_protection = 9; + * + * @param value The deletionProtection to set. + * @return This builder for chaining. + */ + public Builder setDeletionProtection(boolean value) { + + deletionProtection_ = value; + onChanged(); + return this; + } + /** + * + * + *
+     * Set to true to make the table protected against data loss. i.e. deleting
+     * the following resources through Admin APIs are prohibited:
+     *   - The table.
+     *   - The column families in the table.
+     *   - The instance containing the table.
+     * Note one can still delete the data stored in the table through Data APIs.
+     * 
+ * + * bool deletion_protection = 9; + * + * @return This builder for chaining. + */ + public Builder clearDeletionProtection() { + + deletionProtection_ = false; + onChanged(); + return this; + } + @java.lang.Override public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { return super.setUnknownFields(unknownFields); @@ -3894,7 +3922,18 @@ public Table parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new Table(input, extensionRegistry); + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); } }; diff --git a/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/TableOrBuilder.java b/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/TableOrBuilder.java index 831ca5358e..d27cc5d252 100644 --- a/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/TableOrBuilder.java +++ b/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/TableOrBuilder.java @@ -285,4 +285,22 @@ com.google.bigtable.admin.v2.ColumnFamily getColumnFamiliesOrDefault( * */ com.google.bigtable.admin.v2.RestoreInfoOrBuilder getRestoreInfoOrBuilder(); + + /** + * + * + *
+   * Set to true to make the table protected against data loss. i.e. deleting
+   * the following resources through Admin APIs are prohibited:
+   *   - The table.
+   *   - The column families in the table.
+   *   - The instance containing the table.
+   * Note one can still delete the data stored in the table through Data APIs.
+   * 
+ * + * bool deletion_protection = 9; + * + * @return The deletionProtection. + */ + boolean getDeletionProtection(); } diff --git a/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/TableProto.java b/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/TableProto.java index 52363aa70f..c6ca5e60c2 100644 --- a/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/TableProto.java +++ b/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/TableProto.java @@ -97,7 +97,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "_type\030\001 \001(\0162+.google.bigtable.admin.v2.R" + "estoreSourceType\022;\n\013backup_info\030\002 \001(\0132$." + "google.bigtable.admin.v2.BackupInfoH\000B\r\n" - + "\013source_info\"\361\010\n\005Table\022\014\n\004name\030\001 \001(\t\022O\n\016" + + "\013source_info\"\216\t\n\005Table\022\014\n\004name\030\001 \001(\t\022O\n\016" + "cluster_states\030\002 \003(\01322.google.bigtable.a" + "dmin.v2.Table.ClusterStatesEntryB\003\340A\003\022L\n" + "\017column_families\030\003 \003(\01323.google.bigtable" @@ -105,87 +105,88 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "ranularity\030\004 \001(\01624.google.bigtable.admin" + ".v2.Table.TimestampGranularityB\003\340A\005\022@\n\014r" + "estore_info\030\006 \001(\0132%.google.bigtable.admi" - + "n.v2.RestoreInfoB\003\340A\003\032\306\002\n\014ClusterState\022]" - + "\n\021replication_state\030\001 \001(\0162=.google.bigta" - + "ble.admin.v2.Table.ClusterState.Replicat" - + "ionStateB\003\340A\003\022F\n\017encryption_info\030\002 \003(\0132(" - + ".google.bigtable.admin.v2.EncryptionInfo" - + "B\003\340A\003\"\216\001\n\020ReplicationState\022\023\n\017STATE_NOT_" - + "KNOWN\020\000\022\020\n\014INITIALIZING\020\001\022\027\n\023PLANNED_MAI" - + "NTENANCE\020\002\022\031\n\025UNPLANNED_MAINTENANCE\020\003\022\t\n" - + "\005READY\020\004\022\024\n\020READY_OPTIMIZING\020\005\032b\n\022Cluste" - + "rStatesEntry\022\013\n\003key\030\001 \001(\t\022;\n\005value\030\002 \001(\013" - + "2,.google.bigtable.admin.v2.Table.Cluste" - + "rState:\0028\001\032]\n\023ColumnFamiliesEntry\022\013\n\003key" - + "\030\001 \001(\t\0225\n\005value\030\002 \001(\0132&.google.bigtable." - + "admin.v2.ColumnFamily:\0028\001\"I\n\024TimestampGr" - + "anularity\022%\n!TIMESTAMP_GRANULARITY_UNSPE" - + "CIFIED\020\000\022\n\n\006MILLIS\020\001\"q\n\004View\022\024\n\020VIEW_UNS" - + "PECIFIED\020\000\022\r\n\tNAME_ONLY\020\001\022\017\n\013SCHEMA_VIEW" - + "\020\002\022\024\n\020REPLICATION_VIEW\020\003\022\023\n\017ENCRYPTION_V" - + "IEW\020\005\022\010\n\004FULL\020\004:_\352A\\\n\"bigtableadmin.goog" - + "leapis.com/Table\0226projects/{project}/ins" - + "tances/{instance}/tables/{table}\"A\n\014Colu" - + "mnFamily\0221\n\007gc_rule\030\001 \001(\0132 .google.bigta" - + "ble.admin.v2.GcRule\"\325\002\n\006GcRule\022\032\n\020max_nu" - + "m_versions\030\001 \001(\005H\000\022,\n\007max_age\030\002 \001(\0132\031.go" - + "ogle.protobuf.DurationH\000\022E\n\014intersection" - + "\030\003 \001(\0132-.google.bigtable.admin.v2.GcRule" - + ".IntersectionH\000\0227\n\005union\030\004 \001(\0132&.google." - + "bigtable.admin.v2.GcRule.UnionH\000\032?\n\014Inte" - + "rsection\022/\n\005rules\030\001 \003(\0132 .google.bigtabl" - + "e.admin.v2.GcRule\0328\n\005Union\022/\n\005rules\030\001 \003(" - + "\0132 .google.bigtable.admin.v2.GcRuleB\006\n\004r" - + "ule\"\331\002\n\016EncryptionInfo\022U\n\017encryption_typ" - + "e\030\003 \001(\01627.google.bigtable.admin.v2.Encry" - + "ptionInfo.EncryptionTypeB\003\340A\003\0222\n\021encrypt" - + "ion_status\030\004 \001(\0132\022.google.rpc.StatusB\003\340A" - + "\003\022I\n\017kms_key_version\030\002 \001(\tB0\340A\003\372A*\n(clou" - + "dkms.googleapis.com/CryptoKeyVersion\"q\n\016" - + "EncryptionType\022\037\n\033ENCRYPTION_TYPE_UNSPEC" - + "IFIED\020\000\022\035\n\031GOOGLE_DEFAULT_ENCRYPTION\020\001\022\037" - + "\n\033CUSTOMER_MANAGED_ENCRYPTION\020\002\"\314\003\n\010Snap" - + "shot\022\014\n\004name\030\001 \001(\t\0225\n\014source_table\030\002 \001(\013" - + "2\037.google.bigtable.admin.v2.Table\022\027\n\017dat" - + "a_size_bytes\030\003 \001(\003\022/\n\013create_time\030\004 \001(\0132" - + "\032.google.protobuf.Timestamp\022/\n\013delete_ti" - + "me\030\005 \001(\0132\032.google.protobuf.Timestamp\0227\n\005" - + "state\030\006 \001(\0162(.google.bigtable.admin.v2.S" - + "napshot.State\022\023\n\013description\030\007 \001(\t\"5\n\005St" - + "ate\022\023\n\017STATE_NOT_KNOWN\020\000\022\t\n\005READY\020\001\022\014\n\010C" - + "REATING\020\002:{\352Ax\n%bigtableadmin.googleapis" - + ".com/Snapshot\022Oprojects/{project}/instan" - + "ces/{instance}/clusters/{cluster}/snapsh" - + "ots/{snapshot}\"\237\004\n\006Backup\022\014\n\004name\030\001 \001(\t\022" - + "\034\n\014source_table\030\002 \001(\tB\006\340A\005\340A\002\0224\n\013expire_" - + "time\030\003 \001(\0132\032.google.protobuf.TimestampB\003" - + "\340A\002\0223\n\nstart_time\030\004 \001(\0132\032.google.protobu" - + "f.TimestampB\003\340A\003\0221\n\010end_time\030\005 \001(\0132\032.goo" - + "gle.protobuf.TimestampB\003\340A\003\022\027\n\nsize_byte" - + "s\030\006 \001(\003B\003\340A\003\022:\n\005state\030\007 \001(\0162&.google.big" - + "table.admin.v2.Backup.StateB\003\340A\003\022F\n\017encr" - + "yption_info\030\t \001(\0132(.google.bigtable.admi" - + "n.v2.EncryptionInfoB\003\340A\003\"7\n\005State\022\025\n\021STA" - + "TE_UNSPECIFIED\020\000\022\014\n\010CREATING\020\001\022\t\n\005READY\020" - + "\002:u\352Ar\n#bigtableadmin.googleapis.com/Bac" - + "kup\022Kprojects/{project}/instances/{insta" - + "nce}/clusters/{cluster}/backups/{backup}" - + "\"\244\001\n\nBackupInfo\022\023\n\006backup\030\001 \001(\tB\003\340A\003\0223\n\n" - + "start_time\030\002 \001(\0132\032.google.protobuf.Times" - + "tampB\003\340A\003\0221\n\010end_time\030\003 \001(\0132\032.google.pro" - + "tobuf.TimestampB\003\340A\003\022\031\n\014source_table\030\004 \001" - + "(\tB\003\340A\003*D\n\021RestoreSourceType\022#\n\037RESTORE_" - + "SOURCE_TYPE_UNSPECIFIED\020\000\022\n\n\006BACKUP\020\001B\374\002" - + "\n\034com.google.bigtable.admin.v2B\nTablePro" - + "toP\001Z=google.golang.org/genproto/googlea" - + "pis/bigtable/admin/v2;admin\252\002\036Google.Clo" - + "ud.Bigtable.Admin.V2\312\002\036Google\\Cloud\\Bigt" - + "able\\Admin\\V2\352\002\"Google::Cloud::Bigtable:" - + ":Admin::V2\352A\246\001\n(cloudkms.googleapis.com/" - + "CryptoKeyVersion\022zprojects/{project}/loc" - + "ations/{location}/keyRings/{key_ring}/cr" - + "yptoKeys/{crypto_key}/cryptoKeyVersions/" - + "{crypto_key_version}b\006proto3" + + "n.v2.RestoreInfoB\003\340A\003\022\033\n\023deletion_protec" + + "tion\030\t \001(\010\032\306\002\n\014ClusterState\022]\n\021replicati" + + "on_state\030\001 \001(\0162=.google.bigtable.admin.v" + + "2.Table.ClusterState.ReplicationStateB\003\340" + + "A\003\022F\n\017encryption_info\030\002 \003(\0132(.google.big" + + "table.admin.v2.EncryptionInfoB\003\340A\003\"\216\001\n\020R" + + "eplicationState\022\023\n\017STATE_NOT_KNOWN\020\000\022\020\n\014" + + "INITIALIZING\020\001\022\027\n\023PLANNED_MAINTENANCE\020\002\022" + + "\031\n\025UNPLANNED_MAINTENANCE\020\003\022\t\n\005READY\020\004\022\024\n" + + "\020READY_OPTIMIZING\020\005\032b\n\022ClusterStatesEntr" + + "y\022\013\n\003key\030\001 \001(\t\022;\n\005value\030\002 \001(\0132,.google.b" + + "igtable.admin.v2.Table.ClusterState:\0028\001\032" + + "]\n\023ColumnFamiliesEntry\022\013\n\003key\030\001 \001(\t\0225\n\005v" + + "alue\030\002 \001(\0132&.google.bigtable.admin.v2.Co" + + "lumnFamily:\0028\001\"I\n\024TimestampGranularity\022%" + + "\n!TIMESTAMP_GRANULARITY_UNSPECIFIED\020\000\022\n\n" + + "\006MILLIS\020\001\"q\n\004View\022\024\n\020VIEW_UNSPECIFIED\020\000\022" + + "\r\n\tNAME_ONLY\020\001\022\017\n\013SCHEMA_VIEW\020\002\022\024\n\020REPLI" + + "CATION_VIEW\020\003\022\023\n\017ENCRYPTION_VIEW\020\005\022\010\n\004FU" + + "LL\020\004:_\352A\\\n\"bigtableadmin.googleapis.com/" + + "Table\0226projects/{project}/instances/{ins" + + "tance}/tables/{table}\"A\n\014ColumnFamily\0221\n" + + "\007gc_rule\030\001 \001(\0132 .google.bigtable.admin.v" + + "2.GcRule\"\325\002\n\006GcRule\022\032\n\020max_num_versions\030" + + "\001 \001(\005H\000\022,\n\007max_age\030\002 \001(\0132\031.google.protob" + + "uf.DurationH\000\022E\n\014intersection\030\003 \001(\0132-.go" + + "ogle.bigtable.admin.v2.GcRule.Intersecti" + + "onH\000\0227\n\005union\030\004 \001(\0132&.google.bigtable.ad" + + "min.v2.GcRule.UnionH\000\032?\n\014Intersection\022/\n" + + "\005rules\030\001 \003(\0132 .google.bigtable.admin.v2." + + "GcRule\0328\n\005Union\022/\n\005rules\030\001 \003(\0132 .google." + + "bigtable.admin.v2.GcRuleB\006\n\004rule\"\331\002\n\016Enc" + + "ryptionInfo\022U\n\017encryption_type\030\003 \001(\01627.g" + + "oogle.bigtable.admin.v2.EncryptionInfo.E" + + "ncryptionTypeB\003\340A\003\0222\n\021encryption_status\030" + + "\004 \001(\0132\022.google.rpc.StatusB\003\340A\003\022I\n\017kms_ke" + + "y_version\030\002 \001(\tB0\340A\003\372A*\n(cloudkms.google" + + "apis.com/CryptoKeyVersion\"q\n\016EncryptionT" + + "ype\022\037\n\033ENCRYPTION_TYPE_UNSPECIFIED\020\000\022\035\n\031" + + "GOOGLE_DEFAULT_ENCRYPTION\020\001\022\037\n\033CUSTOMER_" + + "MANAGED_ENCRYPTION\020\002\"\314\003\n\010Snapshot\022\014\n\004nam" + + "e\030\001 \001(\t\0225\n\014source_table\030\002 \001(\0132\037.google.b" + + "igtable.admin.v2.Table\022\027\n\017data_size_byte" + + "s\030\003 \001(\003\022/\n\013create_time\030\004 \001(\0132\032.google.pr" + + "otobuf.Timestamp\022/\n\013delete_time\030\005 \001(\0132\032." + + "google.protobuf.Timestamp\0227\n\005state\030\006 \001(\016" + + "2(.google.bigtable.admin.v2.Snapshot.Sta" + + "te\022\023\n\013description\030\007 \001(\t\"5\n\005State\022\023\n\017STAT" + + "E_NOT_KNOWN\020\000\022\t\n\005READY\020\001\022\014\n\010CREATING\020\002:{" + + "\352Ax\n%bigtableadmin.googleapis.com/Snapsh" + + "ot\022Oprojects/{project}/instances/{instan" + + "ce}/clusters/{cluster}/snapshots/{snapsh" + + "ot}\"\237\004\n\006Backup\022\014\n\004name\030\001 \001(\t\022\034\n\014source_t" + + "able\030\002 \001(\tB\006\340A\005\340A\002\0224\n\013expire_time\030\003 \001(\0132" + + "\032.google.protobuf.TimestampB\003\340A\002\0223\n\nstar" + + "t_time\030\004 \001(\0132\032.google.protobuf.Timestamp" + + "B\003\340A\003\0221\n\010end_time\030\005 \001(\0132\032.google.protobu" + + "f.TimestampB\003\340A\003\022\027\n\nsize_bytes\030\006 \001(\003B\003\340A" + + "\003\022:\n\005state\030\007 \001(\0162&.google.bigtable.admin" + + ".v2.Backup.StateB\003\340A\003\022F\n\017encryption_info" + + "\030\t \001(\0132(.google.bigtable.admin.v2.Encryp" + + "tionInfoB\003\340A\003\"7\n\005State\022\025\n\021STATE_UNSPECIF" + + "IED\020\000\022\014\n\010CREATING\020\001\022\t\n\005READY\020\002:u\352Ar\n#big" + + "tableadmin.googleapis.com/Backup\022Kprojec" + + "ts/{project}/instances/{instance}/cluste" + + "rs/{cluster}/backups/{backup}\"\244\001\n\nBackup" + + "Info\022\023\n\006backup\030\001 \001(\tB\003\340A\003\0223\n\nstart_time\030" + + "\002 \001(\0132\032.google.protobuf.TimestampB\003\340A\003\0221" + + "\n\010end_time\030\003 \001(\0132\032.google.protobuf.Times" + + "tampB\003\340A\003\022\031\n\014source_table\030\004 \001(\tB\003\340A\003*D\n\021" + + "RestoreSourceType\022#\n\037RESTORE_SOURCE_TYPE" + + "_UNSPECIFIED\020\000\022\n\n\006BACKUP\020\001B\374\002\n\034com.googl" + + "e.bigtable.admin.v2B\nTableProtoP\001Z=googl" + + "e.golang.org/genproto/googleapis/bigtabl" + + "e/admin/v2;admin\252\002\036Google.Cloud.Bigtable" + + ".Admin.V2\312\002\036Google\\Cloud\\Bigtable\\Admin\\" + + "V2\352\002\"Google::Cloud::Bigtable::Admin::V2\352" + + "A\246\001\n(cloudkms.googleapis.com/CryptoKeyVe" + + "rsion\022zprojects/{project}/locations/{loc" + + "ation}/keyRings/{key_ring}/cryptoKeys/{c" + + "rypto_key}/cryptoKeyVersions/{crypto_key" + + "_version}b\006proto3" }; descriptor = com.google.protobuf.Descriptors.FileDescriptor.internalBuildGeneratedFileFrom( @@ -211,7 +212,12 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( internal_static_google_bigtable_admin_v2_Table_descriptor, new java.lang.String[] { - "Name", "ClusterStates", "ColumnFamilies", "Granularity", "RestoreInfo", + "Name", + "ClusterStates", + "ColumnFamilies", + "Granularity", + "RestoreInfo", + "DeletionProtection", }); internal_static_google_bigtable_admin_v2_Table_ClusterState_descriptor = internal_static_google_bigtable_admin_v2_Table_descriptor.getNestedTypes().get(0); diff --git a/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/UndeleteTableMetadata.java b/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/UndeleteTableMetadata.java index b4488d0427..383ba6159a 100644 --- a/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/UndeleteTableMetadata.java +++ b/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/UndeleteTableMetadata.java @@ -53,82 +53,6 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - private UndeleteTableMetadata( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - java.lang.String s = input.readStringRequireUtf8(); - - name_ = s; - break; - } - case 18: - { - com.google.protobuf.Timestamp.Builder subBuilder = null; - if (startTime_ != null) { - subBuilder = startTime_.toBuilder(); - } - startTime_ = - input.readMessage(com.google.protobuf.Timestamp.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(startTime_); - startTime_ = subBuilder.buildPartial(); - } - - break; - } - case 26: - { - com.google.protobuf.Timestamp.Builder subBuilder = null; - if (endTime_ != null) { - subBuilder = endTime_.toBuilder(); - } - endTime_ = - input.readMessage(com.google.protobuf.Timestamp.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(endTime_); - endTime_ = subBuilder.buildPartial(); - } - - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.bigtable.admin.v2.BigtableTableAdminProto .internal_static_google_bigtable_admin_v2_UndeleteTableMetadata_descriptor; @@ -308,7 +232,7 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io if (endTime_ != null) { output.writeMessage(3, getEndTime()); } - unknownFields.writeTo(output); + getUnknownFields().writeTo(output); } @java.lang.Override @@ -326,7 +250,7 @@ public int getSerializedSize() { if (endTime_ != null) { size += com.google.protobuf.CodedOutputStream.computeMessageSize(3, getEndTime()); } - size += unknownFields.getSerializedSize(); + size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @@ -351,7 +275,7 @@ public boolean equals(final java.lang.Object obj) { if (hasEndTime()) { if (!getEndTime().equals(other.getEndTime())) return false; } - if (!unknownFields.equals(other.unknownFields)) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -372,7 +296,7 @@ public int hashCode() { hash = (37 * hash) + END_TIME_FIELD_NUMBER; hash = (53 * hash) + getEndTime().hashCode(); } - hash = (29 * hash) + unknownFields.hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } @@ -502,17 +426,10 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { } // Construct using com.google.bigtable.admin.v2.UndeleteTableMetadata.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } + private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} } @java.lang.Override @@ -630,7 +547,7 @@ public Builder mergeFrom(com.google.bigtable.admin.v2.UndeleteTableMetadata othe if (other.hasEndTime()) { mergeEndTime(other.getEndTime()); } - this.mergeUnknownFields(other.unknownFields); + this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @@ -645,18 +562,49 @@ public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - com.google.bigtable.admin.v2.UndeleteTableMetadata parsedMessage = null; + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + name_ = input.readStringRequireUtf8(); + + break; + } // case 10 + case 18: + { + input.readMessage(getStartTimeFieldBuilder().getBuilder(), extensionRegistry); + + break; + } // case 18 + case 26: + { + input.readMessage(getEndTimeFieldBuilder().getBuilder(), extensionRegistry); + + break; + } // case 26 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = - (com.google.bigtable.admin.v2.UndeleteTableMetadata) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } + onChanged(); + } // finally return this; } @@ -1156,7 +1104,18 @@ public UndeleteTableMetadata parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new UndeleteTableMetadata(input, extensionRegistry); + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); } }; diff --git a/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/UndeleteTableRequest.java b/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/UndeleteTableRequest.java index 8cecfc37af..1416ee41cd 100644 --- a/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/UndeleteTableRequest.java +++ b/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/UndeleteTableRequest.java @@ -53,52 +53,6 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - private UndeleteTableRequest( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - java.lang.String s = input.readStringRequireUtf8(); - - name_ = s; - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.bigtable.admin.v2.BigtableTableAdminProto .internal_static_google_bigtable_admin_v2_UndeleteTableRequest_descriptor; @@ -188,7 +142,7 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(name_)) { com.google.protobuf.GeneratedMessageV3.writeString(output, 1, name_); } - unknownFields.writeTo(output); + getUnknownFields().writeTo(output); } @java.lang.Override @@ -200,7 +154,7 @@ public int getSerializedSize() { if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(name_)) { size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, name_); } - size += unknownFields.getSerializedSize(); + size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @@ -217,7 +171,7 @@ public boolean equals(final java.lang.Object obj) { (com.google.bigtable.admin.v2.UndeleteTableRequest) obj; if (!getName().equals(other.getName())) return false; - if (!unknownFields.equals(other.unknownFields)) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -230,7 +184,7 @@ public int hashCode() { hash = (19 * hash) + getDescriptor().hashCode(); hash = (37 * hash) + NAME_FIELD_NUMBER; hash = (53 * hash) + getName().hashCode(); - hash = (29 * hash) + unknownFields.hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } @@ -360,17 +314,10 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { } // Construct using com.google.bigtable.admin.v2.UndeleteTableRequest.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } + private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} } @java.lang.Override @@ -460,7 +407,7 @@ public Builder mergeFrom(com.google.bigtable.admin.v2.UndeleteTableRequest other name_ = other.name_; onChanged(); } - this.mergeUnknownFields(other.unknownFields); + this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @@ -475,18 +422,37 @@ public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - com.google.bigtable.admin.v2.UndeleteTableRequest parsedMessage = null; + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + name_ = input.readStringRequireUtf8(); + + break; + } // case 10 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = - (com.google.bigtable.admin.v2.UndeleteTableRequest) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } + onChanged(); + } // finally return this; } @@ -648,7 +614,18 @@ public UndeleteTableRequest parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new UndeleteTableRequest(input, extensionRegistry); + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); } }; diff --git a/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/UpdateAppProfileMetadata.java b/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/UpdateAppProfileMetadata.java index 4455327c4d..c8f33f9e7a 100644 --- a/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/UpdateAppProfileMetadata.java +++ b/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/UpdateAppProfileMetadata.java @@ -50,45 +50,6 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - private UpdateAppProfileMetadata( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.bigtable.admin.v2.BigtableInstanceAdminProto .internal_static_google_bigtable_admin_v2_UpdateAppProfileMetadata_descriptor; @@ -118,7 +79,7 @@ public final boolean isInitialized() { @java.lang.Override public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { - unknownFields.writeTo(output); + getUnknownFields().writeTo(output); } @java.lang.Override @@ -127,7 +88,7 @@ public int getSerializedSize() { if (size != -1) return size; size = 0; - size += unknownFields.getSerializedSize(); + size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @@ -143,7 +104,7 @@ public boolean equals(final java.lang.Object obj) { com.google.bigtable.admin.v2.UpdateAppProfileMetadata other = (com.google.bigtable.admin.v2.UpdateAppProfileMetadata) obj; - if (!unknownFields.equals(other.unknownFields)) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -154,7 +115,7 @@ public int hashCode() { } int hash = 41; hash = (19 * hash) + getDescriptor().hashCode(); - hash = (29 * hash) + unknownFields.hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } @@ -284,17 +245,10 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { } // Construct using com.google.bigtable.admin.v2.UpdateAppProfileMetadata.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } + private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} } @java.lang.Override @@ -377,7 +331,7 @@ public Builder mergeFrom(com.google.protobuf.Message other) { public Builder mergeFrom(com.google.bigtable.admin.v2.UpdateAppProfileMetadata other) { if (other == com.google.bigtable.admin.v2.UpdateAppProfileMetadata.getDefaultInstance()) return this; - this.mergeUnknownFields(other.unknownFields); + this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @@ -392,18 +346,31 @@ public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - com.google.bigtable.admin.v2.UpdateAppProfileMetadata parsedMessage = null; + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = - (com.google.bigtable.admin.v2.UpdateAppProfileMetadata) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } + onChanged(); + } // finally return this; } @@ -439,7 +406,18 @@ public UpdateAppProfileMetadata parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new UpdateAppProfileMetadata(input, extensionRegistry); + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); } }; diff --git a/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/UpdateAppProfileRequest.java b/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/UpdateAppProfileRequest.java index 748c754d5c..10c54caa1c 100644 --- a/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/UpdateAppProfileRequest.java +++ b/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/UpdateAppProfileRequest.java @@ -50,81 +50,6 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - private UpdateAppProfileRequest( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - com.google.bigtable.admin.v2.AppProfile.Builder subBuilder = null; - if (appProfile_ != null) { - subBuilder = appProfile_.toBuilder(); - } - appProfile_ = - input.readMessage( - com.google.bigtable.admin.v2.AppProfile.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(appProfile_); - appProfile_ = subBuilder.buildPartial(); - } - - break; - } - case 18: - { - com.google.protobuf.FieldMask.Builder subBuilder = null; - if (updateMask_ != null) { - subBuilder = updateMask_.toBuilder(); - } - updateMask_ = - input.readMessage(com.google.protobuf.FieldMask.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(updateMask_); - updateMask_ = subBuilder.buildPartial(); - } - - break; - } - case 24: - { - ignoreWarnings_ = input.readBool(); - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.bigtable.admin.v2.BigtableInstanceAdminProto .internal_static_google_bigtable_admin_v2_UpdateAppProfileRequest_descriptor; @@ -287,7 +212,7 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io if (ignoreWarnings_ != false) { output.writeBool(3, ignoreWarnings_); } - unknownFields.writeTo(output); + getUnknownFields().writeTo(output); } @java.lang.Override @@ -305,7 +230,7 @@ public int getSerializedSize() { if (ignoreWarnings_ != false) { size += com.google.protobuf.CodedOutputStream.computeBoolSize(3, ignoreWarnings_); } - size += unknownFields.getSerializedSize(); + size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @@ -330,7 +255,7 @@ public boolean equals(final java.lang.Object obj) { if (!getUpdateMask().equals(other.getUpdateMask())) return false; } if (getIgnoreWarnings() != other.getIgnoreWarnings()) return false; - if (!unknownFields.equals(other.unknownFields)) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -351,7 +276,7 @@ public int hashCode() { } hash = (37 * hash) + IGNORE_WARNINGS_FIELD_NUMBER; hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean(getIgnoreWarnings()); - hash = (29 * hash) + unknownFields.hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } @@ -480,17 +405,10 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { } // Construct using com.google.bigtable.admin.v2.UpdateAppProfileRequest.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } + private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} } @java.lang.Override @@ -607,7 +525,7 @@ public Builder mergeFrom(com.google.bigtable.admin.v2.UpdateAppProfileRequest ot if (other.getIgnoreWarnings() != false) { setIgnoreWarnings(other.getIgnoreWarnings()); } - this.mergeUnknownFields(other.unknownFields); + this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @@ -622,18 +540,49 @@ public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - com.google.bigtable.admin.v2.UpdateAppProfileRequest parsedMessage = null; + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + input.readMessage(getAppProfileFieldBuilder().getBuilder(), extensionRegistry); + + break; + } // case 10 + case 18: + { + input.readMessage(getUpdateMaskFieldBuilder().getBuilder(), extensionRegistry); + + break; + } // case 18 + case 24: + { + ignoreWarnings_ = input.readBool(); + + break; + } // case 24 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = - (com.google.bigtable.admin.v2.UpdateAppProfileRequest) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } + onChanged(); + } // finally return this; } @@ -1125,7 +1074,18 @@ public UpdateAppProfileRequest parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new UpdateAppProfileRequest(input, extensionRegistry); + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); } }; diff --git a/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/UpdateBackupRequest.java b/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/UpdateBackupRequest.java index 6af688de21..a4311ef7bc 100644 --- a/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/UpdateBackupRequest.java +++ b/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/UpdateBackupRequest.java @@ -50,76 +50,6 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - private UpdateBackupRequest( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - com.google.bigtable.admin.v2.Backup.Builder subBuilder = null; - if (backup_ != null) { - subBuilder = backup_.toBuilder(); - } - backup_ = - input.readMessage( - com.google.bigtable.admin.v2.Backup.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(backup_); - backup_ = subBuilder.buildPartial(); - } - - break; - } - case 18: - { - com.google.protobuf.FieldMask.Builder subBuilder = null; - if (updateMask_ != null) { - subBuilder = updateMask_.toBuilder(); - } - updateMask_ = - input.readMessage(com.google.protobuf.FieldMask.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(updateMask_); - updateMask_ = subBuilder.buildPartial(); - } - - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.bigtable.admin.v2.BigtableTableAdminProto .internal_static_google_bigtable_admin_v2_UpdateBackupRequest_descriptor; @@ -274,7 +204,7 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io if (updateMask_ != null) { output.writeMessage(2, getUpdateMask()); } - unknownFields.writeTo(output); + getUnknownFields().writeTo(output); } @java.lang.Override @@ -289,7 +219,7 @@ public int getSerializedSize() { if (updateMask_ != null) { size += com.google.protobuf.CodedOutputStream.computeMessageSize(2, getUpdateMask()); } - size += unknownFields.getSerializedSize(); + size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @@ -313,7 +243,7 @@ public boolean equals(final java.lang.Object obj) { if (hasUpdateMask()) { if (!getUpdateMask().equals(other.getUpdateMask())) return false; } - if (!unknownFields.equals(other.unknownFields)) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -332,7 +262,7 @@ public int hashCode() { hash = (37 * hash) + UPDATE_MASK_FIELD_NUMBER; hash = (53 * hash) + getUpdateMask().hashCode(); } - hash = (29 * hash) + unknownFields.hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } @@ -461,17 +391,10 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { } // Construct using com.google.bigtable.admin.v2.UpdateBackupRequest.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } + private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} } @java.lang.Override @@ -582,7 +505,7 @@ public Builder mergeFrom(com.google.bigtable.admin.v2.UpdateBackupRequest other) if (other.hasUpdateMask()) { mergeUpdateMask(other.getUpdateMask()); } - this.mergeUnknownFields(other.unknownFields); + this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @@ -597,17 +520,43 @@ public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - com.google.bigtable.admin.v2.UpdateBackupRequest parsedMessage = null; + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + input.readMessage(getBackupFieldBuilder().getBuilder(), extensionRegistry); + + break; + } // case 10 + case 18: + { + input.readMessage(getUpdateMaskFieldBuilder().getBuilder(), extensionRegistry); + + break; + } // case 18 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.bigtable.admin.v2.UpdateBackupRequest) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } + onChanged(); + } // finally return this; } @@ -1088,7 +1037,18 @@ public UpdateBackupRequest parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new UpdateBackupRequest(input, extensionRegistry); + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); } }; diff --git a/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/UpdateClusterMetadata.java b/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/UpdateClusterMetadata.java index a4eb043ea0..87faae7b1c 100644 --- a/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/UpdateClusterMetadata.java +++ b/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/UpdateClusterMetadata.java @@ -50,91 +50,6 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - private UpdateClusterMetadata( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - com.google.bigtable.admin.v2.Cluster.Builder subBuilder = null; - if (originalRequest_ != null) { - subBuilder = originalRequest_.toBuilder(); - } - originalRequest_ = - input.readMessage( - com.google.bigtable.admin.v2.Cluster.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(originalRequest_); - originalRequest_ = subBuilder.buildPartial(); - } - - break; - } - case 18: - { - com.google.protobuf.Timestamp.Builder subBuilder = null; - if (requestTime_ != null) { - subBuilder = requestTime_.toBuilder(); - } - requestTime_ = - input.readMessage(com.google.protobuf.Timestamp.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(requestTime_); - requestTime_ = subBuilder.buildPartial(); - } - - break; - } - case 26: - { - com.google.protobuf.Timestamp.Builder subBuilder = null; - if (finishTime_ != null) { - subBuilder = finishTime_.toBuilder(); - } - finishTime_ = - input.readMessage(com.google.protobuf.Timestamp.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(finishTime_); - finishTime_ = subBuilder.buildPartial(); - } - - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.bigtable.admin.v2.BigtableInstanceAdminProto .internal_static_google_bigtable_admin_v2_UpdateClusterMetadata_descriptor; @@ -313,7 +228,7 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io if (finishTime_ != null) { output.writeMessage(3, getFinishTime()); } - unknownFields.writeTo(output); + getUnknownFields().writeTo(output); } @java.lang.Override @@ -331,7 +246,7 @@ public int getSerializedSize() { if (finishTime_ != null) { size += com.google.protobuf.CodedOutputStream.computeMessageSize(3, getFinishTime()); } - size += unknownFields.getSerializedSize(); + size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @@ -359,7 +274,7 @@ public boolean equals(final java.lang.Object obj) { if (hasFinishTime()) { if (!getFinishTime().equals(other.getFinishTime())) return false; } - if (!unknownFields.equals(other.unknownFields)) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -382,7 +297,7 @@ public int hashCode() { hash = (37 * hash) + FINISH_TIME_FIELD_NUMBER; hash = (53 * hash) + getFinishTime().hashCode(); } - hash = (29 * hash) + unknownFields.hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } @@ -511,17 +426,10 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { } // Construct using com.google.bigtable.admin.v2.UpdateClusterMetadata.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } + private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} } @java.lang.Override @@ -646,7 +554,7 @@ public Builder mergeFrom(com.google.bigtable.admin.v2.UpdateClusterMetadata othe if (other.hasFinishTime()) { mergeFinishTime(other.getFinishTime()); } - this.mergeUnknownFields(other.unknownFields); + this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @@ -661,18 +569,49 @@ public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - com.google.bigtable.admin.v2.UpdateClusterMetadata parsedMessage = null; + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + input.readMessage(getOriginalRequestFieldBuilder().getBuilder(), extensionRegistry); + + break; + } // case 10 + case 18: + { + input.readMessage(getRequestTimeFieldBuilder().getBuilder(), extensionRegistry); + + break; + } // case 18 + case 26: + { + input.readMessage(getFinishTimeFieldBuilder().getBuilder(), extensionRegistry); + + break; + } // case 26 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = - (com.google.bigtable.admin.v2.UpdateClusterMetadata) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } + onChanged(); + } // finally return this; } @@ -1262,7 +1201,18 @@ public UpdateClusterMetadata parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new UpdateClusterMetadata(input, extensionRegistry); + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); } }; diff --git a/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/UpdateInstanceMetadata.java b/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/UpdateInstanceMetadata.java index e0acd91878..462d1afca9 100644 --- a/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/UpdateInstanceMetadata.java +++ b/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/UpdateInstanceMetadata.java @@ -50,92 +50,6 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - private UpdateInstanceMetadata( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - com.google.bigtable.admin.v2.PartialUpdateInstanceRequest.Builder subBuilder = null; - if (originalRequest_ != null) { - subBuilder = originalRequest_.toBuilder(); - } - originalRequest_ = - input.readMessage( - com.google.bigtable.admin.v2.PartialUpdateInstanceRequest.parser(), - extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(originalRequest_); - originalRequest_ = subBuilder.buildPartial(); - } - - break; - } - case 18: - { - com.google.protobuf.Timestamp.Builder subBuilder = null; - if (requestTime_ != null) { - subBuilder = requestTime_.toBuilder(); - } - requestTime_ = - input.readMessage(com.google.protobuf.Timestamp.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(requestTime_); - requestTime_ = subBuilder.buildPartial(); - } - - break; - } - case 26: - { - com.google.protobuf.Timestamp.Builder subBuilder = null; - if (finishTime_ != null) { - subBuilder = finishTime_.toBuilder(); - } - finishTime_ = - input.readMessage(com.google.protobuf.Timestamp.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(finishTime_); - finishTime_ = subBuilder.buildPartial(); - } - - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.bigtable.admin.v2.BigtableInstanceAdminProto .internal_static_google_bigtable_admin_v2_UpdateInstanceMetadata_descriptor; @@ -315,7 +229,7 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io if (finishTime_ != null) { output.writeMessage(3, getFinishTime()); } - unknownFields.writeTo(output); + getUnknownFields().writeTo(output); } @java.lang.Override @@ -333,7 +247,7 @@ public int getSerializedSize() { if (finishTime_ != null) { size += com.google.protobuf.CodedOutputStream.computeMessageSize(3, getFinishTime()); } - size += unknownFields.getSerializedSize(); + size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @@ -361,7 +275,7 @@ public boolean equals(final java.lang.Object obj) { if (hasFinishTime()) { if (!getFinishTime().equals(other.getFinishTime())) return false; } - if (!unknownFields.equals(other.unknownFields)) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -384,7 +298,7 @@ public int hashCode() { hash = (37 * hash) + FINISH_TIME_FIELD_NUMBER; hash = (53 * hash) + getFinishTime().hashCode(); } - hash = (29 * hash) + unknownFields.hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } @@ -513,17 +427,10 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { } // Construct using com.google.bigtable.admin.v2.UpdateInstanceMetadata.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } + private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} } @java.lang.Override @@ -648,7 +555,7 @@ public Builder mergeFrom(com.google.bigtable.admin.v2.UpdateInstanceMetadata oth if (other.hasFinishTime()) { mergeFinishTime(other.getFinishTime()); } - this.mergeUnknownFields(other.unknownFields); + this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @@ -663,18 +570,49 @@ public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - com.google.bigtable.admin.v2.UpdateInstanceMetadata parsedMessage = null; + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + input.readMessage(getOriginalRequestFieldBuilder().getBuilder(), extensionRegistry); + + break; + } // case 10 + case 18: + { + input.readMessage(getRequestTimeFieldBuilder().getBuilder(), extensionRegistry); + + break; + } // case 18 + case 26: + { + input.readMessage(getFinishTimeFieldBuilder().getBuilder(), extensionRegistry); + + break; + } // case 26 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = - (com.google.bigtable.admin.v2.UpdateInstanceMetadata) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } + onChanged(); + } // finally return this; } @@ -1268,7 +1206,18 @@ public UpdateInstanceMetadata parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new UpdateInstanceMetadata(input, extensionRegistry); + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); } }; diff --git a/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/UpdateTableMetadata.java b/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/UpdateTableMetadata.java new file mode 100644 index 0000000000..8a951e94b0 --- /dev/null +++ b/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/UpdateTableMetadata.java @@ -0,0 +1,1135 @@ +/* + * Copyright 2020 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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/bigtable/admin/v2/bigtable_table_admin.proto + +package com.google.bigtable.admin.v2; + +/** + * + * + *
+ * Metadata type for the operation returned by
+ * [UpdateTable][google.bigtable.admin.v2.BigtableTableAdmin.UpdateTable].
+ * 
+ * + * Protobuf type {@code google.bigtable.admin.v2.UpdateTableMetadata} + */ +public final class UpdateTableMetadata extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.bigtable.admin.v2.UpdateTableMetadata) + UpdateTableMetadataOrBuilder { + private static final long serialVersionUID = 0L; + // Use UpdateTableMetadata.newBuilder() to construct. + private UpdateTableMetadata(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private UpdateTableMetadata() { + name_ = ""; + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new UpdateTableMetadata(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.bigtable.admin.v2.BigtableTableAdminProto + .internal_static_google_bigtable_admin_v2_UpdateTableMetadata_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.bigtable.admin.v2.BigtableTableAdminProto + .internal_static_google_bigtable_admin_v2_UpdateTableMetadata_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.bigtable.admin.v2.UpdateTableMetadata.class, + com.google.bigtable.admin.v2.UpdateTableMetadata.Builder.class); + } + + public static final int NAME_FIELD_NUMBER = 1; + private volatile java.lang.Object name_; + /** + * + * + *
+   * The name of the table being updated.
+   * 
+ * + * string name = 1; + * + * @return The name. + */ + @java.lang.Override + public java.lang.String getName() { + java.lang.Object ref = name_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + name_ = s; + return s; + } + } + /** + * + * + *
+   * The name of the table being updated.
+   * 
+ * + * string name = 1; + * + * @return The bytes for name. + */ + @java.lang.Override + public com.google.protobuf.ByteString getNameBytes() { + java.lang.Object ref = name_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + name_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int START_TIME_FIELD_NUMBER = 2; + private com.google.protobuf.Timestamp startTime_; + /** + * + * + *
+   * The time at which this operation started.
+   * 
+ * + * .google.protobuf.Timestamp start_time = 2; + * + * @return Whether the startTime field is set. + */ + @java.lang.Override + public boolean hasStartTime() { + return startTime_ != null; + } + /** + * + * + *
+   * The time at which this operation started.
+   * 
+ * + * .google.protobuf.Timestamp start_time = 2; + * + * @return The startTime. + */ + @java.lang.Override + public com.google.protobuf.Timestamp getStartTime() { + return startTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : startTime_; + } + /** + * + * + *
+   * The time at which this operation started.
+   * 
+ * + * .google.protobuf.Timestamp start_time = 2; + */ + @java.lang.Override + public com.google.protobuf.TimestampOrBuilder getStartTimeOrBuilder() { + return getStartTime(); + } + + public static final int END_TIME_FIELD_NUMBER = 3; + private com.google.protobuf.Timestamp endTime_; + /** + * + * + *
+   * If set, the time at which this operation finished or was canceled.
+   * 
+ * + * .google.protobuf.Timestamp end_time = 3; + * + * @return Whether the endTime field is set. + */ + @java.lang.Override + public boolean hasEndTime() { + return endTime_ != null; + } + /** + * + * + *
+   * If set, the time at which this operation finished or was canceled.
+   * 
+ * + * .google.protobuf.Timestamp end_time = 3; + * + * @return The endTime. + */ + @java.lang.Override + public com.google.protobuf.Timestamp getEndTime() { + return endTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : endTime_; + } + /** + * + * + *
+   * If set, the time at which this operation finished or was canceled.
+   * 
+ * + * .google.protobuf.Timestamp end_time = 3; + */ + @java.lang.Override + public com.google.protobuf.TimestampOrBuilder getEndTimeOrBuilder() { + return getEndTime(); + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(name_)) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 1, name_); + } + if (startTime_ != null) { + output.writeMessage(2, getStartTime()); + } + if (endTime_ != null) { + output.writeMessage(3, getEndTime()); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(name_)) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, name_); + } + if (startTime_ != null) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(2, getStartTime()); + } + if (endTime_ != null) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(3, getEndTime()); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.bigtable.admin.v2.UpdateTableMetadata)) { + return super.equals(obj); + } + com.google.bigtable.admin.v2.UpdateTableMetadata other = + (com.google.bigtable.admin.v2.UpdateTableMetadata) obj; + + if (!getName().equals(other.getName())) return false; + if (hasStartTime() != other.hasStartTime()) return false; + if (hasStartTime()) { + if (!getStartTime().equals(other.getStartTime())) return false; + } + if (hasEndTime() != other.hasEndTime()) return false; + if (hasEndTime()) { + if (!getEndTime().equals(other.getEndTime())) return false; + } + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + NAME_FIELD_NUMBER; + hash = (53 * hash) + getName().hashCode(); + if (hasStartTime()) { + hash = (37 * hash) + START_TIME_FIELD_NUMBER; + hash = (53 * hash) + getStartTime().hashCode(); + } + if (hasEndTime()) { + hash = (37 * hash) + END_TIME_FIELD_NUMBER; + hash = (53 * hash) + getEndTime().hashCode(); + } + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.bigtable.admin.v2.UpdateTableMetadata parseFrom(java.nio.ByteBuffer data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.bigtable.admin.v2.UpdateTableMetadata parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.bigtable.admin.v2.UpdateTableMetadata parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.bigtable.admin.v2.UpdateTableMetadata parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.bigtable.admin.v2.UpdateTableMetadata parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.bigtable.admin.v2.UpdateTableMetadata parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.bigtable.admin.v2.UpdateTableMetadata parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.bigtable.admin.v2.UpdateTableMetadata parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.bigtable.admin.v2.UpdateTableMetadata parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.bigtable.admin.v2.UpdateTableMetadata parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.bigtable.admin.v2.UpdateTableMetadata parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.bigtable.admin.v2.UpdateTableMetadata parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder(com.google.bigtable.admin.v2.UpdateTableMetadata prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + /** + * + * + *
+   * Metadata type for the operation returned by
+   * [UpdateTable][google.bigtable.admin.v2.BigtableTableAdmin.UpdateTable].
+   * 
+ * + * Protobuf type {@code google.bigtable.admin.v2.UpdateTableMetadata} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.bigtable.admin.v2.UpdateTableMetadata) + com.google.bigtable.admin.v2.UpdateTableMetadataOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.bigtable.admin.v2.BigtableTableAdminProto + .internal_static_google_bigtable_admin_v2_UpdateTableMetadata_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.bigtable.admin.v2.BigtableTableAdminProto + .internal_static_google_bigtable_admin_v2_UpdateTableMetadata_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.bigtable.admin.v2.UpdateTableMetadata.class, + com.google.bigtable.admin.v2.UpdateTableMetadata.Builder.class); + } + + // Construct using com.google.bigtable.admin.v2.UpdateTableMetadata.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + } + + @java.lang.Override + public Builder clear() { + super.clear(); + name_ = ""; + + if (startTimeBuilder_ == null) { + startTime_ = null; + } else { + startTime_ = null; + startTimeBuilder_ = null; + } + if (endTimeBuilder_ == null) { + endTime_ = null; + } else { + endTime_ = null; + endTimeBuilder_ = null; + } + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.bigtable.admin.v2.BigtableTableAdminProto + .internal_static_google_bigtable_admin_v2_UpdateTableMetadata_descriptor; + } + + @java.lang.Override + public com.google.bigtable.admin.v2.UpdateTableMetadata getDefaultInstanceForType() { + return com.google.bigtable.admin.v2.UpdateTableMetadata.getDefaultInstance(); + } + + @java.lang.Override + public com.google.bigtable.admin.v2.UpdateTableMetadata build() { + com.google.bigtable.admin.v2.UpdateTableMetadata result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.bigtable.admin.v2.UpdateTableMetadata buildPartial() { + com.google.bigtable.admin.v2.UpdateTableMetadata result = + new com.google.bigtable.admin.v2.UpdateTableMetadata(this); + result.name_ = name_; + if (startTimeBuilder_ == null) { + result.startTime_ = startTime_; + } else { + result.startTime_ = startTimeBuilder_.build(); + } + if (endTimeBuilder_ == null) { + result.endTime_ = endTime_; + } else { + result.endTime_ = endTimeBuilder_.build(); + } + onBuilt(); + return result; + } + + @java.lang.Override + public Builder clone() { + return super.clone(); + } + + @java.lang.Override + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.setField(field, value); + } + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); + } + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); + } + + @java.lang.Override + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { + return super.setRepeatedField(field, index, value); + } + + @java.lang.Override + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.addRepeatedField(field, value); + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.bigtable.admin.v2.UpdateTableMetadata) { + return mergeFrom((com.google.bigtable.admin.v2.UpdateTableMetadata) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.bigtable.admin.v2.UpdateTableMetadata other) { + if (other == com.google.bigtable.admin.v2.UpdateTableMetadata.getDefaultInstance()) + return this; + if (!other.getName().isEmpty()) { + name_ = other.name_; + onChanged(); + } + if (other.hasStartTime()) { + mergeStartTime(other.getStartTime()); + } + if (other.hasEndTime()) { + mergeEndTime(other.getEndTime()); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + name_ = input.readStringRequireUtf8(); + + break; + } // case 10 + case 18: + { + input.readMessage(getStartTimeFieldBuilder().getBuilder(), extensionRegistry); + + break; + } // case 18 + case 26: + { + input.readMessage(getEndTimeFieldBuilder().getBuilder(), extensionRegistry); + + break; + } // case 26 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private java.lang.Object name_ = ""; + /** + * + * + *
+     * The name of the table being updated.
+     * 
+ * + * string name = 1; + * + * @return The name. + */ + public java.lang.String getName() { + java.lang.Object ref = name_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + name_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + /** + * + * + *
+     * The name of the table being updated.
+     * 
+ * + * string name = 1; + * + * @return The bytes for name. + */ + public com.google.protobuf.ByteString getNameBytes() { + java.lang.Object ref = name_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + name_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + /** + * + * + *
+     * The name of the table being updated.
+     * 
+ * + * string name = 1; + * + * @param value The name to set. + * @return This builder for chaining. + */ + public Builder setName(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + + name_ = value; + onChanged(); + return this; + } + /** + * + * + *
+     * The name of the table being updated.
+     * 
+ * + * string name = 1; + * + * @return This builder for chaining. + */ + public Builder clearName() { + + name_ = getDefaultInstance().getName(); + onChanged(); + return this; + } + /** + * + * + *
+     * The name of the table being updated.
+     * 
+ * + * string name = 1; + * + * @param value The bytes for name to set. + * @return This builder for chaining. + */ + public Builder setNameBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + + name_ = value; + onChanged(); + return this; + } + + private com.google.protobuf.Timestamp startTime_; + private com.google.protobuf.SingleFieldBuilderV3< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + startTimeBuilder_; + /** + * + * + *
+     * The time at which this operation started.
+     * 
+ * + * .google.protobuf.Timestamp start_time = 2; + * + * @return Whether the startTime field is set. + */ + public boolean hasStartTime() { + return startTimeBuilder_ != null || startTime_ != null; + } + /** + * + * + *
+     * The time at which this operation started.
+     * 
+ * + * .google.protobuf.Timestamp start_time = 2; + * + * @return The startTime. + */ + public com.google.protobuf.Timestamp getStartTime() { + if (startTimeBuilder_ == null) { + return startTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : startTime_; + } else { + return startTimeBuilder_.getMessage(); + } + } + /** + * + * + *
+     * The time at which this operation started.
+     * 
+ * + * .google.protobuf.Timestamp start_time = 2; + */ + public Builder setStartTime(com.google.protobuf.Timestamp value) { + if (startTimeBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + startTime_ = value; + onChanged(); + } else { + startTimeBuilder_.setMessage(value); + } + + return this; + } + /** + * + * + *
+     * The time at which this operation started.
+     * 
+ * + * .google.protobuf.Timestamp start_time = 2; + */ + public Builder setStartTime(com.google.protobuf.Timestamp.Builder builderForValue) { + if (startTimeBuilder_ == null) { + startTime_ = builderForValue.build(); + onChanged(); + } else { + startTimeBuilder_.setMessage(builderForValue.build()); + } + + return this; + } + /** + * + * + *
+     * The time at which this operation started.
+     * 
+ * + * .google.protobuf.Timestamp start_time = 2; + */ + public Builder mergeStartTime(com.google.protobuf.Timestamp value) { + if (startTimeBuilder_ == null) { + if (startTime_ != null) { + startTime_ = + com.google.protobuf.Timestamp.newBuilder(startTime_).mergeFrom(value).buildPartial(); + } else { + startTime_ = value; + } + onChanged(); + } else { + startTimeBuilder_.mergeFrom(value); + } + + return this; + } + /** + * + * + *
+     * The time at which this operation started.
+     * 
+ * + * .google.protobuf.Timestamp start_time = 2; + */ + public Builder clearStartTime() { + if (startTimeBuilder_ == null) { + startTime_ = null; + onChanged(); + } else { + startTime_ = null; + startTimeBuilder_ = null; + } + + return this; + } + /** + * + * + *
+     * The time at which this operation started.
+     * 
+ * + * .google.protobuf.Timestamp start_time = 2; + */ + public com.google.protobuf.Timestamp.Builder getStartTimeBuilder() { + + onChanged(); + return getStartTimeFieldBuilder().getBuilder(); + } + /** + * + * + *
+     * The time at which this operation started.
+     * 
+ * + * .google.protobuf.Timestamp start_time = 2; + */ + public com.google.protobuf.TimestampOrBuilder getStartTimeOrBuilder() { + if (startTimeBuilder_ != null) { + return startTimeBuilder_.getMessageOrBuilder(); + } else { + return startTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : startTime_; + } + } + /** + * + * + *
+     * The time at which this operation started.
+     * 
+ * + * .google.protobuf.Timestamp start_time = 2; + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + getStartTimeFieldBuilder() { + if (startTimeBuilder_ == null) { + startTimeBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder>( + getStartTime(), getParentForChildren(), isClean()); + startTime_ = null; + } + return startTimeBuilder_; + } + + private com.google.protobuf.Timestamp endTime_; + private com.google.protobuf.SingleFieldBuilderV3< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + endTimeBuilder_; + /** + * + * + *
+     * If set, the time at which this operation finished or was canceled.
+     * 
+ * + * .google.protobuf.Timestamp end_time = 3; + * + * @return Whether the endTime field is set. + */ + public boolean hasEndTime() { + return endTimeBuilder_ != null || endTime_ != null; + } + /** + * + * + *
+     * If set, the time at which this operation finished or was canceled.
+     * 
+ * + * .google.protobuf.Timestamp end_time = 3; + * + * @return The endTime. + */ + public com.google.protobuf.Timestamp getEndTime() { + if (endTimeBuilder_ == null) { + return endTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : endTime_; + } else { + return endTimeBuilder_.getMessage(); + } + } + /** + * + * + *
+     * If set, the time at which this operation finished or was canceled.
+     * 
+ * + * .google.protobuf.Timestamp end_time = 3; + */ + public Builder setEndTime(com.google.protobuf.Timestamp value) { + if (endTimeBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + endTime_ = value; + onChanged(); + } else { + endTimeBuilder_.setMessage(value); + } + + return this; + } + /** + * + * + *
+     * If set, the time at which this operation finished or was canceled.
+     * 
+ * + * .google.protobuf.Timestamp end_time = 3; + */ + public Builder setEndTime(com.google.protobuf.Timestamp.Builder builderForValue) { + if (endTimeBuilder_ == null) { + endTime_ = builderForValue.build(); + onChanged(); + } else { + endTimeBuilder_.setMessage(builderForValue.build()); + } + + return this; + } + /** + * + * + *
+     * If set, the time at which this operation finished or was canceled.
+     * 
+ * + * .google.protobuf.Timestamp end_time = 3; + */ + public Builder mergeEndTime(com.google.protobuf.Timestamp value) { + if (endTimeBuilder_ == null) { + if (endTime_ != null) { + endTime_ = + com.google.protobuf.Timestamp.newBuilder(endTime_).mergeFrom(value).buildPartial(); + } else { + endTime_ = value; + } + onChanged(); + } else { + endTimeBuilder_.mergeFrom(value); + } + + return this; + } + /** + * + * + *
+     * If set, the time at which this operation finished or was canceled.
+     * 
+ * + * .google.protobuf.Timestamp end_time = 3; + */ + public Builder clearEndTime() { + if (endTimeBuilder_ == null) { + endTime_ = null; + onChanged(); + } else { + endTime_ = null; + endTimeBuilder_ = null; + } + + return this; + } + /** + * + * + *
+     * If set, the time at which this operation finished or was canceled.
+     * 
+ * + * .google.protobuf.Timestamp end_time = 3; + */ + public com.google.protobuf.Timestamp.Builder getEndTimeBuilder() { + + onChanged(); + return getEndTimeFieldBuilder().getBuilder(); + } + /** + * + * + *
+     * If set, the time at which this operation finished or was canceled.
+     * 
+ * + * .google.protobuf.Timestamp end_time = 3; + */ + public com.google.protobuf.TimestampOrBuilder getEndTimeOrBuilder() { + if (endTimeBuilder_ != null) { + return endTimeBuilder_.getMessageOrBuilder(); + } else { + return endTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : endTime_; + } + } + /** + * + * + *
+     * If set, the time at which this operation finished or was canceled.
+     * 
+ * + * .google.protobuf.Timestamp end_time = 3; + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + getEndTimeFieldBuilder() { + if (endTimeBuilder_ == null) { + endTimeBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder>( + getEndTime(), getParentForChildren(), isClean()); + endTime_ = null; + } + return endTimeBuilder_; + } + + @java.lang.Override + public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFields(unknownFields); + } + + @java.lang.Override + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + // @@protoc_insertion_point(builder_scope:google.bigtable.admin.v2.UpdateTableMetadata) + } + + // @@protoc_insertion_point(class_scope:google.bigtable.admin.v2.UpdateTableMetadata) + private static final com.google.bigtable.admin.v2.UpdateTableMetadata DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.bigtable.admin.v2.UpdateTableMetadata(); + } + + public static com.google.bigtable.admin.v2.UpdateTableMetadata getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public UpdateTableMetadata parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.bigtable.admin.v2.UpdateTableMetadata getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/UpdateTableMetadataOrBuilder.java b/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/UpdateTableMetadataOrBuilder.java new file mode 100644 index 0000000000..734da4bb0d --- /dev/null +++ b/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/UpdateTableMetadataOrBuilder.java @@ -0,0 +1,120 @@ +/* + * Copyright 2020 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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/bigtable/admin/v2/bigtable_table_admin.proto + +package com.google.bigtable.admin.v2; + +public interface UpdateTableMetadataOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.bigtable.admin.v2.UpdateTableMetadata) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * The name of the table being updated.
+   * 
+ * + * string name = 1; + * + * @return The name. + */ + java.lang.String getName(); + /** + * + * + *
+   * The name of the table being updated.
+   * 
+ * + * string name = 1; + * + * @return The bytes for name. + */ + com.google.protobuf.ByteString getNameBytes(); + + /** + * + * + *
+   * The time at which this operation started.
+   * 
+ * + * .google.protobuf.Timestamp start_time = 2; + * + * @return Whether the startTime field is set. + */ + boolean hasStartTime(); + /** + * + * + *
+   * The time at which this operation started.
+   * 
+ * + * .google.protobuf.Timestamp start_time = 2; + * + * @return The startTime. + */ + com.google.protobuf.Timestamp getStartTime(); + /** + * + * + *
+   * The time at which this operation started.
+   * 
+ * + * .google.protobuf.Timestamp start_time = 2; + */ + com.google.protobuf.TimestampOrBuilder getStartTimeOrBuilder(); + + /** + * + * + *
+   * If set, the time at which this operation finished or was canceled.
+   * 
+ * + * .google.protobuf.Timestamp end_time = 3; + * + * @return Whether the endTime field is set. + */ + boolean hasEndTime(); + /** + * + * + *
+   * If set, the time at which this operation finished or was canceled.
+   * 
+ * + * .google.protobuf.Timestamp end_time = 3; + * + * @return The endTime. + */ + com.google.protobuf.Timestamp getEndTime(); + /** + * + * + *
+   * If set, the time at which this operation finished or was canceled.
+   * 
+ * + * .google.protobuf.Timestamp end_time = 3; + */ + com.google.protobuf.TimestampOrBuilder getEndTimeOrBuilder(); +} diff --git a/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/UpdateTableRequest.java b/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/UpdateTableRequest.java new file mode 100644 index 0000000000..b3a21906de --- /dev/null +++ b/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/UpdateTableRequest.java @@ -0,0 +1,1080 @@ +/* + * Copyright 2020 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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/bigtable/admin/v2/bigtable_table_admin.proto + +package com.google.bigtable.admin.v2; + +/** + * + * + *
+ * The request for
+ * [UpdateTable][google.bigtable.admin.v2.BigtableTableAdmin.UpdateTable].
+ * 
+ * + * Protobuf type {@code google.bigtable.admin.v2.UpdateTableRequest} + */ +public final class UpdateTableRequest extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.bigtable.admin.v2.UpdateTableRequest) + UpdateTableRequestOrBuilder { + private static final long serialVersionUID = 0L; + // Use UpdateTableRequest.newBuilder() to construct. + private UpdateTableRequest(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private UpdateTableRequest() {} + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new UpdateTableRequest(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.bigtable.admin.v2.BigtableTableAdminProto + .internal_static_google_bigtable_admin_v2_UpdateTableRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.bigtable.admin.v2.BigtableTableAdminProto + .internal_static_google_bigtable_admin_v2_UpdateTableRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.bigtable.admin.v2.UpdateTableRequest.class, + com.google.bigtable.admin.v2.UpdateTableRequest.Builder.class); + } + + public static final int TABLE_FIELD_NUMBER = 1; + private com.google.bigtable.admin.v2.Table table_; + /** + * + * + *
+   * Required. The table to update.
+   * The table's `name` field is used to identify the table to update.
+   * 
+ * + * .google.bigtable.admin.v2.Table table = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return Whether the table field is set. + */ + @java.lang.Override + public boolean hasTable() { + return table_ != null; + } + /** + * + * + *
+   * Required. The table to update.
+   * The table's `name` field is used to identify the table to update.
+   * 
+ * + * .google.bigtable.admin.v2.Table table = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The table. + */ + @java.lang.Override + public com.google.bigtable.admin.v2.Table getTable() { + return table_ == null ? com.google.bigtable.admin.v2.Table.getDefaultInstance() : table_; + } + /** + * + * + *
+   * Required. The table to update.
+   * The table's `name` field is used to identify the table to update.
+   * 
+ * + * .google.bigtable.admin.v2.Table table = 1 [(.google.api.field_behavior) = REQUIRED]; + * + */ + @java.lang.Override + public com.google.bigtable.admin.v2.TableOrBuilder getTableOrBuilder() { + return getTable(); + } + + public static final int UPDATE_MASK_FIELD_NUMBER = 2; + private com.google.protobuf.FieldMask updateMask_; + /** + * + * + *
+   * Required. The list of fields to update.
+   * A mask specifying which fields (e.g. `deletion_protection`) in the `table`
+   * field should be updated. This mask is relative to the `table` field, not to
+   * the request message. The wildcard (*) path is currently not supported.
+   * Currently UpdateTable is only supported for the following field:
+   *  * `deletion_protection`
+   * If `column_families` is set in `update_mask`, it will return an
+   * UNIMPLEMENTED error.
+   * 
+ * + * .google.protobuf.FieldMask update_mask = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return Whether the updateMask field is set. + */ + @java.lang.Override + public boolean hasUpdateMask() { + return updateMask_ != null; + } + /** + * + * + *
+   * Required. The list of fields to update.
+   * A mask specifying which fields (e.g. `deletion_protection`) in the `table`
+   * field should be updated. This mask is relative to the `table` field, not to
+   * the request message. The wildcard (*) path is currently not supported.
+   * Currently UpdateTable is only supported for the following field:
+   *  * `deletion_protection`
+   * If `column_families` is set in `update_mask`, it will return an
+   * UNIMPLEMENTED error.
+   * 
+ * + * .google.protobuf.FieldMask update_mask = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The updateMask. + */ + @java.lang.Override + public com.google.protobuf.FieldMask getUpdateMask() { + return updateMask_ == null ? com.google.protobuf.FieldMask.getDefaultInstance() : updateMask_; + } + /** + * + * + *
+   * Required. The list of fields to update.
+   * A mask specifying which fields (e.g. `deletion_protection`) in the `table`
+   * field should be updated. This mask is relative to the `table` field, not to
+   * the request message. The wildcard (*) path is currently not supported.
+   * Currently UpdateTable is only supported for the following field:
+   *  * `deletion_protection`
+   * If `column_families` is set in `update_mask`, it will return an
+   * UNIMPLEMENTED error.
+   * 
+ * + * .google.protobuf.FieldMask update_mask = 2 [(.google.api.field_behavior) = REQUIRED]; + * + */ + @java.lang.Override + public com.google.protobuf.FieldMaskOrBuilder getUpdateMaskOrBuilder() { + return getUpdateMask(); + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (table_ != null) { + output.writeMessage(1, getTable()); + } + if (updateMask_ != null) { + output.writeMessage(2, getUpdateMask()); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (table_ != null) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(1, getTable()); + } + if (updateMask_ != null) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(2, getUpdateMask()); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.bigtable.admin.v2.UpdateTableRequest)) { + return super.equals(obj); + } + com.google.bigtable.admin.v2.UpdateTableRequest other = + (com.google.bigtable.admin.v2.UpdateTableRequest) obj; + + if (hasTable() != other.hasTable()) return false; + if (hasTable()) { + if (!getTable().equals(other.getTable())) return false; + } + if (hasUpdateMask() != other.hasUpdateMask()) return false; + if (hasUpdateMask()) { + if (!getUpdateMask().equals(other.getUpdateMask())) return false; + } + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + if (hasTable()) { + hash = (37 * hash) + TABLE_FIELD_NUMBER; + hash = (53 * hash) + getTable().hashCode(); + } + if (hasUpdateMask()) { + hash = (37 * hash) + UPDATE_MASK_FIELD_NUMBER; + hash = (53 * hash) + getUpdateMask().hashCode(); + } + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.bigtable.admin.v2.UpdateTableRequest parseFrom(java.nio.ByteBuffer data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.bigtable.admin.v2.UpdateTableRequest parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.bigtable.admin.v2.UpdateTableRequest parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.bigtable.admin.v2.UpdateTableRequest parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.bigtable.admin.v2.UpdateTableRequest parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.bigtable.admin.v2.UpdateTableRequest parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.bigtable.admin.v2.UpdateTableRequest parseFrom(java.io.InputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.bigtable.admin.v2.UpdateTableRequest parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.bigtable.admin.v2.UpdateTableRequest parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.bigtable.admin.v2.UpdateTableRequest parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.bigtable.admin.v2.UpdateTableRequest parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.bigtable.admin.v2.UpdateTableRequest parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder(com.google.bigtable.admin.v2.UpdateTableRequest prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + /** + * + * + *
+   * The request for
+   * [UpdateTable][google.bigtable.admin.v2.BigtableTableAdmin.UpdateTable].
+   * 
+ * + * Protobuf type {@code google.bigtable.admin.v2.UpdateTableRequest} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.bigtable.admin.v2.UpdateTableRequest) + com.google.bigtable.admin.v2.UpdateTableRequestOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.bigtable.admin.v2.BigtableTableAdminProto + .internal_static_google_bigtable_admin_v2_UpdateTableRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.bigtable.admin.v2.BigtableTableAdminProto + .internal_static_google_bigtable_admin_v2_UpdateTableRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.bigtable.admin.v2.UpdateTableRequest.class, + com.google.bigtable.admin.v2.UpdateTableRequest.Builder.class); + } + + // Construct using com.google.bigtable.admin.v2.UpdateTableRequest.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + } + + @java.lang.Override + public Builder clear() { + super.clear(); + if (tableBuilder_ == null) { + table_ = null; + } else { + table_ = null; + tableBuilder_ = null; + } + if (updateMaskBuilder_ == null) { + updateMask_ = null; + } else { + updateMask_ = null; + updateMaskBuilder_ = null; + } + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.bigtable.admin.v2.BigtableTableAdminProto + .internal_static_google_bigtable_admin_v2_UpdateTableRequest_descriptor; + } + + @java.lang.Override + public com.google.bigtable.admin.v2.UpdateTableRequest getDefaultInstanceForType() { + return com.google.bigtable.admin.v2.UpdateTableRequest.getDefaultInstance(); + } + + @java.lang.Override + public com.google.bigtable.admin.v2.UpdateTableRequest build() { + com.google.bigtable.admin.v2.UpdateTableRequest result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.bigtable.admin.v2.UpdateTableRequest buildPartial() { + com.google.bigtable.admin.v2.UpdateTableRequest result = + new com.google.bigtable.admin.v2.UpdateTableRequest(this); + if (tableBuilder_ == null) { + result.table_ = table_; + } else { + result.table_ = tableBuilder_.build(); + } + if (updateMaskBuilder_ == null) { + result.updateMask_ = updateMask_; + } else { + result.updateMask_ = updateMaskBuilder_.build(); + } + onBuilt(); + return result; + } + + @java.lang.Override + public Builder clone() { + return super.clone(); + } + + @java.lang.Override + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.setField(field, value); + } + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); + } + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); + } + + @java.lang.Override + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { + return super.setRepeatedField(field, index, value); + } + + @java.lang.Override + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.addRepeatedField(field, value); + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.bigtable.admin.v2.UpdateTableRequest) { + return mergeFrom((com.google.bigtable.admin.v2.UpdateTableRequest) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.bigtable.admin.v2.UpdateTableRequest other) { + if (other == com.google.bigtable.admin.v2.UpdateTableRequest.getDefaultInstance()) + return this; + if (other.hasTable()) { + mergeTable(other.getTable()); + } + if (other.hasUpdateMask()) { + mergeUpdateMask(other.getUpdateMask()); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + input.readMessage(getTableFieldBuilder().getBuilder(), extensionRegistry); + + break; + } // case 10 + case 18: + { + input.readMessage(getUpdateMaskFieldBuilder().getBuilder(), extensionRegistry); + + break; + } // case 18 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private com.google.bigtable.admin.v2.Table table_; + private com.google.protobuf.SingleFieldBuilderV3< + com.google.bigtable.admin.v2.Table, + com.google.bigtable.admin.v2.Table.Builder, + com.google.bigtable.admin.v2.TableOrBuilder> + tableBuilder_; + /** + * + * + *
+     * Required. The table to update.
+     * The table's `name` field is used to identify the table to update.
+     * 
+ * + * .google.bigtable.admin.v2.Table table = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return Whether the table field is set. + */ + public boolean hasTable() { + return tableBuilder_ != null || table_ != null; + } + /** + * + * + *
+     * Required. The table to update.
+     * The table's `name` field is used to identify the table to update.
+     * 
+ * + * .google.bigtable.admin.v2.Table table = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The table. + */ + public com.google.bigtable.admin.v2.Table getTable() { + if (tableBuilder_ == null) { + return table_ == null ? com.google.bigtable.admin.v2.Table.getDefaultInstance() : table_; + } else { + return tableBuilder_.getMessage(); + } + } + /** + * + * + *
+     * Required. The table to update.
+     * The table's `name` field is used to identify the table to update.
+     * 
+ * + * .google.bigtable.admin.v2.Table table = 1 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder setTable(com.google.bigtable.admin.v2.Table value) { + if (tableBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + table_ = value; + onChanged(); + } else { + tableBuilder_.setMessage(value); + } + + return this; + } + /** + * + * + *
+     * Required. The table to update.
+     * The table's `name` field is used to identify the table to update.
+     * 
+ * + * .google.bigtable.admin.v2.Table table = 1 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder setTable(com.google.bigtable.admin.v2.Table.Builder builderForValue) { + if (tableBuilder_ == null) { + table_ = builderForValue.build(); + onChanged(); + } else { + tableBuilder_.setMessage(builderForValue.build()); + } + + return this; + } + /** + * + * + *
+     * Required. The table to update.
+     * The table's `name` field is used to identify the table to update.
+     * 
+ * + * .google.bigtable.admin.v2.Table table = 1 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder mergeTable(com.google.bigtable.admin.v2.Table value) { + if (tableBuilder_ == null) { + if (table_ != null) { + table_ = + com.google.bigtable.admin.v2.Table.newBuilder(table_).mergeFrom(value).buildPartial(); + } else { + table_ = value; + } + onChanged(); + } else { + tableBuilder_.mergeFrom(value); + } + + return this; + } + /** + * + * + *
+     * Required. The table to update.
+     * The table's `name` field is used to identify the table to update.
+     * 
+ * + * .google.bigtable.admin.v2.Table table = 1 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder clearTable() { + if (tableBuilder_ == null) { + table_ = null; + onChanged(); + } else { + table_ = null; + tableBuilder_ = null; + } + + return this; + } + /** + * + * + *
+     * Required. The table to update.
+     * The table's `name` field is used to identify the table to update.
+     * 
+ * + * .google.bigtable.admin.v2.Table table = 1 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public com.google.bigtable.admin.v2.Table.Builder getTableBuilder() { + + onChanged(); + return getTableFieldBuilder().getBuilder(); + } + /** + * + * + *
+     * Required. The table to update.
+     * The table's `name` field is used to identify the table to update.
+     * 
+ * + * .google.bigtable.admin.v2.Table table = 1 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public com.google.bigtable.admin.v2.TableOrBuilder getTableOrBuilder() { + if (tableBuilder_ != null) { + return tableBuilder_.getMessageOrBuilder(); + } else { + return table_ == null ? com.google.bigtable.admin.v2.Table.getDefaultInstance() : table_; + } + } + /** + * + * + *
+     * Required. The table to update.
+     * The table's `name` field is used to identify the table to update.
+     * 
+ * + * .google.bigtable.admin.v2.Table table = 1 [(.google.api.field_behavior) = REQUIRED]; + * + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.bigtable.admin.v2.Table, + com.google.bigtable.admin.v2.Table.Builder, + com.google.bigtable.admin.v2.TableOrBuilder> + getTableFieldBuilder() { + if (tableBuilder_ == null) { + tableBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.bigtable.admin.v2.Table, + com.google.bigtable.admin.v2.Table.Builder, + com.google.bigtable.admin.v2.TableOrBuilder>( + getTable(), getParentForChildren(), isClean()); + table_ = null; + } + return tableBuilder_; + } + + private com.google.protobuf.FieldMask updateMask_; + private com.google.protobuf.SingleFieldBuilderV3< + com.google.protobuf.FieldMask, + com.google.protobuf.FieldMask.Builder, + com.google.protobuf.FieldMaskOrBuilder> + updateMaskBuilder_; + /** + * + * + *
+     * Required. The list of fields to update.
+     * A mask specifying which fields (e.g. `deletion_protection`) in the `table`
+     * field should be updated. This mask is relative to the `table` field, not to
+     * the request message. The wildcard (*) path is currently not supported.
+     * Currently UpdateTable is only supported for the following field:
+     *  * `deletion_protection`
+     * If `column_families` is set in `update_mask`, it will return an
+     * UNIMPLEMENTED error.
+     * 
+ * + * .google.protobuf.FieldMask update_mask = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return Whether the updateMask field is set. + */ + public boolean hasUpdateMask() { + return updateMaskBuilder_ != null || updateMask_ != null; + } + /** + * + * + *
+     * Required. The list of fields to update.
+     * A mask specifying which fields (e.g. `deletion_protection`) in the `table`
+     * field should be updated. This mask is relative to the `table` field, not to
+     * the request message. The wildcard (*) path is currently not supported.
+     * Currently UpdateTable is only supported for the following field:
+     *  * `deletion_protection`
+     * If `column_families` is set in `update_mask`, it will return an
+     * UNIMPLEMENTED error.
+     * 
+ * + * .google.protobuf.FieldMask update_mask = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The updateMask. + */ + public com.google.protobuf.FieldMask getUpdateMask() { + if (updateMaskBuilder_ == null) { + return updateMask_ == null + ? com.google.protobuf.FieldMask.getDefaultInstance() + : updateMask_; + } else { + return updateMaskBuilder_.getMessage(); + } + } + /** + * + * + *
+     * Required. The list of fields to update.
+     * A mask specifying which fields (e.g. `deletion_protection`) in the `table`
+     * field should be updated. This mask is relative to the `table` field, not to
+     * the request message. The wildcard (*) path is currently not supported.
+     * Currently UpdateTable is only supported for the following field:
+     *  * `deletion_protection`
+     * If `column_families` is set in `update_mask`, it will return an
+     * UNIMPLEMENTED error.
+     * 
+ * + * .google.protobuf.FieldMask update_mask = 2 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder setUpdateMask(com.google.protobuf.FieldMask value) { + if (updateMaskBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + updateMask_ = value; + onChanged(); + } else { + updateMaskBuilder_.setMessage(value); + } + + return this; + } + /** + * + * + *
+     * Required. The list of fields to update.
+     * A mask specifying which fields (e.g. `deletion_protection`) in the `table`
+     * field should be updated. This mask is relative to the `table` field, not to
+     * the request message. The wildcard (*) path is currently not supported.
+     * Currently UpdateTable is only supported for the following field:
+     *  * `deletion_protection`
+     * If `column_families` is set in `update_mask`, it will return an
+     * UNIMPLEMENTED error.
+     * 
+ * + * .google.protobuf.FieldMask update_mask = 2 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder setUpdateMask(com.google.protobuf.FieldMask.Builder builderForValue) { + if (updateMaskBuilder_ == null) { + updateMask_ = builderForValue.build(); + onChanged(); + } else { + updateMaskBuilder_.setMessage(builderForValue.build()); + } + + return this; + } + /** + * + * + *
+     * Required. The list of fields to update.
+     * A mask specifying which fields (e.g. `deletion_protection`) in the `table`
+     * field should be updated. This mask is relative to the `table` field, not to
+     * the request message. The wildcard (*) path is currently not supported.
+     * Currently UpdateTable is only supported for the following field:
+     *  * `deletion_protection`
+     * If `column_families` is set in `update_mask`, it will return an
+     * UNIMPLEMENTED error.
+     * 
+ * + * .google.protobuf.FieldMask update_mask = 2 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder mergeUpdateMask(com.google.protobuf.FieldMask value) { + if (updateMaskBuilder_ == null) { + if (updateMask_ != null) { + updateMask_ = + com.google.protobuf.FieldMask.newBuilder(updateMask_).mergeFrom(value).buildPartial(); + } else { + updateMask_ = value; + } + onChanged(); + } else { + updateMaskBuilder_.mergeFrom(value); + } + + return this; + } + /** + * + * + *
+     * Required. The list of fields to update.
+     * A mask specifying which fields (e.g. `deletion_protection`) in the `table`
+     * field should be updated. This mask is relative to the `table` field, not to
+     * the request message. The wildcard (*) path is currently not supported.
+     * Currently UpdateTable is only supported for the following field:
+     *  * `deletion_protection`
+     * If `column_families` is set in `update_mask`, it will return an
+     * UNIMPLEMENTED error.
+     * 
+ * + * .google.protobuf.FieldMask update_mask = 2 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder clearUpdateMask() { + if (updateMaskBuilder_ == null) { + updateMask_ = null; + onChanged(); + } else { + updateMask_ = null; + updateMaskBuilder_ = null; + } + + return this; + } + /** + * + * + *
+     * Required. The list of fields to update.
+     * A mask specifying which fields (e.g. `deletion_protection`) in the `table`
+     * field should be updated. This mask is relative to the `table` field, not to
+     * the request message. The wildcard (*) path is currently not supported.
+     * Currently UpdateTable is only supported for the following field:
+     *  * `deletion_protection`
+     * If `column_families` is set in `update_mask`, it will return an
+     * UNIMPLEMENTED error.
+     * 
+ * + * .google.protobuf.FieldMask update_mask = 2 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public com.google.protobuf.FieldMask.Builder getUpdateMaskBuilder() { + + onChanged(); + return getUpdateMaskFieldBuilder().getBuilder(); + } + /** + * + * + *
+     * Required. The list of fields to update.
+     * A mask specifying which fields (e.g. `deletion_protection`) in the `table`
+     * field should be updated. This mask is relative to the `table` field, not to
+     * the request message. The wildcard (*) path is currently not supported.
+     * Currently UpdateTable is only supported for the following field:
+     *  * `deletion_protection`
+     * If `column_families` is set in `update_mask`, it will return an
+     * UNIMPLEMENTED error.
+     * 
+ * + * .google.protobuf.FieldMask update_mask = 2 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public com.google.protobuf.FieldMaskOrBuilder getUpdateMaskOrBuilder() { + if (updateMaskBuilder_ != null) { + return updateMaskBuilder_.getMessageOrBuilder(); + } else { + return updateMask_ == null + ? com.google.protobuf.FieldMask.getDefaultInstance() + : updateMask_; + } + } + /** + * + * + *
+     * Required. The list of fields to update.
+     * A mask specifying which fields (e.g. `deletion_protection`) in the `table`
+     * field should be updated. This mask is relative to the `table` field, not to
+     * the request message. The wildcard (*) path is currently not supported.
+     * Currently UpdateTable is only supported for the following field:
+     *  * `deletion_protection`
+     * If `column_families` is set in `update_mask`, it will return an
+     * UNIMPLEMENTED error.
+     * 
+ * + * .google.protobuf.FieldMask update_mask = 2 [(.google.api.field_behavior) = REQUIRED]; + * + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.protobuf.FieldMask, + com.google.protobuf.FieldMask.Builder, + com.google.protobuf.FieldMaskOrBuilder> + getUpdateMaskFieldBuilder() { + if (updateMaskBuilder_ == null) { + updateMaskBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.protobuf.FieldMask, + com.google.protobuf.FieldMask.Builder, + com.google.protobuf.FieldMaskOrBuilder>( + getUpdateMask(), getParentForChildren(), isClean()); + updateMask_ = null; + } + return updateMaskBuilder_; + } + + @java.lang.Override + public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFields(unknownFields); + } + + @java.lang.Override + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + // @@protoc_insertion_point(builder_scope:google.bigtable.admin.v2.UpdateTableRequest) + } + + // @@protoc_insertion_point(class_scope:google.bigtable.admin.v2.UpdateTableRequest) + private static final com.google.bigtable.admin.v2.UpdateTableRequest DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.bigtable.admin.v2.UpdateTableRequest(); + } + + public static com.google.bigtable.admin.v2.UpdateTableRequest getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public UpdateTableRequest parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.bigtable.admin.v2.UpdateTableRequest getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/UpdateTableRequestOrBuilder.java b/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/UpdateTableRequestOrBuilder.java new file mode 100644 index 0000000000..3ded387418 --- /dev/null +++ b/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/UpdateTableRequestOrBuilder.java @@ -0,0 +1,125 @@ +/* + * Copyright 2020 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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/bigtable/admin/v2/bigtable_table_admin.proto + +package com.google.bigtable.admin.v2; + +public interface UpdateTableRequestOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.bigtable.admin.v2.UpdateTableRequest) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * Required. The table to update.
+   * The table's `name` field is used to identify the table to update.
+   * 
+ * + * .google.bigtable.admin.v2.Table table = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return Whether the table field is set. + */ + boolean hasTable(); + /** + * + * + *
+   * Required. The table to update.
+   * The table's `name` field is used to identify the table to update.
+   * 
+ * + * .google.bigtable.admin.v2.Table table = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The table. + */ + com.google.bigtable.admin.v2.Table getTable(); + /** + * + * + *
+   * Required. The table to update.
+   * The table's `name` field is used to identify the table to update.
+   * 
+ * + * .google.bigtable.admin.v2.Table table = 1 [(.google.api.field_behavior) = REQUIRED]; + * + */ + com.google.bigtable.admin.v2.TableOrBuilder getTableOrBuilder(); + + /** + * + * + *
+   * Required. The list of fields to update.
+   * A mask specifying which fields (e.g. `deletion_protection`) in the `table`
+   * field should be updated. This mask is relative to the `table` field, not to
+   * the request message. The wildcard (*) path is currently not supported.
+   * Currently UpdateTable is only supported for the following field:
+   *  * `deletion_protection`
+   * If `column_families` is set in `update_mask`, it will return an
+   * UNIMPLEMENTED error.
+   * 
+ * + * .google.protobuf.FieldMask update_mask = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return Whether the updateMask field is set. + */ + boolean hasUpdateMask(); + /** + * + * + *
+   * Required. The list of fields to update.
+   * A mask specifying which fields (e.g. `deletion_protection`) in the `table`
+   * field should be updated. This mask is relative to the `table` field, not to
+   * the request message. The wildcard (*) path is currently not supported.
+   * Currently UpdateTable is only supported for the following field:
+   *  * `deletion_protection`
+   * If `column_families` is set in `update_mask`, it will return an
+   * UNIMPLEMENTED error.
+   * 
+ * + * .google.protobuf.FieldMask update_mask = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The updateMask. + */ + com.google.protobuf.FieldMask getUpdateMask(); + /** + * + * + *
+   * Required. The list of fields to update.
+   * A mask specifying which fields (e.g. `deletion_protection`) in the `table`
+   * field should be updated. This mask is relative to the `table` field, not to
+   * the request message. The wildcard (*) path is currently not supported.
+   * Currently UpdateTable is only supported for the following field:
+   *  * `deletion_protection`
+   * If `column_families` is set in `update_mask`, it will return an
+   * UNIMPLEMENTED error.
+   * 
+ * + * .google.protobuf.FieldMask update_mask = 2 [(.google.api.field_behavior) = REQUIRED]; + * + */ + com.google.protobuf.FieldMaskOrBuilder getUpdateMaskOrBuilder(); +} diff --git a/proto-google-cloud-bigtable-admin-v2/src/main/proto/google/bigtable/admin/v2/bigtable_table_admin.proto b/proto-google-cloud-bigtable-admin-v2/src/main/proto/google/bigtable/admin/v2/bigtable_table_admin.proto index 92b9f690b2..6a2d9eac95 100644 --- a/proto-google-cloud-bigtable-admin-v2/src/main/proto/google/bigtable/admin/v2/bigtable_table_admin.proto +++ b/proto-google-cloud-bigtable-admin-v2/src/main/proto/google/bigtable/admin/v2/bigtable_table_admin.proto @@ -100,6 +100,19 @@ service BigtableTableAdmin { option (google.api.method_signature) = "name"; } + // Updates a specified table. + rpc UpdateTable(UpdateTableRequest) returns (google.longrunning.Operation) { + option (google.api.http) = { + patch: "/v2/{table.name=projects/*/instances/*/tables/*}" + body: "table" + }; + option (google.api.method_signature) = "table,update_mask"; + option (google.longrunning.operation_info) = { + response_type: "Table" + metadata_type: "UpdateTableMetadata" + }; + } + // Permanently deletes a specified table and all of its data. rpc DeleteTable(DeleteTableRequest) returns (google.protobuf.Empty) { option (google.api.http) = { @@ -579,6 +592,38 @@ message GetTableRequest { Table.View view = 2; } +// The request for +// [UpdateTable][google.bigtable.admin.v2.BigtableTableAdmin.UpdateTable]. +message UpdateTableRequest { + // Required. The table to update. + // The table's `name` field is used to identify the table to update. + Table table = 1 [(google.api.field_behavior) = REQUIRED]; + + // Required. The list of fields to update. + // A mask specifying which fields (e.g. `deletion_protection`) in the `table` + // field should be updated. This mask is relative to the `table` field, not to + // the request message. The wildcard (*) path is currently not supported. + // Currently UpdateTable is only supported for the following field: + // * `deletion_protection` + // If `column_families` is set in `update_mask`, it will return an + // UNIMPLEMENTED error. + google.protobuf.FieldMask update_mask = 2 + [(google.api.field_behavior) = REQUIRED]; +} + +// Metadata type for the operation returned by +// [UpdateTable][google.bigtable.admin.v2.BigtableTableAdmin.UpdateTable]. +message UpdateTableMetadata { + // The name of the table being updated. + string name = 1; + + // The time at which this operation started. + google.protobuf.Timestamp start_time = 2; + + // If set, the time at which this operation finished or was canceled. + google.protobuf.Timestamp end_time = 3; +} + // Request message for // [google.bigtable.admin.v2.BigtableTableAdmin.DeleteTable][google.bigtable.admin.v2.BigtableTableAdmin.DeleteTable] message DeleteTableRequest { diff --git a/proto-google-cloud-bigtable-admin-v2/src/main/proto/google/bigtable/admin/v2/instance.proto b/proto-google-cloud-bigtable-admin-v2/src/main/proto/google/bigtable/admin/v2/instance.proto index 4dbbbbbfc4..e7e73e00f2 100644 --- a/proto-google-cloud-bigtable-admin-v2/src/main/proto/google/bigtable/admin/v2/instance.proto +++ b/proto-google-cloud-bigtable-admin-v2/src/main/proto/google/bigtable/admin/v2/instance.proto @@ -106,6 +106,9 @@ message Instance { // For instances created before this field was added (August 2021), this value // is `seconds: 0, nanos: 1`. google.protobuf.Timestamp create_time = 7 [(google.api.field_behavior) = OUTPUT_ONLY]; + + // Output only. Reserved for future use. + optional bool satisfies_pzs = 8 [(google.api.field_behavior) = OUTPUT_ONLY]; } // The Autoscaling targets for a Cluster. These determine the recommended nodes. diff --git a/proto-google-cloud-bigtable-admin-v2/src/main/proto/google/bigtable/admin/v2/table.proto b/proto-google-cloud-bigtable-admin-v2/src/main/proto/google/bigtable/admin/v2/table.proto index 4e5d2a4a72..5a59fd203d 100644 --- a/proto-google-cloud-bigtable-admin-v2/src/main/proto/google/bigtable/admin/v2/table.proto +++ b/proto-google-cloud-bigtable-admin-v2/src/main/proto/google/bigtable/admin/v2/table.proto @@ -156,6 +156,14 @@ message Table { // Output only. If this table was restored from another data source (e.g. a backup), this // field will be populated with information about the restore. RestoreInfo restore_info = 6 [(google.api.field_behavior) = OUTPUT_ONLY]; + + // Set to true to make the table protected against data loss. i.e. deleting + // the following resources through Admin APIs are prohibited: + // - The table. + // - The column families in the table. + // - The instance containing the table. + // Note one can still delete the data stored in the table through Data APIs. + bool deletion_protection = 9; } // A set of columns within a table which share a common configuration. diff --git a/proto-google-cloud-bigtable-v2/clirr-ignored-differences.xml b/proto-google-cloud-bigtable-v2/clirr-ignored-differences.xml index 0259e4ee6e..3dc1fb98dc 100644 --- a/proto-google-cloud-bigtable-v2/clirr-ignored-differences.xml +++ b/proto-google-cloud-bigtable-v2/clirr-ignored-differences.xml @@ -4,6 +4,65 @@ 7012 com/google/bigtable/v2/*OrBuilder - * has*(*) + * get*(*) + + + 7012 + com/google/bigtable/v2/*OrBuilder + boolean contains*(*) + + + 7012 + com/google/bigtable/v2/*OrBuilder + boolean has*(*) + + + + + + 7002 + com/google/bigtable/v2/RequestStats* + ** + + + 8001 + com/google/bigtable/v2/AllReadStats* + + + 8001 + com/google/bigtable/v2/ReadEfficiencyStats* + + + 8001 + com/google/bigtable/v2/ReadIteratorStats* + + + 8001 + com/google/bigtable/v2/RequestStats$StatsCase + + + 6001 + com/google/bigtable/v2/ReadRowsRequest$RequestStatsView + REQUEST_STATS_EFFICIENCY + + + 6011 + com/google/bigtable/v2/ReadRowsRequest$RequestStatsView + REQUEST_STATS_EFFICIENCY_VALUE + + + 6011 + com/google/bigtable/v2/RequestStats + ALL_READ_STATS_FIELD_NUMBER + + + 6011 + com/google/bigtable/v2/RequestStats + READ_EFFICIENCY_STATS_FIELD_NUMBER + + + 6003 + com/google/bigtable/v2/ReadRowsRequest$RequestStatsView + REQUEST_STATS_FULL_VALUE \ No newline at end of file diff --git a/proto-google-cloud-bigtable-v2/pom.xml b/proto-google-cloud-bigtable-v2/pom.xml index 42f7b20c96..cf7f5a352c 100644 --- a/proto-google-cloud-bigtable-v2/pom.xml +++ b/proto-google-cloud-bigtable-v2/pom.xml @@ -4,13 +4,13 @@ 4.0.0 com.google.api.grpc proto-google-cloud-bigtable-v2 - 2.11.2-SNAPSHOT + 2.17.1-SNAPSHOT proto-google-cloud-bigtable-v2 PROTO library for proto-google-cloud-bigtable-v2 com.google.cloud google-cloud-bigtable-parent - 2.11.2-SNAPSHOT + 2.17.1-SNAPSHOT @@ -18,14 +18,14 @@ com.google.cloud google-cloud-bigtable-deps-bom - 2.11.2-SNAPSHOT + 2.17.1-SNAPSHOT pom import com.google.cloud google-cloud-bigtable-bom - 2.11.2-SNAPSHOT + 2.17.1-SNAPSHOT pom import diff --git a/proto-google-cloud-bigtable-v2/src/main/java/com/google/bigtable/v2/BigtableProto.java b/proto-google-cloud-bigtable-v2/src/main/java/com/google/bigtable/v2/BigtableProto.java index 5de4d1ecd5..8cb7595eee 100644 --- a/proto-google-cloud-bigtable-v2/src/main/java/com/google/bigtable/v2/BigtableProto.java +++ b/proto-google-cloud-bigtable-v2/src/main/java/com/google/bigtable/v2/BigtableProto.java @@ -145,200 +145,207 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "proto\032\027google/api/client.proto\032\037google/a" + "pi/field_behavior.proto\032\031google/api/reso" + "urce.proto\032\030google/api/routing.proto\032\035go" - + "ogle/bigtable/v2/data.proto\032\036google/prot" + + "ogle/bigtable/v2/data.proto\032&google/bigt" + + "able/v2/request_stats.proto\032\036google/prot" + "obuf/duration.proto\032\037google/protobuf/tim" + "estamp.proto\032\036google/protobuf/wrappers.p" - + "roto\032\027google/rpc/status.proto\"\326\001\n\017ReadRo" + + "roto\032\027google/rpc/status.proto\"\220\003\n\017ReadRo" + "wsRequest\022>\n\ntable_name\030\001 \001(\tB*\340A\002\372A$\n\"b" + "igtableadmin.googleapis.com/Table\022\026\n\016app" + "_profile_id\030\005 \001(\t\022(\n\004rows\030\002 \001(\0132\032.google" + ".bigtable.v2.RowSet\022-\n\006filter\030\003 \001(\0132\035.go" + "ogle.bigtable.v2.RowFilter\022\022\n\nrows_limit" - + "\030\004 \001(\003\"\370\002\n\020ReadRowsResponse\022>\n\006chunks\030\001 " - + "\003(\0132..google.bigtable.v2.ReadRowsRespons" - + "e.CellChunk\022\034\n\024last_scanned_row_key\030\002 \001(" - + "\014\032\205\002\n\tCellChunk\022\017\n\007row_key\030\001 \001(\014\0221\n\013fami" - + "ly_name\030\002 \001(\0132\034.google.protobuf.StringVa" - + "lue\022.\n\tqualifier\030\003 \001(\0132\033.google.protobuf" - + ".BytesValue\022\030\n\020timestamp_micros\030\004 \001(\003\022\016\n" - + "\006labels\030\005 \003(\t\022\r\n\005value\030\006 \001(\014\022\022\n\nvalue_si" - + "ze\030\007 \001(\005\022\023\n\treset_row\030\010 \001(\010H\000\022\024\n\ncommit_" - + "row\030\t \001(\010H\000B\014\n\nrow_status\"n\n\024SampleRowKe" - + "ysRequest\022>\n\ntable_name\030\001 \001(\tB*\340A\002\372A$\n\"b" - + "igtableadmin.googleapis.com/Table\022\026\n\016app" - + "_profile_id\030\002 \001(\t\">\n\025SampleRowKeysRespon" - + "se\022\017\n\007row_key\030\001 \001(\014\022\024\n\014offset_bytes\030\002 \001(" - + "\003\"\266\001\n\020MutateRowRequest\022>\n\ntable_name\030\001 \001" + + "\030\004 \001(\003\022P\n\022request_stats_view\030\006 \001(\01624.goo" + + "gle.bigtable.v2.ReadRowsRequest.RequestS" + + "tatsView\"f\n\020RequestStatsView\022\"\n\036REQUEST_" + + "STATS_VIEW_UNSPECIFIED\020\000\022\026\n\022REQUEST_STAT" + + "S_NONE\020\001\022\026\n\022REQUEST_STATS_FULL\020\002\"\261\003\n\020Rea" + + "dRowsResponse\022>\n\006chunks\030\001 \003(\0132..google.b" + + "igtable.v2.ReadRowsResponse.CellChunk\022\034\n" + + "\024last_scanned_row_key\030\002 \001(\014\0227\n\rrequest_s" + + "tats\030\003 \001(\0132 .google.bigtable.v2.RequestS" + + "tats\032\205\002\n\tCellChunk\022\017\n\007row_key\030\001 \001(\014\0221\n\013f" + + "amily_name\030\002 \001(\0132\034.google.protobuf.Strin" + + "gValue\022.\n\tqualifier\030\003 \001(\0132\033.google.proto" + + "buf.BytesValue\022\030\n\020timestamp_micros\030\004 \001(\003" + + "\022\016\n\006labels\030\005 \003(\t\022\r\n\005value\030\006 \001(\014\022\022\n\nvalue" + + "_size\030\007 \001(\005\022\023\n\treset_row\030\010 \001(\010H\000\022\024\n\ncomm" + + "it_row\030\t \001(\010H\000B\014\n\nrow_status\"n\n\024SampleRo" + + "wKeysRequest\022>\n\ntable_name\030\001 \001(\tB*\340A\002\372A$" + + "\n\"bigtableadmin.googleapis.com/Table\022\026\n\016" + + "app_profile_id\030\002 \001(\t\">\n\025SampleRowKeysRes" + + "ponse\022\017\n\007row_key\030\001 \001(\014\022\024\n\014offset_bytes\030\002" + + " \001(\003\"\266\001\n\020MutateRowRequest\022>\n\ntable_name\030" + + "\001 \001(\tB*\340A\002\372A$\n\"bigtableadmin.googleapis." + + "com/Table\022\026\n\016app_profile_id\030\004 \001(\t\022\024\n\007row" + + "_key\030\002 \001(\014B\003\340A\002\0224\n\tmutations\030\003 \003(\0132\034.goo" + + "gle.bigtable.v2.MutationB\003\340A\002\"\023\n\021MutateR" + + "owResponse\"\376\001\n\021MutateRowsRequest\022>\n\ntabl" + + "e_name\030\001 \001(\tB*\340A\002\372A$\n\"bigtableadmin.goog" + + "leapis.com/Table\022\026\n\016app_profile_id\030\003 \001(\t" + + "\022A\n\007entries\030\002 \003(\0132+.google.bigtable.v2.M" + + "utateRowsRequest.EntryB\003\340A\002\032N\n\005Entry\022\017\n\007" + + "row_key\030\001 \001(\014\0224\n\tmutations\030\002 \003(\0132\034.googl" + + "e.bigtable.v2.MutationB\003\340A\002\"\217\001\n\022MutateRo" + + "wsResponse\022=\n\007entries\030\001 \003(\0132,.google.big" + + "table.v2.MutateRowsResponse.Entry\032:\n\005Ent" + + "ry\022\r\n\005index\030\001 \001(\003\022\"\n\006status\030\002 \001(\0132\022.goog" + + "le.rpc.Status\"\256\002\n\030CheckAndMutateRowReque" + + "st\022>\n\ntable_name\030\001 \001(\tB*\340A\002\372A$\n\"bigtable" + + "admin.googleapis.com/Table\022\026\n\016app_profil" + + "e_id\030\007 \001(\t\022\024\n\007row_key\030\002 \001(\014B\003\340A\002\0227\n\020pred" + + "icate_filter\030\006 \001(\0132\035.google.bigtable.v2." + + "RowFilter\0224\n\016true_mutations\030\004 \003(\0132\034.goog" + + "le.bigtable.v2.Mutation\0225\n\017false_mutatio" + + "ns\030\005 \003(\0132\034.google.bigtable.v2.Mutation\"6" + + "\n\031CheckAndMutateRowResponse\022\031\n\021predicate" + + "_matched\030\001 \001(\010\"i\n\022PingAndWarmRequest\022;\n\004" + + "name\030\001 \001(\tB-\340A\002\372A\'\n%bigtableadmin.google" + + "apis.com/Instance\022\026\n\016app_profile_id\030\002 \001(" + + "\t\"\025\n\023PingAndWarmResponse\"\306\001\n\031ReadModifyW" + + "riteRowRequest\022>\n\ntable_name\030\001 \001(\tB*\340A\002\372" + + "A$\n\"bigtableadmin.googleapis.com/Table\022\026" + + "\n\016app_profile_id\030\004 \001(\t\022\024\n\007row_key\030\002 \001(\014B" + + "\003\340A\002\022;\n\005rules\030\003 \003(\0132\'.google.bigtable.v2" + + ".ReadModifyWriteRuleB\003\340A\002\"B\n\032ReadModifyW" + + "riteRowResponse\022$\n\003row\030\001 \001(\0132\027.google.bi" + + "gtable.v2.Row\"\206\001\n,GenerateInitialChangeS" + + "treamPartitionsRequest\022>\n\ntable_name\030\001 \001" + "(\tB*\340A\002\372A$\n\"bigtableadmin.googleapis.com" - + "/Table\022\026\n\016app_profile_id\030\004 \001(\t\022\024\n\007row_ke" - + "y\030\002 \001(\014B\003\340A\002\0224\n\tmutations\030\003 \003(\0132\034.google" - + ".bigtable.v2.MutationB\003\340A\002\"\023\n\021MutateRowR" - + "esponse\"\376\001\n\021MutateRowsRequest\022>\n\ntable_n" - + "ame\030\001 \001(\tB*\340A\002\372A$\n\"bigtableadmin.googlea" - + "pis.com/Table\022\026\n\016app_profile_id\030\003 \001(\t\022A\n" - + "\007entries\030\002 \003(\0132+.google.bigtable.v2.Muta" - + "teRowsRequest.EntryB\003\340A\002\032N\n\005Entry\022\017\n\007row" - + "_key\030\001 \001(\014\0224\n\tmutations\030\002 \003(\0132\034.google.b" - + "igtable.v2.MutationB\003\340A\002\"\217\001\n\022MutateRowsR" - + "esponse\022=\n\007entries\030\001 \003(\0132,.google.bigtab" - + "le.v2.MutateRowsResponse.Entry\032:\n\005Entry\022" - + "\r\n\005index\030\001 \001(\003\022\"\n\006status\030\002 \001(\0132\022.google." - + "rpc.Status\"\256\002\n\030CheckAndMutateRowRequest\022" - + ">\n\ntable_name\030\001 \001(\tB*\340A\002\372A$\n\"bigtableadm" - + "in.googleapis.com/Table\022\026\n\016app_profile_i" - + "d\030\007 \001(\t\022\024\n\007row_key\030\002 \001(\014B\003\340A\002\0227\n\020predica" - + "te_filter\030\006 \001(\0132\035.google.bigtable.v2.Row" - + "Filter\0224\n\016true_mutations\030\004 \003(\0132\034.google." - + "bigtable.v2.Mutation\0225\n\017false_mutations\030" - + "\005 \003(\0132\034.google.bigtable.v2.Mutation\"6\n\031C" - + "heckAndMutateRowResponse\022\031\n\021predicate_ma" - + "tched\030\001 \001(\010\"i\n\022PingAndWarmRequest\022;\n\004nam" - + "e\030\001 \001(\tB-\340A\002\372A\'\n%bigtableadmin.googleapi" - + "s.com/Instance\022\026\n\016app_profile_id\030\002 \001(\t\"\025" - + "\n\023PingAndWarmResponse\"\306\001\n\031ReadModifyWrit" - + "eRowRequest\022>\n\ntable_name\030\001 \001(\tB*\340A\002\372A$\n" - + "\"bigtableadmin.googleapis.com/Table\022\026\n\016a" - + "pp_profile_id\030\004 \001(\t\022\024\n\007row_key\030\002 \001(\014B\003\340A" - + "\002\022;\n\005rules\030\003 \003(\0132\'.google.bigtable.v2.Re" - + "adModifyWriteRuleB\003\340A\002\"B\n\032ReadModifyWrit" - + "eRowResponse\022$\n\003row\030\001 \001(\0132\027.google.bigta" - + "ble.v2.Row\"\206\001\n,GenerateInitialChangeStre" - + "amPartitionsRequest\022>\n\ntable_name\030\001 \001(\tB" - + "*\340A\002\372A$\n\"bigtableadmin.googleapis.com/Ta" - + "ble\022\026\n\016app_profile_id\030\002 \001(\t\"g\n-GenerateI" - + "nitialChangeStreamPartitionsResponse\0226\n\t" - + "partition\030\001 \001(\0132#.google.bigtable.v2.Str" - + "eamPartition\"\233\003\n\027ReadChangeStreamRequest" - + "\022>\n\ntable_name\030\001 \001(\tB*\340A\002\372A$\n\"bigtablead" - + "min.googleapis.com/Table\022\026\n\016app_profile_" - + "id\030\002 \001(\t\0226\n\tpartition\030\003 \001(\0132#.google.big" - + "table.v2.StreamPartition\0220\n\nstart_time\030\004" - + " \001(\0132\032.google.protobuf.TimestampH\000\022K\n\023co" - + "ntinuation_tokens\030\006 \001(\0132,.google.bigtabl" - + "e.v2.StreamContinuationTokensH\000\022,\n\010end_t" - + "ime\030\005 \001(\0132\032.google.protobuf.Timestamp\0225\n" - + "\022heartbeat_duration\030\007 \001(\0132\031.google.proto" - + "buf.DurationB\014\n\nstart_from\"\327\t\n\030ReadChang" - + "eStreamResponse\022N\n\013data_change\030\001 \001(\01327.g" - + "oogle.bigtable.v2.ReadChangeStreamRespon" - + "se.DataChangeH\000\022K\n\theartbeat\030\002 \001(\01326.goo" - + "gle.bigtable.v2.ReadChangeStreamResponse" - + ".HeartbeatH\000\022P\n\014close_stream\030\003 \001(\01328.goo" - + "gle.bigtable.v2.ReadChangeStreamResponse" - + ".CloseStreamH\000\032\364\001\n\rMutationChunk\022X\n\nchun" - + "k_info\030\001 \001(\0132D.google.bigtable.v2.ReadCh" - + "angeStreamResponse.MutationChunk.ChunkIn" - + "fo\022.\n\010mutation\030\002 \001(\0132\034.google.bigtable.v" - + "2.Mutation\032Y\n\tChunkInfo\022\032\n\022chunked_value" - + "_size\030\001 \001(\005\022\034\n\024chunked_value_offset\030\002 \001(" - + "\005\022\022\n\nlast_chunk\030\003 \001(\010\032\274\003\n\nDataChange\022J\n\004" - + "type\030\001 \001(\0162<.google.bigtable.v2.ReadChan" - + "geStreamResponse.DataChange.Type\022\031\n\021sour" - + "ce_cluster_id\030\002 \001(\t\022\017\n\007row_key\030\003 \001(\014\0224\n\020" - + "commit_timestamp\030\004 \001(\0132\032.google.protobuf" - + ".Timestamp\022\022\n\ntiebreaker\030\005 \001(\005\022J\n\006chunks" - + "\030\006 \003(\0132:.google.bigtable.v2.ReadChangeSt" - + "reamResponse.MutationChunk\022\014\n\004done\030\010 \001(\010" - + "\022\r\n\005token\030\t \001(\t\0221\n\rlow_watermark\030\n \001(\0132\032" - + ".google.protobuf.Timestamp\"P\n\004Type\022\024\n\020TY" - + "PE_UNSPECIFIED\020\000\022\010\n\004USER\020\001\022\026\n\022GARBAGE_CO" - + "LLECTION\020\002\022\020\n\014CONTINUATION\020\003\032\207\001\n\tHeartbe" - + "at\022G\n\022continuation_token\030\001 \001(\0132+.google." - + "bigtable.v2.StreamContinuationToken\0221\n\rl" - + "ow_watermark\030\002 \001(\0132\032.google.protobuf.Tim" - + "estamp\032{\n\013CloseStream\022\"\n\006status\030\001 \001(\0132\022." - + "google.rpc.Status\022H\n\023continuation_tokens" - + "\030\002 \003(\0132+.google.bigtable.v2.StreamContin" - + "uationTokenB\017\n\rstream_record2\327\030\n\010Bigtabl" - + "e\022\233\002\n\010ReadRows\022#.google.bigtable.v2.Read" - + "RowsRequest\032$.google.bigtable.v2.ReadRow" - + "sResponse\"\301\001\202\323\344\223\002>\"9/v2/{table_name=proj" - + "ects/*/instances/*/tables/*}:readRows:\001*" - + "\212\323\344\223\002N\022:\n\ntable_name\022,{table_name=projec" - + "ts/*/instances/*/tables/*}\022\020\n\016app_profil" - + "e_id\332A\ntable_name\332A\031table_name,app_profi" - + "le_id0\001\022\254\002\n\rSampleRowKeys\022(.google.bigta" - + "ble.v2.SampleRowKeysRequest\032).google.big" - + "table.v2.SampleRowKeysResponse\"\303\001\202\323\344\223\002@\022" - + ">/v2/{table_name=projects/*/instances/*/" - + "tables/*}:sampleRowKeys\212\323\344\223\002N\022:\n\ntable_n" - + "ame\022,{table_name=projects/*/instances/*/" - + "tables/*}\022\020\n\016app_profile_id\332A\ntable_name" - + "\332A\031table_name,app_profile_id0\001\022\301\002\n\tMutat" - + "eRow\022$.google.bigtable.v2.MutateRowReque" - + "st\032%.google.bigtable.v2.MutateRowRespons" - + "e\"\346\001\202\323\344\223\002?\":/v2/{table_name=projects/*/i" - + "nstances/*/tables/*}:mutateRow:\001*\212\323\344\223\002N\022" - + ":\n\ntable_name\022,{table_name=projects/*/in" - + "stances/*/tables/*}\022\020\n\016app_profile_id\332A\034" - + "table_name,row_key,mutations\332A+table_nam" - + "e,row_key,mutations,app_profile_id\022\263\002\n\nM" - + "utateRows\022%.google.bigtable.v2.MutateRow" - + "sRequest\032&.google.bigtable.v2.MutateRows" - + "Response\"\323\001\202\323\344\223\002@\";/v2/{table_name=proje" - + "cts/*/instances/*/tables/*}:mutateRows:\001" - + "*\212\323\344\223\002N\022:\n\ntable_name\022,{table_name=proje" - + "cts/*/instances/*/tables/*}\022\020\n\016app_profi" - + "le_id\332A\022table_name,entries\332A!table_name," - + "entries,app_profile_id0\001\022\255\003\n\021CheckAndMut" - + "ateRow\022,.google.bigtable.v2.CheckAndMuta" - + "teRowRequest\032-.google.bigtable.v2.CheckA" - + "ndMutateRowResponse\"\272\002\202\323\344\223\002G\"B/v2/{table" - + "_name=projects/*/instances/*/tables/*}:c" - + "heckAndMutateRow:\001*\212\323\344\223\002N\022:\n\ntable_name\022" + + "/Table\022\026\n\016app_profile_id\030\002 \001(\t\"g\n-Genera" + + "teInitialChangeStreamPartitionsResponse\022" + + "6\n\tpartition\030\001 \001(\0132#.google.bigtable.v2." + + "StreamPartition\"\233\003\n\027ReadChangeStreamRequ" + + "est\022>\n\ntable_name\030\001 \001(\tB*\340A\002\372A$\n\"bigtabl" + + "eadmin.googleapis.com/Table\022\026\n\016app_profi" + + "le_id\030\002 \001(\t\0226\n\tpartition\030\003 \001(\0132#.google." + + "bigtable.v2.StreamPartition\0220\n\nstart_tim" + + "e\030\004 \001(\0132\032.google.protobuf.TimestampH\000\022K\n" + + "\023continuation_tokens\030\006 \001(\0132,.google.bigt" + + "able.v2.StreamContinuationTokensH\000\022,\n\010en" + + "d_time\030\005 \001(\0132\032.google.protobuf.Timestamp" + + "\0225\n\022heartbeat_duration\030\007 \001(\0132\031.google.pr" + + "otobuf.DurationB\014\n\nstart_from\"\327\t\n\030ReadCh" + + "angeStreamResponse\022N\n\013data_change\030\001 \001(\0132" + + "7.google.bigtable.v2.ReadChangeStreamRes" + + "ponse.DataChangeH\000\022K\n\theartbeat\030\002 \001(\01326." + + "google.bigtable.v2.ReadChangeStreamRespo" + + "nse.HeartbeatH\000\022P\n\014close_stream\030\003 \001(\01328." + + "google.bigtable.v2.ReadChangeStreamRespo" + + "nse.CloseStreamH\000\032\364\001\n\rMutationChunk\022X\n\nc" + + "hunk_info\030\001 \001(\0132D.google.bigtable.v2.Rea" + + "dChangeStreamResponse.MutationChunk.Chun" + + "kInfo\022.\n\010mutation\030\002 \001(\0132\034.google.bigtabl" + + "e.v2.Mutation\032Y\n\tChunkInfo\022\032\n\022chunked_va" + + "lue_size\030\001 \001(\005\022\034\n\024chunked_value_offset\030\002" + + " \001(\005\022\022\n\nlast_chunk\030\003 \001(\010\032\274\003\n\nDataChange\022" + + "J\n\004type\030\001 \001(\0162<.google.bigtable.v2.ReadC" + + "hangeStreamResponse.DataChange.Type\022\031\n\021s" + + "ource_cluster_id\030\002 \001(\t\022\017\n\007row_key\030\003 \001(\014\022" + + "4\n\020commit_timestamp\030\004 \001(\0132\032.google.proto" + + "buf.Timestamp\022\022\n\ntiebreaker\030\005 \001(\005\022J\n\006chu" + + "nks\030\006 \003(\0132:.google.bigtable.v2.ReadChang" + + "eStreamResponse.MutationChunk\022\014\n\004done\030\010 " + + "\001(\010\022\r\n\005token\030\t \001(\t\0221\n\rlow_watermark\030\n \001(" + + "\0132\032.google.protobuf.Timestamp\"P\n\004Type\022\024\n" + + "\020TYPE_UNSPECIFIED\020\000\022\010\n\004USER\020\001\022\026\n\022GARBAGE" + + "_COLLECTION\020\002\022\020\n\014CONTINUATION\020\003\032\207\001\n\tHear" + + "tbeat\022G\n\022continuation_token\030\001 \001(\0132+.goog" + + "le.bigtable.v2.StreamContinuationToken\0221" + + "\n\rlow_watermark\030\002 \001(\0132\032.google.protobuf." + + "Timestamp\032{\n\013CloseStream\022\"\n\006status\030\001 \001(\013" + + "2\022.google.rpc.Status\022H\n\023continuation_tok" + + "ens\030\002 \003(\0132+.google.bigtable.v2.StreamCon" + + "tinuationTokenB\017\n\rstream_record2\327\030\n\010Bigt" + + "able\022\233\002\n\010ReadRows\022#.google.bigtable.v2.R" + + "eadRowsRequest\032$.google.bigtable.v2.Read" + + "RowsResponse\"\301\001\202\323\344\223\002>\"9/v2/{table_name=p" + + "rojects/*/instances/*/tables/*}:readRows" + + ":\001*\212\323\344\223\002N\022:\n\ntable_name\022,{table_name=pro" + + "jects/*/instances/*/tables/*}\022\020\n\016app_pro" + + "file_id\332A\ntable_name\332A\031table_name,app_pr" + + "ofile_id0\001\022\254\002\n\rSampleRowKeys\022(.google.bi" + + "gtable.v2.SampleRowKeysRequest\032).google." + + "bigtable.v2.SampleRowKeysResponse\"\303\001\202\323\344\223" + + "\002@\022>/v2/{table_name=projects/*/instances" + + "/*/tables/*}:sampleRowKeys\212\323\344\223\002N\022:\n\ntabl" + + "e_name\022,{table_name=projects/*/instances" + + "/*/tables/*}\022\020\n\016app_profile_id\332A\ntable_n" + + "ame\332A\031table_name,app_profile_id0\001\022\301\002\n\tMu" + + "tateRow\022$.google.bigtable.v2.MutateRowRe" + + "quest\032%.google.bigtable.v2.MutateRowResp" + + "onse\"\346\001\202\323\344\223\002?\":/v2/{table_name=projects/" + + "*/instances/*/tables/*}:mutateRow:\001*\212\323\344\223" + + "\002N\022:\n\ntable_name\022,{table_name=projects/*" + + "/instances/*/tables/*}\022\020\n\016app_profile_id" + + "\332A\034table_name,row_key,mutations\332A+table_" + + "name,row_key,mutations,app_profile_id\022\263\002" + + "\n\nMutateRows\022%.google.bigtable.v2.Mutate" + + "RowsRequest\032&.google.bigtable.v2.MutateR" + + "owsResponse\"\323\001\202\323\344\223\002@\";/v2/{table_name=pr" + + "ojects/*/instances/*/tables/*}:mutateRow" + + "s:\001*\212\323\344\223\002N\022:\n\ntable_name\022,{table_name=pr" + + "ojects/*/instances/*/tables/*}\022\020\n\016app_pr" + + "ofile_id\332A\022table_name,entries\332A!table_na" + + "me,entries,app_profile_id0\001\022\255\003\n\021CheckAnd" + + "MutateRow\022,.google.bigtable.v2.CheckAndM" + + "utateRowRequest\032-.google.bigtable.v2.Che" + + "ckAndMutateRowResponse\"\272\002\202\323\344\223\002G\"B/v2/{ta" + + "ble_name=projects/*/instances/*/tables/*" + + "}:checkAndMutateRow:\001*\212\323\344\223\002N\022:\n\ntable_na" + + "me\022,{table_name=projects/*/instances/*/t" + + "ables/*}\022\020\n\016app_profile_id\332ABtable_name," + + "row_key,predicate_filter,true_mutations," + + "false_mutations\332AQtable_name,row_key,pre" + + "dicate_filter,true_mutations,false_mutat" + + "ions,app_profile_id\022\356\001\n\013PingAndWarm\022&.go" + + "ogle.bigtable.v2.PingAndWarmRequest\032\'.go" + + "ogle.bigtable.v2.PingAndWarmResponse\"\215\001\202" + + "\323\344\223\002+\"&/v2/{name=projects/*/instances/*}" + + ":ping:\001*\212\323\344\223\0029\022%\n\004name\022\035{name=projects/*" + + "/instances/*}\022\020\n\016app_profile_id\332A\004name\332A" + + "\023name,app_profile_id\022\335\002\n\022ReadModifyWrite" + + "Row\022-.google.bigtable.v2.ReadModifyWrite" + + "RowRequest\032..google.bigtable.v2.ReadModi" + + "fyWriteRowResponse\"\347\001\202\323\344\223\002H\"C/v2/{table_" + + "name=projects/*/instances/*/tables/*}:re" + + "adModifyWriteRow:\001*\212\323\344\223\002N\022:\n\ntable_name\022" + ",{table_name=projects/*/instances/*/tabl" - + "es/*}\022\020\n\016app_profile_id\332ABtable_name,row" - + "_key,predicate_filter,true_mutations,fal" - + "se_mutations\332AQtable_name,row_key,predic" - + "ate_filter,true_mutations,false_mutation" - + "s,app_profile_id\022\356\001\n\013PingAndWarm\022&.googl" - + "e.bigtable.v2.PingAndWarmRequest\032\'.googl" - + "e.bigtable.v2.PingAndWarmResponse\"\215\001\202\323\344\223" - + "\002+\"&/v2/{name=projects/*/instances/*}:pi" - + "ng:\001*\212\323\344\223\0029\022%\n\004name\022\035{name=projects/*/in" - + "stances/*}\022\020\n\016app_profile_id\332A\004name\332A\023na" - + "me,app_profile_id\022\335\002\n\022ReadModifyWriteRow" - + "\022-.google.bigtable.v2.ReadModifyWriteRow" - + "Request\032..google.bigtable.v2.ReadModifyW" - + "riteRowResponse\"\347\001\202\323\344\223\002H\"C/v2/{table_nam" - + "e=projects/*/instances/*/tables/*}:readM" - + "odifyWriteRow:\001*\212\323\344\223\002N\022:\n\ntable_name\022,{t" - + "able_name=projects/*/instances/*/tables/" - + "*}\022\020\n\016app_profile_id\332A\030table_name,row_ke" - + "y,rules\332A\'table_name,row_key,rules,app_p" - + "rofile_id\022\273\002\n%GenerateInitialChangeStrea" - + "mPartitions\022@.google.bigtable.v2.Generat" - + "eInitialChangeStreamPartitionsRequest\032A." - + "google.bigtable.v2.GenerateInitialChange" - + "StreamPartitionsResponse\"\212\001\202\323\344\223\002[\"V/v2/{" - + "table_name=projects/*/instances/*/tables" - + "/*}:generateInitialChangeStreamPartition" - + "s:\001*\332A\ntable_name\332A\031table_name,app_profi" - + "le_id0\001\022\346\001\n\020ReadChangeStream\022+.google.bi" - + "gtable.v2.ReadChangeStreamRequest\032,.goog" - + "le.bigtable.v2.ReadChangeStreamResponse\"" - + "u\202\323\344\223\002F\"A/v2/{table_name=projects/*/inst" - + "ances/*/tables/*}:readChangeStream:\001*\332A\n" - + "table_name\332A\031table_name,app_profile_id0\001" - + "\032\333\002\312A\027bigtable.googleapis.com\322A\275\002https:/" - + "/www.googleapis.com/auth/bigtable.data,h" - + "ttps://www.googleapis.com/auth/bigtable." - + "data.readonly,https://www.googleapis.com" - + "/auth/cloud-bigtable.data,https://www.go" - + "ogleapis.com/auth/cloud-bigtable.data.re" - + "adonly,https://www.googleapis.com/auth/c" - + "loud-platform,https://www.googleapis.com" - + "/auth/cloud-platform.read-onlyB\353\002\n\026com.g" - + "oogle.bigtable.v2B\rBigtableProtoP\001Z:goog" - + "le.golang.org/genproto/googleapis/bigtab" - + "le/v2;bigtable\252\002\030Google.Cloud.Bigtable.V" - + "2\312\002\030Google\\Cloud\\Bigtable\\V2\352\002\033Google::C" - + "loud::Bigtable::V2\352A\\\n\"bigtableadmin.goo" - + "gleapis.com/Table\0226projects/{project}/in" - + "stances/{instance}/tables/{table}\352AP\n%bi" - + "gtableadmin.googleapis.com/Instance\022\'pro" - + "jects/{project}/instances/{instance}b\006pr" - + "oto3" + + "es/*}\022\020\n\016app_profile_id\332A\030table_name,row" + + "_key,rules\332A\'table_name,row_key,rules,ap" + + "p_profile_id\022\273\002\n%GenerateInitialChangeSt" + + "reamPartitions\022@.google.bigtable.v2.Gene" + + "rateInitialChangeStreamPartitionsRequest" + + "\032A.google.bigtable.v2.GenerateInitialCha" + + "ngeStreamPartitionsResponse\"\212\001\202\323\344\223\002[\"V/v" + + "2/{table_name=projects/*/instances/*/tab" + + "les/*}:generateInitialChangeStreamPartit" + + "ions:\001*\332A\ntable_name\332A\031table_name,app_pr" + + "ofile_id0\001\022\346\001\n\020ReadChangeStream\022+.google" + + ".bigtable.v2.ReadChangeStreamRequest\032,.g" + + "oogle.bigtable.v2.ReadChangeStreamRespon" + + "se\"u\202\323\344\223\002F\"A/v2/{table_name=projects/*/i" + + "nstances/*/tables/*}:readChangeStream:\001*" + + "\332A\ntable_name\332A\031table_name,app_profile_i" + + "d0\001\032\333\002\312A\027bigtable.googleapis.com\322A\275\002http" + + "s://www.googleapis.com/auth/bigtable.dat" + + "a,https://www.googleapis.com/auth/bigtab" + + "le.data.readonly,https://www.googleapis." + + "com/auth/cloud-bigtable.data,https://www" + + ".googleapis.com/auth/cloud-bigtable.data" + + ".readonly,https://www.googleapis.com/aut" + + "h/cloud-platform,https://www.googleapis." + + "com/auth/cloud-platform.read-onlyB\353\002\n\026co" + + "m.google.bigtable.v2B\rBigtableProtoP\001Z:g" + + "oogle.golang.org/genproto/googleapis/big" + + "table/v2;bigtable\252\002\030Google.Cloud.Bigtabl" + + "e.V2\312\002\030Google\\Cloud\\Bigtable\\V2\352\002\033Google" + + "::Cloud::Bigtable::V2\352AP\n%bigtableadmin." + + "googleapis.com/Instance\022\'projects/{proje" + + "ct}/instances/{instance}\352A\\\n\"bigtableadm" + + "in.googleapis.com/Table\0226projects/{proje" + + "ct}/instances/{instance}/tables/{table}b" + + "\006proto3" }; descriptor = com.google.protobuf.Descriptors.FileDescriptor.internalBuildGeneratedFileFrom( @@ -350,6 +357,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { com.google.api.ResourceProto.getDescriptor(), com.google.api.RoutingProto.getDescriptor(), com.google.bigtable.v2.DataProto.getDescriptor(), + com.google.bigtable.v2.RequestStatsProto.getDescriptor(), com.google.protobuf.DurationProto.getDescriptor(), com.google.protobuf.TimestampProto.getDescriptor(), com.google.protobuf.WrappersProto.getDescriptor(), @@ -361,7 +369,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( internal_static_google_bigtable_v2_ReadRowsRequest_descriptor, new java.lang.String[] { - "TableName", "AppProfileId", "Rows", "Filter", "RowsLimit", + "TableName", "AppProfileId", "Rows", "Filter", "RowsLimit", "RequestStatsView", }); internal_static_google_bigtable_v2_ReadRowsResponse_descriptor = getDescriptor().getMessageTypes().get(1); @@ -369,7 +377,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( internal_static_google_bigtable_v2_ReadRowsResponse_descriptor, new java.lang.String[] { - "Chunks", "LastScannedRowKey", + "Chunks", "LastScannedRowKey", "RequestStats", }); internal_static_google_bigtable_v2_ReadRowsResponse_CellChunk_descriptor = internal_static_google_bigtable_v2_ReadRowsResponse_descriptor.getNestedTypes().get(0); @@ -616,6 +624,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { com.google.api.ResourceProto.getDescriptor(); com.google.api.RoutingProto.getDescriptor(); com.google.bigtable.v2.DataProto.getDescriptor(); + com.google.bigtable.v2.RequestStatsProto.getDescriptor(); com.google.protobuf.DurationProto.getDescriptor(); com.google.protobuf.TimestampProto.getDescriptor(); com.google.protobuf.WrappersProto.getDescriptor(); diff --git a/proto-google-cloud-bigtable-v2/src/main/java/com/google/bigtable/v2/Cell.java b/proto-google-cloud-bigtable-v2/src/main/java/com/google/bigtable/v2/Cell.java index ebf47a5681..d6b97cdc4b 100644 --- a/proto-google-cloud-bigtable-v2/src/main/java/com/google/bigtable/v2/Cell.java +++ b/proto-google-cloud-bigtable-v2/src/main/java/com/google/bigtable/v2/Cell.java @@ -53,69 +53,6 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - private Cell( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - int mutable_bitField0_ = 0; - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 8: - { - timestampMicros_ = input.readInt64(); - break; - } - case 18: - { - value_ = input.readBytes(); - break; - } - case 26: - { - java.lang.String s = input.readStringRequireUtf8(); - if (!((mutable_bitField0_ & 0x00000001) != 0)) { - labels_ = new com.google.protobuf.LazyStringArrayList(); - mutable_bitField0_ |= 0x00000001; - } - labels_.add(s); - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); - } finally { - if (((mutable_bitField0_ & 0x00000001) != 0)) { - labels_ = labels_.getUnmodifiableView(); - } - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.bigtable.v2.DataProto.internal_static_google_bigtable_v2_Cell_descriptor; } @@ -256,7 +193,7 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io for (int i = 0; i < labels_.size(); i++) { com.google.protobuf.GeneratedMessageV3.writeString(output, 3, labels_.getRaw(i)); } - unknownFields.writeTo(output); + getUnknownFields().writeTo(output); } @java.lang.Override @@ -279,7 +216,7 @@ public int getSerializedSize() { size += dataSize; size += 1 * getLabelsList().size(); } - size += unknownFields.getSerializedSize(); + size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @@ -297,7 +234,7 @@ public boolean equals(final java.lang.Object obj) { if (getTimestampMicros() != other.getTimestampMicros()) return false; if (!getValue().equals(other.getValue())) return false; if (!getLabelsList().equals(other.getLabelsList())) return false; - if (!unknownFields.equals(other.unknownFields)) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -316,7 +253,7 @@ public int hashCode() { hash = (37 * hash) + LABELS_FIELD_NUMBER; hash = (53 * hash) + getLabelsList().hashCode(); } - hash = (29 * hash) + unknownFields.hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } @@ -442,17 +379,10 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { } // Construct using com.google.bigtable.v2.Cell.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } + private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} } @java.lang.Override @@ -562,7 +492,7 @@ public Builder mergeFrom(com.google.bigtable.v2.Cell other) { } onChanged(); } - this.mergeUnknownFields(other.unknownFields); + this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @@ -577,17 +507,50 @@ public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - com.google.bigtable.v2.Cell parsedMessage = null; + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 8: + { + timestampMicros_ = input.readInt64(); + + break; + } // case 8 + case 18: + { + value_ = input.readBytes(); + + break; + } // case 18 + case 26: + { + java.lang.String s = input.readStringRequireUtf8(); + ensureLabelsIsMutable(); + labels_.add(s); + break; + } // case 26 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.bigtable.v2.Cell) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } + onChanged(); + } // finally return this; } @@ -921,7 +884,18 @@ public Cell parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new Cell(input, extensionRegistry); + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); } }; diff --git a/proto-google-cloud-bigtable-v2/src/main/java/com/google/bigtable/v2/CheckAndMutateRowRequest.java b/proto-google-cloud-bigtable-v2/src/main/java/com/google/bigtable/v2/CheckAndMutateRowRequest.java index 0d1ca2cae2..a45a41ba9b 100644 --- a/proto-google-cloud-bigtable-v2/src/main/java/com/google/bigtable/v2/CheckAndMutateRowRequest.java +++ b/proto-google-cloud-bigtable-v2/src/main/java/com/google/bigtable/v2/CheckAndMutateRowRequest.java @@ -56,106 +56,6 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - private CheckAndMutateRowRequest( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - int mutable_bitField0_ = 0; - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - java.lang.String s = input.readStringRequireUtf8(); - - tableName_ = s; - break; - } - case 18: - { - rowKey_ = input.readBytes(); - break; - } - case 34: - { - if (!((mutable_bitField0_ & 0x00000001) != 0)) { - trueMutations_ = new java.util.ArrayList(); - mutable_bitField0_ |= 0x00000001; - } - trueMutations_.add( - input.readMessage(com.google.bigtable.v2.Mutation.parser(), extensionRegistry)); - break; - } - case 42: - { - if (!((mutable_bitField0_ & 0x00000002) != 0)) { - falseMutations_ = new java.util.ArrayList(); - mutable_bitField0_ |= 0x00000002; - } - falseMutations_.add( - input.readMessage(com.google.bigtable.v2.Mutation.parser(), extensionRegistry)); - break; - } - case 50: - { - com.google.bigtable.v2.RowFilter.Builder subBuilder = null; - if (predicateFilter_ != null) { - subBuilder = predicateFilter_.toBuilder(); - } - predicateFilter_ = - input.readMessage(com.google.bigtable.v2.RowFilter.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(predicateFilter_); - predicateFilter_ = subBuilder.buildPartial(); - } - - break; - } - case 58: - { - java.lang.String s = input.readStringRequireUtf8(); - - appProfileId_ = s; - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); - } finally { - if (((mutable_bitField0_ & 0x00000001) != 0)) { - trueMutations_ = java.util.Collections.unmodifiableList(trueMutations_); - } - if (((mutable_bitField0_ & 0x00000002) != 0)) { - falseMutations_ = java.util.Collections.unmodifiableList(falseMutations_); - } - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.bigtable.v2.BigtableProto .internal_static_google_bigtable_v2_CheckAndMutateRowRequest_descriptor; @@ -566,7 +466,7 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(appProfileId_)) { com.google.protobuf.GeneratedMessageV3.writeString(output, 7, appProfileId_); } - unknownFields.writeTo(output); + getUnknownFields().writeTo(output); } @java.lang.Override @@ -593,7 +493,7 @@ public int getSerializedSize() { if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(appProfileId_)) { size += com.google.protobuf.GeneratedMessageV3.computeStringSize(7, appProfileId_); } - size += unknownFields.getSerializedSize(); + size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @@ -618,7 +518,7 @@ public boolean equals(final java.lang.Object obj) { } if (!getTrueMutationsList().equals(other.getTrueMutationsList())) return false; if (!getFalseMutationsList().equals(other.getFalseMutationsList())) return false; - if (!unknownFields.equals(other.unknownFields)) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -647,7 +547,7 @@ public int hashCode() { hash = (37 * hash) + FALSE_MUTATIONS_FIELD_NUMBER; hash = (53 * hash) + getFalseMutationsList().hashCode(); } - hash = (29 * hash) + unknownFields.hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } @@ -776,20 +676,10 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { } // Construct using com.google.bigtable.v2.CheckAndMutateRowRequest.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } + private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) { - getTrueMutationsFieldBuilder(); - getFalseMutationsFieldBuilder(); - } } @java.lang.Override @@ -809,16 +699,18 @@ public Builder clear() { } if (trueMutationsBuilder_ == null) { trueMutations_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000001); } else { + trueMutations_ = null; trueMutationsBuilder_.clear(); } + bitField0_ = (bitField0_ & ~0x00000001); if (falseMutationsBuilder_ == null) { falseMutations_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000002); } else { + falseMutations_ = null; falseMutationsBuilder_.clear(); } + bitField0_ = (bitField0_ & ~0x00000002); return this; } @@ -991,7 +883,7 @@ public Builder mergeFrom(com.google.bigtable.v2.CheckAndMutateRowRequest other) } } } - this.mergeUnknownFields(other.unknownFields); + this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @@ -1006,17 +898,79 @@ public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - com.google.bigtable.v2.CheckAndMutateRowRequest parsedMessage = null; + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + tableName_ = input.readStringRequireUtf8(); + + break; + } // case 10 + case 18: + { + rowKey_ = input.readBytes(); + + break; + } // case 18 + case 34: + { + com.google.bigtable.v2.Mutation m = + input.readMessage(com.google.bigtable.v2.Mutation.parser(), extensionRegistry); + if (trueMutationsBuilder_ == null) { + ensureTrueMutationsIsMutable(); + trueMutations_.add(m); + } else { + trueMutationsBuilder_.addMessage(m); + } + break; + } // case 34 + case 42: + { + com.google.bigtable.v2.Mutation m = + input.readMessage(com.google.bigtable.v2.Mutation.parser(), extensionRegistry); + if (falseMutationsBuilder_ == null) { + ensureFalseMutationsIsMutable(); + falseMutations_.add(m); + } else { + falseMutationsBuilder_.addMessage(m); + } + break; + } // case 42 + case 50: + { + input.readMessage(getPredicateFilterFieldBuilder().getBuilder(), extensionRegistry); + + break; + } // case 50 + case 58: + { + appProfileId_ = input.readStringRequireUtf8(); + + break; + } // case 58 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.bigtable.v2.CheckAndMutateRowRequest) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } + onChanged(); + } // finally return this; } @@ -2409,7 +2363,18 @@ public CheckAndMutateRowRequest parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new CheckAndMutateRowRequest(input, extensionRegistry); + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); } }; diff --git a/proto-google-cloud-bigtable-v2/src/main/java/com/google/bigtable/v2/CheckAndMutateRowResponse.java b/proto-google-cloud-bigtable-v2/src/main/java/com/google/bigtable/v2/CheckAndMutateRowResponse.java index afcf90a5c8..038804e44b 100644 --- a/proto-google-cloud-bigtable-v2/src/main/java/com/google/bigtable/v2/CheckAndMutateRowResponse.java +++ b/proto-google-cloud-bigtable-v2/src/main/java/com/google/bigtable/v2/CheckAndMutateRowResponse.java @@ -50,50 +50,6 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - private CheckAndMutateRowResponse( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 8: - { - predicateMatched_ = input.readBool(); - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.bigtable.v2.BigtableProto .internal_static_google_bigtable_v2_CheckAndMutateRowResponse_descriptor; @@ -145,7 +101,7 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io if (predicateMatched_ != false) { output.writeBool(1, predicateMatched_); } - unknownFields.writeTo(output); + getUnknownFields().writeTo(output); } @java.lang.Override @@ -157,7 +113,7 @@ public int getSerializedSize() { if (predicateMatched_ != false) { size += com.google.protobuf.CodedOutputStream.computeBoolSize(1, predicateMatched_); } - size += unknownFields.getSerializedSize(); + size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @@ -174,7 +130,7 @@ public boolean equals(final java.lang.Object obj) { (com.google.bigtable.v2.CheckAndMutateRowResponse) obj; if (getPredicateMatched() != other.getPredicateMatched()) return false; - if (!unknownFields.equals(other.unknownFields)) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -187,7 +143,7 @@ public int hashCode() { hash = (19 * hash) + getDescriptor().hashCode(); hash = (37 * hash) + PREDICATE_MATCHED_FIELD_NUMBER; hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean(getPredicateMatched()); - hash = (29 * hash) + unknownFields.hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } @@ -316,17 +272,10 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { } // Construct using com.google.bigtable.v2.CheckAndMutateRowResponse.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } + private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} } @java.lang.Override @@ -415,7 +364,7 @@ public Builder mergeFrom(com.google.bigtable.v2.CheckAndMutateRowResponse other) if (other.getPredicateMatched() != false) { setPredicateMatched(other.getPredicateMatched()); } - this.mergeUnknownFields(other.unknownFields); + this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @@ -430,17 +379,37 @@ public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - com.google.bigtable.v2.CheckAndMutateRowResponse parsedMessage = null; + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 8: + { + predicateMatched_ = input.readBool(); + + break; + } // case 8 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.bigtable.v2.CheckAndMutateRowResponse) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } + onChanged(); + } // finally return this; } @@ -531,7 +500,18 @@ public CheckAndMutateRowResponse parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new CheckAndMutateRowResponse(input, extensionRegistry); + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); } }; diff --git a/proto-google-cloud-bigtable-v2/src/main/java/com/google/bigtable/v2/Column.java b/proto-google-cloud-bigtable-v2/src/main/java/com/google/bigtable/v2/Column.java index 4a26a89fd6..780f63da2d 100644 --- a/proto-google-cloud-bigtable-v2/src/main/java/com/google/bigtable/v2/Column.java +++ b/proto-google-cloud-bigtable-v2/src/main/java/com/google/bigtable/v2/Column.java @@ -54,64 +54,6 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - private Column( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - int mutable_bitField0_ = 0; - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - qualifier_ = input.readBytes(); - break; - } - case 18: - { - if (!((mutable_bitField0_ & 0x00000001) != 0)) { - cells_ = new java.util.ArrayList(); - mutable_bitField0_ |= 0x00000001; - } - cells_.add( - input.readMessage(com.google.bigtable.v2.Cell.parser(), extensionRegistry)); - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); - } finally { - if (((mutable_bitField0_ & 0x00000001) != 0)) { - cells_ = java.util.Collections.unmodifiableList(cells_); - } - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.bigtable.v2.DataProto.internal_static_google_bigtable_v2_Column_descriptor; } @@ -235,7 +177,7 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io for (int i = 0; i < cells_.size(); i++) { output.writeMessage(2, cells_.get(i)); } - unknownFields.writeTo(output); + getUnknownFields().writeTo(output); } @java.lang.Override @@ -250,7 +192,7 @@ public int getSerializedSize() { for (int i = 0; i < cells_.size(); i++) { size += com.google.protobuf.CodedOutputStream.computeMessageSize(2, cells_.get(i)); } - size += unknownFields.getSerializedSize(); + size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @@ -267,7 +209,7 @@ public boolean equals(final java.lang.Object obj) { if (!getQualifier().equals(other.getQualifier())) return false; if (!getCellsList().equals(other.getCellsList())) return false; - if (!unknownFields.equals(other.unknownFields)) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -284,7 +226,7 @@ public int hashCode() { hash = (37 * hash) + CELLS_FIELD_NUMBER; hash = (53 * hash) + getCellsList().hashCode(); } - hash = (29 * hash) + unknownFields.hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } @@ -411,19 +353,10 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { } // Construct using com.google.bigtable.v2.Column.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } + private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) { - getCellsFieldBuilder(); - } } @java.lang.Override @@ -433,10 +366,11 @@ public Builder clear() { if (cellsBuilder_ == null) { cells_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000001); } else { + cells_ = null; cellsBuilder_.clear(); } + bitField0_ = (bitField0_ & ~0x00000001); return this; } @@ -552,7 +486,7 @@ public Builder mergeFrom(com.google.bigtable.v2.Column other) { } } } - this.mergeUnknownFields(other.unknownFields); + this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @@ -567,17 +501,49 @@ public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - com.google.bigtable.v2.Column parsedMessage = null; + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + qualifier_ = input.readBytes(); + + break; + } // case 10 + case 18: + { + com.google.bigtable.v2.Cell m = + input.readMessage(com.google.bigtable.v2.Cell.parser(), extensionRegistry); + if (cellsBuilder_ == null) { + ensureCellsIsMutable(); + cells_.add(m); + } else { + cellsBuilder_.addMessage(m); + } + break; + } // case 18 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.bigtable.v2.Column) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } + onChanged(); + } // finally return this; } @@ -1024,7 +990,18 @@ public Column parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new Column(input, extensionRegistry); + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); } }; diff --git a/proto-google-cloud-bigtable-v2/src/main/java/com/google/bigtable/v2/ColumnRange.java b/proto-google-cloud-bigtable-v2/src/main/java/com/google/bigtable/v2/ColumnRange.java index ad0f09e338..a5da9d1288 100644 --- a/proto-google-cloud-bigtable-v2/src/main/java/com/google/bigtable/v2/ColumnRange.java +++ b/proto-google-cloud-bigtable-v2/src/main/java/com/google/bigtable/v2/ColumnRange.java @@ -55,76 +55,6 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - private ColumnRange( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - java.lang.String s = input.readStringRequireUtf8(); - - familyName_ = s; - break; - } - case 18: - { - startQualifier_ = input.readBytes(); - startQualifierCase_ = 2; - break; - } - case 26: - { - startQualifier_ = input.readBytes(); - startQualifierCase_ = 3; - break; - } - case 34: - { - endQualifier_ = input.readBytes(); - endQualifierCase_ = 4; - break; - } - case 42: - { - endQualifier_ = input.readBytes(); - endQualifierCase_ = 5; - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.bigtable.v2.DataProto .internal_static_google_bigtable_v2_ColumnRange_descriptor; @@ -452,7 +382,7 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io if (endQualifierCase_ == 5) { output.writeBytes(5, (com.google.protobuf.ByteString) endQualifier_); } - unknownFields.writeTo(output); + getUnknownFields().writeTo(output); } @java.lang.Override @@ -484,7 +414,7 @@ public int getSerializedSize() { com.google.protobuf.CodedOutputStream.computeBytesSize( 5, (com.google.protobuf.ByteString) endQualifier_); } - size += unknownFields.getSerializedSize(); + size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @@ -522,7 +452,7 @@ public boolean equals(final java.lang.Object obj) { case 0: default: } - if (!unknownFields.equals(other.unknownFields)) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -559,7 +489,7 @@ public int hashCode() { case 0: default: } - hash = (29 * hash) + unknownFields.hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } @@ -690,17 +620,10 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { } // Construct using com.google.bigtable.v2.ColumnRange.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } + private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} } @java.lang.Override @@ -838,7 +761,7 @@ public Builder mergeFrom(com.google.bigtable.v2.ColumnRange other) { break; } } - this.mergeUnknownFields(other.unknownFields); + this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @@ -853,17 +776,61 @@ public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - com.google.bigtable.v2.ColumnRange parsedMessage = null; + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + familyName_ = input.readStringRequireUtf8(); + + break; + } // case 10 + case 18: + { + startQualifier_ = input.readBytes(); + startQualifierCase_ = 2; + break; + } // case 18 + case 26: + { + startQualifier_ = input.readBytes(); + startQualifierCase_ = 3; + break; + } // case 26 + case 34: + { + endQualifier_ = input.readBytes(); + endQualifierCase_ = 4; + break; + } // case 34 + case 42: + { + endQualifier_ = input.readBytes(); + endQualifierCase_ = 5; + break; + } // case 42 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.bigtable.v2.ColumnRange) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } + onChanged(); + } // finally return this; } @@ -1321,7 +1288,18 @@ public ColumnRange parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new ColumnRange(input, extensionRegistry); + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); } }; diff --git a/proto-google-cloud-bigtable-v2/src/main/java/com/google/bigtable/v2/Family.java b/proto-google-cloud-bigtable-v2/src/main/java/com/google/bigtable/v2/Family.java index ac1b91e9bb..25e73be090 100644 --- a/proto-google-cloud-bigtable-v2/src/main/java/com/google/bigtable/v2/Family.java +++ b/proto-google-cloud-bigtable-v2/src/main/java/com/google/bigtable/v2/Family.java @@ -54,66 +54,6 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - private Family( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - int mutable_bitField0_ = 0; - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - java.lang.String s = input.readStringRequireUtf8(); - - name_ = s; - break; - } - case 18: - { - if (!((mutable_bitField0_ & 0x00000001) != 0)) { - columns_ = new java.util.ArrayList(); - mutable_bitField0_ |= 0x00000001; - } - columns_.add( - input.readMessage(com.google.bigtable.v2.Column.parser(), extensionRegistry)); - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); - } finally { - if (((mutable_bitField0_ & 0x00000001) != 0)) { - columns_ = java.util.Collections.unmodifiableList(columns_); - } - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.bigtable.v2.DataProto.internal_static_google_bigtable_v2_Family_descriptor; } @@ -275,7 +215,7 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io for (int i = 0; i < columns_.size(); i++) { output.writeMessage(2, columns_.get(i)); } - unknownFields.writeTo(output); + getUnknownFields().writeTo(output); } @java.lang.Override @@ -290,7 +230,7 @@ public int getSerializedSize() { for (int i = 0; i < columns_.size(); i++) { size += com.google.protobuf.CodedOutputStream.computeMessageSize(2, columns_.get(i)); } - size += unknownFields.getSerializedSize(); + size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @@ -307,7 +247,7 @@ public boolean equals(final java.lang.Object obj) { if (!getName().equals(other.getName())) return false; if (!getColumnsList().equals(other.getColumnsList())) return false; - if (!unknownFields.equals(other.unknownFields)) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -324,7 +264,7 @@ public int hashCode() { hash = (37 * hash) + COLUMNS_FIELD_NUMBER; hash = (53 * hash) + getColumnsList().hashCode(); } - hash = (29 * hash) + unknownFields.hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } @@ -451,19 +391,10 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { } // Construct using com.google.bigtable.v2.Family.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } + private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) { - getColumnsFieldBuilder(); - } } @java.lang.Override @@ -473,10 +404,11 @@ public Builder clear() { if (columnsBuilder_ == null) { columns_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000001); } else { + columns_ = null; columnsBuilder_.clear(); } + bitField0_ = (bitField0_ & ~0x00000001); return this; } @@ -593,7 +525,7 @@ public Builder mergeFrom(com.google.bigtable.v2.Family other) { } } } - this.mergeUnknownFields(other.unknownFields); + this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @@ -608,17 +540,49 @@ public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - com.google.bigtable.v2.Family parsedMessage = null; + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + name_ = input.readStringRequireUtf8(); + + break; + } // case 10 + case 18: + { + com.google.bigtable.v2.Column m = + input.readMessage(com.google.bigtable.v2.Column.parser(), extensionRegistry); + if (columnsBuilder_ == null) { + ensureColumnsIsMutable(); + columns_.add(m); + } else { + columnsBuilder_.addMessage(m); + } + break; + } // case 18 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.bigtable.v2.Family) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } + onChanged(); + } // finally return this; } @@ -1133,7 +1097,18 @@ public Family parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new Family(input, extensionRegistry); + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); } }; diff --git a/proto-google-cloud-bigtable-v2/src/main/java/com/google/bigtable/v2/FullReadStatsView.java b/proto-google-cloud-bigtable-v2/src/main/java/com/google/bigtable/v2/FullReadStatsView.java new file mode 100644 index 0000000000..f0e0c2b726 --- /dev/null +++ b/proto-google-cloud-bigtable-v2/src/main/java/com/google/bigtable/v2/FullReadStatsView.java @@ -0,0 +1,1020 @@ +/* + * Copyright 2020 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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/bigtable/v2/request_stats.proto + +package com.google.bigtable.v2; + +/** + * + * + *
+ * FullReadStatsView captures all known information about a read.
+ * 
+ * + * Protobuf type {@code google.bigtable.v2.FullReadStatsView} + */ +public final class FullReadStatsView extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.bigtable.v2.FullReadStatsView) + FullReadStatsViewOrBuilder { + private static final long serialVersionUID = 0L; + // Use FullReadStatsView.newBuilder() to construct. + private FullReadStatsView(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private FullReadStatsView() {} + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new FullReadStatsView(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.bigtable.v2.RequestStatsProto + .internal_static_google_bigtable_v2_FullReadStatsView_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.bigtable.v2.RequestStatsProto + .internal_static_google_bigtable_v2_FullReadStatsView_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.bigtable.v2.FullReadStatsView.class, + com.google.bigtable.v2.FullReadStatsView.Builder.class); + } + + public static final int READ_ITERATION_STATS_FIELD_NUMBER = 1; + private com.google.bigtable.v2.ReadIterationStats readIterationStats_; + /** + * + * + *
+   * Iteration stats describe how efficient the read is, e.g. comparing
+   * rows seen vs. rows returned or cells seen vs cells returned can provide an
+   * indication of read efficiency (the higher the ratio of seen to retuned the
+   * better).
+   * 
+ * + * .google.bigtable.v2.ReadIterationStats read_iteration_stats = 1; + * + * @return Whether the readIterationStats field is set. + */ + @java.lang.Override + public boolean hasReadIterationStats() { + return readIterationStats_ != null; + } + /** + * + * + *
+   * Iteration stats describe how efficient the read is, e.g. comparing
+   * rows seen vs. rows returned or cells seen vs cells returned can provide an
+   * indication of read efficiency (the higher the ratio of seen to retuned the
+   * better).
+   * 
+ * + * .google.bigtable.v2.ReadIterationStats read_iteration_stats = 1; + * + * @return The readIterationStats. + */ + @java.lang.Override + public com.google.bigtable.v2.ReadIterationStats getReadIterationStats() { + return readIterationStats_ == null + ? com.google.bigtable.v2.ReadIterationStats.getDefaultInstance() + : readIterationStats_; + } + /** + * + * + *
+   * Iteration stats describe how efficient the read is, e.g. comparing
+   * rows seen vs. rows returned or cells seen vs cells returned can provide an
+   * indication of read efficiency (the higher the ratio of seen to retuned the
+   * better).
+   * 
+ * + * .google.bigtable.v2.ReadIterationStats read_iteration_stats = 1; + */ + @java.lang.Override + public com.google.bigtable.v2.ReadIterationStatsOrBuilder getReadIterationStatsOrBuilder() { + return getReadIterationStats(); + } + + public static final int REQUEST_LATENCY_STATS_FIELD_NUMBER = 2; + private com.google.bigtable.v2.RequestLatencyStats requestLatencyStats_; + /** + * + * + *
+   * Request latency stats describe the time taken to complete a request, from
+   * the server side.
+   * 
+ * + * .google.bigtable.v2.RequestLatencyStats request_latency_stats = 2; + * + * @return Whether the requestLatencyStats field is set. + */ + @java.lang.Override + public boolean hasRequestLatencyStats() { + return requestLatencyStats_ != null; + } + /** + * + * + *
+   * Request latency stats describe the time taken to complete a request, from
+   * the server side.
+   * 
+ * + * .google.bigtable.v2.RequestLatencyStats request_latency_stats = 2; + * + * @return The requestLatencyStats. + */ + @java.lang.Override + public com.google.bigtable.v2.RequestLatencyStats getRequestLatencyStats() { + return requestLatencyStats_ == null + ? com.google.bigtable.v2.RequestLatencyStats.getDefaultInstance() + : requestLatencyStats_; + } + /** + * + * + *
+   * Request latency stats describe the time taken to complete a request, from
+   * the server side.
+   * 
+ * + * .google.bigtable.v2.RequestLatencyStats request_latency_stats = 2; + */ + @java.lang.Override + public com.google.bigtable.v2.RequestLatencyStatsOrBuilder getRequestLatencyStatsOrBuilder() { + return getRequestLatencyStats(); + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (readIterationStats_ != null) { + output.writeMessage(1, getReadIterationStats()); + } + if (requestLatencyStats_ != null) { + output.writeMessage(2, getRequestLatencyStats()); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (readIterationStats_ != null) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(1, getReadIterationStats()); + } + if (requestLatencyStats_ != null) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(2, getRequestLatencyStats()); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.bigtable.v2.FullReadStatsView)) { + return super.equals(obj); + } + com.google.bigtable.v2.FullReadStatsView other = (com.google.bigtable.v2.FullReadStatsView) obj; + + if (hasReadIterationStats() != other.hasReadIterationStats()) return false; + if (hasReadIterationStats()) { + if (!getReadIterationStats().equals(other.getReadIterationStats())) return false; + } + if (hasRequestLatencyStats() != other.hasRequestLatencyStats()) return false; + if (hasRequestLatencyStats()) { + if (!getRequestLatencyStats().equals(other.getRequestLatencyStats())) return false; + } + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + if (hasReadIterationStats()) { + hash = (37 * hash) + READ_ITERATION_STATS_FIELD_NUMBER; + hash = (53 * hash) + getReadIterationStats().hashCode(); + } + if (hasRequestLatencyStats()) { + hash = (37 * hash) + REQUEST_LATENCY_STATS_FIELD_NUMBER; + hash = (53 * hash) + getRequestLatencyStats().hashCode(); + } + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.bigtable.v2.FullReadStatsView parseFrom(java.nio.ByteBuffer data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.bigtable.v2.FullReadStatsView parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.bigtable.v2.FullReadStatsView parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.bigtable.v2.FullReadStatsView parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.bigtable.v2.FullReadStatsView parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.bigtable.v2.FullReadStatsView parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.bigtable.v2.FullReadStatsView parseFrom(java.io.InputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.bigtable.v2.FullReadStatsView parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.bigtable.v2.FullReadStatsView parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.bigtable.v2.FullReadStatsView parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.bigtable.v2.FullReadStatsView parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.bigtable.v2.FullReadStatsView parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder(com.google.bigtable.v2.FullReadStatsView prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + /** + * + * + *
+   * FullReadStatsView captures all known information about a read.
+   * 
+ * + * Protobuf type {@code google.bigtable.v2.FullReadStatsView} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.bigtable.v2.FullReadStatsView) + com.google.bigtable.v2.FullReadStatsViewOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.bigtable.v2.RequestStatsProto + .internal_static_google_bigtable_v2_FullReadStatsView_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.bigtable.v2.RequestStatsProto + .internal_static_google_bigtable_v2_FullReadStatsView_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.bigtable.v2.FullReadStatsView.class, + com.google.bigtable.v2.FullReadStatsView.Builder.class); + } + + // Construct using com.google.bigtable.v2.FullReadStatsView.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + } + + @java.lang.Override + public Builder clear() { + super.clear(); + if (readIterationStatsBuilder_ == null) { + readIterationStats_ = null; + } else { + readIterationStats_ = null; + readIterationStatsBuilder_ = null; + } + if (requestLatencyStatsBuilder_ == null) { + requestLatencyStats_ = null; + } else { + requestLatencyStats_ = null; + requestLatencyStatsBuilder_ = null; + } + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.bigtable.v2.RequestStatsProto + .internal_static_google_bigtable_v2_FullReadStatsView_descriptor; + } + + @java.lang.Override + public com.google.bigtable.v2.FullReadStatsView getDefaultInstanceForType() { + return com.google.bigtable.v2.FullReadStatsView.getDefaultInstance(); + } + + @java.lang.Override + public com.google.bigtable.v2.FullReadStatsView build() { + com.google.bigtable.v2.FullReadStatsView result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.bigtable.v2.FullReadStatsView buildPartial() { + com.google.bigtable.v2.FullReadStatsView result = + new com.google.bigtable.v2.FullReadStatsView(this); + if (readIterationStatsBuilder_ == null) { + result.readIterationStats_ = readIterationStats_; + } else { + result.readIterationStats_ = readIterationStatsBuilder_.build(); + } + if (requestLatencyStatsBuilder_ == null) { + result.requestLatencyStats_ = requestLatencyStats_; + } else { + result.requestLatencyStats_ = requestLatencyStatsBuilder_.build(); + } + onBuilt(); + return result; + } + + @java.lang.Override + public Builder clone() { + return super.clone(); + } + + @java.lang.Override + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.setField(field, value); + } + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); + } + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); + } + + @java.lang.Override + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { + return super.setRepeatedField(field, index, value); + } + + @java.lang.Override + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.addRepeatedField(field, value); + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.bigtable.v2.FullReadStatsView) { + return mergeFrom((com.google.bigtable.v2.FullReadStatsView) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.bigtable.v2.FullReadStatsView other) { + if (other == com.google.bigtable.v2.FullReadStatsView.getDefaultInstance()) return this; + if (other.hasReadIterationStats()) { + mergeReadIterationStats(other.getReadIterationStats()); + } + if (other.hasRequestLatencyStats()) { + mergeRequestLatencyStats(other.getRequestLatencyStats()); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + input.readMessage( + getReadIterationStatsFieldBuilder().getBuilder(), extensionRegistry); + + break; + } // case 10 + case 18: + { + input.readMessage( + getRequestLatencyStatsFieldBuilder().getBuilder(), extensionRegistry); + + break; + } // case 18 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private com.google.bigtable.v2.ReadIterationStats readIterationStats_; + private com.google.protobuf.SingleFieldBuilderV3< + com.google.bigtable.v2.ReadIterationStats, + com.google.bigtable.v2.ReadIterationStats.Builder, + com.google.bigtable.v2.ReadIterationStatsOrBuilder> + readIterationStatsBuilder_; + /** + * + * + *
+     * Iteration stats describe how efficient the read is, e.g. comparing
+     * rows seen vs. rows returned or cells seen vs cells returned can provide an
+     * indication of read efficiency (the higher the ratio of seen to retuned the
+     * better).
+     * 
+ * + * .google.bigtable.v2.ReadIterationStats read_iteration_stats = 1; + * + * @return Whether the readIterationStats field is set. + */ + public boolean hasReadIterationStats() { + return readIterationStatsBuilder_ != null || readIterationStats_ != null; + } + /** + * + * + *
+     * Iteration stats describe how efficient the read is, e.g. comparing
+     * rows seen vs. rows returned or cells seen vs cells returned can provide an
+     * indication of read efficiency (the higher the ratio of seen to retuned the
+     * better).
+     * 
+ * + * .google.bigtable.v2.ReadIterationStats read_iteration_stats = 1; + * + * @return The readIterationStats. + */ + public com.google.bigtable.v2.ReadIterationStats getReadIterationStats() { + if (readIterationStatsBuilder_ == null) { + return readIterationStats_ == null + ? com.google.bigtable.v2.ReadIterationStats.getDefaultInstance() + : readIterationStats_; + } else { + return readIterationStatsBuilder_.getMessage(); + } + } + /** + * + * + *
+     * Iteration stats describe how efficient the read is, e.g. comparing
+     * rows seen vs. rows returned or cells seen vs cells returned can provide an
+     * indication of read efficiency (the higher the ratio of seen to retuned the
+     * better).
+     * 
+ * + * .google.bigtable.v2.ReadIterationStats read_iteration_stats = 1; + */ + public Builder setReadIterationStats(com.google.bigtable.v2.ReadIterationStats value) { + if (readIterationStatsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + readIterationStats_ = value; + onChanged(); + } else { + readIterationStatsBuilder_.setMessage(value); + } + + return this; + } + /** + * + * + *
+     * Iteration stats describe how efficient the read is, e.g. comparing
+     * rows seen vs. rows returned or cells seen vs cells returned can provide an
+     * indication of read efficiency (the higher the ratio of seen to retuned the
+     * better).
+     * 
+ * + * .google.bigtable.v2.ReadIterationStats read_iteration_stats = 1; + */ + public Builder setReadIterationStats( + com.google.bigtable.v2.ReadIterationStats.Builder builderForValue) { + if (readIterationStatsBuilder_ == null) { + readIterationStats_ = builderForValue.build(); + onChanged(); + } else { + readIterationStatsBuilder_.setMessage(builderForValue.build()); + } + + return this; + } + /** + * + * + *
+     * Iteration stats describe how efficient the read is, e.g. comparing
+     * rows seen vs. rows returned or cells seen vs cells returned can provide an
+     * indication of read efficiency (the higher the ratio of seen to retuned the
+     * better).
+     * 
+ * + * .google.bigtable.v2.ReadIterationStats read_iteration_stats = 1; + */ + public Builder mergeReadIterationStats(com.google.bigtable.v2.ReadIterationStats value) { + if (readIterationStatsBuilder_ == null) { + if (readIterationStats_ != null) { + readIterationStats_ = + com.google.bigtable.v2.ReadIterationStats.newBuilder(readIterationStats_) + .mergeFrom(value) + .buildPartial(); + } else { + readIterationStats_ = value; + } + onChanged(); + } else { + readIterationStatsBuilder_.mergeFrom(value); + } + + return this; + } + /** + * + * + *
+     * Iteration stats describe how efficient the read is, e.g. comparing
+     * rows seen vs. rows returned or cells seen vs cells returned can provide an
+     * indication of read efficiency (the higher the ratio of seen to retuned the
+     * better).
+     * 
+ * + * .google.bigtable.v2.ReadIterationStats read_iteration_stats = 1; + */ + public Builder clearReadIterationStats() { + if (readIterationStatsBuilder_ == null) { + readIterationStats_ = null; + onChanged(); + } else { + readIterationStats_ = null; + readIterationStatsBuilder_ = null; + } + + return this; + } + /** + * + * + *
+     * Iteration stats describe how efficient the read is, e.g. comparing
+     * rows seen vs. rows returned or cells seen vs cells returned can provide an
+     * indication of read efficiency (the higher the ratio of seen to retuned the
+     * better).
+     * 
+ * + * .google.bigtable.v2.ReadIterationStats read_iteration_stats = 1; + */ + public com.google.bigtable.v2.ReadIterationStats.Builder getReadIterationStatsBuilder() { + + onChanged(); + return getReadIterationStatsFieldBuilder().getBuilder(); + } + /** + * + * + *
+     * Iteration stats describe how efficient the read is, e.g. comparing
+     * rows seen vs. rows returned or cells seen vs cells returned can provide an
+     * indication of read efficiency (the higher the ratio of seen to retuned the
+     * better).
+     * 
+ * + * .google.bigtable.v2.ReadIterationStats read_iteration_stats = 1; + */ + public com.google.bigtable.v2.ReadIterationStatsOrBuilder getReadIterationStatsOrBuilder() { + if (readIterationStatsBuilder_ != null) { + return readIterationStatsBuilder_.getMessageOrBuilder(); + } else { + return readIterationStats_ == null + ? com.google.bigtable.v2.ReadIterationStats.getDefaultInstance() + : readIterationStats_; + } + } + /** + * + * + *
+     * Iteration stats describe how efficient the read is, e.g. comparing
+     * rows seen vs. rows returned or cells seen vs cells returned can provide an
+     * indication of read efficiency (the higher the ratio of seen to retuned the
+     * better).
+     * 
+ * + * .google.bigtable.v2.ReadIterationStats read_iteration_stats = 1; + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.bigtable.v2.ReadIterationStats, + com.google.bigtable.v2.ReadIterationStats.Builder, + com.google.bigtable.v2.ReadIterationStatsOrBuilder> + getReadIterationStatsFieldBuilder() { + if (readIterationStatsBuilder_ == null) { + readIterationStatsBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.bigtable.v2.ReadIterationStats, + com.google.bigtable.v2.ReadIterationStats.Builder, + com.google.bigtable.v2.ReadIterationStatsOrBuilder>( + getReadIterationStats(), getParentForChildren(), isClean()); + readIterationStats_ = null; + } + return readIterationStatsBuilder_; + } + + private com.google.bigtable.v2.RequestLatencyStats requestLatencyStats_; + private com.google.protobuf.SingleFieldBuilderV3< + com.google.bigtable.v2.RequestLatencyStats, + com.google.bigtable.v2.RequestLatencyStats.Builder, + com.google.bigtable.v2.RequestLatencyStatsOrBuilder> + requestLatencyStatsBuilder_; + /** + * + * + *
+     * Request latency stats describe the time taken to complete a request, from
+     * the server side.
+     * 
+ * + * .google.bigtable.v2.RequestLatencyStats request_latency_stats = 2; + * + * @return Whether the requestLatencyStats field is set. + */ + public boolean hasRequestLatencyStats() { + return requestLatencyStatsBuilder_ != null || requestLatencyStats_ != null; + } + /** + * + * + *
+     * Request latency stats describe the time taken to complete a request, from
+     * the server side.
+     * 
+ * + * .google.bigtable.v2.RequestLatencyStats request_latency_stats = 2; + * + * @return The requestLatencyStats. + */ + public com.google.bigtable.v2.RequestLatencyStats getRequestLatencyStats() { + if (requestLatencyStatsBuilder_ == null) { + return requestLatencyStats_ == null + ? com.google.bigtable.v2.RequestLatencyStats.getDefaultInstance() + : requestLatencyStats_; + } else { + return requestLatencyStatsBuilder_.getMessage(); + } + } + /** + * + * + *
+     * Request latency stats describe the time taken to complete a request, from
+     * the server side.
+     * 
+ * + * .google.bigtable.v2.RequestLatencyStats request_latency_stats = 2; + */ + public Builder setRequestLatencyStats(com.google.bigtable.v2.RequestLatencyStats value) { + if (requestLatencyStatsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + requestLatencyStats_ = value; + onChanged(); + } else { + requestLatencyStatsBuilder_.setMessage(value); + } + + return this; + } + /** + * + * + *
+     * Request latency stats describe the time taken to complete a request, from
+     * the server side.
+     * 
+ * + * .google.bigtable.v2.RequestLatencyStats request_latency_stats = 2; + */ + public Builder setRequestLatencyStats( + com.google.bigtable.v2.RequestLatencyStats.Builder builderForValue) { + if (requestLatencyStatsBuilder_ == null) { + requestLatencyStats_ = builderForValue.build(); + onChanged(); + } else { + requestLatencyStatsBuilder_.setMessage(builderForValue.build()); + } + + return this; + } + /** + * + * + *
+     * Request latency stats describe the time taken to complete a request, from
+     * the server side.
+     * 
+ * + * .google.bigtable.v2.RequestLatencyStats request_latency_stats = 2; + */ + public Builder mergeRequestLatencyStats(com.google.bigtable.v2.RequestLatencyStats value) { + if (requestLatencyStatsBuilder_ == null) { + if (requestLatencyStats_ != null) { + requestLatencyStats_ = + com.google.bigtable.v2.RequestLatencyStats.newBuilder(requestLatencyStats_) + .mergeFrom(value) + .buildPartial(); + } else { + requestLatencyStats_ = value; + } + onChanged(); + } else { + requestLatencyStatsBuilder_.mergeFrom(value); + } + + return this; + } + /** + * + * + *
+     * Request latency stats describe the time taken to complete a request, from
+     * the server side.
+     * 
+ * + * .google.bigtable.v2.RequestLatencyStats request_latency_stats = 2; + */ + public Builder clearRequestLatencyStats() { + if (requestLatencyStatsBuilder_ == null) { + requestLatencyStats_ = null; + onChanged(); + } else { + requestLatencyStats_ = null; + requestLatencyStatsBuilder_ = null; + } + + return this; + } + /** + * + * + *
+     * Request latency stats describe the time taken to complete a request, from
+     * the server side.
+     * 
+ * + * .google.bigtable.v2.RequestLatencyStats request_latency_stats = 2; + */ + public com.google.bigtable.v2.RequestLatencyStats.Builder getRequestLatencyStatsBuilder() { + + onChanged(); + return getRequestLatencyStatsFieldBuilder().getBuilder(); + } + /** + * + * + *
+     * Request latency stats describe the time taken to complete a request, from
+     * the server side.
+     * 
+ * + * .google.bigtable.v2.RequestLatencyStats request_latency_stats = 2; + */ + public com.google.bigtable.v2.RequestLatencyStatsOrBuilder getRequestLatencyStatsOrBuilder() { + if (requestLatencyStatsBuilder_ != null) { + return requestLatencyStatsBuilder_.getMessageOrBuilder(); + } else { + return requestLatencyStats_ == null + ? com.google.bigtable.v2.RequestLatencyStats.getDefaultInstance() + : requestLatencyStats_; + } + } + /** + * + * + *
+     * Request latency stats describe the time taken to complete a request, from
+     * the server side.
+     * 
+ * + * .google.bigtable.v2.RequestLatencyStats request_latency_stats = 2; + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.bigtable.v2.RequestLatencyStats, + com.google.bigtable.v2.RequestLatencyStats.Builder, + com.google.bigtable.v2.RequestLatencyStatsOrBuilder> + getRequestLatencyStatsFieldBuilder() { + if (requestLatencyStatsBuilder_ == null) { + requestLatencyStatsBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.bigtable.v2.RequestLatencyStats, + com.google.bigtable.v2.RequestLatencyStats.Builder, + com.google.bigtable.v2.RequestLatencyStatsOrBuilder>( + getRequestLatencyStats(), getParentForChildren(), isClean()); + requestLatencyStats_ = null; + } + return requestLatencyStatsBuilder_; + } + + @java.lang.Override + public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFields(unknownFields); + } + + @java.lang.Override + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + // @@protoc_insertion_point(builder_scope:google.bigtable.v2.FullReadStatsView) + } + + // @@protoc_insertion_point(class_scope:google.bigtable.v2.FullReadStatsView) + private static final com.google.bigtable.v2.FullReadStatsView DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.bigtable.v2.FullReadStatsView(); + } + + public static com.google.bigtable.v2.FullReadStatsView getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public FullReadStatsView parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.bigtable.v2.FullReadStatsView getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/proto-google-cloud-bigtable-v2/src/main/java/com/google/bigtable/v2/FullReadStatsViewOrBuilder.java b/proto-google-cloud-bigtable-v2/src/main/java/com/google/bigtable/v2/FullReadStatsViewOrBuilder.java new file mode 100644 index 0000000000..e98b57f732 --- /dev/null +++ b/proto-google-cloud-bigtable-v2/src/main/java/com/google/bigtable/v2/FullReadStatsViewOrBuilder.java @@ -0,0 +1,107 @@ +/* + * Copyright 2020 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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/bigtable/v2/request_stats.proto + +package com.google.bigtable.v2; + +public interface FullReadStatsViewOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.bigtable.v2.FullReadStatsView) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * Iteration stats describe how efficient the read is, e.g. comparing
+   * rows seen vs. rows returned or cells seen vs cells returned can provide an
+   * indication of read efficiency (the higher the ratio of seen to retuned the
+   * better).
+   * 
+ * + * .google.bigtable.v2.ReadIterationStats read_iteration_stats = 1; + * + * @return Whether the readIterationStats field is set. + */ + boolean hasReadIterationStats(); + /** + * + * + *
+   * Iteration stats describe how efficient the read is, e.g. comparing
+   * rows seen vs. rows returned or cells seen vs cells returned can provide an
+   * indication of read efficiency (the higher the ratio of seen to retuned the
+   * better).
+   * 
+ * + * .google.bigtable.v2.ReadIterationStats read_iteration_stats = 1; + * + * @return The readIterationStats. + */ + com.google.bigtable.v2.ReadIterationStats getReadIterationStats(); + /** + * + * + *
+   * Iteration stats describe how efficient the read is, e.g. comparing
+   * rows seen vs. rows returned or cells seen vs cells returned can provide an
+   * indication of read efficiency (the higher the ratio of seen to retuned the
+   * better).
+   * 
+ * + * .google.bigtable.v2.ReadIterationStats read_iteration_stats = 1; + */ + com.google.bigtable.v2.ReadIterationStatsOrBuilder getReadIterationStatsOrBuilder(); + + /** + * + * + *
+   * Request latency stats describe the time taken to complete a request, from
+   * the server side.
+   * 
+ * + * .google.bigtable.v2.RequestLatencyStats request_latency_stats = 2; + * + * @return Whether the requestLatencyStats field is set. + */ + boolean hasRequestLatencyStats(); + /** + * + * + *
+   * Request latency stats describe the time taken to complete a request, from
+   * the server side.
+   * 
+ * + * .google.bigtable.v2.RequestLatencyStats request_latency_stats = 2; + * + * @return The requestLatencyStats. + */ + com.google.bigtable.v2.RequestLatencyStats getRequestLatencyStats(); + /** + * + * + *
+   * Request latency stats describe the time taken to complete a request, from
+   * the server side.
+   * 
+ * + * .google.bigtable.v2.RequestLatencyStats request_latency_stats = 2; + */ + com.google.bigtable.v2.RequestLatencyStatsOrBuilder getRequestLatencyStatsOrBuilder(); +} diff --git a/proto-google-cloud-bigtable-v2/src/main/java/com/google/bigtable/v2/MutateRowRequest.java b/proto-google-cloud-bigtable-v2/src/main/java/com/google/bigtable/v2/MutateRowRequest.java index 6e46da8f24..00c657bb3a 100644 --- a/proto-google-cloud-bigtable-v2/src/main/java/com/google/bigtable/v2/MutateRowRequest.java +++ b/proto-google-cloud-bigtable-v2/src/main/java/com/google/bigtable/v2/MutateRowRequest.java @@ -55,78 +55,6 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - private MutateRowRequest( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - int mutable_bitField0_ = 0; - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - java.lang.String s = input.readStringRequireUtf8(); - - tableName_ = s; - break; - } - case 18: - { - rowKey_ = input.readBytes(); - break; - } - case 26: - { - if (!((mutable_bitField0_ & 0x00000001) != 0)) { - mutations_ = new java.util.ArrayList(); - mutable_bitField0_ |= 0x00000001; - } - mutations_.add( - input.readMessage(com.google.bigtable.v2.Mutation.parser(), extensionRegistry)); - break; - } - case 34: - { - java.lang.String s = input.readStringRequireUtf8(); - - appProfileId_ = s; - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); - } finally { - if (((mutable_bitField0_ & 0x00000001) != 0)) { - mutations_ = java.util.Collections.unmodifiableList(mutations_); - } - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.bigtable.v2.BigtableProto .internal_static_google_bigtable_v2_MutateRowRequest_descriptor; @@ -383,7 +311,7 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(appProfileId_)) { com.google.protobuf.GeneratedMessageV3.writeString(output, 4, appProfileId_); } - unknownFields.writeTo(output); + getUnknownFields().writeTo(output); } @java.lang.Override @@ -404,7 +332,7 @@ public int getSerializedSize() { if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(appProfileId_)) { size += com.google.protobuf.GeneratedMessageV3.computeStringSize(4, appProfileId_); } - size += unknownFields.getSerializedSize(); + size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @@ -423,7 +351,7 @@ public boolean equals(final java.lang.Object obj) { if (!getAppProfileId().equals(other.getAppProfileId())) return false; if (!getRowKey().equals(other.getRowKey())) return false; if (!getMutationsList().equals(other.getMutationsList())) return false; - if (!unknownFields.equals(other.unknownFields)) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -444,7 +372,7 @@ public int hashCode() { hash = (37 * hash) + MUTATIONS_FIELD_NUMBER; hash = (53 * hash) + getMutationsList().hashCode(); } - hash = (29 * hash) + unknownFields.hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } @@ -573,19 +501,10 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { } // Construct using com.google.bigtable.v2.MutateRowRequest.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } + private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) { - getMutationsFieldBuilder(); - } } @java.lang.Override @@ -599,10 +518,11 @@ public Builder clear() { if (mutationsBuilder_ == null) { mutations_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000001); } else { + mutations_ = null; mutationsBuilder_.clear(); } + bitField0_ = (bitField0_ & ~0x00000001); return this; } @@ -730,7 +650,7 @@ public Builder mergeFrom(com.google.bigtable.v2.MutateRowRequest other) { } } } - this.mergeUnknownFields(other.unknownFields); + this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @@ -745,17 +665,61 @@ public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - com.google.bigtable.v2.MutateRowRequest parsedMessage = null; + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + tableName_ = input.readStringRequireUtf8(); + + break; + } // case 10 + case 18: + { + rowKey_ = input.readBytes(); + + break; + } // case 18 + case 26: + { + com.google.bigtable.v2.Mutation m = + input.readMessage(com.google.bigtable.v2.Mutation.parser(), extensionRegistry); + if (mutationsBuilder_ == null) { + ensureMutationsIsMutable(); + mutations_.add(m); + } else { + mutationsBuilder_.addMessage(m); + } + break; + } // case 26 + case 34: + { + appProfileId_ = input.readStringRequireUtf8(); + + break; + } // case 34 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.bigtable.v2.MutateRowRequest) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } + onChanged(); + } // finally return this; } @@ -1505,7 +1469,18 @@ public MutateRowRequest parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new MutateRowRequest(input, extensionRegistry); + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); } }; diff --git a/proto-google-cloud-bigtable-v2/src/main/java/com/google/bigtable/v2/MutateRowResponse.java b/proto-google-cloud-bigtable-v2/src/main/java/com/google/bigtable/v2/MutateRowResponse.java index 90ee12a5a4..154c3818b9 100644 --- a/proto-google-cloud-bigtable-v2/src/main/java/com/google/bigtable/v2/MutateRowResponse.java +++ b/proto-google-cloud-bigtable-v2/src/main/java/com/google/bigtable/v2/MutateRowResponse.java @@ -50,45 +50,6 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - private MutateRowResponse( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.bigtable.v2.BigtableProto .internal_static_google_bigtable_v2_MutateRowResponse_descriptor; @@ -118,7 +79,7 @@ public final boolean isInitialized() { @java.lang.Override public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { - unknownFields.writeTo(output); + getUnknownFields().writeTo(output); } @java.lang.Override @@ -127,7 +88,7 @@ public int getSerializedSize() { if (size != -1) return size; size = 0; - size += unknownFields.getSerializedSize(); + size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @@ -142,7 +103,7 @@ public boolean equals(final java.lang.Object obj) { } com.google.bigtable.v2.MutateRowResponse other = (com.google.bigtable.v2.MutateRowResponse) obj; - if (!unknownFields.equals(other.unknownFields)) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -153,7 +114,7 @@ public int hashCode() { } int hash = 41; hash = (19 * hash) + getDescriptor().hashCode(); - hash = (29 * hash) + unknownFields.hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } @@ -282,17 +243,10 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { } // Construct using com.google.bigtable.v2.MutateRowResponse.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } + private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} } @java.lang.Override @@ -374,7 +328,7 @@ public Builder mergeFrom(com.google.protobuf.Message other) { public Builder mergeFrom(com.google.bigtable.v2.MutateRowResponse other) { if (other == com.google.bigtable.v2.MutateRowResponse.getDefaultInstance()) return this; - this.mergeUnknownFields(other.unknownFields); + this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @@ -389,17 +343,31 @@ public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - com.google.bigtable.v2.MutateRowResponse parsedMessage = null; + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.bigtable.v2.MutateRowResponse) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } + onChanged(); + } // finally return this; } @@ -435,7 +403,18 @@ public MutateRowResponse parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new MutateRowResponse(input, extensionRegistry); + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); } }; diff --git a/proto-google-cloud-bigtable-v2/src/main/java/com/google/bigtable/v2/MutateRowsRequest.java b/proto-google-cloud-bigtable-v2/src/main/java/com/google/bigtable/v2/MutateRowsRequest.java index e0aed28a41..72a373f79d 100644 --- a/proto-google-cloud-bigtable-v2/src/main/java/com/google/bigtable/v2/MutateRowsRequest.java +++ b/proto-google-cloud-bigtable-v2/src/main/java/com/google/bigtable/v2/MutateRowsRequest.java @@ -54,75 +54,6 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - private MutateRowsRequest( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - int mutable_bitField0_ = 0; - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - java.lang.String s = input.readStringRequireUtf8(); - - tableName_ = s; - break; - } - case 18: - { - if (!((mutable_bitField0_ & 0x00000001) != 0)) { - entries_ = - new java.util.ArrayList(); - mutable_bitField0_ |= 0x00000001; - } - entries_.add( - input.readMessage( - com.google.bigtable.v2.MutateRowsRequest.Entry.parser(), extensionRegistry)); - break; - } - case 26: - { - java.lang.String s = input.readStringRequireUtf8(); - - appProfileId_ = s; - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); - } finally { - if (((mutable_bitField0_ & 0x00000001) != 0)) { - entries_ = java.util.Collections.unmodifiableList(entries_); - } - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.bigtable.v2.BigtableProto .internal_static_google_bigtable_v2_MutateRowsRequest_descriptor; @@ -267,64 +198,6 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - private Entry( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - int mutable_bitField0_ = 0; - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - rowKey_ = input.readBytes(); - break; - } - case 18: - { - if (!((mutable_bitField0_ & 0x00000001) != 0)) { - mutations_ = new java.util.ArrayList(); - mutable_bitField0_ |= 0x00000001; - } - mutations_.add( - input.readMessage(com.google.bigtable.v2.Mutation.parser(), extensionRegistry)); - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); - } finally { - if (((mutable_bitField0_ & 0x00000001) != 0)) { - mutations_ = java.util.Collections.unmodifiableList(mutations_); - } - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.bigtable.v2.BigtableProto .internal_static_google_bigtable_v2_MutateRowsRequest_Entry_descriptor; @@ -472,7 +345,7 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io for (int i = 0; i < mutations_.size(); i++) { output.writeMessage(2, mutations_.get(i)); } - unknownFields.writeTo(output); + getUnknownFields().writeTo(output); } @java.lang.Override @@ -487,7 +360,7 @@ public int getSerializedSize() { for (int i = 0; i < mutations_.size(); i++) { size += com.google.protobuf.CodedOutputStream.computeMessageSize(2, mutations_.get(i)); } - size += unknownFields.getSerializedSize(); + size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @@ -505,7 +378,7 @@ public boolean equals(final java.lang.Object obj) { if (!getRowKey().equals(other.getRowKey())) return false; if (!getMutationsList().equals(other.getMutationsList())) return false; - if (!unknownFields.equals(other.unknownFields)) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -522,7 +395,7 @@ public int hashCode() { hash = (37 * hash) + MUTATIONS_FIELD_NUMBER; hash = (53 * hash) + getMutationsList().hashCode(); } - hash = (29 * hash) + unknownFields.hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } @@ -653,19 +526,10 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { } // Construct using com.google.bigtable.v2.MutateRowsRequest.Entry.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } + private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) { - getMutationsFieldBuilder(); - } } @java.lang.Override @@ -675,10 +539,11 @@ public Builder clear() { if (mutationsBuilder_ == null) { mutations_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000001); } else { + mutations_ = null; mutationsBuilder_.clear(); } + bitField0_ = (bitField0_ & ~0x00000001); return this; } @@ -799,7 +664,7 @@ public Builder mergeFrom(com.google.bigtable.v2.MutateRowsRequest.Entry other) { } } } - this.mergeUnknownFields(other.unknownFields); + this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @@ -814,17 +679,50 @@ public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - com.google.bigtable.v2.MutateRowsRequest.Entry parsedMessage = null; + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + rowKey_ = input.readBytes(); + + break; + } // case 10 + case 18: + { + com.google.bigtable.v2.Mutation m = + input.readMessage( + com.google.bigtable.v2.Mutation.parser(), extensionRegistry); + if (mutationsBuilder_ == null) { + ensureMutationsIsMutable(); + mutations_.add(m); + } else { + mutationsBuilder_.addMessage(m); + } + break; + } // case 18 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.bigtable.v2.MutateRowsRequest.Entry) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } + onChanged(); + } // finally return this; } @@ -1356,7 +1254,19 @@ public Entry parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new Entry(input, extensionRegistry); + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException() + .setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); } }; @@ -1601,7 +1511,7 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(appProfileId_)) { com.google.protobuf.GeneratedMessageV3.writeString(output, 3, appProfileId_); } - unknownFields.writeTo(output); + getUnknownFields().writeTo(output); } @java.lang.Override @@ -1619,7 +1529,7 @@ public int getSerializedSize() { if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(appProfileId_)) { size += com.google.protobuf.GeneratedMessageV3.computeStringSize(3, appProfileId_); } - size += unknownFields.getSerializedSize(); + size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @@ -1637,7 +1547,7 @@ public boolean equals(final java.lang.Object obj) { if (!getTableName().equals(other.getTableName())) return false; if (!getAppProfileId().equals(other.getAppProfileId())) return false; if (!getEntriesList().equals(other.getEntriesList())) return false; - if (!unknownFields.equals(other.unknownFields)) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -1656,7 +1566,7 @@ public int hashCode() { hash = (37 * hash) + ENTRIES_FIELD_NUMBER; hash = (53 * hash) + getEntriesList().hashCode(); } - hash = (29 * hash) + unknownFields.hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } @@ -1785,19 +1695,10 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { } // Construct using com.google.bigtable.v2.MutateRowsRequest.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } + private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) { - getEntriesFieldBuilder(); - } } @java.lang.Override @@ -1809,10 +1710,11 @@ public Builder clear() { if (entriesBuilder_ == null) { entries_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000001); } else { + entries_ = null; entriesBuilder_.clear(); } + bitField0_ = (bitField0_ & ~0x00000001); return this; } @@ -1936,7 +1838,7 @@ public Builder mergeFrom(com.google.bigtable.v2.MutateRowsRequest other) { } } } - this.mergeUnknownFields(other.unknownFields); + this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @@ -1951,17 +1853,56 @@ public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - com.google.bigtable.v2.MutateRowsRequest parsedMessage = null; + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + tableName_ = input.readStringRequireUtf8(); + + break; + } // case 10 + case 18: + { + com.google.bigtable.v2.MutateRowsRequest.Entry m = + input.readMessage( + com.google.bigtable.v2.MutateRowsRequest.Entry.parser(), extensionRegistry); + if (entriesBuilder_ == null) { + ensureEntriesIsMutable(); + entries_.add(m); + } else { + entriesBuilder_.addMessage(m); + } + break; + } // case 18 + case 26: + { + appProfileId_ = input.readStringRequireUtf8(); + + break; + } // case 26 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.bigtable.v2.MutateRowsRequest) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } + onChanged(); + } // finally return this; } @@ -2685,7 +2626,18 @@ public MutateRowsRequest parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new MutateRowsRequest(input, extensionRegistry); + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); } }; diff --git a/proto-google-cloud-bigtable-v2/src/main/java/com/google/bigtable/v2/MutateRowsResponse.java b/proto-google-cloud-bigtable-v2/src/main/java/com/google/bigtable/v2/MutateRowsResponse.java index 6f3b818671..783b6f4faa 100644 --- a/proto-google-cloud-bigtable-v2/src/main/java/com/google/bigtable/v2/MutateRowsResponse.java +++ b/proto-google-cloud-bigtable-v2/src/main/java/com/google/bigtable/v2/MutateRowsResponse.java @@ -52,61 +52,6 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - private MutateRowsResponse( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - int mutable_bitField0_ = 0; - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - if (!((mutable_bitField0_ & 0x00000001) != 0)) { - entries_ = - new java.util.ArrayList(); - mutable_bitField0_ |= 0x00000001; - } - entries_.add( - input.readMessage( - com.google.bigtable.v2.MutateRowsResponse.Entry.parser(), extensionRegistry)); - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); - } finally { - if (((mutable_bitField0_ & 0x00000001) != 0)) { - entries_ = java.util.Collections.unmodifiableList(entries_); - } - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.bigtable.v2.BigtableProto .internal_static_google_bigtable_v2_MutateRowsResponse_descriptor; @@ -217,64 +162,6 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - private Entry( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 8: - { - index_ = input.readInt64(); - break; - } - case 18: - { - com.google.rpc.Status.Builder subBuilder = null; - if (status_ != null) { - subBuilder = status_.toBuilder(); - } - status_ = input.readMessage(com.google.rpc.Status.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(status_); - status_ = subBuilder.buildPartial(); - } - - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.bigtable.v2.BigtableProto .internal_static_google_bigtable_v2_MutateRowsResponse_Entry_descriptor; @@ -384,7 +271,7 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io if (status_ != null) { output.writeMessage(2, getStatus()); } - unknownFields.writeTo(output); + getUnknownFields().writeTo(output); } @java.lang.Override @@ -399,7 +286,7 @@ public int getSerializedSize() { if (status_ != null) { size += com.google.protobuf.CodedOutputStream.computeMessageSize(2, getStatus()); } - size += unknownFields.getSerializedSize(); + size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @@ -420,7 +307,7 @@ public boolean equals(final java.lang.Object obj) { if (hasStatus()) { if (!getStatus().equals(other.getStatus())) return false; } - if (!unknownFields.equals(other.unknownFields)) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -437,7 +324,7 @@ public int hashCode() { hash = (37 * hash) + STATUS_FIELD_NUMBER; hash = (53 * hash) + getStatus().hashCode(); } - hash = (29 * hash) + unknownFields.hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } @@ -568,17 +455,10 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { } // Construct using com.google.bigtable.v2.MutateRowsResponse.Entry.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } + private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} } @java.lang.Override @@ -683,7 +563,7 @@ public Builder mergeFrom(com.google.bigtable.v2.MutateRowsResponse.Entry other) if (other.hasStatus()) { mergeStatus(other.getStatus()); } - this.mergeUnknownFields(other.unknownFields); + this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @@ -698,18 +578,43 @@ public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - com.google.bigtable.v2.MutateRowsResponse.Entry parsedMessage = null; + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 8: + { + index_ = input.readInt64(); + + break; + } // case 8 + case 18: + { + input.readMessage(getStatusFieldBuilder().getBuilder(), extensionRegistry); + + break; + } // case 18 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = - (com.google.bigtable.v2.MutateRowsResponse.Entry) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } + onChanged(); + } // finally return this; } @@ -1001,7 +906,19 @@ public Entry parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new Entry(input, extensionRegistry); + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException() + .setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); } }; @@ -1106,7 +1023,7 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io for (int i = 0; i < entries_.size(); i++) { output.writeMessage(1, entries_.get(i)); } - unknownFields.writeTo(output); + getUnknownFields().writeTo(output); } @java.lang.Override @@ -1118,7 +1035,7 @@ public int getSerializedSize() { for (int i = 0; i < entries_.size(); i++) { size += com.google.protobuf.CodedOutputStream.computeMessageSize(1, entries_.get(i)); } - size += unknownFields.getSerializedSize(); + size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @@ -1135,7 +1052,7 @@ public boolean equals(final java.lang.Object obj) { (com.google.bigtable.v2.MutateRowsResponse) obj; if (!getEntriesList().equals(other.getEntriesList())) return false; - if (!unknownFields.equals(other.unknownFields)) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -1150,7 +1067,7 @@ public int hashCode() { hash = (37 * hash) + ENTRIES_FIELD_NUMBER; hash = (53 * hash) + getEntriesList().hashCode(); } - hash = (29 * hash) + unknownFields.hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } @@ -1279,19 +1196,10 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { } // Construct using com.google.bigtable.v2.MutateRowsResponse.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } + private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) { - getEntriesFieldBuilder(); - } } @java.lang.Override @@ -1299,10 +1207,11 @@ public Builder clear() { super.clear(); if (entriesBuilder_ == null) { entries_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000001); } else { + entries_ = null; entriesBuilder_.clear(); } + bitField0_ = (bitField0_ & ~0x00000001); return this; } @@ -1416,7 +1325,7 @@ public Builder mergeFrom(com.google.bigtable.v2.MutateRowsResponse other) { } } } - this.mergeUnknownFields(other.unknownFields); + this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @@ -1431,17 +1340,45 @@ public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - com.google.bigtable.v2.MutateRowsResponse parsedMessage = null; + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + com.google.bigtable.v2.MutateRowsResponse.Entry m = + input.readMessage( + com.google.bigtable.v2.MutateRowsResponse.Entry.parser(), + extensionRegistry); + if (entriesBuilder_ == null) { + ensureEntriesIsMutable(); + entries_.add(m); + } else { + entriesBuilder_.addMessage(m); + } + break; + } // case 10 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.bigtable.v2.MutateRowsResponse) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } + onChanged(); + } // finally return this; } @@ -1830,7 +1767,18 @@ public MutateRowsResponse parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new MutateRowsResponse(input, extensionRegistry); + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); } }; diff --git a/proto-google-cloud-bigtable-v2/src/main/java/com/google/bigtable/v2/Mutation.java b/proto-google-cloud-bigtable-v2/src/main/java/com/google/bigtable/v2/Mutation.java index 62b4124598..177339dfa8 100644 --- a/proto-google-cloud-bigtable-v2/src/main/java/com/google/bigtable/v2/Mutation.java +++ b/proto-google-cloud-bigtable-v2/src/main/java/com/google/bigtable/v2/Mutation.java @@ -50,112 +50,6 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - private Mutation( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - com.google.bigtable.v2.Mutation.SetCell.Builder subBuilder = null; - if (mutationCase_ == 1) { - subBuilder = ((com.google.bigtable.v2.Mutation.SetCell) mutation_).toBuilder(); - } - mutation_ = - input.readMessage( - com.google.bigtable.v2.Mutation.SetCell.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom((com.google.bigtable.v2.Mutation.SetCell) mutation_); - mutation_ = subBuilder.buildPartial(); - } - mutationCase_ = 1; - break; - } - case 18: - { - com.google.bigtable.v2.Mutation.DeleteFromColumn.Builder subBuilder = null; - if (mutationCase_ == 2) { - subBuilder = - ((com.google.bigtable.v2.Mutation.DeleteFromColumn) mutation_).toBuilder(); - } - mutation_ = - input.readMessage( - com.google.bigtable.v2.Mutation.DeleteFromColumn.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom((com.google.bigtable.v2.Mutation.DeleteFromColumn) mutation_); - mutation_ = subBuilder.buildPartial(); - } - mutationCase_ = 2; - break; - } - case 26: - { - com.google.bigtable.v2.Mutation.DeleteFromFamily.Builder subBuilder = null; - if (mutationCase_ == 3) { - subBuilder = - ((com.google.bigtable.v2.Mutation.DeleteFromFamily) mutation_).toBuilder(); - } - mutation_ = - input.readMessage( - com.google.bigtable.v2.Mutation.DeleteFromFamily.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom((com.google.bigtable.v2.Mutation.DeleteFromFamily) mutation_); - mutation_ = subBuilder.buildPartial(); - } - mutationCase_ = 3; - break; - } - case 34: - { - com.google.bigtable.v2.Mutation.DeleteFromRow.Builder subBuilder = null; - if (mutationCase_ == 4) { - subBuilder = - ((com.google.bigtable.v2.Mutation.DeleteFromRow) mutation_).toBuilder(); - } - mutation_ = - input.readMessage( - com.google.bigtable.v2.Mutation.DeleteFromRow.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom((com.google.bigtable.v2.Mutation.DeleteFromRow) mutation_); - mutation_ = subBuilder.buildPartial(); - } - mutationCase_ = 4; - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.bigtable.v2.DataProto.internal_static_google_bigtable_v2_Mutation_descriptor; } @@ -281,67 +175,6 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - private SetCell( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - java.lang.String s = input.readStringRequireUtf8(); - - familyName_ = s; - break; - } - case 18: - { - columnQualifier_ = input.readBytes(); - break; - } - case 24: - { - timestampMicros_ = input.readInt64(); - break; - } - case 34: - { - value_ = input.readBytes(); - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.bigtable.v2.DataProto .internal_static_google_bigtable_v2_Mutation_SetCell_descriptor; @@ -493,7 +326,7 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io if (!value_.isEmpty()) { output.writeBytes(4, value_); } - unknownFields.writeTo(output); + getUnknownFields().writeTo(output); } @java.lang.Override @@ -514,7 +347,7 @@ public int getSerializedSize() { if (!value_.isEmpty()) { size += com.google.protobuf.CodedOutputStream.computeBytesSize(4, value_); } - size += unknownFields.getSerializedSize(); + size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @@ -533,7 +366,7 @@ public boolean equals(final java.lang.Object obj) { if (!getColumnQualifier().equals(other.getColumnQualifier())) return false; if (getTimestampMicros() != other.getTimestampMicros()) return false; if (!getValue().equals(other.getValue())) return false; - if (!unknownFields.equals(other.unknownFields)) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -552,7 +385,7 @@ public int hashCode() { hash = (53 * hash) + com.google.protobuf.Internal.hashLong(getTimestampMicros()); hash = (37 * hash) + VALUE_FIELD_NUMBER; hash = (53 * hash) + getValue().hashCode(); - hash = (29 * hash) + unknownFields.hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } @@ -683,17 +516,10 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { } // Construct using com.google.bigtable.v2.Mutation.SetCell.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } + private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} } @java.lang.Override @@ -802,7 +628,7 @@ public Builder mergeFrom(com.google.bigtable.v2.Mutation.SetCell other) { if (other.getValue() != com.google.protobuf.ByteString.EMPTY) { setValue(other.getValue()); } - this.mergeUnknownFields(other.unknownFields); + this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @@ -817,17 +643,55 @@ public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - com.google.bigtable.v2.Mutation.SetCell parsedMessage = null; + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + familyName_ = input.readStringRequireUtf8(); + + break; + } // case 10 + case 18: + { + columnQualifier_ = input.readBytes(); + + break; + } // case 18 + case 24: + { + timestampMicros_ = input.readInt64(); + + break; + } // case 24 + case 34: + { + value_ = input.readBytes(); + + break; + } // case 34 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.bigtable.v2.Mutation.SetCell) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } + onChanged(); + } // finally return this; } @@ -1153,7 +1017,19 @@ public SetCell parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new SetCell(input, extensionRegistry); + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException() + .setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); } }; @@ -1289,73 +1165,6 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - private DeleteFromColumn( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - java.lang.String s = input.readStringRequireUtf8(); - - familyName_ = s; - break; - } - case 18: - { - columnQualifier_ = input.readBytes(); - break; - } - case 26: - { - com.google.bigtable.v2.TimestampRange.Builder subBuilder = null; - if (timeRange_ != null) { - subBuilder = timeRange_.toBuilder(); - } - timeRange_ = - input.readMessage( - com.google.bigtable.v2.TimestampRange.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(timeRange_); - timeRange_ = subBuilder.buildPartial(); - } - - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.bigtable.v2.DataProto .internal_static_google_bigtable_v2_Mutation_DeleteFromColumn_descriptor; @@ -1512,7 +1321,7 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io if (timeRange_ != null) { output.writeMessage(3, getTimeRange()); } - unknownFields.writeTo(output); + getUnknownFields().writeTo(output); } @java.lang.Override @@ -1530,7 +1339,7 @@ public int getSerializedSize() { if (timeRange_ != null) { size += com.google.protobuf.CodedOutputStream.computeMessageSize(3, getTimeRange()); } - size += unknownFields.getSerializedSize(); + size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @@ -1552,7 +1361,7 @@ public boolean equals(final java.lang.Object obj) { if (hasTimeRange()) { if (!getTimeRange().equals(other.getTimeRange())) return false; } - if (!unknownFields.equals(other.unknownFields)) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -1571,7 +1380,7 @@ public int hashCode() { hash = (37 * hash) + TIME_RANGE_FIELD_NUMBER; hash = (53 * hash) + getTimeRange().hashCode(); } - hash = (29 * hash) + unknownFields.hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } @@ -1703,17 +1512,10 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { } // Construct using com.google.bigtable.v2.Mutation.DeleteFromColumn.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } + private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} } @java.lang.Override @@ -1825,7 +1627,7 @@ public Builder mergeFrom(com.google.bigtable.v2.Mutation.DeleteFromColumn other) if (other.hasTimeRange()) { mergeTimeRange(other.getTimeRange()); } - this.mergeUnknownFields(other.unknownFields); + this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @@ -1840,18 +1642,49 @@ public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - com.google.bigtable.v2.Mutation.DeleteFromColumn parsedMessage = null; + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + familyName_ = input.readStringRequireUtf8(); + + break; + } // case 10 + case 18: + { + columnQualifier_ = input.readBytes(); + + break; + } // case 18 + case 26: + { + input.readMessage(getTimeRangeFieldBuilder().getBuilder(), extensionRegistry); + + break; + } // case 26 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = - (com.google.bigtable.v2.Mutation.DeleteFromColumn) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } + onChanged(); + } // finally return this; } @@ -2243,7 +2076,19 @@ public DeleteFromColumn parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new DeleteFromColumn(input, extensionRegistry); + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException() + .setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); } }; @@ -2328,52 +2173,6 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - private DeleteFromFamily( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - java.lang.String s = input.readStringRequireUtf8(); - - familyName_ = s; - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.bigtable.v2.DataProto .internal_static_google_bigtable_v2_Mutation_DeleteFromFamily_descriptor; @@ -2457,7 +2256,7 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(familyName_)) { com.google.protobuf.GeneratedMessageV3.writeString(output, 1, familyName_); } - unknownFields.writeTo(output); + getUnknownFields().writeTo(output); } @java.lang.Override @@ -2469,7 +2268,7 @@ public int getSerializedSize() { if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(familyName_)) { size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, familyName_); } - size += unknownFields.getSerializedSize(); + size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @@ -2486,7 +2285,7 @@ public boolean equals(final java.lang.Object obj) { (com.google.bigtable.v2.Mutation.DeleteFromFamily) obj; if (!getFamilyName().equals(other.getFamilyName())) return false; - if (!unknownFields.equals(other.unknownFields)) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -2499,7 +2298,7 @@ public int hashCode() { hash = (19 * hash) + getDescriptor().hashCode(); hash = (37 * hash) + FAMILY_NAME_FIELD_NUMBER; hash = (53 * hash) + getFamilyName().hashCode(); - hash = (29 * hash) + unknownFields.hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } @@ -2630,17 +2429,10 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { } // Construct using com.google.bigtable.v2.Mutation.DeleteFromFamily.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } + private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} } @java.lang.Override @@ -2732,7 +2524,7 @@ public Builder mergeFrom(com.google.bigtable.v2.Mutation.DeleteFromFamily other) familyName_ = other.familyName_; onChanged(); } - this.mergeUnknownFields(other.unknownFields); + this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @@ -2747,18 +2539,37 @@ public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - com.google.bigtable.v2.Mutation.DeleteFromFamily parsedMessage = null; + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + familyName_ = input.readStringRequireUtf8(); + + break; + } // case 10 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = - (com.google.bigtable.v2.Mutation.DeleteFromFamily) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } + onChanged(); + } // finally return this; } @@ -2906,7 +2717,19 @@ public DeleteFromFamily parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new DeleteFromFamily(input, extensionRegistry); + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException() + .setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); } }; @@ -2961,45 +2784,6 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - private DeleteFromRow( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.bigtable.v2.DataProto .internal_static_google_bigtable_v2_Mutation_DeleteFromRow_descriptor; @@ -3029,7 +2813,7 @@ public final boolean isInitialized() { @java.lang.Override public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { - unknownFields.writeTo(output); + getUnknownFields().writeTo(output); } @java.lang.Override @@ -3038,7 +2822,7 @@ public int getSerializedSize() { if (size != -1) return size; size = 0; - size += unknownFields.getSerializedSize(); + size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @@ -3054,7 +2838,7 @@ public boolean equals(final java.lang.Object obj) { com.google.bigtable.v2.Mutation.DeleteFromRow other = (com.google.bigtable.v2.Mutation.DeleteFromRow) obj; - if (!unknownFields.equals(other.unknownFields)) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -3065,7 +2849,7 @@ public int hashCode() { } int hash = 41; hash = (19 * hash) + getDescriptor().hashCode(); - hash = (29 * hash) + unknownFields.hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } @@ -3196,17 +2980,10 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { } // Construct using com.google.bigtable.v2.Mutation.DeleteFromRow.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } + private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} } @java.lang.Override @@ -3291,7 +3068,7 @@ public Builder mergeFrom(com.google.protobuf.Message other) { public Builder mergeFrom(com.google.bigtable.v2.Mutation.DeleteFromRow other) { if (other == com.google.bigtable.v2.Mutation.DeleteFromRow.getDefaultInstance()) return this; - this.mergeUnknownFields(other.unknownFields); + this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @@ -3306,17 +3083,31 @@ public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - com.google.bigtable.v2.Mutation.DeleteFromRow parsedMessage = null; + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.bigtable.v2.Mutation.DeleteFromRow) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } + onChanged(); + } // finally return this; } @@ -3353,7 +3144,19 @@ public DeleteFromRow parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new DeleteFromRow(input, extensionRegistry); + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException() + .setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); } }; @@ -3655,7 +3458,7 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io if (mutationCase_ == 4) { output.writeMessage(4, (com.google.bigtable.v2.Mutation.DeleteFromRow) mutation_); } - unknownFields.writeTo(output); + getUnknownFields().writeTo(output); } @java.lang.Override @@ -3684,7 +3487,7 @@ public int getSerializedSize() { com.google.protobuf.CodedOutputStream.computeMessageSize( 4, (com.google.bigtable.v2.Mutation.DeleteFromRow) mutation_); } - size += unknownFields.getSerializedSize(); + size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @@ -3716,7 +3519,7 @@ public boolean equals(final java.lang.Object obj) { case 0: default: } - if (!unknownFields.equals(other.unknownFields)) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -3747,7 +3550,7 @@ public int hashCode() { case 0: default: } - hash = (29 * hash) + unknownFields.hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } @@ -3874,22 +3677,27 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { } // Construct using com.google.bigtable.v2.Mutation.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } + private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} } @java.lang.Override public Builder clear() { super.clear(); + if (setCellBuilder_ != null) { + setCellBuilder_.clear(); + } + if (deleteFromColumnBuilder_ != null) { + deleteFromColumnBuilder_.clear(); + } + if (deleteFromFamilyBuilder_ != null) { + deleteFromFamilyBuilder_.clear(); + } + if (deleteFromRowBuilder_ != null) { + deleteFromRowBuilder_.clear(); + } mutationCase_ = 0; mutation_ = null; return this; @@ -4022,7 +3830,7 @@ public Builder mergeFrom(com.google.bigtable.v2.Mutation other) { break; } } - this.mergeUnknownFields(other.unknownFields); + this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @@ -4037,17 +3845,57 @@ public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - com.google.bigtable.v2.Mutation parsedMessage = null; + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + input.readMessage(getSetCellFieldBuilder().getBuilder(), extensionRegistry); + mutationCase_ = 1; + break; + } // case 10 + case 18: + { + input.readMessage( + getDeleteFromColumnFieldBuilder().getBuilder(), extensionRegistry); + mutationCase_ = 2; + break; + } // case 18 + case 26: + { + input.readMessage( + getDeleteFromFamilyFieldBuilder().getBuilder(), extensionRegistry); + mutationCase_ = 3; + break; + } // case 26 + case 34: + { + input.readMessage(getDeleteFromRowFieldBuilder().getBuilder(), extensionRegistry); + mutationCase_ = 4; + break; + } // case 34 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.bigtable.v2.Mutation) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } + onChanged(); + } // finally return this; } @@ -4938,7 +4786,18 @@ public Mutation parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new Mutation(input, extensionRegistry); + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); } }; diff --git a/proto-google-cloud-bigtable-v2/src/main/java/com/google/bigtable/v2/PingAndWarmRequest.java b/proto-google-cloud-bigtable-v2/src/main/java/com/google/bigtable/v2/PingAndWarmRequest.java index c602d4fc6c..03d0839d7c 100644 --- a/proto-google-cloud-bigtable-v2/src/main/java/com/google/bigtable/v2/PingAndWarmRequest.java +++ b/proto-google-cloud-bigtable-v2/src/main/java/com/google/bigtable/v2/PingAndWarmRequest.java @@ -53,59 +53,6 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - private PingAndWarmRequest( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - java.lang.String s = input.readStringRequireUtf8(); - - name_ = s; - break; - } - case 18: - { - java.lang.String s = input.readStringRequireUtf8(); - - appProfileId_ = s; - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.bigtable.v2.BigtableProto .internal_static_google_bigtable_v2_PingAndWarmRequest_descriptor; @@ -247,7 +194,7 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(appProfileId_)) { com.google.protobuf.GeneratedMessageV3.writeString(output, 2, appProfileId_); } - unknownFields.writeTo(output); + getUnknownFields().writeTo(output); } @java.lang.Override @@ -262,7 +209,7 @@ public int getSerializedSize() { if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(appProfileId_)) { size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, appProfileId_); } - size += unknownFields.getSerializedSize(); + size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @@ -280,7 +227,7 @@ public boolean equals(final java.lang.Object obj) { if (!getName().equals(other.getName())) return false; if (!getAppProfileId().equals(other.getAppProfileId())) return false; - if (!unknownFields.equals(other.unknownFields)) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -295,7 +242,7 @@ public int hashCode() { hash = (53 * hash) + getName().hashCode(); hash = (37 * hash) + APP_PROFILE_ID_FIELD_NUMBER; hash = (53 * hash) + getAppProfileId().hashCode(); - hash = (29 * hash) + unknownFields.hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } @@ -424,17 +371,10 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { } // Construct using com.google.bigtable.v2.PingAndWarmRequest.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } + private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} } @java.lang.Override @@ -530,7 +470,7 @@ public Builder mergeFrom(com.google.bigtable.v2.PingAndWarmRequest other) { appProfileId_ = other.appProfileId_; onChanged(); } - this.mergeUnknownFields(other.unknownFields); + this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @@ -545,17 +485,43 @@ public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - com.google.bigtable.v2.PingAndWarmRequest parsedMessage = null; + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + name_ = input.readStringRequireUtf8(); + + break; + } // case 10 + case 18: + { + appProfileId_ = input.readStringRequireUtf8(); + + break; + } // case 18 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.bigtable.v2.PingAndWarmRequest) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } + onChanged(); + } // finally return this; } @@ -823,7 +789,18 @@ public PingAndWarmRequest parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new PingAndWarmRequest(input, extensionRegistry); + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); } }; diff --git a/proto-google-cloud-bigtable-v2/src/main/java/com/google/bigtable/v2/PingAndWarmResponse.java b/proto-google-cloud-bigtable-v2/src/main/java/com/google/bigtable/v2/PingAndWarmResponse.java index 0c31dbc0ed..80eb3431fb 100644 --- a/proto-google-cloud-bigtable-v2/src/main/java/com/google/bigtable/v2/PingAndWarmResponse.java +++ b/proto-google-cloud-bigtable-v2/src/main/java/com/google/bigtable/v2/PingAndWarmResponse.java @@ -50,45 +50,6 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - private PingAndWarmResponse( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.bigtable.v2.BigtableProto .internal_static_google_bigtable_v2_PingAndWarmResponse_descriptor; @@ -118,7 +79,7 @@ public final boolean isInitialized() { @java.lang.Override public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { - unknownFields.writeTo(output); + getUnknownFields().writeTo(output); } @java.lang.Override @@ -127,7 +88,7 @@ public int getSerializedSize() { if (size != -1) return size; size = 0; - size += unknownFields.getSerializedSize(); + size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @@ -143,7 +104,7 @@ public boolean equals(final java.lang.Object obj) { com.google.bigtable.v2.PingAndWarmResponse other = (com.google.bigtable.v2.PingAndWarmResponse) obj; - if (!unknownFields.equals(other.unknownFields)) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -154,7 +115,7 @@ public int hashCode() { } int hash = 41; hash = (19 * hash) + getDescriptor().hashCode(); - hash = (29 * hash) + unknownFields.hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } @@ -283,17 +244,10 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { } // Construct using com.google.bigtable.v2.PingAndWarmResponse.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } + private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} } @java.lang.Override @@ -375,7 +329,7 @@ public Builder mergeFrom(com.google.protobuf.Message other) { public Builder mergeFrom(com.google.bigtable.v2.PingAndWarmResponse other) { if (other == com.google.bigtable.v2.PingAndWarmResponse.getDefaultInstance()) return this; - this.mergeUnknownFields(other.unknownFields); + this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @@ -390,17 +344,31 @@ public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - com.google.bigtable.v2.PingAndWarmResponse parsedMessage = null; + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.bigtable.v2.PingAndWarmResponse) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } + onChanged(); + } // finally return this; } @@ -436,7 +404,18 @@ public PingAndWarmResponse parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new PingAndWarmResponse(input, extensionRegistry); + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); } }; diff --git a/proto-google-cloud-bigtable-v2/src/main/java/com/google/bigtable/v2/ReadIterationStats.java b/proto-google-cloud-bigtable-v2/src/main/java/com/google/bigtable/v2/ReadIterationStats.java new file mode 100644 index 0000000000..26955faba7 --- /dev/null +++ b/proto-google-cloud-bigtable-v2/src/main/java/com/google/bigtable/v2/ReadIterationStats.java @@ -0,0 +1,811 @@ +/* + * Copyright 2020 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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/bigtable/v2/request_stats.proto + +package com.google.bigtable.v2; + +/** + * + * + *
+ * ReadIterationStats captures information about the iteration of rows or cells
+ * over the course of a read, e.g. how many results were scanned in a read
+ * operation versus the results returned.
+ * 
+ * + * Protobuf type {@code google.bigtable.v2.ReadIterationStats} + */ +public final class ReadIterationStats extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.bigtable.v2.ReadIterationStats) + ReadIterationStatsOrBuilder { + private static final long serialVersionUID = 0L; + // Use ReadIterationStats.newBuilder() to construct. + private ReadIterationStats(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private ReadIterationStats() {} + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new ReadIterationStats(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.bigtable.v2.RequestStatsProto + .internal_static_google_bigtable_v2_ReadIterationStats_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.bigtable.v2.RequestStatsProto + .internal_static_google_bigtable_v2_ReadIterationStats_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.bigtable.v2.ReadIterationStats.class, + com.google.bigtable.v2.ReadIterationStats.Builder.class); + } + + public static final int ROWS_SEEN_COUNT_FIELD_NUMBER = 1; + private long rowsSeenCount_; + /** + * + * + *
+   * The rows seen (scanned) as part of the request. This includes the count of
+   * rows returned, as captured below.
+   * 
+ * + * int64 rows_seen_count = 1; + * + * @return The rowsSeenCount. + */ + @java.lang.Override + public long getRowsSeenCount() { + return rowsSeenCount_; + } + + public static final int ROWS_RETURNED_COUNT_FIELD_NUMBER = 2; + private long rowsReturnedCount_; + /** + * + * + *
+   * The rows returned as part of the request.
+   * 
+ * + * int64 rows_returned_count = 2; + * + * @return The rowsReturnedCount. + */ + @java.lang.Override + public long getRowsReturnedCount() { + return rowsReturnedCount_; + } + + public static final int CELLS_SEEN_COUNT_FIELD_NUMBER = 3; + private long cellsSeenCount_; + /** + * + * + *
+   * The cells seen (scanned) as part of the request. This includes the count of
+   * cells returned, as captured below.
+   * 
+ * + * int64 cells_seen_count = 3; + * + * @return The cellsSeenCount. + */ + @java.lang.Override + public long getCellsSeenCount() { + return cellsSeenCount_; + } + + public static final int CELLS_RETURNED_COUNT_FIELD_NUMBER = 4; + private long cellsReturnedCount_; + /** + * + * + *
+   * The cells returned as part of the request.
+   * 
+ * + * int64 cells_returned_count = 4; + * + * @return The cellsReturnedCount. + */ + @java.lang.Override + public long getCellsReturnedCount() { + return cellsReturnedCount_; + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (rowsSeenCount_ != 0L) { + output.writeInt64(1, rowsSeenCount_); + } + if (rowsReturnedCount_ != 0L) { + output.writeInt64(2, rowsReturnedCount_); + } + if (cellsSeenCount_ != 0L) { + output.writeInt64(3, cellsSeenCount_); + } + if (cellsReturnedCount_ != 0L) { + output.writeInt64(4, cellsReturnedCount_); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (rowsSeenCount_ != 0L) { + size += com.google.protobuf.CodedOutputStream.computeInt64Size(1, rowsSeenCount_); + } + if (rowsReturnedCount_ != 0L) { + size += com.google.protobuf.CodedOutputStream.computeInt64Size(2, rowsReturnedCount_); + } + if (cellsSeenCount_ != 0L) { + size += com.google.protobuf.CodedOutputStream.computeInt64Size(3, cellsSeenCount_); + } + if (cellsReturnedCount_ != 0L) { + size += com.google.protobuf.CodedOutputStream.computeInt64Size(4, cellsReturnedCount_); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.bigtable.v2.ReadIterationStats)) { + return super.equals(obj); + } + com.google.bigtable.v2.ReadIterationStats other = + (com.google.bigtable.v2.ReadIterationStats) obj; + + if (getRowsSeenCount() != other.getRowsSeenCount()) return false; + if (getRowsReturnedCount() != other.getRowsReturnedCount()) return false; + if (getCellsSeenCount() != other.getCellsSeenCount()) return false; + if (getCellsReturnedCount() != other.getCellsReturnedCount()) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + ROWS_SEEN_COUNT_FIELD_NUMBER; + hash = (53 * hash) + com.google.protobuf.Internal.hashLong(getRowsSeenCount()); + hash = (37 * hash) + ROWS_RETURNED_COUNT_FIELD_NUMBER; + hash = (53 * hash) + com.google.protobuf.Internal.hashLong(getRowsReturnedCount()); + hash = (37 * hash) + CELLS_SEEN_COUNT_FIELD_NUMBER; + hash = (53 * hash) + com.google.protobuf.Internal.hashLong(getCellsSeenCount()); + hash = (37 * hash) + CELLS_RETURNED_COUNT_FIELD_NUMBER; + hash = (53 * hash) + com.google.protobuf.Internal.hashLong(getCellsReturnedCount()); + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.bigtable.v2.ReadIterationStats parseFrom(java.nio.ByteBuffer data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.bigtable.v2.ReadIterationStats parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.bigtable.v2.ReadIterationStats parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.bigtable.v2.ReadIterationStats parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.bigtable.v2.ReadIterationStats parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.bigtable.v2.ReadIterationStats parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.bigtable.v2.ReadIterationStats parseFrom(java.io.InputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.bigtable.v2.ReadIterationStats parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.bigtable.v2.ReadIterationStats parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.bigtable.v2.ReadIterationStats parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.bigtable.v2.ReadIterationStats parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.bigtable.v2.ReadIterationStats parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder(com.google.bigtable.v2.ReadIterationStats prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + /** + * + * + *
+   * ReadIterationStats captures information about the iteration of rows or cells
+   * over the course of a read, e.g. how many results were scanned in a read
+   * operation versus the results returned.
+   * 
+ * + * Protobuf type {@code google.bigtable.v2.ReadIterationStats} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.bigtable.v2.ReadIterationStats) + com.google.bigtable.v2.ReadIterationStatsOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.bigtable.v2.RequestStatsProto + .internal_static_google_bigtable_v2_ReadIterationStats_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.bigtable.v2.RequestStatsProto + .internal_static_google_bigtable_v2_ReadIterationStats_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.bigtable.v2.ReadIterationStats.class, + com.google.bigtable.v2.ReadIterationStats.Builder.class); + } + + // Construct using com.google.bigtable.v2.ReadIterationStats.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + } + + @java.lang.Override + public Builder clear() { + super.clear(); + rowsSeenCount_ = 0L; + + rowsReturnedCount_ = 0L; + + cellsSeenCount_ = 0L; + + cellsReturnedCount_ = 0L; + + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.bigtable.v2.RequestStatsProto + .internal_static_google_bigtable_v2_ReadIterationStats_descriptor; + } + + @java.lang.Override + public com.google.bigtable.v2.ReadIterationStats getDefaultInstanceForType() { + return com.google.bigtable.v2.ReadIterationStats.getDefaultInstance(); + } + + @java.lang.Override + public com.google.bigtable.v2.ReadIterationStats build() { + com.google.bigtable.v2.ReadIterationStats result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.bigtable.v2.ReadIterationStats buildPartial() { + com.google.bigtable.v2.ReadIterationStats result = + new com.google.bigtable.v2.ReadIterationStats(this); + result.rowsSeenCount_ = rowsSeenCount_; + result.rowsReturnedCount_ = rowsReturnedCount_; + result.cellsSeenCount_ = cellsSeenCount_; + result.cellsReturnedCount_ = cellsReturnedCount_; + onBuilt(); + return result; + } + + @java.lang.Override + public Builder clone() { + return super.clone(); + } + + @java.lang.Override + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.setField(field, value); + } + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); + } + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); + } + + @java.lang.Override + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { + return super.setRepeatedField(field, index, value); + } + + @java.lang.Override + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.addRepeatedField(field, value); + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.bigtable.v2.ReadIterationStats) { + return mergeFrom((com.google.bigtable.v2.ReadIterationStats) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.bigtable.v2.ReadIterationStats other) { + if (other == com.google.bigtable.v2.ReadIterationStats.getDefaultInstance()) return this; + if (other.getRowsSeenCount() != 0L) { + setRowsSeenCount(other.getRowsSeenCount()); + } + if (other.getRowsReturnedCount() != 0L) { + setRowsReturnedCount(other.getRowsReturnedCount()); + } + if (other.getCellsSeenCount() != 0L) { + setCellsSeenCount(other.getCellsSeenCount()); + } + if (other.getCellsReturnedCount() != 0L) { + setCellsReturnedCount(other.getCellsReturnedCount()); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 8: + { + rowsSeenCount_ = input.readInt64(); + + break; + } // case 8 + case 16: + { + rowsReturnedCount_ = input.readInt64(); + + break; + } // case 16 + case 24: + { + cellsSeenCount_ = input.readInt64(); + + break; + } // case 24 + case 32: + { + cellsReturnedCount_ = input.readInt64(); + + break; + } // case 32 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private long rowsSeenCount_; + /** + * + * + *
+     * The rows seen (scanned) as part of the request. This includes the count of
+     * rows returned, as captured below.
+     * 
+ * + * int64 rows_seen_count = 1; + * + * @return The rowsSeenCount. + */ + @java.lang.Override + public long getRowsSeenCount() { + return rowsSeenCount_; + } + /** + * + * + *
+     * The rows seen (scanned) as part of the request. This includes the count of
+     * rows returned, as captured below.
+     * 
+ * + * int64 rows_seen_count = 1; + * + * @param value The rowsSeenCount to set. + * @return This builder for chaining. + */ + public Builder setRowsSeenCount(long value) { + + rowsSeenCount_ = value; + onChanged(); + return this; + } + /** + * + * + *
+     * The rows seen (scanned) as part of the request. This includes the count of
+     * rows returned, as captured below.
+     * 
+ * + * int64 rows_seen_count = 1; + * + * @return This builder for chaining. + */ + public Builder clearRowsSeenCount() { + + rowsSeenCount_ = 0L; + onChanged(); + return this; + } + + private long rowsReturnedCount_; + /** + * + * + *
+     * The rows returned as part of the request.
+     * 
+ * + * int64 rows_returned_count = 2; + * + * @return The rowsReturnedCount. + */ + @java.lang.Override + public long getRowsReturnedCount() { + return rowsReturnedCount_; + } + /** + * + * + *
+     * The rows returned as part of the request.
+     * 
+ * + * int64 rows_returned_count = 2; + * + * @param value The rowsReturnedCount to set. + * @return This builder for chaining. + */ + public Builder setRowsReturnedCount(long value) { + + rowsReturnedCount_ = value; + onChanged(); + return this; + } + /** + * + * + *
+     * The rows returned as part of the request.
+     * 
+ * + * int64 rows_returned_count = 2; + * + * @return This builder for chaining. + */ + public Builder clearRowsReturnedCount() { + + rowsReturnedCount_ = 0L; + onChanged(); + return this; + } + + private long cellsSeenCount_; + /** + * + * + *
+     * The cells seen (scanned) as part of the request. This includes the count of
+     * cells returned, as captured below.
+     * 
+ * + * int64 cells_seen_count = 3; + * + * @return The cellsSeenCount. + */ + @java.lang.Override + public long getCellsSeenCount() { + return cellsSeenCount_; + } + /** + * + * + *
+     * The cells seen (scanned) as part of the request. This includes the count of
+     * cells returned, as captured below.
+     * 
+ * + * int64 cells_seen_count = 3; + * + * @param value The cellsSeenCount to set. + * @return This builder for chaining. + */ + public Builder setCellsSeenCount(long value) { + + cellsSeenCount_ = value; + onChanged(); + return this; + } + /** + * + * + *
+     * The cells seen (scanned) as part of the request. This includes the count of
+     * cells returned, as captured below.
+     * 
+ * + * int64 cells_seen_count = 3; + * + * @return This builder for chaining. + */ + public Builder clearCellsSeenCount() { + + cellsSeenCount_ = 0L; + onChanged(); + return this; + } + + private long cellsReturnedCount_; + /** + * + * + *
+     * The cells returned as part of the request.
+     * 
+ * + * int64 cells_returned_count = 4; + * + * @return The cellsReturnedCount. + */ + @java.lang.Override + public long getCellsReturnedCount() { + return cellsReturnedCount_; + } + /** + * + * + *
+     * The cells returned as part of the request.
+     * 
+ * + * int64 cells_returned_count = 4; + * + * @param value The cellsReturnedCount to set. + * @return This builder for chaining. + */ + public Builder setCellsReturnedCount(long value) { + + cellsReturnedCount_ = value; + onChanged(); + return this; + } + /** + * + * + *
+     * The cells returned as part of the request.
+     * 
+ * + * int64 cells_returned_count = 4; + * + * @return This builder for chaining. + */ + public Builder clearCellsReturnedCount() { + + cellsReturnedCount_ = 0L; + onChanged(); + return this; + } + + @java.lang.Override + public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFields(unknownFields); + } + + @java.lang.Override + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + // @@protoc_insertion_point(builder_scope:google.bigtable.v2.ReadIterationStats) + } + + // @@protoc_insertion_point(class_scope:google.bigtable.v2.ReadIterationStats) + private static final com.google.bigtable.v2.ReadIterationStats DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.bigtable.v2.ReadIterationStats(); + } + + public static com.google.bigtable.v2.ReadIterationStats getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public ReadIterationStats parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.bigtable.v2.ReadIterationStats getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/proto-google-cloud-bigtable-v2/src/main/java/com/google/bigtable/v2/ReadIterationStatsOrBuilder.java b/proto-google-cloud-bigtable-v2/src/main/java/com/google/bigtable/v2/ReadIterationStatsOrBuilder.java new file mode 100644 index 0000000000..c9f7c6e842 --- /dev/null +++ b/proto-google-cloud-bigtable-v2/src/main/java/com/google/bigtable/v2/ReadIterationStatsOrBuilder.java @@ -0,0 +1,79 @@ +/* + * Copyright 2020 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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/bigtable/v2/request_stats.proto + +package com.google.bigtable.v2; + +public interface ReadIterationStatsOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.bigtable.v2.ReadIterationStats) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * The rows seen (scanned) as part of the request. This includes the count of
+   * rows returned, as captured below.
+   * 
+ * + * int64 rows_seen_count = 1; + * + * @return The rowsSeenCount. + */ + long getRowsSeenCount(); + + /** + * + * + *
+   * The rows returned as part of the request.
+   * 
+ * + * int64 rows_returned_count = 2; + * + * @return The rowsReturnedCount. + */ + long getRowsReturnedCount(); + + /** + * + * + *
+   * The cells seen (scanned) as part of the request. This includes the count of
+   * cells returned, as captured below.
+   * 
+ * + * int64 cells_seen_count = 3; + * + * @return The cellsSeenCount. + */ + long getCellsSeenCount(); + + /** + * + * + *
+   * The cells returned as part of the request.
+   * 
+ * + * int64 cells_returned_count = 4; + * + * @return The cellsReturnedCount. + */ + long getCellsReturnedCount(); +} diff --git a/proto-google-cloud-bigtable-v2/src/main/java/com/google/bigtable/v2/ReadModifyWriteRowRequest.java b/proto-google-cloud-bigtable-v2/src/main/java/com/google/bigtable/v2/ReadModifyWriteRowRequest.java index a048b66796..9bd7eef837 100644 --- a/proto-google-cloud-bigtable-v2/src/main/java/com/google/bigtable/v2/ReadModifyWriteRowRequest.java +++ b/proto-google-cloud-bigtable-v2/src/main/java/com/google/bigtable/v2/ReadModifyWriteRowRequest.java @@ -55,79 +55,6 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - private ReadModifyWriteRowRequest( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - int mutable_bitField0_ = 0; - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - java.lang.String s = input.readStringRequireUtf8(); - - tableName_ = s; - break; - } - case 18: - { - rowKey_ = input.readBytes(); - break; - } - case 26: - { - if (!((mutable_bitField0_ & 0x00000001) != 0)) { - rules_ = new java.util.ArrayList(); - mutable_bitField0_ |= 0x00000001; - } - rules_.add( - input.readMessage( - com.google.bigtable.v2.ReadModifyWriteRule.parser(), extensionRegistry)); - break; - } - case 34: - { - java.lang.String s = input.readStringRequireUtf8(); - - appProfileId_ = s; - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); - } finally { - if (((mutable_bitField0_ & 0x00000001) != 0)) { - rules_ = java.util.Collections.unmodifiableList(rules_); - } - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.bigtable.v2.BigtableProto .internal_static_google_bigtable_v2_ReadModifyWriteRowRequest_descriptor; @@ -386,7 +313,7 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(appProfileId_)) { com.google.protobuf.GeneratedMessageV3.writeString(output, 4, appProfileId_); } - unknownFields.writeTo(output); + getUnknownFields().writeTo(output); } @java.lang.Override @@ -407,7 +334,7 @@ public int getSerializedSize() { if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(appProfileId_)) { size += com.google.protobuf.GeneratedMessageV3.computeStringSize(4, appProfileId_); } - size += unknownFields.getSerializedSize(); + size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @@ -427,7 +354,7 @@ public boolean equals(final java.lang.Object obj) { if (!getAppProfileId().equals(other.getAppProfileId())) return false; if (!getRowKey().equals(other.getRowKey())) return false; if (!getRulesList().equals(other.getRulesList())) return false; - if (!unknownFields.equals(other.unknownFields)) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -448,7 +375,7 @@ public int hashCode() { hash = (37 * hash) + RULES_FIELD_NUMBER; hash = (53 * hash) + getRulesList().hashCode(); } - hash = (29 * hash) + unknownFields.hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } @@ -577,19 +504,10 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { } // Construct using com.google.bigtable.v2.ReadModifyWriteRowRequest.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } + private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) { - getRulesFieldBuilder(); - } } @java.lang.Override @@ -603,10 +521,11 @@ public Builder clear() { if (rulesBuilder_ == null) { rules_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000001); } else { + rules_ = null; rulesBuilder_.clear(); } + bitField0_ = (bitField0_ & ~0x00000001); return this; } @@ -735,7 +654,7 @@ public Builder mergeFrom(com.google.bigtable.v2.ReadModifyWriteRowRequest other) } } } - this.mergeUnknownFields(other.unknownFields); + this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @@ -750,17 +669,62 @@ public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - com.google.bigtable.v2.ReadModifyWriteRowRequest parsedMessage = null; + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + tableName_ = input.readStringRequireUtf8(); + + break; + } // case 10 + case 18: + { + rowKey_ = input.readBytes(); + + break; + } // case 18 + case 26: + { + com.google.bigtable.v2.ReadModifyWriteRule m = + input.readMessage( + com.google.bigtable.v2.ReadModifyWriteRule.parser(), extensionRegistry); + if (rulesBuilder_ == null) { + ensureRulesIsMutable(); + rules_.add(m); + } else { + rulesBuilder_.addMessage(m); + } + break; + } // case 26 + case 34: + { + appProfileId_ = input.readStringRequireUtf8(); + + break; + } // case 34 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.bigtable.v2.ReadModifyWriteRowRequest) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } + onChanged(); + } // finally return this; } @@ -1516,7 +1480,18 @@ public ReadModifyWriteRowRequest parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new ReadModifyWriteRowRequest(input, extensionRegistry); + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); } }; diff --git a/proto-google-cloud-bigtable-v2/src/main/java/com/google/bigtable/v2/ReadModifyWriteRowResponse.java b/proto-google-cloud-bigtable-v2/src/main/java/com/google/bigtable/v2/ReadModifyWriteRowResponse.java index d1155353ba..e79c933d51 100644 --- a/proto-google-cloud-bigtable-v2/src/main/java/com/google/bigtable/v2/ReadModifyWriteRowResponse.java +++ b/proto-google-cloud-bigtable-v2/src/main/java/com/google/bigtable/v2/ReadModifyWriteRowResponse.java @@ -50,59 +50,6 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - private ReadModifyWriteRowResponse( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - com.google.bigtable.v2.Row.Builder subBuilder = null; - if (row_ != null) { - subBuilder = row_.toBuilder(); - } - row_ = input.readMessage(com.google.bigtable.v2.Row.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(row_); - row_ = subBuilder.buildPartial(); - } - - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.bigtable.v2.BigtableProto .internal_static_google_bigtable_v2_ReadModifyWriteRowResponse_descriptor; @@ -181,7 +128,7 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io if (row_ != null) { output.writeMessage(1, getRow()); } - unknownFields.writeTo(output); + getUnknownFields().writeTo(output); } @java.lang.Override @@ -193,7 +140,7 @@ public int getSerializedSize() { if (row_ != null) { size += com.google.protobuf.CodedOutputStream.computeMessageSize(1, getRow()); } - size += unknownFields.getSerializedSize(); + size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @@ -213,7 +160,7 @@ public boolean equals(final java.lang.Object obj) { if (hasRow()) { if (!getRow().equals(other.getRow())) return false; } - if (!unknownFields.equals(other.unknownFields)) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -228,7 +175,7 @@ public int hashCode() { hash = (37 * hash) + ROW_FIELD_NUMBER; hash = (53 * hash) + getRow().hashCode(); } - hash = (29 * hash) + unknownFields.hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } @@ -357,17 +304,10 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { } // Construct using com.google.bigtable.v2.ReadModifyWriteRowResponse.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } + private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} } @java.lang.Override @@ -464,7 +404,7 @@ public Builder mergeFrom(com.google.bigtable.v2.ReadModifyWriteRowResponse other if (other.hasRow()) { mergeRow(other.getRow()); } - this.mergeUnknownFields(other.unknownFields); + this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @@ -479,18 +419,37 @@ public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - com.google.bigtable.v2.ReadModifyWriteRowResponse parsedMessage = null; + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + input.readMessage(getRowFieldBuilder().getBuilder(), extensionRegistry); + + break; + } // case 10 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = - (com.google.bigtable.v2.ReadModifyWriteRowResponse) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } + onChanged(); + } // finally return this; } @@ -703,7 +662,18 @@ public ReadModifyWriteRowResponse parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new ReadModifyWriteRowResponse(input, extensionRegistry); + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); } }; diff --git a/proto-google-cloud-bigtable-v2/src/main/java/com/google/bigtable/v2/ReadModifyWriteRule.java b/proto-google-cloud-bigtable-v2/src/main/java/com/google/bigtable/v2/ReadModifyWriteRule.java index 1826e984c4..a02ecbb670 100644 --- a/proto-google-cloud-bigtable-v2/src/main/java/com/google/bigtable/v2/ReadModifyWriteRule.java +++ b/proto-google-cloud-bigtable-v2/src/main/java/com/google/bigtable/v2/ReadModifyWriteRule.java @@ -54,69 +54,6 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - private ReadModifyWriteRule( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - java.lang.String s = input.readStringRequireUtf8(); - - familyName_ = s; - break; - } - case 18: - { - columnQualifier_ = input.readBytes(); - break; - } - case 26: - { - rule_ = input.readBytes(); - ruleCase_ = 3; - break; - } - case 32: - { - rule_ = input.readInt64(); - ruleCase_ = 4; - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.bigtable.v2.DataProto .internal_static_google_bigtable_v2_ReadModifyWriteRule_descriptor; @@ -356,7 +293,7 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io if (ruleCase_ == 4) { output.writeInt64(4, (long) ((java.lang.Long) rule_)); } - unknownFields.writeTo(output); + getUnknownFields().writeTo(output); } @java.lang.Override @@ -381,7 +318,7 @@ public int getSerializedSize() { com.google.protobuf.CodedOutputStream.computeInt64Size( 4, (long) ((java.lang.Long) rule_)); } - size += unknownFields.getSerializedSize(); + size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @@ -410,7 +347,7 @@ public boolean equals(final java.lang.Object obj) { case 0: default: } - if (!unknownFields.equals(other.unknownFields)) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -437,7 +374,7 @@ public int hashCode() { case 0: default: } - hash = (29 * hash) + unknownFields.hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } @@ -567,17 +504,10 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { } // Construct using com.google.bigtable.v2.ReadModifyWriteRule.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } + private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} } @java.lang.Override @@ -697,7 +627,7 @@ public Builder mergeFrom(com.google.bigtable.v2.ReadModifyWriteRule other) { break; } } - this.mergeUnknownFields(other.unknownFields); + this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @@ -712,17 +642,55 @@ public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - com.google.bigtable.v2.ReadModifyWriteRule parsedMessage = null; + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + familyName_ = input.readStringRequireUtf8(); + + break; + } // case 10 + case 18: + { + columnQualifier_ = input.readBytes(); + + break; + } // case 18 + case 26: + { + rule_ = input.readBytes(); + ruleCase_ = 3; + break; + } // case 26 + case 32: + { + rule_ = input.readInt64(); + ruleCase_ = 4; + break; + } // case 32 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.bigtable.v2.ReadModifyWriteRule) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } + onChanged(); + } // finally return this; } @@ -1105,7 +1073,18 @@ public ReadModifyWriteRule parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new ReadModifyWriteRule(input, extensionRegistry); + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); } }; diff --git a/proto-google-cloud-bigtable-v2/src/main/java/com/google/bigtable/v2/ReadRowsRequest.java b/proto-google-cloud-bigtable-v2/src/main/java/com/google/bigtable/v2/ReadRowsRequest.java index 0c8a055a78..bb9349047c 100644 --- a/proto-google-cloud-bigtable-v2/src/main/java/com/google/bigtable/v2/ReadRowsRequest.java +++ b/proto-google-cloud-bigtable-v2/src/main/java/com/google/bigtable/v2/ReadRowsRequest.java @@ -40,6 +40,7 @@ private ReadRowsRequest(com.google.protobuf.GeneratedMessageV3.Builder builde private ReadRowsRequest() { tableName_ = ""; appProfileId_ = ""; + requestStatsView_ = 0; } @java.lang.Override @@ -53,93 +54,6 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - private ReadRowsRequest( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - java.lang.String s = input.readStringRequireUtf8(); - - tableName_ = s; - break; - } - case 18: - { - com.google.bigtable.v2.RowSet.Builder subBuilder = null; - if (rows_ != null) { - subBuilder = rows_.toBuilder(); - } - rows_ = input.readMessage(com.google.bigtable.v2.RowSet.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(rows_); - rows_ = subBuilder.buildPartial(); - } - - break; - } - case 26: - { - com.google.bigtable.v2.RowFilter.Builder subBuilder = null; - if (filter_ != null) { - subBuilder = filter_.toBuilder(); - } - filter_ = - input.readMessage(com.google.bigtable.v2.RowFilter.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(filter_); - filter_ = subBuilder.buildPartial(); - } - - break; - } - case 32: - { - rowsLimit_ = input.readInt64(); - break; - } - case 42: - { - java.lang.String s = input.readStringRequireUtf8(); - - appProfileId_ = s; - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.bigtable.v2.BigtableProto .internal_static_google_bigtable_v2_ReadRowsRequest_descriptor; @@ -155,6 +69,170 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { com.google.bigtable.v2.ReadRowsRequest.Builder.class); } + /** + * + * + *
+   * The desired view into RequestStats that should be returned in the response.
+   * See also: RequestStats message.
+   * 
+ * + * Protobuf enum {@code google.bigtable.v2.ReadRowsRequest.RequestStatsView} + */ + public enum RequestStatsView implements com.google.protobuf.ProtocolMessageEnum { + /** + * + * + *
+     * The default / unset value. The API will default to the NONE option below.
+     * 
+ * + * REQUEST_STATS_VIEW_UNSPECIFIED = 0; + */ + REQUEST_STATS_VIEW_UNSPECIFIED(0), + /** + * + * + *
+     * Do not include any RequestStats in the response. This will leave the
+     * RequestStats embedded message unset in the response.
+     * 
+ * + * REQUEST_STATS_NONE = 1; + */ + REQUEST_STATS_NONE(1), + /** + * + * + *
+     * Include the full set of available RequestStats in the response,
+     * applicable to this read.
+     * 
+ * + * REQUEST_STATS_FULL = 2; + */ + REQUEST_STATS_FULL(2), + UNRECOGNIZED(-1), + ; + + /** + * + * + *
+     * The default / unset value. The API will default to the NONE option below.
+     * 
+ * + * REQUEST_STATS_VIEW_UNSPECIFIED = 0; + */ + public static final int REQUEST_STATS_VIEW_UNSPECIFIED_VALUE = 0; + /** + * + * + *
+     * Do not include any RequestStats in the response. This will leave the
+     * RequestStats embedded message unset in the response.
+     * 
+ * + * REQUEST_STATS_NONE = 1; + */ + public static final int REQUEST_STATS_NONE_VALUE = 1; + /** + * + * + *
+     * Include the full set of available RequestStats in the response,
+     * applicable to this read.
+     * 
+ * + * REQUEST_STATS_FULL = 2; + */ + public static final int REQUEST_STATS_FULL_VALUE = 2; + + public final int getNumber() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalArgumentException( + "Can't get the number of an unknown enum value."); + } + return value; + } + + /** + * @param value The numeric wire value of the corresponding enum entry. + * @return The enum associated with the given numeric wire value. + * @deprecated Use {@link #forNumber(int)} instead. + */ + @java.lang.Deprecated + public static RequestStatsView valueOf(int value) { + return forNumber(value); + } + + /** + * @param value The numeric wire value of the corresponding enum entry. + * @return The enum associated with the given numeric wire value. + */ + public static RequestStatsView forNumber(int value) { + switch (value) { + case 0: + return REQUEST_STATS_VIEW_UNSPECIFIED; + case 1: + return REQUEST_STATS_NONE; + case 2: + return REQUEST_STATS_FULL; + default: + return null; + } + } + + public static com.google.protobuf.Internal.EnumLiteMap internalGetValueMap() { + return internalValueMap; + } + + private static final com.google.protobuf.Internal.EnumLiteMap + internalValueMap = + new com.google.protobuf.Internal.EnumLiteMap() { + public RequestStatsView findValueByNumber(int number) { + return RequestStatsView.forNumber(number); + } + }; + + public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalStateException( + "Can't get the descriptor of an unrecognized enum value."); + } + return getDescriptor().getValues().get(ordinal()); + } + + public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType() { + return getDescriptor(); + } + + public static final com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { + return com.google.bigtable.v2.ReadRowsRequest.getDescriptor().getEnumTypes().get(0); + } + + private static final RequestStatsView[] VALUES = values(); + + public static RequestStatsView valueOf( + com.google.protobuf.Descriptors.EnumValueDescriptor desc) { + if (desc.getType() != getDescriptor()) { + throw new java.lang.IllegalArgumentException("EnumValueDescriptor is not for this type."); + } + if (desc.getIndex() == -1) { + return UNRECOGNIZED; + } + return VALUES[desc.getIndex()]; + } + + private final int value; + + private RequestStatsView(int value) { + this.value = value; + } + + // @@protoc_insertion_point(enum_scope:google.bigtable.v2.ReadRowsRequest.RequestStatsView) + } + public static final int TABLE_NAME_FIELD_NUMBER = 1; private volatile java.lang.Object tableName_; /** @@ -218,8 +296,8 @@ public com.google.protobuf.ByteString getTableNameBytes() { * * *
-   * This value specifies routing for replication. If not specified, the
-   * "default" application profile will be used.
+   * This value specifies routing for replication. This API only accepts the
+   * empty value of app_profile_id.
    * 
* * string app_profile_id = 5; @@ -242,8 +320,8 @@ public java.lang.String getAppProfileId() { * * *
-   * This value specifies routing for replication. If not specified, the
-   * "default" application profile will be used.
+   * This value specifies routing for replication. This API only accepts the
+   * empty value of app_profile_id.
    * 
* * string app_profile_id = 5; @@ -380,6 +458,44 @@ public long getRowsLimit() { return rowsLimit_; } + public static final int REQUEST_STATS_VIEW_FIELD_NUMBER = 6; + private int requestStatsView_; + /** + * + * + *
+   * The view into RequestStats, as described above.
+   * 
+ * + * .google.bigtable.v2.ReadRowsRequest.RequestStatsView request_stats_view = 6; + * + * @return The enum numeric value on the wire for requestStatsView. + */ + @java.lang.Override + public int getRequestStatsViewValue() { + return requestStatsView_; + } + /** + * + * + *
+   * The view into RequestStats, as described above.
+   * 
+ * + * .google.bigtable.v2.ReadRowsRequest.RequestStatsView request_stats_view = 6; + * + * @return The requestStatsView. + */ + @java.lang.Override + public com.google.bigtable.v2.ReadRowsRequest.RequestStatsView getRequestStatsView() { + @SuppressWarnings("deprecation") + com.google.bigtable.v2.ReadRowsRequest.RequestStatsView result = + com.google.bigtable.v2.ReadRowsRequest.RequestStatsView.valueOf(requestStatsView_); + return result == null + ? com.google.bigtable.v2.ReadRowsRequest.RequestStatsView.UNRECOGNIZED + : result; + } + private byte memoizedIsInitialized = -1; @java.lang.Override @@ -409,7 +525,12 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(appProfileId_)) { com.google.protobuf.GeneratedMessageV3.writeString(output, 5, appProfileId_); } - unknownFields.writeTo(output); + if (requestStatsView_ + != com.google.bigtable.v2.ReadRowsRequest.RequestStatsView.REQUEST_STATS_VIEW_UNSPECIFIED + .getNumber()) { + output.writeEnum(6, requestStatsView_); + } + getUnknownFields().writeTo(output); } @java.lang.Override @@ -433,7 +554,12 @@ public int getSerializedSize() { if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(appProfileId_)) { size += com.google.protobuf.GeneratedMessageV3.computeStringSize(5, appProfileId_); } - size += unknownFields.getSerializedSize(); + if (requestStatsView_ + != com.google.bigtable.v2.ReadRowsRequest.RequestStatsView.REQUEST_STATS_VIEW_UNSPECIFIED + .getNumber()) { + size += com.google.protobuf.CodedOutputStream.computeEnumSize(6, requestStatsView_); + } + size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @@ -459,7 +585,8 @@ public boolean equals(final java.lang.Object obj) { if (!getFilter().equals(other.getFilter())) return false; } if (getRowsLimit() != other.getRowsLimit()) return false; - if (!unknownFields.equals(other.unknownFields)) return false; + if (requestStatsView_ != other.requestStatsView_) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -484,7 +611,9 @@ public int hashCode() { } hash = (37 * hash) + ROWS_LIMIT_FIELD_NUMBER; hash = (53 * hash) + com.google.protobuf.Internal.hashLong(getRowsLimit()); - hash = (29 * hash) + unknownFields.hashCode(); + hash = (37 * hash) + REQUEST_STATS_VIEW_FIELD_NUMBER; + hash = (53 * hash) + requestStatsView_; + hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } @@ -613,17 +742,10 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { } // Construct using com.google.bigtable.v2.ReadRowsRequest.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } + private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} } @java.lang.Override @@ -647,6 +769,8 @@ public Builder clear() { } rowsLimit_ = 0L; + requestStatsView_ = 0; + return this; } @@ -687,6 +811,7 @@ public com.google.bigtable.v2.ReadRowsRequest buildPartial() { result.filter_ = filterBuilder_.build(); } result.rowsLimit_ = rowsLimit_; + result.requestStatsView_ = requestStatsView_; onBuilt(); return result; } @@ -753,7 +878,10 @@ public Builder mergeFrom(com.google.bigtable.v2.ReadRowsRequest other) { if (other.getRowsLimit() != 0L) { setRowsLimit(other.getRowsLimit()); } - this.mergeUnknownFields(other.unknownFields); + if (other.requestStatsView_ != 0) { + setRequestStatsViewValue(other.getRequestStatsViewValue()); + } + this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @@ -768,17 +896,67 @@ public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - com.google.bigtable.v2.ReadRowsRequest parsedMessage = null; + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + tableName_ = input.readStringRequireUtf8(); + + break; + } // case 10 + case 18: + { + input.readMessage(getRowsFieldBuilder().getBuilder(), extensionRegistry); + + break; + } // case 18 + case 26: + { + input.readMessage(getFilterFieldBuilder().getBuilder(), extensionRegistry); + + break; + } // case 26 + case 32: + { + rowsLimit_ = input.readInt64(); + + break; + } // case 32 + case 42: + { + appProfileId_ = input.readStringRequireUtf8(); + + break; + } // case 42 + case 48: + { + requestStatsView_ = input.readEnum(); + + break; + } // case 48 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.bigtable.v2.ReadRowsRequest) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } + onChanged(); + } // finally return this; } @@ -913,8 +1091,8 @@ public Builder setTableNameBytes(com.google.protobuf.ByteString value) { * * *
-     * This value specifies routing for replication. If not specified, the
-     * "default" application profile will be used.
+     * This value specifies routing for replication. This API only accepts the
+     * empty value of app_profile_id.
      * 
* * string app_profile_id = 5; @@ -936,8 +1114,8 @@ public java.lang.String getAppProfileId() { * * *
-     * This value specifies routing for replication. If not specified, the
-     * "default" application profile will be used.
+     * This value specifies routing for replication. This API only accepts the
+     * empty value of app_profile_id.
      * 
* * string app_profile_id = 5; @@ -959,8 +1137,8 @@ public com.google.protobuf.ByteString getAppProfileIdBytes() { * * *
-     * This value specifies routing for replication. If not specified, the
-     * "default" application profile will be used.
+     * This value specifies routing for replication. This API only accepts the
+     * empty value of app_profile_id.
      * 
* * string app_profile_id = 5; @@ -981,8 +1159,8 @@ public Builder setAppProfileId(java.lang.String value) { * * *
-     * This value specifies routing for replication. If not specified, the
-     * "default" application profile will be used.
+     * This value specifies routing for replication. This API only accepts the
+     * empty value of app_profile_id.
      * 
* * string app_profile_id = 5; @@ -999,8 +1177,8 @@ public Builder clearAppProfileId() { * * *
-     * This value specifies routing for replication. If not specified, the
-     * "default" application profile will be used.
+     * This value specifies routing for replication. This API only accepts the
+     * empty value of app_profile_id.
      * 
* * string app_profile_id = 5; @@ -1449,6 +1627,100 @@ public Builder clearRowsLimit() { return this; } + private int requestStatsView_ = 0; + /** + * + * + *
+     * The view into RequestStats, as described above.
+     * 
+ * + * .google.bigtable.v2.ReadRowsRequest.RequestStatsView request_stats_view = 6; + * + * @return The enum numeric value on the wire for requestStatsView. + */ + @java.lang.Override + public int getRequestStatsViewValue() { + return requestStatsView_; + } + /** + * + * + *
+     * The view into RequestStats, as described above.
+     * 
+ * + * .google.bigtable.v2.ReadRowsRequest.RequestStatsView request_stats_view = 6; + * + * @param value The enum numeric value on the wire for requestStatsView to set. + * @return This builder for chaining. + */ + public Builder setRequestStatsViewValue(int value) { + + requestStatsView_ = value; + onChanged(); + return this; + } + /** + * + * + *
+     * The view into RequestStats, as described above.
+     * 
+ * + * .google.bigtable.v2.ReadRowsRequest.RequestStatsView request_stats_view = 6; + * + * @return The requestStatsView. + */ + @java.lang.Override + public com.google.bigtable.v2.ReadRowsRequest.RequestStatsView getRequestStatsView() { + @SuppressWarnings("deprecation") + com.google.bigtable.v2.ReadRowsRequest.RequestStatsView result = + com.google.bigtable.v2.ReadRowsRequest.RequestStatsView.valueOf(requestStatsView_); + return result == null + ? com.google.bigtable.v2.ReadRowsRequest.RequestStatsView.UNRECOGNIZED + : result; + } + /** + * + * + *
+     * The view into RequestStats, as described above.
+     * 
+ * + * .google.bigtable.v2.ReadRowsRequest.RequestStatsView request_stats_view = 6; + * + * @param value The requestStatsView to set. + * @return This builder for chaining. + */ + public Builder setRequestStatsView( + com.google.bigtable.v2.ReadRowsRequest.RequestStatsView value) { + if (value == null) { + throw new NullPointerException(); + } + + requestStatsView_ = value.getNumber(); + onChanged(); + return this; + } + /** + * + * + *
+     * The view into RequestStats, as described above.
+     * 
+ * + * .google.bigtable.v2.ReadRowsRequest.RequestStatsView request_stats_view = 6; + * + * @return This builder for chaining. + */ + public Builder clearRequestStatsView() { + + requestStatsView_ = 0; + onChanged(); + return this; + } + @java.lang.Override public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { return super.setUnknownFields(unknownFields); @@ -1481,7 +1753,18 @@ public ReadRowsRequest parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new ReadRowsRequest(input, extensionRegistry); + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); } }; diff --git a/proto-google-cloud-bigtable-v2/src/main/java/com/google/bigtable/v2/ReadRowsRequestOrBuilder.java b/proto-google-cloud-bigtable-v2/src/main/java/com/google/bigtable/v2/ReadRowsRequestOrBuilder.java index 9455f46c5c..2b2e969f06 100644 --- a/proto-google-cloud-bigtable-v2/src/main/java/com/google/bigtable/v2/ReadRowsRequestOrBuilder.java +++ b/proto-google-cloud-bigtable-v2/src/main/java/com/google/bigtable/v2/ReadRowsRequestOrBuilder.java @@ -60,8 +60,8 @@ public interface ReadRowsRequestOrBuilder * * *
-   * This value specifies routing for replication. If not specified, the
-   * "default" application profile will be used.
+   * This value specifies routing for replication. This API only accepts the
+   * empty value of app_profile_id.
    * 
* * string app_profile_id = 5; @@ -73,8 +73,8 @@ public interface ReadRowsRequestOrBuilder * * *
-   * This value specifies routing for replication. If not specified, the
-   * "default" application profile will be used.
+   * This value specifies routing for replication. This API only accepts the
+   * empty value of app_profile_id.
    * 
* * string app_profile_id = 5; @@ -172,4 +172,29 @@ public interface ReadRowsRequestOrBuilder * @return The rowsLimit. */ long getRowsLimit(); + + /** + * + * + *
+   * The view into RequestStats, as described above.
+   * 
+ * + * .google.bigtable.v2.ReadRowsRequest.RequestStatsView request_stats_view = 6; + * + * @return The enum numeric value on the wire for requestStatsView. + */ + int getRequestStatsViewValue(); + /** + * + * + *
+   * The view into RequestStats, as described above.
+   * 
+ * + * .google.bigtable.v2.ReadRowsRequest.RequestStatsView request_stats_view = 6; + * + * @return The requestStatsView. + */ + com.google.bigtable.v2.ReadRowsRequest.RequestStatsView getRequestStatsView(); } diff --git a/proto-google-cloud-bigtable-v2/src/main/java/com/google/bigtable/v2/ReadRowsResponse.java b/proto-google-cloud-bigtable-v2/src/main/java/com/google/bigtable/v2/ReadRowsResponse.java index 98ac786491..2de28f715e 100644 --- a/proto-google-cloud-bigtable-v2/src/main/java/com/google/bigtable/v2/ReadRowsResponse.java +++ b/proto-google-cloud-bigtable-v2/src/main/java/com/google/bigtable/v2/ReadRowsResponse.java @@ -53,67 +53,6 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - private ReadRowsResponse( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - int mutable_bitField0_ = 0; - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - if (!((mutable_bitField0_ & 0x00000001) != 0)) { - chunks_ = - new java.util.ArrayList(); - mutable_bitField0_ |= 0x00000001; - } - chunks_.add( - input.readMessage( - com.google.bigtable.v2.ReadRowsResponse.CellChunk.parser(), - extensionRegistry)); - break; - } - case 18: - { - lastScannedRowKey_ = input.readBytes(); - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); - } finally { - if (((mutable_bitField0_ & 0x00000001) != 0)) { - chunks_ = java.util.Collections.unmodifiableList(chunks_); - } - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.bigtable.v2.BigtableProto .internal_static_google_bigtable_v2_ReadRowsResponse_descriptor; @@ -452,121 +391,6 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - private CellChunk( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - int mutable_bitField0_ = 0; - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - rowKey_ = input.readBytes(); - break; - } - case 18: - { - com.google.protobuf.StringValue.Builder subBuilder = null; - if (familyName_ != null) { - subBuilder = familyName_.toBuilder(); - } - familyName_ = - input.readMessage(com.google.protobuf.StringValue.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(familyName_); - familyName_ = subBuilder.buildPartial(); - } - - break; - } - case 26: - { - com.google.protobuf.BytesValue.Builder subBuilder = null; - if (qualifier_ != null) { - subBuilder = qualifier_.toBuilder(); - } - qualifier_ = - input.readMessage(com.google.protobuf.BytesValue.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(qualifier_); - qualifier_ = subBuilder.buildPartial(); - } - - break; - } - case 32: - { - timestampMicros_ = input.readInt64(); - break; - } - case 42: - { - java.lang.String s = input.readStringRequireUtf8(); - if (!((mutable_bitField0_ & 0x00000001) != 0)) { - labels_ = new com.google.protobuf.LazyStringArrayList(); - mutable_bitField0_ |= 0x00000001; - } - labels_.add(s); - break; - } - case 50: - { - value_ = input.readBytes(); - break; - } - case 56: - { - valueSize_ = input.readInt32(); - break; - } - case 64: - { - rowStatus_ = input.readBool(); - rowStatusCase_ = 8; - break; - } - case 72: - { - rowStatus_ = input.readBool(); - rowStatusCase_ = 9; - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); - } finally { - if (((mutable_bitField0_ & 0x00000001) != 0)) { - labels_ = labels_.getUnmodifiableView(); - } - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.bigtable.v2.BigtableProto .internal_static_google_bigtable_v2_ReadRowsResponse_CellChunk_descriptor; @@ -1023,7 +847,7 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io if (rowStatusCase_ == 9) { output.writeBool(9, (boolean) ((java.lang.Boolean) rowStatus_)); } - unknownFields.writeTo(output); + getUnknownFields().writeTo(output); } @java.lang.Override @@ -1068,7 +892,7 @@ public int getSerializedSize() { com.google.protobuf.CodedOutputStream.computeBoolSize( 9, (boolean) ((java.lang.Boolean) rowStatus_)); } - size += unknownFields.getSerializedSize(); + size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @@ -1108,7 +932,7 @@ public boolean equals(final java.lang.Object obj) { case 0: default: } - if (!unknownFields.equals(other.unknownFields)) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -1151,7 +975,7 @@ public int hashCode() { case 0: default: } - hash = (29 * hash) + unknownFields.hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } @@ -1283,17 +1107,10 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { } // Construct using com.google.bigtable.v2.ReadRowsResponse.CellChunk.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } + private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} } @java.lang.Override @@ -1473,7 +1290,7 @@ public Builder mergeFrom(com.google.bigtable.v2.ReadRowsResponse.CellChunk other break; } } - this.mergeUnknownFields(other.unknownFields); + this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @@ -1488,18 +1305,86 @@ public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - com.google.bigtable.v2.ReadRowsResponse.CellChunk parsedMessage = null; + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + rowKey_ = input.readBytes(); + + break; + } // case 10 + case 18: + { + input.readMessage(getFamilyNameFieldBuilder().getBuilder(), extensionRegistry); + + break; + } // case 18 + case 26: + { + input.readMessage(getQualifierFieldBuilder().getBuilder(), extensionRegistry); + + break; + } // case 26 + case 32: + { + timestampMicros_ = input.readInt64(); + + break; + } // case 32 + case 42: + { + java.lang.String s = input.readStringRequireUtf8(); + ensureLabelsIsMutable(); + labels_.add(s); + break; + } // case 42 + case 50: + { + value_ = input.readBytes(); + + break; + } // case 50 + case 56: + { + valueSize_ = input.readInt32(); + + break; + } // case 56 + case 64: + { + rowStatus_ = input.readBool(); + rowStatusCase_ = 8; + break; + } // case 64 + case 72: + { + rowStatus_ = input.readBool(); + rowStatusCase_ = 9; + break; + } // case 72 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = - (com.google.bigtable.v2.ReadRowsResponse.CellChunk) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } + onChanged(); + } // finally return this; } @@ -2600,7 +2485,19 @@ public CellChunk parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new CellChunk(input, extensionRegistry); + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException() + .setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); } }; @@ -2712,6 +2609,102 @@ public com.google.protobuf.ByteString getLastScannedRowKey() { return lastScannedRowKey_; } + public static final int REQUEST_STATS_FIELD_NUMBER = 3; + private com.google.bigtable.v2.RequestStats requestStats_; + /** + * + * + *
+   * If requested, provide enhanced query performance statistics. The semantics
+   * dictate:
+   *   * request_stats is empty on every (streamed) response, except
+   *   * request_stats has non-empty information after all chunks have been
+   *     streamed, where the ReadRowsResponse message only contains
+   *     request_stats.
+   *       * For example, if a read request would have returned an empty
+   *         response instead a single ReadRowsResponse is streamed with empty
+   *         chunks and request_stats filled.
+   * Visually, response messages will stream as follows:
+   *    ... -> {chunks: [...]} -> {chunks: [], request_stats: {...}}
+   *   \______________________/  \________________________________/
+   *       Primary response         Trailer of RequestStats info
+   * Or if the read did not return any values:
+   *   {chunks: [], request_stats: {...}}
+   *   \________________________________/
+   *      Trailer of RequestStats info
+   * 
+ * + * .google.bigtable.v2.RequestStats request_stats = 3; + * + * @return Whether the requestStats field is set. + */ + @java.lang.Override + public boolean hasRequestStats() { + return requestStats_ != null; + } + /** + * + * + *
+   * If requested, provide enhanced query performance statistics. The semantics
+   * dictate:
+   *   * request_stats is empty on every (streamed) response, except
+   *   * request_stats has non-empty information after all chunks have been
+   *     streamed, where the ReadRowsResponse message only contains
+   *     request_stats.
+   *       * For example, if a read request would have returned an empty
+   *         response instead a single ReadRowsResponse is streamed with empty
+   *         chunks and request_stats filled.
+   * Visually, response messages will stream as follows:
+   *    ... -> {chunks: [...]} -> {chunks: [], request_stats: {...}}
+   *   \______________________/  \________________________________/
+   *       Primary response         Trailer of RequestStats info
+   * Or if the read did not return any values:
+   *   {chunks: [], request_stats: {...}}
+   *   \________________________________/
+   *      Trailer of RequestStats info
+   * 
+ * + * .google.bigtable.v2.RequestStats request_stats = 3; + * + * @return The requestStats. + */ + @java.lang.Override + public com.google.bigtable.v2.RequestStats getRequestStats() { + return requestStats_ == null + ? com.google.bigtable.v2.RequestStats.getDefaultInstance() + : requestStats_; + } + /** + * + * + *
+   * If requested, provide enhanced query performance statistics. The semantics
+   * dictate:
+   *   * request_stats is empty on every (streamed) response, except
+   *   * request_stats has non-empty information after all chunks have been
+   *     streamed, where the ReadRowsResponse message only contains
+   *     request_stats.
+   *       * For example, if a read request would have returned an empty
+   *         response instead a single ReadRowsResponse is streamed with empty
+   *         chunks and request_stats filled.
+   * Visually, response messages will stream as follows:
+   *    ... -> {chunks: [...]} -> {chunks: [], request_stats: {...}}
+   *   \______________________/  \________________________________/
+   *       Primary response         Trailer of RequestStats info
+   * Or if the read did not return any values:
+   *   {chunks: [], request_stats: {...}}
+   *   \________________________________/
+   *      Trailer of RequestStats info
+   * 
+ * + * .google.bigtable.v2.RequestStats request_stats = 3; + */ + @java.lang.Override + public com.google.bigtable.v2.RequestStatsOrBuilder getRequestStatsOrBuilder() { + return getRequestStats(); + } + private byte memoizedIsInitialized = -1; @java.lang.Override @@ -2732,7 +2725,10 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io if (!lastScannedRowKey_.isEmpty()) { output.writeBytes(2, lastScannedRowKey_); } - unknownFields.writeTo(output); + if (requestStats_ != null) { + output.writeMessage(3, getRequestStats()); + } + getUnknownFields().writeTo(output); } @java.lang.Override @@ -2747,7 +2743,10 @@ public int getSerializedSize() { if (!lastScannedRowKey_.isEmpty()) { size += com.google.protobuf.CodedOutputStream.computeBytesSize(2, lastScannedRowKey_); } - size += unknownFields.getSerializedSize(); + if (requestStats_ != null) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(3, getRequestStats()); + } + size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @@ -2764,7 +2763,11 @@ public boolean equals(final java.lang.Object obj) { if (!getChunksList().equals(other.getChunksList())) return false; if (!getLastScannedRowKey().equals(other.getLastScannedRowKey())) return false; - if (!unknownFields.equals(other.unknownFields)) return false; + if (hasRequestStats() != other.hasRequestStats()) return false; + if (hasRequestStats()) { + if (!getRequestStats().equals(other.getRequestStats())) return false; + } + if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -2781,7 +2784,11 @@ public int hashCode() { } hash = (37 * hash) + LAST_SCANNED_ROW_KEY_FIELD_NUMBER; hash = (53 * hash) + getLastScannedRowKey().hashCode(); - hash = (29 * hash) + unknownFields.hashCode(); + if (hasRequestStats()) { + hash = (37 * hash) + REQUEST_STATS_FIELD_NUMBER; + hash = (53 * hash) + getRequestStats().hashCode(); + } + hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } @@ -2910,19 +2917,10 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { } // Construct using com.google.bigtable.v2.ReadRowsResponse.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } + private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) { - getChunksFieldBuilder(); - } } @java.lang.Override @@ -2930,12 +2928,19 @@ public Builder clear() { super.clear(); if (chunksBuilder_ == null) { chunks_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000001); } else { + chunks_ = null; chunksBuilder_.clear(); } + bitField0_ = (bitField0_ & ~0x00000001); lastScannedRowKey_ = com.google.protobuf.ByteString.EMPTY; + if (requestStatsBuilder_ == null) { + requestStats_ = null; + } else { + requestStats_ = null; + requestStatsBuilder_ = null; + } return this; } @@ -2974,6 +2979,11 @@ public com.google.bigtable.v2.ReadRowsResponse buildPartial() { result.chunks_ = chunksBuilder_.build(); } result.lastScannedRowKey_ = lastScannedRowKey_; + if (requestStatsBuilder_ == null) { + result.requestStats_ = requestStats_; + } else { + result.requestStats_ = requestStatsBuilder_.build(); + } onBuilt(); return result; } @@ -3053,7 +3063,10 @@ public Builder mergeFrom(com.google.bigtable.v2.ReadRowsResponse other) { if (other.getLastScannedRowKey() != com.google.protobuf.ByteString.EMPTY) { setLastScannedRowKey(other.getLastScannedRowKey()); } - this.mergeUnknownFields(other.unknownFields); + if (other.hasRequestStats()) { + mergeRequestStats(other.getRequestStats()); + } + this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @@ -3068,17 +3081,57 @@ public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - com.google.bigtable.v2.ReadRowsResponse parsedMessage = null; + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + com.google.bigtable.v2.ReadRowsResponse.CellChunk m = + input.readMessage( + com.google.bigtable.v2.ReadRowsResponse.CellChunk.parser(), + extensionRegistry); + if (chunksBuilder_ == null) { + ensureChunksIsMutable(); + chunks_.add(m); + } else { + chunksBuilder_.addMessage(m); + } + break; + } // case 10 + case 18: + { + lastScannedRowKey_ = input.readBytes(); + + break; + } // case 18 + case 26: + { + input.readMessage(getRequestStatsFieldBuilder().getBuilder(), extensionRegistry); + + break; + } // case 26 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.bigtable.v2.ReadRowsResponse) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } + onChanged(); + } // finally return this; } @@ -3511,6 +3564,335 @@ public Builder clearLastScannedRowKey() { return this; } + private com.google.bigtable.v2.RequestStats requestStats_; + private com.google.protobuf.SingleFieldBuilderV3< + com.google.bigtable.v2.RequestStats, + com.google.bigtable.v2.RequestStats.Builder, + com.google.bigtable.v2.RequestStatsOrBuilder> + requestStatsBuilder_; + /** + * + * + *
+     * If requested, provide enhanced query performance statistics. The semantics
+     * dictate:
+     *   * request_stats is empty on every (streamed) response, except
+     *   * request_stats has non-empty information after all chunks have been
+     *     streamed, where the ReadRowsResponse message only contains
+     *     request_stats.
+     *       * For example, if a read request would have returned an empty
+     *         response instead a single ReadRowsResponse is streamed with empty
+     *         chunks and request_stats filled.
+     * Visually, response messages will stream as follows:
+     *    ... -> {chunks: [...]} -> {chunks: [], request_stats: {...}}
+     *   \______________________/  \________________________________/
+     *       Primary response         Trailer of RequestStats info
+     * Or if the read did not return any values:
+     *   {chunks: [], request_stats: {...}}
+     *   \________________________________/
+     *      Trailer of RequestStats info
+     * 
+ * + * .google.bigtable.v2.RequestStats request_stats = 3; + * + * @return Whether the requestStats field is set. + */ + public boolean hasRequestStats() { + return requestStatsBuilder_ != null || requestStats_ != null; + } + /** + * + * + *
+     * If requested, provide enhanced query performance statistics. The semantics
+     * dictate:
+     *   * request_stats is empty on every (streamed) response, except
+     *   * request_stats has non-empty information after all chunks have been
+     *     streamed, where the ReadRowsResponse message only contains
+     *     request_stats.
+     *       * For example, if a read request would have returned an empty
+     *         response instead a single ReadRowsResponse is streamed with empty
+     *         chunks and request_stats filled.
+     * Visually, response messages will stream as follows:
+     *    ... -> {chunks: [...]} -> {chunks: [], request_stats: {...}}
+     *   \______________________/  \________________________________/
+     *       Primary response         Trailer of RequestStats info
+     * Or if the read did not return any values:
+     *   {chunks: [], request_stats: {...}}
+     *   \________________________________/
+     *      Trailer of RequestStats info
+     * 
+ * + * .google.bigtable.v2.RequestStats request_stats = 3; + * + * @return The requestStats. + */ + public com.google.bigtable.v2.RequestStats getRequestStats() { + if (requestStatsBuilder_ == null) { + return requestStats_ == null + ? com.google.bigtable.v2.RequestStats.getDefaultInstance() + : requestStats_; + } else { + return requestStatsBuilder_.getMessage(); + } + } + /** + * + * + *
+     * If requested, provide enhanced query performance statistics. The semantics
+     * dictate:
+     *   * request_stats is empty on every (streamed) response, except
+     *   * request_stats has non-empty information after all chunks have been
+     *     streamed, where the ReadRowsResponse message only contains
+     *     request_stats.
+     *       * For example, if a read request would have returned an empty
+     *         response instead a single ReadRowsResponse is streamed with empty
+     *         chunks and request_stats filled.
+     * Visually, response messages will stream as follows:
+     *    ... -> {chunks: [...]} -> {chunks: [], request_stats: {...}}
+     *   \______________________/  \________________________________/
+     *       Primary response         Trailer of RequestStats info
+     * Or if the read did not return any values:
+     *   {chunks: [], request_stats: {...}}
+     *   \________________________________/
+     *      Trailer of RequestStats info
+     * 
+ * + * .google.bigtable.v2.RequestStats request_stats = 3; + */ + public Builder setRequestStats(com.google.bigtable.v2.RequestStats value) { + if (requestStatsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + requestStats_ = value; + onChanged(); + } else { + requestStatsBuilder_.setMessage(value); + } + + return this; + } + /** + * + * + *
+     * If requested, provide enhanced query performance statistics. The semantics
+     * dictate:
+     *   * request_stats is empty on every (streamed) response, except
+     *   * request_stats has non-empty information after all chunks have been
+     *     streamed, where the ReadRowsResponse message only contains
+     *     request_stats.
+     *       * For example, if a read request would have returned an empty
+     *         response instead a single ReadRowsResponse is streamed with empty
+     *         chunks and request_stats filled.
+     * Visually, response messages will stream as follows:
+     *    ... -> {chunks: [...]} -> {chunks: [], request_stats: {...}}
+     *   \______________________/  \________________________________/
+     *       Primary response         Trailer of RequestStats info
+     * Or if the read did not return any values:
+     *   {chunks: [], request_stats: {...}}
+     *   \________________________________/
+     *      Trailer of RequestStats info
+     * 
+ * + * .google.bigtable.v2.RequestStats request_stats = 3; + */ + public Builder setRequestStats(com.google.bigtable.v2.RequestStats.Builder builderForValue) { + if (requestStatsBuilder_ == null) { + requestStats_ = builderForValue.build(); + onChanged(); + } else { + requestStatsBuilder_.setMessage(builderForValue.build()); + } + + return this; + } + /** + * + * + *
+     * If requested, provide enhanced query performance statistics. The semantics
+     * dictate:
+     *   * request_stats is empty on every (streamed) response, except
+     *   * request_stats has non-empty information after all chunks have been
+     *     streamed, where the ReadRowsResponse message only contains
+     *     request_stats.
+     *       * For example, if a read request would have returned an empty
+     *         response instead a single ReadRowsResponse is streamed with empty
+     *         chunks and request_stats filled.
+     * Visually, response messages will stream as follows:
+     *    ... -> {chunks: [...]} -> {chunks: [], request_stats: {...}}
+     *   \______________________/  \________________________________/
+     *       Primary response         Trailer of RequestStats info
+     * Or if the read did not return any values:
+     *   {chunks: [], request_stats: {...}}
+     *   \________________________________/
+     *      Trailer of RequestStats info
+     * 
+ * + * .google.bigtable.v2.RequestStats request_stats = 3; + */ + public Builder mergeRequestStats(com.google.bigtable.v2.RequestStats value) { + if (requestStatsBuilder_ == null) { + if (requestStats_ != null) { + requestStats_ = + com.google.bigtable.v2.RequestStats.newBuilder(requestStats_) + .mergeFrom(value) + .buildPartial(); + } else { + requestStats_ = value; + } + onChanged(); + } else { + requestStatsBuilder_.mergeFrom(value); + } + + return this; + } + /** + * + * + *
+     * If requested, provide enhanced query performance statistics. The semantics
+     * dictate:
+     *   * request_stats is empty on every (streamed) response, except
+     *   * request_stats has non-empty information after all chunks have been
+     *     streamed, where the ReadRowsResponse message only contains
+     *     request_stats.
+     *       * For example, if a read request would have returned an empty
+     *         response instead a single ReadRowsResponse is streamed with empty
+     *         chunks and request_stats filled.
+     * Visually, response messages will stream as follows:
+     *    ... -> {chunks: [...]} -> {chunks: [], request_stats: {...}}
+     *   \______________________/  \________________________________/
+     *       Primary response         Trailer of RequestStats info
+     * Or if the read did not return any values:
+     *   {chunks: [], request_stats: {...}}
+     *   \________________________________/
+     *      Trailer of RequestStats info
+     * 
+ * + * .google.bigtable.v2.RequestStats request_stats = 3; + */ + public Builder clearRequestStats() { + if (requestStatsBuilder_ == null) { + requestStats_ = null; + onChanged(); + } else { + requestStats_ = null; + requestStatsBuilder_ = null; + } + + return this; + } + /** + * + * + *
+     * If requested, provide enhanced query performance statistics. The semantics
+     * dictate:
+     *   * request_stats is empty on every (streamed) response, except
+     *   * request_stats has non-empty information after all chunks have been
+     *     streamed, where the ReadRowsResponse message only contains
+     *     request_stats.
+     *       * For example, if a read request would have returned an empty
+     *         response instead a single ReadRowsResponse is streamed with empty
+     *         chunks and request_stats filled.
+     * Visually, response messages will stream as follows:
+     *    ... -> {chunks: [...]} -> {chunks: [], request_stats: {...}}
+     *   \______________________/  \________________________________/
+     *       Primary response         Trailer of RequestStats info
+     * Or if the read did not return any values:
+     *   {chunks: [], request_stats: {...}}
+     *   \________________________________/
+     *      Trailer of RequestStats info
+     * 
+ * + * .google.bigtable.v2.RequestStats request_stats = 3; + */ + public com.google.bigtable.v2.RequestStats.Builder getRequestStatsBuilder() { + + onChanged(); + return getRequestStatsFieldBuilder().getBuilder(); + } + /** + * + * + *
+     * If requested, provide enhanced query performance statistics. The semantics
+     * dictate:
+     *   * request_stats is empty on every (streamed) response, except
+     *   * request_stats has non-empty information after all chunks have been
+     *     streamed, where the ReadRowsResponse message only contains
+     *     request_stats.
+     *       * For example, if a read request would have returned an empty
+     *         response instead a single ReadRowsResponse is streamed with empty
+     *         chunks and request_stats filled.
+     * Visually, response messages will stream as follows:
+     *    ... -> {chunks: [...]} -> {chunks: [], request_stats: {...}}
+     *   \______________________/  \________________________________/
+     *       Primary response         Trailer of RequestStats info
+     * Or if the read did not return any values:
+     *   {chunks: [], request_stats: {...}}
+     *   \________________________________/
+     *      Trailer of RequestStats info
+     * 
+ * + * .google.bigtable.v2.RequestStats request_stats = 3; + */ + public com.google.bigtable.v2.RequestStatsOrBuilder getRequestStatsOrBuilder() { + if (requestStatsBuilder_ != null) { + return requestStatsBuilder_.getMessageOrBuilder(); + } else { + return requestStats_ == null + ? com.google.bigtable.v2.RequestStats.getDefaultInstance() + : requestStats_; + } + } + /** + * + * + *
+     * If requested, provide enhanced query performance statistics. The semantics
+     * dictate:
+     *   * request_stats is empty on every (streamed) response, except
+     *   * request_stats has non-empty information after all chunks have been
+     *     streamed, where the ReadRowsResponse message only contains
+     *     request_stats.
+     *       * For example, if a read request would have returned an empty
+     *         response instead a single ReadRowsResponse is streamed with empty
+     *         chunks and request_stats filled.
+     * Visually, response messages will stream as follows:
+     *    ... -> {chunks: [...]} -> {chunks: [], request_stats: {...}}
+     *   \______________________/  \________________________________/
+     *       Primary response         Trailer of RequestStats info
+     * Or if the read did not return any values:
+     *   {chunks: [], request_stats: {...}}
+     *   \________________________________/
+     *      Trailer of RequestStats info
+     * 
+ * + * .google.bigtable.v2.RequestStats request_stats = 3; + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.bigtable.v2.RequestStats, + com.google.bigtable.v2.RequestStats.Builder, + com.google.bigtable.v2.RequestStatsOrBuilder> + getRequestStatsFieldBuilder() { + if (requestStatsBuilder_ == null) { + requestStatsBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.bigtable.v2.RequestStats, + com.google.bigtable.v2.RequestStats.Builder, + com.google.bigtable.v2.RequestStatsOrBuilder>( + getRequestStats(), getParentForChildren(), isClean()); + requestStats_ = null; + } + return requestStatsBuilder_; + } + @java.lang.Override public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { return super.setUnknownFields(unknownFields); @@ -3543,7 +3925,18 @@ public ReadRowsResponse parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new ReadRowsResponse(input, extensionRegistry); + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); } }; diff --git a/proto-google-cloud-bigtable-v2/src/main/java/com/google/bigtable/v2/ReadRowsResponseOrBuilder.java b/proto-google-cloud-bigtable-v2/src/main/java/com/google/bigtable/v2/ReadRowsResponseOrBuilder.java index 84410a4c1e..26522bed3b 100644 --- a/proto-google-cloud-bigtable-v2/src/main/java/com/google/bigtable/v2/ReadRowsResponseOrBuilder.java +++ b/proto-google-cloud-bigtable-v2/src/main/java/com/google/bigtable/v2/ReadRowsResponseOrBuilder.java @@ -93,4 +93,87 @@ public interface ReadRowsResponseOrBuilder * @return The lastScannedRowKey. */ com.google.protobuf.ByteString getLastScannedRowKey(); + + /** + * + * + *
+   * If requested, provide enhanced query performance statistics. The semantics
+   * dictate:
+   *   * request_stats is empty on every (streamed) response, except
+   *   * request_stats has non-empty information after all chunks have been
+   *     streamed, where the ReadRowsResponse message only contains
+   *     request_stats.
+   *       * For example, if a read request would have returned an empty
+   *         response instead a single ReadRowsResponse is streamed with empty
+   *         chunks and request_stats filled.
+   * Visually, response messages will stream as follows:
+   *    ... -> {chunks: [...]} -> {chunks: [], request_stats: {...}}
+   *   \______________________/  \________________________________/
+   *       Primary response         Trailer of RequestStats info
+   * Or if the read did not return any values:
+   *   {chunks: [], request_stats: {...}}
+   *   \________________________________/
+   *      Trailer of RequestStats info
+   * 
+ * + * .google.bigtable.v2.RequestStats request_stats = 3; + * + * @return Whether the requestStats field is set. + */ + boolean hasRequestStats(); + /** + * + * + *
+   * If requested, provide enhanced query performance statistics. The semantics
+   * dictate:
+   *   * request_stats is empty on every (streamed) response, except
+   *   * request_stats has non-empty information after all chunks have been
+   *     streamed, where the ReadRowsResponse message only contains
+   *     request_stats.
+   *       * For example, if a read request would have returned an empty
+   *         response instead a single ReadRowsResponse is streamed with empty
+   *         chunks and request_stats filled.
+   * Visually, response messages will stream as follows:
+   *    ... -> {chunks: [...]} -> {chunks: [], request_stats: {...}}
+   *   \______________________/  \________________________________/
+   *       Primary response         Trailer of RequestStats info
+   * Or if the read did not return any values:
+   *   {chunks: [], request_stats: {...}}
+   *   \________________________________/
+   *      Trailer of RequestStats info
+   * 
+ * + * .google.bigtable.v2.RequestStats request_stats = 3; + * + * @return The requestStats. + */ + com.google.bigtable.v2.RequestStats getRequestStats(); + /** + * + * + *
+   * If requested, provide enhanced query performance statistics. The semantics
+   * dictate:
+   *   * request_stats is empty on every (streamed) response, except
+   *   * request_stats has non-empty information after all chunks have been
+   *     streamed, where the ReadRowsResponse message only contains
+   *     request_stats.
+   *       * For example, if a read request would have returned an empty
+   *         response instead a single ReadRowsResponse is streamed with empty
+   *         chunks and request_stats filled.
+   * Visually, response messages will stream as follows:
+   *    ... -> {chunks: [...]} -> {chunks: [], request_stats: {...}}
+   *   \______________________/  \________________________________/
+   *       Primary response         Trailer of RequestStats info
+   * Or if the read did not return any values:
+   *   {chunks: [], request_stats: {...}}
+   *   \________________________________/
+   *      Trailer of RequestStats info
+   * 
+ * + * .google.bigtable.v2.RequestStats request_stats = 3; + */ + com.google.bigtable.v2.RequestStatsOrBuilder getRequestStatsOrBuilder(); } diff --git a/proto-google-cloud-bigtable-v2/src/main/java/com/google/bigtable/v2/RequestLatencyStats.java b/proto-google-cloud-bigtable-v2/src/main/java/com/google/bigtable/v2/RequestLatencyStats.java new file mode 100644 index 0000000000..b8f0d518de --- /dev/null +++ b/proto-google-cloud-bigtable-v2/src/main/java/com/google/bigtable/v2/RequestLatencyStats.java @@ -0,0 +1,876 @@ +/* + * Copyright 2020 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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/bigtable/v2/request_stats.proto + +package com.google.bigtable.v2; + +/** + * + * + *
+ * RequestLatencyStats provides a measurement of the latency of the request as
+ * it interacts with different systems over its lifetime, e.g. how long the
+ * request took to execute within a frontend server.
+ * 
+ * + * Protobuf type {@code google.bigtable.v2.RequestLatencyStats} + */ +public final class RequestLatencyStats extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.bigtable.v2.RequestLatencyStats) + RequestLatencyStatsOrBuilder { + private static final long serialVersionUID = 0L; + // Use RequestLatencyStats.newBuilder() to construct. + private RequestLatencyStats(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private RequestLatencyStats() {} + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new RequestLatencyStats(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.bigtable.v2.RequestStatsProto + .internal_static_google_bigtable_v2_RequestLatencyStats_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.bigtable.v2.RequestStatsProto + .internal_static_google_bigtable_v2_RequestLatencyStats_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.bigtable.v2.RequestLatencyStats.class, + com.google.bigtable.v2.RequestLatencyStats.Builder.class); + } + + public static final int FRONTEND_SERVER_LATENCY_FIELD_NUMBER = 1; + private com.google.protobuf.Duration frontendServerLatency_; + /** + * + * + *
+   * The latency measured by the frontend server handling this request, from
+   * when the request was received, to when this value is sent back in the
+   * response. For more context on the component that is measuring this latency,
+   * see: https://cloud.google.com/bigtable/docs/overview
+   * Note: This value may be slightly shorter than the value reported into
+   * aggregate latency metrics in Monitoring for this request
+   * (https://cloud.google.com/bigtable/docs/monitoring-instance) as this value
+   * needs to be sent in the response before the latency measurement including
+   * that transmission is finalized.
+   * Note: This value includes the end-to-end latency of contacting nodes in
+   * the targeted cluster, e.g. measuring from when the first byte arrives at
+   * the frontend server, to when this value is sent back as the last value in
+   * the response, including any latency incurred by contacting nodes, waiting
+   * for results from nodes, and finally sending results from nodes back to the
+   * caller.
+   * 
+ * + * .google.protobuf.Duration frontend_server_latency = 1; + * + * @return Whether the frontendServerLatency field is set. + */ + @java.lang.Override + public boolean hasFrontendServerLatency() { + return frontendServerLatency_ != null; + } + /** + * + * + *
+   * The latency measured by the frontend server handling this request, from
+   * when the request was received, to when this value is sent back in the
+   * response. For more context on the component that is measuring this latency,
+   * see: https://cloud.google.com/bigtable/docs/overview
+   * Note: This value may be slightly shorter than the value reported into
+   * aggregate latency metrics in Monitoring for this request
+   * (https://cloud.google.com/bigtable/docs/monitoring-instance) as this value
+   * needs to be sent in the response before the latency measurement including
+   * that transmission is finalized.
+   * Note: This value includes the end-to-end latency of contacting nodes in
+   * the targeted cluster, e.g. measuring from when the first byte arrives at
+   * the frontend server, to when this value is sent back as the last value in
+   * the response, including any latency incurred by contacting nodes, waiting
+   * for results from nodes, and finally sending results from nodes back to the
+   * caller.
+   * 
+ * + * .google.protobuf.Duration frontend_server_latency = 1; + * + * @return The frontendServerLatency. + */ + @java.lang.Override + public com.google.protobuf.Duration getFrontendServerLatency() { + return frontendServerLatency_ == null + ? com.google.protobuf.Duration.getDefaultInstance() + : frontendServerLatency_; + } + /** + * + * + *
+   * The latency measured by the frontend server handling this request, from
+   * when the request was received, to when this value is sent back in the
+   * response. For more context on the component that is measuring this latency,
+   * see: https://cloud.google.com/bigtable/docs/overview
+   * Note: This value may be slightly shorter than the value reported into
+   * aggregate latency metrics in Monitoring for this request
+   * (https://cloud.google.com/bigtable/docs/monitoring-instance) as this value
+   * needs to be sent in the response before the latency measurement including
+   * that transmission is finalized.
+   * Note: This value includes the end-to-end latency of contacting nodes in
+   * the targeted cluster, e.g. measuring from when the first byte arrives at
+   * the frontend server, to when this value is sent back as the last value in
+   * the response, including any latency incurred by contacting nodes, waiting
+   * for results from nodes, and finally sending results from nodes back to the
+   * caller.
+   * 
+ * + * .google.protobuf.Duration frontend_server_latency = 1; + */ + @java.lang.Override + public com.google.protobuf.DurationOrBuilder getFrontendServerLatencyOrBuilder() { + return getFrontendServerLatency(); + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (frontendServerLatency_ != null) { + output.writeMessage(1, getFrontendServerLatency()); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (frontendServerLatency_ != null) { + size += + com.google.protobuf.CodedOutputStream.computeMessageSize(1, getFrontendServerLatency()); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.bigtable.v2.RequestLatencyStats)) { + return super.equals(obj); + } + com.google.bigtable.v2.RequestLatencyStats other = + (com.google.bigtable.v2.RequestLatencyStats) obj; + + if (hasFrontendServerLatency() != other.hasFrontendServerLatency()) return false; + if (hasFrontendServerLatency()) { + if (!getFrontendServerLatency().equals(other.getFrontendServerLatency())) return false; + } + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + if (hasFrontendServerLatency()) { + hash = (37 * hash) + FRONTEND_SERVER_LATENCY_FIELD_NUMBER; + hash = (53 * hash) + getFrontendServerLatency().hashCode(); + } + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.bigtable.v2.RequestLatencyStats parseFrom(java.nio.ByteBuffer data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.bigtable.v2.RequestLatencyStats parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.bigtable.v2.RequestLatencyStats parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.bigtable.v2.RequestLatencyStats parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.bigtable.v2.RequestLatencyStats parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.bigtable.v2.RequestLatencyStats parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.bigtable.v2.RequestLatencyStats parseFrom(java.io.InputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.bigtable.v2.RequestLatencyStats parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.bigtable.v2.RequestLatencyStats parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.bigtable.v2.RequestLatencyStats parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.bigtable.v2.RequestLatencyStats parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.bigtable.v2.RequestLatencyStats parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder(com.google.bigtable.v2.RequestLatencyStats prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + /** + * + * + *
+   * RequestLatencyStats provides a measurement of the latency of the request as
+   * it interacts with different systems over its lifetime, e.g. how long the
+   * request took to execute within a frontend server.
+   * 
+ * + * Protobuf type {@code google.bigtable.v2.RequestLatencyStats} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.bigtable.v2.RequestLatencyStats) + com.google.bigtable.v2.RequestLatencyStatsOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.bigtable.v2.RequestStatsProto + .internal_static_google_bigtable_v2_RequestLatencyStats_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.bigtable.v2.RequestStatsProto + .internal_static_google_bigtable_v2_RequestLatencyStats_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.bigtable.v2.RequestLatencyStats.class, + com.google.bigtable.v2.RequestLatencyStats.Builder.class); + } + + // Construct using com.google.bigtable.v2.RequestLatencyStats.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + } + + @java.lang.Override + public Builder clear() { + super.clear(); + if (frontendServerLatencyBuilder_ == null) { + frontendServerLatency_ = null; + } else { + frontendServerLatency_ = null; + frontendServerLatencyBuilder_ = null; + } + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.bigtable.v2.RequestStatsProto + .internal_static_google_bigtable_v2_RequestLatencyStats_descriptor; + } + + @java.lang.Override + public com.google.bigtable.v2.RequestLatencyStats getDefaultInstanceForType() { + return com.google.bigtable.v2.RequestLatencyStats.getDefaultInstance(); + } + + @java.lang.Override + public com.google.bigtable.v2.RequestLatencyStats build() { + com.google.bigtable.v2.RequestLatencyStats result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.bigtable.v2.RequestLatencyStats buildPartial() { + com.google.bigtable.v2.RequestLatencyStats result = + new com.google.bigtable.v2.RequestLatencyStats(this); + if (frontendServerLatencyBuilder_ == null) { + result.frontendServerLatency_ = frontendServerLatency_; + } else { + result.frontendServerLatency_ = frontendServerLatencyBuilder_.build(); + } + onBuilt(); + return result; + } + + @java.lang.Override + public Builder clone() { + return super.clone(); + } + + @java.lang.Override + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.setField(field, value); + } + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); + } + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); + } + + @java.lang.Override + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { + return super.setRepeatedField(field, index, value); + } + + @java.lang.Override + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.addRepeatedField(field, value); + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.bigtable.v2.RequestLatencyStats) { + return mergeFrom((com.google.bigtable.v2.RequestLatencyStats) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.bigtable.v2.RequestLatencyStats other) { + if (other == com.google.bigtable.v2.RequestLatencyStats.getDefaultInstance()) return this; + if (other.hasFrontendServerLatency()) { + mergeFrontendServerLatency(other.getFrontendServerLatency()); + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + input.readMessage( + getFrontendServerLatencyFieldBuilder().getBuilder(), extensionRegistry); + + break; + } // case 10 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private com.google.protobuf.Duration frontendServerLatency_; + private com.google.protobuf.SingleFieldBuilderV3< + com.google.protobuf.Duration, + com.google.protobuf.Duration.Builder, + com.google.protobuf.DurationOrBuilder> + frontendServerLatencyBuilder_; + /** + * + * + *
+     * The latency measured by the frontend server handling this request, from
+     * when the request was received, to when this value is sent back in the
+     * response. For more context on the component that is measuring this latency,
+     * see: https://cloud.google.com/bigtable/docs/overview
+     * Note: This value may be slightly shorter than the value reported into
+     * aggregate latency metrics in Monitoring for this request
+     * (https://cloud.google.com/bigtable/docs/monitoring-instance) as this value
+     * needs to be sent in the response before the latency measurement including
+     * that transmission is finalized.
+     * Note: This value includes the end-to-end latency of contacting nodes in
+     * the targeted cluster, e.g. measuring from when the first byte arrives at
+     * the frontend server, to when this value is sent back as the last value in
+     * the response, including any latency incurred by contacting nodes, waiting
+     * for results from nodes, and finally sending results from nodes back to the
+     * caller.
+     * 
+ * + * .google.protobuf.Duration frontend_server_latency = 1; + * + * @return Whether the frontendServerLatency field is set. + */ + public boolean hasFrontendServerLatency() { + return frontendServerLatencyBuilder_ != null || frontendServerLatency_ != null; + } + /** + * + * + *
+     * The latency measured by the frontend server handling this request, from
+     * when the request was received, to when this value is sent back in the
+     * response. For more context on the component that is measuring this latency,
+     * see: https://cloud.google.com/bigtable/docs/overview
+     * Note: This value may be slightly shorter than the value reported into
+     * aggregate latency metrics in Monitoring for this request
+     * (https://cloud.google.com/bigtable/docs/monitoring-instance) as this value
+     * needs to be sent in the response before the latency measurement including
+     * that transmission is finalized.
+     * Note: This value includes the end-to-end latency of contacting nodes in
+     * the targeted cluster, e.g. measuring from when the first byte arrives at
+     * the frontend server, to when this value is sent back as the last value in
+     * the response, including any latency incurred by contacting nodes, waiting
+     * for results from nodes, and finally sending results from nodes back to the
+     * caller.
+     * 
+ * + * .google.protobuf.Duration frontend_server_latency = 1; + * + * @return The frontendServerLatency. + */ + public com.google.protobuf.Duration getFrontendServerLatency() { + if (frontendServerLatencyBuilder_ == null) { + return frontendServerLatency_ == null + ? com.google.protobuf.Duration.getDefaultInstance() + : frontendServerLatency_; + } else { + return frontendServerLatencyBuilder_.getMessage(); + } + } + /** + * + * + *
+     * The latency measured by the frontend server handling this request, from
+     * when the request was received, to when this value is sent back in the
+     * response. For more context on the component that is measuring this latency,
+     * see: https://cloud.google.com/bigtable/docs/overview
+     * Note: This value may be slightly shorter than the value reported into
+     * aggregate latency metrics in Monitoring for this request
+     * (https://cloud.google.com/bigtable/docs/monitoring-instance) as this value
+     * needs to be sent in the response before the latency measurement including
+     * that transmission is finalized.
+     * Note: This value includes the end-to-end latency of contacting nodes in
+     * the targeted cluster, e.g. measuring from when the first byte arrives at
+     * the frontend server, to when this value is sent back as the last value in
+     * the response, including any latency incurred by contacting nodes, waiting
+     * for results from nodes, and finally sending results from nodes back to the
+     * caller.
+     * 
+ * + * .google.protobuf.Duration frontend_server_latency = 1; + */ + public Builder setFrontendServerLatency(com.google.protobuf.Duration value) { + if (frontendServerLatencyBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + frontendServerLatency_ = value; + onChanged(); + } else { + frontendServerLatencyBuilder_.setMessage(value); + } + + return this; + } + /** + * + * + *
+     * The latency measured by the frontend server handling this request, from
+     * when the request was received, to when this value is sent back in the
+     * response. For more context on the component that is measuring this latency,
+     * see: https://cloud.google.com/bigtable/docs/overview
+     * Note: This value may be slightly shorter than the value reported into
+     * aggregate latency metrics in Monitoring for this request
+     * (https://cloud.google.com/bigtable/docs/monitoring-instance) as this value
+     * needs to be sent in the response before the latency measurement including
+     * that transmission is finalized.
+     * Note: This value includes the end-to-end latency of contacting nodes in
+     * the targeted cluster, e.g. measuring from when the first byte arrives at
+     * the frontend server, to when this value is sent back as the last value in
+     * the response, including any latency incurred by contacting nodes, waiting
+     * for results from nodes, and finally sending results from nodes back to the
+     * caller.
+     * 
+ * + * .google.protobuf.Duration frontend_server_latency = 1; + */ + public Builder setFrontendServerLatency(com.google.protobuf.Duration.Builder builderForValue) { + if (frontendServerLatencyBuilder_ == null) { + frontendServerLatency_ = builderForValue.build(); + onChanged(); + } else { + frontendServerLatencyBuilder_.setMessage(builderForValue.build()); + } + + return this; + } + /** + * + * + *
+     * The latency measured by the frontend server handling this request, from
+     * when the request was received, to when this value is sent back in the
+     * response. For more context on the component that is measuring this latency,
+     * see: https://cloud.google.com/bigtable/docs/overview
+     * Note: This value may be slightly shorter than the value reported into
+     * aggregate latency metrics in Monitoring for this request
+     * (https://cloud.google.com/bigtable/docs/monitoring-instance) as this value
+     * needs to be sent in the response before the latency measurement including
+     * that transmission is finalized.
+     * Note: This value includes the end-to-end latency of contacting nodes in
+     * the targeted cluster, e.g. measuring from when the first byte arrives at
+     * the frontend server, to when this value is sent back as the last value in
+     * the response, including any latency incurred by contacting nodes, waiting
+     * for results from nodes, and finally sending results from nodes back to the
+     * caller.
+     * 
+ * + * .google.protobuf.Duration frontend_server_latency = 1; + */ + public Builder mergeFrontendServerLatency(com.google.protobuf.Duration value) { + if (frontendServerLatencyBuilder_ == null) { + if (frontendServerLatency_ != null) { + frontendServerLatency_ = + com.google.protobuf.Duration.newBuilder(frontendServerLatency_) + .mergeFrom(value) + .buildPartial(); + } else { + frontendServerLatency_ = value; + } + onChanged(); + } else { + frontendServerLatencyBuilder_.mergeFrom(value); + } + + return this; + } + /** + * + * + *
+     * The latency measured by the frontend server handling this request, from
+     * when the request was received, to when this value is sent back in the
+     * response. For more context on the component that is measuring this latency,
+     * see: https://cloud.google.com/bigtable/docs/overview
+     * Note: This value may be slightly shorter than the value reported into
+     * aggregate latency metrics in Monitoring for this request
+     * (https://cloud.google.com/bigtable/docs/monitoring-instance) as this value
+     * needs to be sent in the response before the latency measurement including
+     * that transmission is finalized.
+     * Note: This value includes the end-to-end latency of contacting nodes in
+     * the targeted cluster, e.g. measuring from when the first byte arrives at
+     * the frontend server, to when this value is sent back as the last value in
+     * the response, including any latency incurred by contacting nodes, waiting
+     * for results from nodes, and finally sending results from nodes back to the
+     * caller.
+     * 
+ * + * .google.protobuf.Duration frontend_server_latency = 1; + */ + public Builder clearFrontendServerLatency() { + if (frontendServerLatencyBuilder_ == null) { + frontendServerLatency_ = null; + onChanged(); + } else { + frontendServerLatency_ = null; + frontendServerLatencyBuilder_ = null; + } + + return this; + } + /** + * + * + *
+     * The latency measured by the frontend server handling this request, from
+     * when the request was received, to when this value is sent back in the
+     * response. For more context on the component that is measuring this latency,
+     * see: https://cloud.google.com/bigtable/docs/overview
+     * Note: This value may be slightly shorter than the value reported into
+     * aggregate latency metrics in Monitoring for this request
+     * (https://cloud.google.com/bigtable/docs/monitoring-instance) as this value
+     * needs to be sent in the response before the latency measurement including
+     * that transmission is finalized.
+     * Note: This value includes the end-to-end latency of contacting nodes in
+     * the targeted cluster, e.g. measuring from when the first byte arrives at
+     * the frontend server, to when this value is sent back as the last value in
+     * the response, including any latency incurred by contacting nodes, waiting
+     * for results from nodes, and finally sending results from nodes back to the
+     * caller.
+     * 
+ * + * .google.protobuf.Duration frontend_server_latency = 1; + */ + public com.google.protobuf.Duration.Builder getFrontendServerLatencyBuilder() { + + onChanged(); + return getFrontendServerLatencyFieldBuilder().getBuilder(); + } + /** + * + * + *
+     * The latency measured by the frontend server handling this request, from
+     * when the request was received, to when this value is sent back in the
+     * response. For more context on the component that is measuring this latency,
+     * see: https://cloud.google.com/bigtable/docs/overview
+     * Note: This value may be slightly shorter than the value reported into
+     * aggregate latency metrics in Monitoring for this request
+     * (https://cloud.google.com/bigtable/docs/monitoring-instance) as this value
+     * needs to be sent in the response before the latency measurement including
+     * that transmission is finalized.
+     * Note: This value includes the end-to-end latency of contacting nodes in
+     * the targeted cluster, e.g. measuring from when the first byte arrives at
+     * the frontend server, to when this value is sent back as the last value in
+     * the response, including any latency incurred by contacting nodes, waiting
+     * for results from nodes, and finally sending results from nodes back to the
+     * caller.
+     * 
+ * + * .google.protobuf.Duration frontend_server_latency = 1; + */ + public com.google.protobuf.DurationOrBuilder getFrontendServerLatencyOrBuilder() { + if (frontendServerLatencyBuilder_ != null) { + return frontendServerLatencyBuilder_.getMessageOrBuilder(); + } else { + return frontendServerLatency_ == null + ? com.google.protobuf.Duration.getDefaultInstance() + : frontendServerLatency_; + } + } + /** + * + * + *
+     * The latency measured by the frontend server handling this request, from
+     * when the request was received, to when this value is sent back in the
+     * response. For more context on the component that is measuring this latency,
+     * see: https://cloud.google.com/bigtable/docs/overview
+     * Note: This value may be slightly shorter than the value reported into
+     * aggregate latency metrics in Monitoring for this request
+     * (https://cloud.google.com/bigtable/docs/monitoring-instance) as this value
+     * needs to be sent in the response before the latency measurement including
+     * that transmission is finalized.
+     * Note: This value includes the end-to-end latency of contacting nodes in
+     * the targeted cluster, e.g. measuring from when the first byte arrives at
+     * the frontend server, to when this value is sent back as the last value in
+     * the response, including any latency incurred by contacting nodes, waiting
+     * for results from nodes, and finally sending results from nodes back to the
+     * caller.
+     * 
+ * + * .google.protobuf.Duration frontend_server_latency = 1; + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.protobuf.Duration, + com.google.protobuf.Duration.Builder, + com.google.protobuf.DurationOrBuilder> + getFrontendServerLatencyFieldBuilder() { + if (frontendServerLatencyBuilder_ == null) { + frontendServerLatencyBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.protobuf.Duration, + com.google.protobuf.Duration.Builder, + com.google.protobuf.DurationOrBuilder>( + getFrontendServerLatency(), getParentForChildren(), isClean()); + frontendServerLatency_ = null; + } + return frontendServerLatencyBuilder_; + } + + @java.lang.Override + public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFields(unknownFields); + } + + @java.lang.Override + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + // @@protoc_insertion_point(builder_scope:google.bigtable.v2.RequestLatencyStats) + } + + // @@protoc_insertion_point(class_scope:google.bigtable.v2.RequestLatencyStats) + private static final com.google.bigtable.v2.RequestLatencyStats DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.bigtable.v2.RequestLatencyStats(); + } + + public static com.google.bigtable.v2.RequestLatencyStats getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public RequestLatencyStats parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.bigtable.v2.RequestLatencyStats getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/proto-google-cloud-bigtable-v2/src/main/java/com/google/bigtable/v2/RequestLatencyStatsOrBuilder.java b/proto-google-cloud-bigtable-v2/src/main/java/com/google/bigtable/v2/RequestLatencyStatsOrBuilder.java new file mode 100644 index 0000000000..956f3a7af7 --- /dev/null +++ b/proto-google-cloud-bigtable-v2/src/main/java/com/google/bigtable/v2/RequestLatencyStatsOrBuilder.java @@ -0,0 +1,102 @@ +/* + * Copyright 2020 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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/bigtable/v2/request_stats.proto + +package com.google.bigtable.v2; + +public interface RequestLatencyStatsOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.bigtable.v2.RequestLatencyStats) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * The latency measured by the frontend server handling this request, from
+   * when the request was received, to when this value is sent back in the
+   * response. For more context on the component that is measuring this latency,
+   * see: https://cloud.google.com/bigtable/docs/overview
+   * Note: This value may be slightly shorter than the value reported into
+   * aggregate latency metrics in Monitoring for this request
+   * (https://cloud.google.com/bigtable/docs/monitoring-instance) as this value
+   * needs to be sent in the response before the latency measurement including
+   * that transmission is finalized.
+   * Note: This value includes the end-to-end latency of contacting nodes in
+   * the targeted cluster, e.g. measuring from when the first byte arrives at
+   * the frontend server, to when this value is sent back as the last value in
+   * the response, including any latency incurred by contacting nodes, waiting
+   * for results from nodes, and finally sending results from nodes back to the
+   * caller.
+   * 
+ * + * .google.protobuf.Duration frontend_server_latency = 1; + * + * @return Whether the frontendServerLatency field is set. + */ + boolean hasFrontendServerLatency(); + /** + * + * + *
+   * The latency measured by the frontend server handling this request, from
+   * when the request was received, to when this value is sent back in the
+   * response. For more context on the component that is measuring this latency,
+   * see: https://cloud.google.com/bigtable/docs/overview
+   * Note: This value may be slightly shorter than the value reported into
+   * aggregate latency metrics in Monitoring for this request
+   * (https://cloud.google.com/bigtable/docs/monitoring-instance) as this value
+   * needs to be sent in the response before the latency measurement including
+   * that transmission is finalized.
+   * Note: This value includes the end-to-end latency of contacting nodes in
+   * the targeted cluster, e.g. measuring from when the first byte arrives at
+   * the frontend server, to when this value is sent back as the last value in
+   * the response, including any latency incurred by contacting nodes, waiting
+   * for results from nodes, and finally sending results from nodes back to the
+   * caller.
+   * 
+ * + * .google.protobuf.Duration frontend_server_latency = 1; + * + * @return The frontendServerLatency. + */ + com.google.protobuf.Duration getFrontendServerLatency(); + /** + * + * + *
+   * The latency measured by the frontend server handling this request, from
+   * when the request was received, to when this value is sent back in the
+   * response. For more context on the component that is measuring this latency,
+   * see: https://cloud.google.com/bigtable/docs/overview
+   * Note: This value may be slightly shorter than the value reported into
+   * aggregate latency metrics in Monitoring for this request
+   * (https://cloud.google.com/bigtable/docs/monitoring-instance) as this value
+   * needs to be sent in the response before the latency measurement including
+   * that transmission is finalized.
+   * Note: This value includes the end-to-end latency of contacting nodes in
+   * the targeted cluster, e.g. measuring from when the first byte arrives at
+   * the frontend server, to when this value is sent back as the last value in
+   * the response, including any latency incurred by contacting nodes, waiting
+   * for results from nodes, and finally sending results from nodes back to the
+   * caller.
+   * 
+ * + * .google.protobuf.Duration frontend_server_latency = 1; + */ + com.google.protobuf.DurationOrBuilder getFrontendServerLatencyOrBuilder(); +} diff --git a/proto-google-cloud-bigtable-v2/src/main/java/com/google/bigtable/v2/RequestStats.java b/proto-google-cloud-bigtable-v2/src/main/java/com/google/bigtable/v2/RequestStats.java new file mode 100644 index 0000000000..9f648b3022 --- /dev/null +++ b/proto-google-cloud-bigtable-v2/src/main/java/com/google/bigtable/v2/RequestStats.java @@ -0,0 +1,824 @@ +/* + * Copyright 2020 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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/bigtable/v2/request_stats.proto + +package com.google.bigtable.v2; + +/** + * + * + *
+ * RequestStats is the container for additional information pertaining to a
+ * single request, helpful for evaluating the performance of the sent request.
+ * Currently, there are the following supported methods:
+ *   * google.bigtable.v2.ReadRows
+ * 
+ * + * Protobuf type {@code google.bigtable.v2.RequestStats} + */ +public final class RequestStats extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.bigtable.v2.RequestStats) + RequestStatsOrBuilder { + private static final long serialVersionUID = 0L; + // Use RequestStats.newBuilder() to construct. + private RequestStats(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private RequestStats() {} + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new RequestStats(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.bigtable.v2.RequestStatsProto + .internal_static_google_bigtable_v2_RequestStats_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.bigtable.v2.RequestStatsProto + .internal_static_google_bigtable_v2_RequestStats_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.bigtable.v2.RequestStats.class, + com.google.bigtable.v2.RequestStats.Builder.class); + } + + private int statsViewCase_ = 0; + private java.lang.Object statsView_; + + public enum StatsViewCase + implements + com.google.protobuf.Internal.EnumLite, + com.google.protobuf.AbstractMessage.InternalOneOfEnum { + FULL_READ_STATS_VIEW(1), + STATSVIEW_NOT_SET(0); + private final int value; + + private StatsViewCase(int value) { + this.value = value; + } + /** + * @param value The number of the enum to look for. + * @return The enum associated with the given number. + * @deprecated Use {@link #forNumber(int)} instead. + */ + @java.lang.Deprecated + public static StatsViewCase valueOf(int value) { + return forNumber(value); + } + + public static StatsViewCase forNumber(int value) { + switch (value) { + case 1: + return FULL_READ_STATS_VIEW; + case 0: + return STATSVIEW_NOT_SET; + default: + return null; + } + } + + public int getNumber() { + return this.value; + } + }; + + public StatsViewCase getStatsViewCase() { + return StatsViewCase.forNumber(statsViewCase_); + } + + public static final int FULL_READ_STATS_VIEW_FIELD_NUMBER = 1; + /** + * + * + *
+   * Available with the ReadRowsRequest.RequestStatsView.REQUEST_STATS_FULL
+   * view, see package google.bigtable.v2.
+   * 
+ * + * .google.bigtable.v2.FullReadStatsView full_read_stats_view = 1; + * + * @return Whether the fullReadStatsView field is set. + */ + @java.lang.Override + public boolean hasFullReadStatsView() { + return statsViewCase_ == 1; + } + /** + * + * + *
+   * Available with the ReadRowsRequest.RequestStatsView.REQUEST_STATS_FULL
+   * view, see package google.bigtable.v2.
+   * 
+ * + * .google.bigtable.v2.FullReadStatsView full_read_stats_view = 1; + * + * @return The fullReadStatsView. + */ + @java.lang.Override + public com.google.bigtable.v2.FullReadStatsView getFullReadStatsView() { + if (statsViewCase_ == 1) { + return (com.google.bigtable.v2.FullReadStatsView) statsView_; + } + return com.google.bigtable.v2.FullReadStatsView.getDefaultInstance(); + } + /** + * + * + *
+   * Available with the ReadRowsRequest.RequestStatsView.REQUEST_STATS_FULL
+   * view, see package google.bigtable.v2.
+   * 
+ * + * .google.bigtable.v2.FullReadStatsView full_read_stats_view = 1; + */ + @java.lang.Override + public com.google.bigtable.v2.FullReadStatsViewOrBuilder getFullReadStatsViewOrBuilder() { + if (statsViewCase_ == 1) { + return (com.google.bigtable.v2.FullReadStatsView) statsView_; + } + return com.google.bigtable.v2.FullReadStatsView.getDefaultInstance(); + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (statsViewCase_ == 1) { + output.writeMessage(1, (com.google.bigtable.v2.FullReadStatsView) statsView_); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (statsViewCase_ == 1) { + size += + com.google.protobuf.CodedOutputStream.computeMessageSize( + 1, (com.google.bigtable.v2.FullReadStatsView) statsView_); + } + size += getUnknownFields().getSerializedSize(); + memoizedSize = size; + return size; + } + + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.bigtable.v2.RequestStats)) { + return super.equals(obj); + } + com.google.bigtable.v2.RequestStats other = (com.google.bigtable.v2.RequestStats) obj; + + if (!getStatsViewCase().equals(other.getStatsViewCase())) return false; + switch (statsViewCase_) { + case 1: + if (!getFullReadStatsView().equals(other.getFullReadStatsView())) return false; + break; + case 0: + default: + } + if (!getUnknownFields().equals(other.getUnknownFields())) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + switch (statsViewCase_) { + case 1: + hash = (37 * hash) + FULL_READ_STATS_VIEW_FIELD_NUMBER; + hash = (53 * hash) + getFullReadStatsView().hashCode(); + break; + case 0: + default: + } + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.bigtable.v2.RequestStats parseFrom(java.nio.ByteBuffer data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.bigtable.v2.RequestStats parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.bigtable.v2.RequestStats parseFrom(com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.bigtable.v2.RequestStats parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.bigtable.v2.RequestStats parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.bigtable.v2.RequestStats parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.bigtable.v2.RequestStats parseFrom(java.io.InputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.bigtable.v2.RequestStats parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.bigtable.v2.RequestStats parseDelimitedFrom(java.io.InputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.bigtable.v2.RequestStats parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.bigtable.v2.RequestStats parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.bigtable.v2.RequestStats parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } + + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } + + public static Builder newBuilder(com.google.bigtable.v2.RequestStats prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } + + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } + + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + /** + * + * + *
+   * RequestStats is the container for additional information pertaining to a
+   * single request, helpful for evaluating the performance of the sent request.
+   * Currently, there are the following supported methods:
+   *   * google.bigtable.v2.ReadRows
+   * 
+ * + * Protobuf type {@code google.bigtable.v2.RequestStats} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.bigtable.v2.RequestStats) + com.google.bigtable.v2.RequestStatsOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.bigtable.v2.RequestStatsProto + .internal_static_google_bigtable_v2_RequestStats_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.bigtable.v2.RequestStatsProto + .internal_static_google_bigtable_v2_RequestStats_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.bigtable.v2.RequestStats.class, + com.google.bigtable.v2.RequestStats.Builder.class); + } + + // Construct using com.google.bigtable.v2.RequestStats.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + } + + @java.lang.Override + public Builder clear() { + super.clear(); + if (fullReadStatsViewBuilder_ != null) { + fullReadStatsViewBuilder_.clear(); + } + statsViewCase_ = 0; + statsView_ = null; + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.bigtable.v2.RequestStatsProto + .internal_static_google_bigtable_v2_RequestStats_descriptor; + } + + @java.lang.Override + public com.google.bigtable.v2.RequestStats getDefaultInstanceForType() { + return com.google.bigtable.v2.RequestStats.getDefaultInstance(); + } + + @java.lang.Override + public com.google.bigtable.v2.RequestStats build() { + com.google.bigtable.v2.RequestStats result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.bigtable.v2.RequestStats buildPartial() { + com.google.bigtable.v2.RequestStats result = new com.google.bigtable.v2.RequestStats(this); + if (statsViewCase_ == 1) { + if (fullReadStatsViewBuilder_ == null) { + result.statsView_ = statsView_; + } else { + result.statsView_ = fullReadStatsViewBuilder_.build(); + } + } + result.statsViewCase_ = statsViewCase_; + onBuilt(); + return result; + } + + @java.lang.Override + public Builder clone() { + return super.clone(); + } + + @java.lang.Override + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.setField(field, value); + } + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); + } + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); + } + + @java.lang.Override + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { + return super.setRepeatedField(field, index, value); + } + + @java.lang.Override + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.addRepeatedField(field, value); + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.bigtable.v2.RequestStats) { + return mergeFrom((com.google.bigtable.v2.RequestStats) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.bigtable.v2.RequestStats other) { + if (other == com.google.bigtable.v2.RequestStats.getDefaultInstance()) return this; + switch (other.getStatsViewCase()) { + case FULL_READ_STATS_VIEW: + { + mergeFullReadStatsView(other.getFullReadStatsView()); + break; + } + case STATSVIEW_NOT_SET: + { + break; + } + } + this.mergeUnknownFields(other.getUnknownFields()); + onChanged(); + return this; + } + + @java.lang.Override + public final boolean isInitialized() { + return true; + } + + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + input.readMessage( + getFullReadStatsViewFieldBuilder().getBuilder(), extensionRegistry); + statsViewCase_ = 1; + break; + } // case 10 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.unwrapIOException(); + } finally { + onChanged(); + } // finally + return this; + } + + private int statsViewCase_ = 0; + private java.lang.Object statsView_; + + public StatsViewCase getStatsViewCase() { + return StatsViewCase.forNumber(statsViewCase_); + } + + public Builder clearStatsView() { + statsViewCase_ = 0; + statsView_ = null; + onChanged(); + return this; + } + + private com.google.protobuf.SingleFieldBuilderV3< + com.google.bigtable.v2.FullReadStatsView, + com.google.bigtable.v2.FullReadStatsView.Builder, + com.google.bigtable.v2.FullReadStatsViewOrBuilder> + fullReadStatsViewBuilder_; + /** + * + * + *
+     * Available with the ReadRowsRequest.RequestStatsView.REQUEST_STATS_FULL
+     * view, see package google.bigtable.v2.
+     * 
+ * + * .google.bigtable.v2.FullReadStatsView full_read_stats_view = 1; + * + * @return Whether the fullReadStatsView field is set. + */ + @java.lang.Override + public boolean hasFullReadStatsView() { + return statsViewCase_ == 1; + } + /** + * + * + *
+     * Available with the ReadRowsRequest.RequestStatsView.REQUEST_STATS_FULL
+     * view, see package google.bigtable.v2.
+     * 
+ * + * .google.bigtable.v2.FullReadStatsView full_read_stats_view = 1; + * + * @return The fullReadStatsView. + */ + @java.lang.Override + public com.google.bigtable.v2.FullReadStatsView getFullReadStatsView() { + if (fullReadStatsViewBuilder_ == null) { + if (statsViewCase_ == 1) { + return (com.google.bigtable.v2.FullReadStatsView) statsView_; + } + return com.google.bigtable.v2.FullReadStatsView.getDefaultInstance(); + } else { + if (statsViewCase_ == 1) { + return fullReadStatsViewBuilder_.getMessage(); + } + return com.google.bigtable.v2.FullReadStatsView.getDefaultInstance(); + } + } + /** + * + * + *
+     * Available with the ReadRowsRequest.RequestStatsView.REQUEST_STATS_FULL
+     * view, see package google.bigtable.v2.
+     * 
+ * + * .google.bigtable.v2.FullReadStatsView full_read_stats_view = 1; + */ + public Builder setFullReadStatsView(com.google.bigtable.v2.FullReadStatsView value) { + if (fullReadStatsViewBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + statsView_ = value; + onChanged(); + } else { + fullReadStatsViewBuilder_.setMessage(value); + } + statsViewCase_ = 1; + return this; + } + /** + * + * + *
+     * Available with the ReadRowsRequest.RequestStatsView.REQUEST_STATS_FULL
+     * view, see package google.bigtable.v2.
+     * 
+ * + * .google.bigtable.v2.FullReadStatsView full_read_stats_view = 1; + */ + public Builder setFullReadStatsView( + com.google.bigtable.v2.FullReadStatsView.Builder builderForValue) { + if (fullReadStatsViewBuilder_ == null) { + statsView_ = builderForValue.build(); + onChanged(); + } else { + fullReadStatsViewBuilder_.setMessage(builderForValue.build()); + } + statsViewCase_ = 1; + return this; + } + /** + * + * + *
+     * Available with the ReadRowsRequest.RequestStatsView.REQUEST_STATS_FULL
+     * view, see package google.bigtable.v2.
+     * 
+ * + * .google.bigtable.v2.FullReadStatsView full_read_stats_view = 1; + */ + public Builder mergeFullReadStatsView(com.google.bigtable.v2.FullReadStatsView value) { + if (fullReadStatsViewBuilder_ == null) { + if (statsViewCase_ == 1 + && statsView_ != com.google.bigtable.v2.FullReadStatsView.getDefaultInstance()) { + statsView_ = + com.google.bigtable.v2.FullReadStatsView.newBuilder( + (com.google.bigtable.v2.FullReadStatsView) statsView_) + .mergeFrom(value) + .buildPartial(); + } else { + statsView_ = value; + } + onChanged(); + } else { + if (statsViewCase_ == 1) { + fullReadStatsViewBuilder_.mergeFrom(value); + } else { + fullReadStatsViewBuilder_.setMessage(value); + } + } + statsViewCase_ = 1; + return this; + } + /** + * + * + *
+     * Available with the ReadRowsRequest.RequestStatsView.REQUEST_STATS_FULL
+     * view, see package google.bigtable.v2.
+     * 
+ * + * .google.bigtable.v2.FullReadStatsView full_read_stats_view = 1; + */ + public Builder clearFullReadStatsView() { + if (fullReadStatsViewBuilder_ == null) { + if (statsViewCase_ == 1) { + statsViewCase_ = 0; + statsView_ = null; + onChanged(); + } + } else { + if (statsViewCase_ == 1) { + statsViewCase_ = 0; + statsView_ = null; + } + fullReadStatsViewBuilder_.clear(); + } + return this; + } + /** + * + * + *
+     * Available with the ReadRowsRequest.RequestStatsView.REQUEST_STATS_FULL
+     * view, see package google.bigtable.v2.
+     * 
+ * + * .google.bigtable.v2.FullReadStatsView full_read_stats_view = 1; + */ + public com.google.bigtable.v2.FullReadStatsView.Builder getFullReadStatsViewBuilder() { + return getFullReadStatsViewFieldBuilder().getBuilder(); + } + /** + * + * + *
+     * Available with the ReadRowsRequest.RequestStatsView.REQUEST_STATS_FULL
+     * view, see package google.bigtable.v2.
+     * 
+ * + * .google.bigtable.v2.FullReadStatsView full_read_stats_view = 1; + */ + @java.lang.Override + public com.google.bigtable.v2.FullReadStatsViewOrBuilder getFullReadStatsViewOrBuilder() { + if ((statsViewCase_ == 1) && (fullReadStatsViewBuilder_ != null)) { + return fullReadStatsViewBuilder_.getMessageOrBuilder(); + } else { + if (statsViewCase_ == 1) { + return (com.google.bigtable.v2.FullReadStatsView) statsView_; + } + return com.google.bigtable.v2.FullReadStatsView.getDefaultInstance(); + } + } + /** + * + * + *
+     * Available with the ReadRowsRequest.RequestStatsView.REQUEST_STATS_FULL
+     * view, see package google.bigtable.v2.
+     * 
+ * + * .google.bigtable.v2.FullReadStatsView full_read_stats_view = 1; + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.bigtable.v2.FullReadStatsView, + com.google.bigtable.v2.FullReadStatsView.Builder, + com.google.bigtable.v2.FullReadStatsViewOrBuilder> + getFullReadStatsViewFieldBuilder() { + if (fullReadStatsViewBuilder_ == null) { + if (!(statsViewCase_ == 1)) { + statsView_ = com.google.bigtable.v2.FullReadStatsView.getDefaultInstance(); + } + fullReadStatsViewBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.bigtable.v2.FullReadStatsView, + com.google.bigtable.v2.FullReadStatsView.Builder, + com.google.bigtable.v2.FullReadStatsViewOrBuilder>( + (com.google.bigtable.v2.FullReadStatsView) statsView_, + getParentForChildren(), + isClean()); + statsView_ = null; + } + statsViewCase_ = 1; + onChanged(); + ; + return fullReadStatsViewBuilder_; + } + + @java.lang.Override + public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFields(unknownFields); + } + + @java.lang.Override + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + // @@protoc_insertion_point(builder_scope:google.bigtable.v2.RequestStats) + } + + // @@protoc_insertion_point(class_scope:google.bigtable.v2.RequestStats) + private static final com.google.bigtable.v2.RequestStats DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.bigtable.v2.RequestStats(); + } + + public static com.google.bigtable.v2.RequestStats getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public RequestStats parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); + } + }; + + public static com.google.protobuf.Parser parser() { + return PARSER; + } + + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.bigtable.v2.RequestStats getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/proto-google-cloud-bigtable-v2/src/main/java/com/google/bigtable/v2/RequestStatsOrBuilder.java b/proto-google-cloud-bigtable-v2/src/main/java/com/google/bigtable/v2/RequestStatsOrBuilder.java new file mode 100644 index 0000000000..00b8f2cad4 --- /dev/null +++ b/proto-google-cloud-bigtable-v2/src/main/java/com/google/bigtable/v2/RequestStatsOrBuilder.java @@ -0,0 +1,65 @@ +/* + * Copyright 2020 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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/bigtable/v2/request_stats.proto + +package com.google.bigtable.v2; + +public interface RequestStatsOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.bigtable.v2.RequestStats) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * Available with the ReadRowsRequest.RequestStatsView.REQUEST_STATS_FULL
+   * view, see package google.bigtable.v2.
+   * 
+ * + * .google.bigtable.v2.FullReadStatsView full_read_stats_view = 1; + * + * @return Whether the fullReadStatsView field is set. + */ + boolean hasFullReadStatsView(); + /** + * + * + *
+   * Available with the ReadRowsRequest.RequestStatsView.REQUEST_STATS_FULL
+   * view, see package google.bigtable.v2.
+   * 
+ * + * .google.bigtable.v2.FullReadStatsView full_read_stats_view = 1; + * + * @return The fullReadStatsView. + */ + com.google.bigtable.v2.FullReadStatsView getFullReadStatsView(); + /** + * + * + *
+   * Available with the ReadRowsRequest.RequestStatsView.REQUEST_STATS_FULL
+   * view, see package google.bigtable.v2.
+   * 
+ * + * .google.bigtable.v2.FullReadStatsView full_read_stats_view = 1; + */ + com.google.bigtable.v2.FullReadStatsViewOrBuilder getFullReadStatsViewOrBuilder(); + + public com.google.bigtable.v2.RequestStats.StatsViewCase getStatsViewCase(); +} diff --git a/proto-google-cloud-bigtable-v2/src/main/java/com/google/bigtable/v2/RequestStatsProto.java b/proto-google-cloud-bigtable-v2/src/main/java/com/google/bigtable/v2/RequestStatsProto.java new file mode 100644 index 0000000000..512d606b8b --- /dev/null +++ b/proto-google-cloud-bigtable-v2/src/main/java/com/google/bigtable/v2/RequestStatsProto.java @@ -0,0 +1,118 @@ +/* + * Copyright 2020 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. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/bigtable/v2/request_stats.proto + +package com.google.bigtable.v2; + +public final class RequestStatsProto { + private RequestStatsProto() {} + + public static void registerAllExtensions(com.google.protobuf.ExtensionRegistryLite registry) {} + + public static void registerAllExtensions(com.google.protobuf.ExtensionRegistry registry) { + registerAllExtensions((com.google.protobuf.ExtensionRegistryLite) registry); + } + + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_bigtable_v2_ReadIterationStats_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_bigtable_v2_ReadIterationStats_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_bigtable_v2_RequestLatencyStats_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_bigtable_v2_RequestLatencyStats_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_bigtable_v2_FullReadStatsView_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_bigtable_v2_FullReadStatsView_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_bigtable_v2_RequestStats_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_bigtable_v2_RequestStats_fieldAccessorTable; + + public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + return descriptor; + } + + private static com.google.protobuf.Descriptors.FileDescriptor descriptor; + + static { + java.lang.String[] descriptorData = { + "\n&google/bigtable/v2/request_stats.proto" + + "\022\022google.bigtable.v2\032\036google/protobuf/du" + + "ration.proto\"\202\001\n\022ReadIterationStats\022\027\n\017r" + + "ows_seen_count\030\001 \001(\003\022\033\n\023rows_returned_co" + + "unt\030\002 \001(\003\022\030\n\020cells_seen_count\030\003 \001(\003\022\034\n\024c" + + "ells_returned_count\030\004 \001(\003\"Q\n\023RequestLate" + + "ncyStats\022:\n\027frontend_server_latency\030\001 \001(" + + "\0132\031.google.protobuf.Duration\"\241\001\n\021FullRea" + + "dStatsView\022D\n\024read_iteration_stats\030\001 \001(\013" + + "2&.google.bigtable.v2.ReadIterationStats" + + "\022F\n\025request_latency_stats\030\002 \001(\0132\'.google" + + ".bigtable.v2.RequestLatencyStats\"c\n\014Requ" + + "estStats\022E\n\024full_read_stats_view\030\001 \001(\0132%" + + ".google.bigtable.v2.FullReadStatsViewH\000B" + + "\014\n\nstats_viewB\275\001\n\026com.google.bigtable.v2" + + "B\021RequestStatsProtoP\001Z:google.golang.org" + + "/genproto/googleapis/bigtable/v2;bigtabl" + + "e\252\002\030Google.Cloud.Bigtable.V2\312\002\030Google\\Cl" + + "oud\\Bigtable\\V2\352\002\033Google::Cloud::Bigtabl" + + "e::V2b\006proto3" + }; + descriptor = + com.google.protobuf.Descriptors.FileDescriptor.internalBuildGeneratedFileFrom( + descriptorData, + new com.google.protobuf.Descriptors.FileDescriptor[] { + com.google.protobuf.DurationProto.getDescriptor(), + }); + internal_static_google_bigtable_v2_ReadIterationStats_descriptor = + getDescriptor().getMessageTypes().get(0); + internal_static_google_bigtable_v2_ReadIterationStats_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_bigtable_v2_ReadIterationStats_descriptor, + new java.lang.String[] { + "RowsSeenCount", "RowsReturnedCount", "CellsSeenCount", "CellsReturnedCount", + }); + internal_static_google_bigtable_v2_RequestLatencyStats_descriptor = + getDescriptor().getMessageTypes().get(1); + internal_static_google_bigtable_v2_RequestLatencyStats_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_bigtable_v2_RequestLatencyStats_descriptor, + new java.lang.String[] { + "FrontendServerLatency", + }); + internal_static_google_bigtable_v2_FullReadStatsView_descriptor = + getDescriptor().getMessageTypes().get(2); + internal_static_google_bigtable_v2_FullReadStatsView_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_bigtable_v2_FullReadStatsView_descriptor, + new java.lang.String[] { + "ReadIterationStats", "RequestLatencyStats", + }); + internal_static_google_bigtable_v2_RequestStats_descriptor = + getDescriptor().getMessageTypes().get(3); + internal_static_google_bigtable_v2_RequestStats_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_bigtable_v2_RequestStats_descriptor, + new java.lang.String[] { + "FullReadStatsView", "StatsView", + }); + com.google.protobuf.DurationProto.getDescriptor(); + } + + // @@protoc_insertion_point(outer_class_scope) +} diff --git a/proto-google-cloud-bigtable-v2/src/main/java/com/google/bigtable/v2/ResponseParams.java b/proto-google-cloud-bigtable-v2/src/main/java/com/google/bigtable/v2/ResponseParams.java index c64592a2b4..6c0fc5c63f 100644 --- a/proto-google-cloud-bigtable-v2/src/main/java/com/google/bigtable/v2/ResponseParams.java +++ b/proto-google-cloud-bigtable-v2/src/main/java/com/google/bigtable/v2/ResponseParams.java @@ -56,60 +56,6 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - private ResponseParams( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - int mutable_bitField0_ = 0; - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - java.lang.String s = input.readStringRequireUtf8(); - bitField0_ |= 0x00000001; - zoneId_ = s; - break; - } - case 18: - { - java.lang.String s = input.readStringRequireUtf8(); - bitField0_ |= 0x00000002; - clusterId_ = s; - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.bigtable.v2.ResponseParamsProto .internal_static_google_bigtable_v2_ResponseParams_descriptor; @@ -277,7 +223,7 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io if (((bitField0_ & 0x00000002) != 0)) { com.google.protobuf.GeneratedMessageV3.writeString(output, 2, clusterId_); } - unknownFields.writeTo(output); + getUnknownFields().writeTo(output); } @java.lang.Override @@ -292,7 +238,7 @@ public int getSerializedSize() { if (((bitField0_ & 0x00000002) != 0)) { size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, clusterId_); } - size += unknownFields.getSerializedSize(); + size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @@ -315,7 +261,7 @@ public boolean equals(final java.lang.Object obj) { if (hasClusterId()) { if (!getClusterId().equals(other.getClusterId())) return false; } - if (!unknownFields.equals(other.unknownFields)) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -334,7 +280,7 @@ public int hashCode() { hash = (37 * hash) + CLUSTER_ID_FIELD_NUMBER; hash = (53 * hash) + getClusterId().hashCode(); } - hash = (29 * hash) + unknownFields.hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } @@ -465,17 +411,10 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { } // Construct using com.google.bigtable.v2.ResponseParams.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } + private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} } @java.lang.Override @@ -582,7 +521,7 @@ public Builder mergeFrom(com.google.bigtable.v2.ResponseParams other) { clusterId_ = other.clusterId_; onChanged(); } - this.mergeUnknownFields(other.unknownFields); + this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @@ -597,17 +536,43 @@ public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - com.google.bigtable.v2.ResponseParams parsedMessage = null; + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + zoneId_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000001; + break; + } // case 10 + case 18: + { + clusterId_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000002; + break; + } // case 18 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.bigtable.v2.ResponseParams) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } + onChanged(); + } // finally return this; } @@ -891,7 +856,18 @@ public ResponseParams parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new ResponseParams(input, extensionRegistry); + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); } }; diff --git a/proto-google-cloud-bigtable-v2/src/main/java/com/google/bigtable/v2/Row.java b/proto-google-cloud-bigtable-v2/src/main/java/com/google/bigtable/v2/Row.java index 117cd8638f..8fe37c4d46 100644 --- a/proto-google-cloud-bigtable-v2/src/main/java/com/google/bigtable/v2/Row.java +++ b/proto-google-cloud-bigtable-v2/src/main/java/com/google/bigtable/v2/Row.java @@ -54,64 +54,6 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - private Row( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - int mutable_bitField0_ = 0; - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - key_ = input.readBytes(); - break; - } - case 18: - { - if (!((mutable_bitField0_ & 0x00000001) != 0)) { - families_ = new java.util.ArrayList(); - mutable_bitField0_ |= 0x00000001; - } - families_.add( - input.readMessage(com.google.bigtable.v2.Family.parser(), extensionRegistry)); - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); - } finally { - if (((mutable_bitField0_ & 0x00000001) != 0)) { - families_ = java.util.Collections.unmodifiableList(families_); - } - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.bigtable.v2.DataProto.internal_static_google_bigtable_v2_Row_descriptor; } @@ -239,7 +181,7 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io for (int i = 0; i < families_.size(); i++) { output.writeMessage(2, families_.get(i)); } - unknownFields.writeTo(output); + getUnknownFields().writeTo(output); } @java.lang.Override @@ -254,7 +196,7 @@ public int getSerializedSize() { for (int i = 0; i < families_.size(); i++) { size += com.google.protobuf.CodedOutputStream.computeMessageSize(2, families_.get(i)); } - size += unknownFields.getSerializedSize(); + size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @@ -271,7 +213,7 @@ public boolean equals(final java.lang.Object obj) { if (!getKey().equals(other.getKey())) return false; if (!getFamiliesList().equals(other.getFamiliesList())) return false; - if (!unknownFields.equals(other.unknownFields)) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -288,7 +230,7 @@ public int hashCode() { hash = (37 * hash) + FAMILIES_FIELD_NUMBER; hash = (53 * hash) + getFamiliesList().hashCode(); } - hash = (29 * hash) + unknownFields.hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } @@ -415,19 +357,10 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { } // Construct using com.google.bigtable.v2.Row.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } + private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) { - getFamiliesFieldBuilder(); - } } @java.lang.Override @@ -437,10 +370,11 @@ public Builder clear() { if (familiesBuilder_ == null) { families_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000001); } else { + families_ = null; familiesBuilder_.clear(); } + bitField0_ = (bitField0_ & ~0x00000001); return this; } @@ -556,7 +490,7 @@ public Builder mergeFrom(com.google.bigtable.v2.Row other) { } } } - this.mergeUnknownFields(other.unknownFields); + this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @@ -571,17 +505,49 @@ public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - com.google.bigtable.v2.Row parsedMessage = null; + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + key_ = input.readBytes(); + + break; + } // case 10 + case 18: + { + com.google.bigtable.v2.Family m = + input.readMessage(com.google.bigtable.v2.Family.parser(), extensionRegistry); + if (familiesBuilder_ == null) { + ensureFamiliesIsMutable(); + families_.add(m); + } else { + familiesBuilder_.addMessage(m); + } + break; + } // case 18 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.bigtable.v2.Row) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } + onChanged(); + } // finally return this; } @@ -1044,7 +1010,18 @@ public Row parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new Row(input, extensionRegistry); + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); } }; diff --git a/proto-google-cloud-bigtable-v2/src/main/java/com/google/bigtable/v2/RowFilter.java b/proto-google-cloud-bigtable-v2/src/main/java/com/google/bigtable/v2/RowFilter.java index 802514aace..89d7c853b7 100644 --- a/proto-google-cloud-bigtable-v2/src/main/java/com/google/bigtable/v2/RowFilter.java +++ b/proto-google-cloud-bigtable-v2/src/main/java/com/google/bigtable/v2/RowFilter.java @@ -77,219 +77,6 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - private RowFilter( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - com.google.bigtable.v2.RowFilter.Chain.Builder subBuilder = null; - if (filterCase_ == 1) { - subBuilder = ((com.google.bigtable.v2.RowFilter.Chain) filter_).toBuilder(); - } - filter_ = - input.readMessage( - com.google.bigtable.v2.RowFilter.Chain.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom((com.google.bigtable.v2.RowFilter.Chain) filter_); - filter_ = subBuilder.buildPartial(); - } - filterCase_ = 1; - break; - } - case 18: - { - com.google.bigtable.v2.RowFilter.Interleave.Builder subBuilder = null; - if (filterCase_ == 2) { - subBuilder = ((com.google.bigtable.v2.RowFilter.Interleave) filter_).toBuilder(); - } - filter_ = - input.readMessage( - com.google.bigtable.v2.RowFilter.Interleave.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom((com.google.bigtable.v2.RowFilter.Interleave) filter_); - filter_ = subBuilder.buildPartial(); - } - filterCase_ = 2; - break; - } - case 26: - { - com.google.bigtable.v2.RowFilter.Condition.Builder subBuilder = null; - if (filterCase_ == 3) { - subBuilder = ((com.google.bigtable.v2.RowFilter.Condition) filter_).toBuilder(); - } - filter_ = - input.readMessage( - com.google.bigtable.v2.RowFilter.Condition.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom((com.google.bigtable.v2.RowFilter.Condition) filter_); - filter_ = subBuilder.buildPartial(); - } - filterCase_ = 3; - break; - } - case 34: - { - filter_ = input.readBytes(); - filterCase_ = 4; - break; - } - case 42: - { - java.lang.String s = input.readStringRequireUtf8(); - filterCase_ = 5; - filter_ = s; - break; - } - case 50: - { - filter_ = input.readBytes(); - filterCase_ = 6; - break; - } - case 58: - { - com.google.bigtable.v2.ColumnRange.Builder subBuilder = null; - if (filterCase_ == 7) { - subBuilder = ((com.google.bigtable.v2.ColumnRange) filter_).toBuilder(); - } - filter_ = - input.readMessage(com.google.bigtable.v2.ColumnRange.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom((com.google.bigtable.v2.ColumnRange) filter_); - filter_ = subBuilder.buildPartial(); - } - filterCase_ = 7; - break; - } - case 66: - { - com.google.bigtable.v2.TimestampRange.Builder subBuilder = null; - if (filterCase_ == 8) { - subBuilder = ((com.google.bigtable.v2.TimestampRange) filter_).toBuilder(); - } - filter_ = - input.readMessage( - com.google.bigtable.v2.TimestampRange.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom((com.google.bigtable.v2.TimestampRange) filter_); - filter_ = subBuilder.buildPartial(); - } - filterCase_ = 8; - break; - } - case 74: - { - filter_ = input.readBytes(); - filterCase_ = 9; - break; - } - case 80: - { - filter_ = input.readInt32(); - filterCase_ = 10; - break; - } - case 88: - { - filter_ = input.readInt32(); - filterCase_ = 11; - break; - } - case 96: - { - filter_ = input.readInt32(); - filterCase_ = 12; - break; - } - case 104: - { - filter_ = input.readBool(); - filterCase_ = 13; - break; - } - case 113: - { - filter_ = input.readDouble(); - filterCase_ = 14; - break; - } - case 122: - { - com.google.bigtable.v2.ValueRange.Builder subBuilder = null; - if (filterCase_ == 15) { - subBuilder = ((com.google.bigtable.v2.ValueRange) filter_).toBuilder(); - } - filter_ = - input.readMessage(com.google.bigtable.v2.ValueRange.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom((com.google.bigtable.v2.ValueRange) filter_); - filter_ = subBuilder.buildPartial(); - } - filterCase_ = 15; - break; - } - case 128: - { - filter_ = input.readBool(); - filterCase_ = 16; - break; - } - case 136: - { - filter_ = input.readBool(); - filterCase_ = 17; - break; - } - case 144: - { - filter_ = input.readBool(); - filterCase_ = 18; - break; - } - case 154: - { - java.lang.String s = input.readStringRequireUtf8(); - filterCase_ = 19; - filter_ = s; - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.bigtable.v2.DataProto.internal_static_google_bigtable_v2_RowFilter_descriptor; } @@ -403,60 +190,6 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - private Chain( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - int mutable_bitField0_ = 0; - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - if (!((mutable_bitField0_ & 0x00000001) != 0)) { - filters_ = new java.util.ArrayList(); - mutable_bitField0_ |= 0x00000001; - } - filters_.add( - input.readMessage( - com.google.bigtable.v2.RowFilter.parser(), extensionRegistry)); - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); - } finally { - if (((mutable_bitField0_ & 0x00000001) != 0)) { - filters_ = java.util.Collections.unmodifiableList(filters_); - } - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.bigtable.v2.DataProto .internal_static_google_bigtable_v2_RowFilter_Chain_descriptor; @@ -568,7 +301,7 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io for (int i = 0; i < filters_.size(); i++) { output.writeMessage(1, filters_.get(i)); } - unknownFields.writeTo(output); + getUnknownFields().writeTo(output); } @java.lang.Override @@ -580,7 +313,7 @@ public int getSerializedSize() { for (int i = 0; i < filters_.size(); i++) { size += com.google.protobuf.CodedOutputStream.computeMessageSize(1, filters_.get(i)); } - size += unknownFields.getSerializedSize(); + size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @@ -596,7 +329,7 @@ public boolean equals(final java.lang.Object obj) { com.google.bigtable.v2.RowFilter.Chain other = (com.google.bigtable.v2.RowFilter.Chain) obj; if (!getFiltersList().equals(other.getFiltersList())) return false; - if (!unknownFields.equals(other.unknownFields)) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -611,7 +344,7 @@ public int hashCode() { hash = (37 * hash) + FILTERS_FIELD_NUMBER; hash = (53 * hash) + getFiltersList().hashCode(); } - hash = (29 * hash) + unknownFields.hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } @@ -742,19 +475,10 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { } // Construct using com.google.bigtable.v2.RowFilter.Chain.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } + private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) { - getFiltersFieldBuilder(); - } } @java.lang.Override @@ -762,10 +486,11 @@ public Builder clear() { super.clear(); if (filtersBuilder_ == null) { filters_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000001); } else { + filters_ = null; filtersBuilder_.clear(); } + bitField0_ = (bitField0_ & ~0x00000001); return this; } @@ -881,7 +606,7 @@ public Builder mergeFrom(com.google.bigtable.v2.RowFilter.Chain other) { } } } - this.mergeUnknownFields(other.unknownFields); + this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @@ -896,17 +621,44 @@ public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - com.google.bigtable.v2.RowFilter.Chain parsedMessage = null; + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + com.google.bigtable.v2.RowFilter m = + input.readMessage( + com.google.bigtable.v2.RowFilter.parser(), extensionRegistry); + if (filtersBuilder_ == null) { + ensureFiltersIsMutable(); + filters_.add(m); + } else { + filtersBuilder_.addMessage(m); + } + break; + } // case 10 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.bigtable.v2.RowFilter.Chain) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } + onChanged(); + } // finally return this; } @@ -1329,7 +1081,19 @@ public Chain parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new Chain(input, extensionRegistry); + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException() + .setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); } }; @@ -1549,60 +1313,6 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - private Interleave( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - int mutable_bitField0_ = 0; - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - if (!((mutable_bitField0_ & 0x00000001) != 0)) { - filters_ = new java.util.ArrayList(); - mutable_bitField0_ |= 0x00000001; - } - filters_.add( - input.readMessage( - com.google.bigtable.v2.RowFilter.parser(), extensionRegistry)); - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); - } finally { - if (((mutable_bitField0_ & 0x00000001) != 0)) { - filters_ = java.util.Collections.unmodifiableList(filters_); - } - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.bigtable.v2.DataProto .internal_static_google_bigtable_v2_RowFilter_Interleave_descriptor; @@ -1814,7 +1524,7 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io for (int i = 0; i < filters_.size(); i++) { output.writeMessage(1, filters_.get(i)); } - unknownFields.writeTo(output); + getUnknownFields().writeTo(output); } @java.lang.Override @@ -1826,7 +1536,7 @@ public int getSerializedSize() { for (int i = 0; i < filters_.size(); i++) { size += com.google.protobuf.CodedOutputStream.computeMessageSize(1, filters_.get(i)); } - size += unknownFields.getSerializedSize(); + size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @@ -1843,7 +1553,7 @@ public boolean equals(final java.lang.Object obj) { (com.google.bigtable.v2.RowFilter.Interleave) obj; if (!getFiltersList().equals(other.getFiltersList())) return false; - if (!unknownFields.equals(other.unknownFields)) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -1858,7 +1568,7 @@ public int hashCode() { hash = (37 * hash) + FILTERS_FIELD_NUMBER; hash = (53 * hash) + getFiltersList().hashCode(); } - hash = (29 * hash) + unknownFields.hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } @@ -1990,19 +1700,10 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { } // Construct using com.google.bigtable.v2.RowFilter.Interleave.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } + private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) { - getFiltersFieldBuilder(); - } } @java.lang.Override @@ -2010,10 +1711,11 @@ public Builder clear() { super.clear(); if (filtersBuilder_ == null) { filters_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000001); } else { + filters_ = null; filtersBuilder_.clear(); } + bitField0_ = (bitField0_ & ~0x00000001); return this; } @@ -2129,7 +1831,7 @@ public Builder mergeFrom(com.google.bigtable.v2.RowFilter.Interleave other) { } } } - this.mergeUnknownFields(other.unknownFields); + this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @@ -2144,17 +1846,44 @@ public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - com.google.bigtable.v2.RowFilter.Interleave parsedMessage = null; + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + com.google.bigtable.v2.RowFilter m = + input.readMessage( + com.google.bigtable.v2.RowFilter.parser(), extensionRegistry); + if (filtersBuilder_ == null) { + ensureFiltersIsMutable(); + filters_.add(m); + } else { + filtersBuilder_.addMessage(m); + } + break; + } // case 10 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.bigtable.v2.RowFilter.Interleave) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } + onChanged(); + } // finally return this; } @@ -2937,7 +2666,19 @@ public Interleave parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new Interleave(input, extensionRegistry); + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException() + .setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); } }; @@ -3115,90 +2856,6 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - private Condition( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - com.google.bigtable.v2.RowFilter.Builder subBuilder = null; - if (predicateFilter_ != null) { - subBuilder = predicateFilter_.toBuilder(); - } - predicateFilter_ = - input.readMessage(com.google.bigtable.v2.RowFilter.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(predicateFilter_); - predicateFilter_ = subBuilder.buildPartial(); - } - - break; - } - case 18: - { - com.google.bigtable.v2.RowFilter.Builder subBuilder = null; - if (trueFilter_ != null) { - subBuilder = trueFilter_.toBuilder(); - } - trueFilter_ = - input.readMessage(com.google.bigtable.v2.RowFilter.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(trueFilter_); - trueFilter_ = subBuilder.buildPartial(); - } - - break; - } - case 26: - { - com.google.bigtable.v2.RowFilter.Builder subBuilder = null; - if (falseFilter_ != null) { - subBuilder = falseFilter_.toBuilder(); - } - falseFilter_ = - input.readMessage(com.google.bigtable.v2.RowFilter.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(falseFilter_); - falseFilter_ = subBuilder.buildPartial(); - } - - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.bigtable.v2.DataProto .internal_static_google_bigtable_v2_RowFilter_Condition_descriptor; @@ -3393,7 +3050,7 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io if (falseFilter_ != null) { output.writeMessage(3, getFalseFilter()); } - unknownFields.writeTo(output); + getUnknownFields().writeTo(output); } @java.lang.Override @@ -3411,7 +3068,7 @@ public int getSerializedSize() { if (falseFilter_ != null) { size += com.google.protobuf.CodedOutputStream.computeMessageSize(3, getFalseFilter()); } - size += unknownFields.getSerializedSize(); + size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @@ -3439,7 +3096,7 @@ public boolean equals(final java.lang.Object obj) { if (hasFalseFilter()) { if (!getFalseFilter().equals(other.getFalseFilter())) return false; } - if (!unknownFields.equals(other.unknownFields)) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -3462,7 +3119,7 @@ public int hashCode() { hash = (37 * hash) + FALSE_FILTER_FIELD_NUMBER; hash = (53 * hash) + getFalseFilter().hashCode(); } - hash = (29 * hash) + unknownFields.hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } @@ -3598,17 +3255,10 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { } // Construct using com.google.bigtable.v2.RowFilter.Condition.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } + private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} } @java.lang.Override @@ -3734,7 +3384,7 @@ public Builder mergeFrom(com.google.bigtable.v2.RowFilter.Condition other) { if (other.hasFalseFilter()) { mergeFalseFilter(other.getFalseFilter()); } - this.mergeUnknownFields(other.unknownFields); + this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @@ -3749,17 +3399,50 @@ public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - com.google.bigtable.v2.RowFilter.Condition parsedMessage = null; + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + input.readMessage( + getPredicateFilterFieldBuilder().getBuilder(), extensionRegistry); + + break; + } // case 10 + case 18: + { + input.readMessage(getTrueFilterFieldBuilder().getBuilder(), extensionRegistry); + + break; + } // case 18 + case 26: + { + input.readMessage(getFalseFilterFieldBuilder().getBuilder(), extensionRegistry); + + break; + } // case 26 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.bigtable.v2.RowFilter.Condition) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } + onChanged(); + } // finally return this; } @@ -4387,7 +4070,19 @@ public Condition parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new Condition(input, extensionRegistry); + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException() + .setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); } }; @@ -5620,7 +5315,7 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io if (filterCase_ == 19) { com.google.protobuf.GeneratedMessageV3.writeString(output, 19, filter_); } - unknownFields.writeTo(output); + getUnknownFields().writeTo(output); } @java.lang.Override @@ -5720,7 +5415,7 @@ public int getSerializedSize() { if (filterCase_ == 19) { size += com.google.protobuf.GeneratedMessageV3.computeStringSize(19, filter_); } - size += unknownFields.getSerializedSize(); + size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @@ -5799,7 +5494,7 @@ public boolean equals(final java.lang.Object obj) { case 0: default: } - if (!unknownFields.equals(other.unknownFields)) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -5893,7 +5588,7 @@ public int hashCode() { case 0: default: } - hash = (29 * hash) + unknownFields.hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } @@ -6048,22 +5743,33 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { } // Construct using com.google.bigtable.v2.RowFilter.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } + private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} } @java.lang.Override public Builder clear() { super.clear(); + if (chainBuilder_ != null) { + chainBuilder_.clear(); + } + if (interleaveBuilder_ != null) { + interleaveBuilder_.clear(); + } + if (conditionBuilder_ != null) { + conditionBuilder_.clear(); + } + if (columnRangeFilterBuilder_ != null) { + columnRangeFilterBuilder_.clear(); + } + if (timestampRangeFilterBuilder_ != null) { + timestampRangeFilterBuilder_.clear(); + } + if (valueRangeFilterBuilder_ != null) { + valueRangeFilterBuilder_.clear(); + } filterCase_ = 0; filter_ = null; return this; @@ -6328,7 +6034,7 @@ public Builder mergeFrom(com.google.bigtable.v2.RowFilter other) { break; } } - this.mergeUnknownFields(other.unknownFields); + this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @@ -6343,17 +6049,150 @@ public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - com.google.bigtable.v2.RowFilter parsedMessage = null; + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + input.readMessage(getChainFieldBuilder().getBuilder(), extensionRegistry); + filterCase_ = 1; + break; + } // case 10 + case 18: + { + input.readMessage(getInterleaveFieldBuilder().getBuilder(), extensionRegistry); + filterCase_ = 2; + break; + } // case 18 + case 26: + { + input.readMessage(getConditionFieldBuilder().getBuilder(), extensionRegistry); + filterCase_ = 3; + break; + } // case 26 + case 34: + { + filter_ = input.readBytes(); + filterCase_ = 4; + break; + } // case 34 + case 42: + { + java.lang.String s = input.readStringRequireUtf8(); + filterCase_ = 5; + filter_ = s; + break; + } // case 42 + case 50: + { + filter_ = input.readBytes(); + filterCase_ = 6; + break; + } // case 50 + case 58: + { + input.readMessage( + getColumnRangeFilterFieldBuilder().getBuilder(), extensionRegistry); + filterCase_ = 7; + break; + } // case 58 + case 66: + { + input.readMessage( + getTimestampRangeFilterFieldBuilder().getBuilder(), extensionRegistry); + filterCase_ = 8; + break; + } // case 66 + case 74: + { + filter_ = input.readBytes(); + filterCase_ = 9; + break; + } // case 74 + case 80: + { + filter_ = input.readInt32(); + filterCase_ = 10; + break; + } // case 80 + case 88: + { + filter_ = input.readInt32(); + filterCase_ = 11; + break; + } // case 88 + case 96: + { + filter_ = input.readInt32(); + filterCase_ = 12; + break; + } // case 96 + case 104: + { + filter_ = input.readBool(); + filterCase_ = 13; + break; + } // case 104 + case 113: + { + filter_ = input.readDouble(); + filterCase_ = 14; + break; + } // case 113 + case 122: + { + input.readMessage( + getValueRangeFilterFieldBuilder().getBuilder(), extensionRegistry); + filterCase_ = 15; + break; + } // case 122 + case 128: + { + filter_ = input.readBool(); + filterCase_ = 16; + break; + } // case 128 + case 136: + { + filter_ = input.readBool(); + filterCase_ = 17; + break; + } // case 136 + case 144: + { + filter_ = input.readBool(); + filterCase_ = 18; + break; + } // case 144 + case 154: + { + java.lang.String s = input.readStringRequireUtf8(); + filterCase_ = 19; + filter_ = s; + break; + } // case 154 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.bigtable.v2.RowFilter) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } + onChanged(); + } // finally return this; } @@ -9128,7 +8967,18 @@ public RowFilter parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new RowFilter(input, extensionRegistry); + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); } }; diff --git a/proto-google-cloud-bigtable-v2/src/main/java/com/google/bigtable/v2/RowRange.java b/proto-google-cloud-bigtable-v2/src/main/java/com/google/bigtable/v2/RowRange.java index a297a4448f..a9cdcc73c4 100644 --- a/proto-google-cloud-bigtable-v2/src/main/java/com/google/bigtable/v2/RowRange.java +++ b/proto-google-cloud-bigtable-v2/src/main/java/com/google/bigtable/v2/RowRange.java @@ -50,69 +50,6 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - private RowRange( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - startKey_ = input.readBytes(); - startKeyCase_ = 1; - break; - } - case 18: - { - startKey_ = input.readBytes(); - startKeyCase_ = 2; - break; - } - case 26: - { - endKey_ = input.readBytes(); - endKeyCase_ = 3; - break; - } - case 34: - { - endKey_ = input.readBytes(); - endKeyCase_ = 4; - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.bigtable.v2.DataProto.internal_static_google_bigtable_v2_RowRange_descriptor; } @@ -386,7 +323,7 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io if (endKeyCase_ == 4) { output.writeBytes(4, (com.google.protobuf.ByteString) endKey_); } - unknownFields.writeTo(output); + getUnknownFields().writeTo(output); } @java.lang.Override @@ -415,7 +352,7 @@ public int getSerializedSize() { com.google.protobuf.CodedOutputStream.computeBytesSize( 4, (com.google.protobuf.ByteString) endKey_); } - size += unknownFields.getSerializedSize(); + size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @@ -452,7 +389,7 @@ public boolean equals(final java.lang.Object obj) { case 0: default: } - if (!unknownFields.equals(other.unknownFields)) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -487,7 +424,7 @@ public int hashCode() { case 0: default: } - hash = (29 * hash) + unknownFields.hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } @@ -614,17 +551,10 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { } // Construct using com.google.bigtable.v2.RowRange.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } + private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} } @java.lang.Override @@ -755,7 +685,7 @@ public Builder mergeFrom(com.google.bigtable.v2.RowRange other) { break; } } - this.mergeUnknownFields(other.unknownFields); + this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @@ -770,17 +700,55 @@ public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - com.google.bigtable.v2.RowRange parsedMessage = null; + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + startKey_ = input.readBytes(); + startKeyCase_ = 1; + break; + } // case 10 + case 18: + { + startKey_ = input.readBytes(); + startKeyCase_ = 2; + break; + } // case 18 + case 26: + { + endKey_ = input.readBytes(); + endKeyCase_ = 3; + break; + } // case 26 + case 34: + { + endKey_ = input.readBytes(); + endKeyCase_ = 4; + break; + } // case 34 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.bigtable.v2.RowRange) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } + onChanged(); + } // finally return this; } @@ -1132,7 +1100,18 @@ public RowRange parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new RowRange(input, extensionRegistry); + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); } }; diff --git a/proto-google-cloud-bigtable-v2/src/main/java/com/google/bigtable/v2/RowSet.java b/proto-google-cloud-bigtable-v2/src/main/java/com/google/bigtable/v2/RowSet.java index 1b67c0fe43..86d5b281a9 100644 --- a/proto-google-cloud-bigtable-v2/src/main/java/com/google/bigtable/v2/RowSet.java +++ b/proto-google-cloud-bigtable-v2/src/main/java/com/google/bigtable/v2/RowSet.java @@ -53,71 +53,6 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - private RowSet( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - int mutable_bitField0_ = 0; - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - if (!((mutable_bitField0_ & 0x00000001) != 0)) { - rowKeys_ = new java.util.ArrayList(); - mutable_bitField0_ |= 0x00000001; - } - rowKeys_.add(input.readBytes()); - break; - } - case 18: - { - if (!((mutable_bitField0_ & 0x00000002) != 0)) { - rowRanges_ = new java.util.ArrayList(); - mutable_bitField0_ |= 0x00000002; - } - rowRanges_.add( - input.readMessage(com.google.bigtable.v2.RowRange.parser(), extensionRegistry)); - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); - } finally { - if (((mutable_bitField0_ & 0x00000001) != 0)) { - rowKeys_ = java.util.Collections.unmodifiableList(rowKeys_); // C - } - if (((mutable_bitField0_ & 0x00000002) != 0)) { - rowRanges_ = java.util.Collections.unmodifiableList(rowRanges_); - } - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.bigtable.v2.DataProto.internal_static_google_bigtable_v2_RowSet_descriptor; } @@ -267,7 +202,7 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io for (int i = 0; i < rowRanges_.size(); i++) { output.writeMessage(2, rowRanges_.get(i)); } - unknownFields.writeTo(output); + getUnknownFields().writeTo(output); } @java.lang.Override @@ -287,7 +222,7 @@ public int getSerializedSize() { for (int i = 0; i < rowRanges_.size(); i++) { size += com.google.protobuf.CodedOutputStream.computeMessageSize(2, rowRanges_.get(i)); } - size += unknownFields.getSerializedSize(); + size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @@ -304,7 +239,7 @@ public boolean equals(final java.lang.Object obj) { if (!getRowKeysList().equals(other.getRowKeysList())) return false; if (!getRowRangesList().equals(other.getRowRangesList())) return false; - if (!unknownFields.equals(other.unknownFields)) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -323,7 +258,7 @@ public int hashCode() { hash = (37 * hash) + ROW_RANGES_FIELD_NUMBER; hash = (53 * hash) + getRowRangesList().hashCode(); } - hash = (29 * hash) + unknownFields.hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } @@ -449,19 +384,10 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { } // Construct using com.google.bigtable.v2.RowSet.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } + private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) { - getRowRangesFieldBuilder(); - } } @java.lang.Override @@ -471,10 +397,11 @@ public Builder clear() { bitField0_ = (bitField0_ & ~0x00000001); if (rowRangesBuilder_ == null) { rowRanges_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000002); } else { + rowRanges_ = null; rowRangesBuilder_.clear(); } + bitField0_ = (bitField0_ & ~0x00000002); return this; } @@ -601,7 +528,7 @@ public Builder mergeFrom(com.google.bigtable.v2.RowSet other) { } } } - this.mergeUnknownFields(other.unknownFields); + this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @@ -616,17 +543,50 @@ public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - com.google.bigtable.v2.RowSet parsedMessage = null; + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + com.google.protobuf.ByteString v = input.readBytes(); + ensureRowKeysIsMutable(); + rowKeys_.add(v); + break; + } // case 10 + case 18: + { + com.google.bigtable.v2.RowRange m = + input.readMessage(com.google.bigtable.v2.RowRange.parser(), extensionRegistry); + if (rowRangesBuilder_ == null) { + ensureRowRangesIsMutable(); + rowRanges_.add(m); + } else { + rowRangesBuilder_.addMessage(m); + } + break; + } // case 18 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.bigtable.v2.RowSet) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } + onChanged(); + } // finally return this; } @@ -1146,7 +1106,18 @@ public RowSet parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new RowSet(input, extensionRegistry); + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); } }; diff --git a/proto-google-cloud-bigtable-v2/src/main/java/com/google/bigtable/v2/SampleRowKeysRequest.java b/proto-google-cloud-bigtable-v2/src/main/java/com/google/bigtable/v2/SampleRowKeysRequest.java index 8405901e00..6bebd6765d 100644 --- a/proto-google-cloud-bigtable-v2/src/main/java/com/google/bigtable/v2/SampleRowKeysRequest.java +++ b/proto-google-cloud-bigtable-v2/src/main/java/com/google/bigtable/v2/SampleRowKeysRequest.java @@ -53,59 +53,6 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - private SampleRowKeysRequest( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - java.lang.String s = input.readStringRequireUtf8(); - - tableName_ = s; - break; - } - case 18: - { - java.lang.String s = input.readStringRequireUtf8(); - - appProfileId_ = s; - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.bigtable.v2.BigtableProto .internal_static_google_bigtable_v2_SampleRowKeysRequest_descriptor; @@ -249,7 +196,7 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(appProfileId_)) { com.google.protobuf.GeneratedMessageV3.writeString(output, 2, appProfileId_); } - unknownFields.writeTo(output); + getUnknownFields().writeTo(output); } @java.lang.Override @@ -264,7 +211,7 @@ public int getSerializedSize() { if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(appProfileId_)) { size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, appProfileId_); } - size += unknownFields.getSerializedSize(); + size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @@ -282,7 +229,7 @@ public boolean equals(final java.lang.Object obj) { if (!getTableName().equals(other.getTableName())) return false; if (!getAppProfileId().equals(other.getAppProfileId())) return false; - if (!unknownFields.equals(other.unknownFields)) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -297,7 +244,7 @@ public int hashCode() { hash = (53 * hash) + getTableName().hashCode(); hash = (37 * hash) + APP_PROFILE_ID_FIELD_NUMBER; hash = (53 * hash) + getAppProfileId().hashCode(); - hash = (29 * hash) + unknownFields.hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } @@ -426,17 +373,10 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { } // Construct using com.google.bigtable.v2.SampleRowKeysRequest.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } + private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} } @java.lang.Override @@ -532,7 +472,7 @@ public Builder mergeFrom(com.google.bigtable.v2.SampleRowKeysRequest other) { appProfileId_ = other.appProfileId_; onChanged(); } - this.mergeUnknownFields(other.unknownFields); + this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @@ -547,17 +487,43 @@ public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - com.google.bigtable.v2.SampleRowKeysRequest parsedMessage = null; + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + tableName_ = input.readStringRequireUtf8(); + + break; + } // case 10 + case 18: + { + appProfileId_ = input.readStringRequireUtf8(); + + break; + } // case 18 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.bigtable.v2.SampleRowKeysRequest) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } + onChanged(); + } // finally return this; } @@ -830,7 +796,18 @@ public SampleRowKeysRequest parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new SampleRowKeysRequest(input, extensionRegistry); + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); } }; diff --git a/proto-google-cloud-bigtable-v2/src/main/java/com/google/bigtable/v2/SampleRowKeysResponse.java b/proto-google-cloud-bigtable-v2/src/main/java/com/google/bigtable/v2/SampleRowKeysResponse.java index 36d74de3af..64730abc0c 100644 --- a/proto-google-cloud-bigtable-v2/src/main/java/com/google/bigtable/v2/SampleRowKeysResponse.java +++ b/proto-google-cloud-bigtable-v2/src/main/java/com/google/bigtable/v2/SampleRowKeysResponse.java @@ -52,55 +52,6 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - private SampleRowKeysResponse( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - rowKey_ = input.readBytes(); - break; - } - case 16: - { - offsetBytes_ = input.readInt64(); - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.bigtable.v2.BigtableProto .internal_static_google_bigtable_v2_SampleRowKeysResponse_descriptor; @@ -181,7 +132,7 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io if (offsetBytes_ != 0L) { output.writeInt64(2, offsetBytes_); } - unknownFields.writeTo(output); + getUnknownFields().writeTo(output); } @java.lang.Override @@ -196,7 +147,7 @@ public int getSerializedSize() { if (offsetBytes_ != 0L) { size += com.google.protobuf.CodedOutputStream.computeInt64Size(2, offsetBytes_); } - size += unknownFields.getSerializedSize(); + size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @@ -214,7 +165,7 @@ public boolean equals(final java.lang.Object obj) { if (!getRowKey().equals(other.getRowKey())) return false; if (getOffsetBytes() != other.getOffsetBytes()) return false; - if (!unknownFields.equals(other.unknownFields)) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -229,7 +180,7 @@ public int hashCode() { hash = (53 * hash) + getRowKey().hashCode(); hash = (37 * hash) + OFFSET_BYTES_FIELD_NUMBER; hash = (53 * hash) + com.google.protobuf.Internal.hashLong(getOffsetBytes()); - hash = (29 * hash) + unknownFields.hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } @@ -358,17 +309,10 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { } // Construct using com.google.bigtable.v2.SampleRowKeysResponse.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } + private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} } @java.lang.Override @@ -462,7 +406,7 @@ public Builder mergeFrom(com.google.bigtable.v2.SampleRowKeysResponse other) { if (other.getOffsetBytes() != 0L) { setOffsetBytes(other.getOffsetBytes()); } - this.mergeUnknownFields(other.unknownFields); + this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @@ -477,17 +421,43 @@ public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - com.google.bigtable.v2.SampleRowKeysResponse parsedMessage = null; + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + rowKey_ = input.readBytes(); + + break; + } // case 10 + case 16: + { + offsetBytes_ = input.readInt64(); + + break; + } // case 16 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.bigtable.v2.SampleRowKeysResponse) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } + onChanged(); + } // finally return this; } @@ -657,7 +627,18 @@ public SampleRowKeysResponse parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new SampleRowKeysResponse(input, extensionRegistry); + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); } }; diff --git a/proto-google-cloud-bigtable-v2/src/main/java/com/google/bigtable/v2/TimestampRange.java b/proto-google-cloud-bigtable-v2/src/main/java/com/google/bigtable/v2/TimestampRange.java index 996b2caa20..b570b88de0 100644 --- a/proto-google-cloud-bigtable-v2/src/main/java/com/google/bigtable/v2/TimestampRange.java +++ b/proto-google-cloud-bigtable-v2/src/main/java/com/google/bigtable/v2/TimestampRange.java @@ -50,55 +50,6 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - private TimestampRange( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 8: - { - startTimestampMicros_ = input.readInt64(); - break; - } - case 16: - { - endTimestampMicros_ = input.readInt64(); - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.bigtable.v2.DataProto .internal_static_google_bigtable_v2_TimestampRange_descriptor; @@ -170,7 +121,7 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io if (endTimestampMicros_ != 0L) { output.writeInt64(2, endTimestampMicros_); } - unknownFields.writeTo(output); + getUnknownFields().writeTo(output); } @java.lang.Override @@ -185,7 +136,7 @@ public int getSerializedSize() { if (endTimestampMicros_ != 0L) { size += com.google.protobuf.CodedOutputStream.computeInt64Size(2, endTimestampMicros_); } - size += unknownFields.getSerializedSize(); + size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @@ -202,7 +153,7 @@ public boolean equals(final java.lang.Object obj) { if (getStartTimestampMicros() != other.getStartTimestampMicros()) return false; if (getEndTimestampMicros() != other.getEndTimestampMicros()) return false; - if (!unknownFields.equals(other.unknownFields)) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -217,7 +168,7 @@ public int hashCode() { hash = (53 * hash) + com.google.protobuf.Internal.hashLong(getStartTimestampMicros()); hash = (37 * hash) + END_TIMESTAMP_MICROS_FIELD_NUMBER; hash = (53 * hash) + com.google.protobuf.Internal.hashLong(getEndTimestampMicros()); - hash = (29 * hash) + unknownFields.hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } @@ -345,17 +296,10 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { } // Construct using com.google.bigtable.v2.TimestampRange.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } + private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} } @java.lang.Override @@ -449,7 +393,7 @@ public Builder mergeFrom(com.google.bigtable.v2.TimestampRange other) { if (other.getEndTimestampMicros() != 0L) { setEndTimestampMicros(other.getEndTimestampMicros()); } - this.mergeUnknownFields(other.unknownFields); + this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @@ -464,17 +408,43 @@ public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - com.google.bigtable.v2.TimestampRange parsedMessage = null; + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 8: + { + startTimestampMicros_ = input.readInt64(); + + break; + } // case 8 + case 16: + { + endTimestampMicros_ = input.readInt64(); + + break; + } // case 16 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.bigtable.v2.TimestampRange) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } + onChanged(); + } // finally return this; } @@ -614,7 +584,18 @@ public TimestampRange parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new TimestampRange(input, extensionRegistry); + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); } }; diff --git a/proto-google-cloud-bigtable-v2/src/main/java/com/google/bigtable/v2/ValueRange.java b/proto-google-cloud-bigtable-v2/src/main/java/com/google/bigtable/v2/ValueRange.java index 1ae97c5675..b9ad1af05f 100644 --- a/proto-google-cloud-bigtable-v2/src/main/java/com/google/bigtable/v2/ValueRange.java +++ b/proto-google-cloud-bigtable-v2/src/main/java/com/google/bigtable/v2/ValueRange.java @@ -50,69 +50,6 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - private ValueRange( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - startValue_ = input.readBytes(); - startValueCase_ = 1; - break; - } - case 18: - { - startValue_ = input.readBytes(); - startValueCase_ = 2; - break; - } - case 26: - { - endValue_ = input.readBytes(); - endValueCase_ = 3; - break; - } - case 34: - { - endValue_ = input.readBytes(); - endValueCase_ = 4; - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.bigtable.v2.DataProto .internal_static_google_bigtable_v2_ValueRange_descriptor; @@ -388,7 +325,7 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io if (endValueCase_ == 4) { output.writeBytes(4, (com.google.protobuf.ByteString) endValue_); } - unknownFields.writeTo(output); + getUnknownFields().writeTo(output); } @java.lang.Override @@ -417,7 +354,7 @@ public int getSerializedSize() { com.google.protobuf.CodedOutputStream.computeBytesSize( 4, (com.google.protobuf.ByteString) endValue_); } - size += unknownFields.getSerializedSize(); + size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @@ -454,7 +391,7 @@ public boolean equals(final java.lang.Object obj) { case 0: default: } - if (!unknownFields.equals(other.unknownFields)) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -489,7 +426,7 @@ public int hashCode() { case 0: default: } - hash = (29 * hash) + unknownFields.hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } @@ -617,17 +554,10 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { } // Construct using com.google.bigtable.v2.ValueRange.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } + private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} } @java.lang.Override @@ -758,7 +688,7 @@ public Builder mergeFrom(com.google.bigtable.v2.ValueRange other) { break; } } - this.mergeUnknownFields(other.unknownFields); + this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @@ -773,17 +703,55 @@ public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - com.google.bigtable.v2.ValueRange parsedMessage = null; + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + startValue_ = input.readBytes(); + startValueCase_ = 1; + break; + } // case 10 + case 18: + { + startValue_ = input.readBytes(); + startValueCase_ = 2; + break; + } // case 18 + case 26: + { + endValue_ = input.readBytes(); + endValueCase_ = 3; + break; + } // case 26 + case 34: + { + endValue_ = input.readBytes(); + endValueCase_ = 4; + break; + } // case 34 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.bigtable.v2.ValueRange) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } + onChanged(); + } // finally return this; } @@ -1135,7 +1103,18 @@ public ValueRange parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new ValueRange(input, extensionRegistry); + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); } }; diff --git a/proto-google-cloud-bigtable-v2/src/main/proto/google/bigtable/v2/bigtable.proto b/proto-google-cloud-bigtable-v2/src/main/proto/google/bigtable/v2/bigtable.proto index 8452338077..ba2ce46796 100644 --- a/proto-google-cloud-bigtable-v2/src/main/proto/google/bigtable/v2/bigtable.proto +++ b/proto-google-cloud-bigtable-v2/src/main/proto/google/bigtable/v2/bigtable.proto @@ -22,6 +22,7 @@ import "google/api/field_behavior.proto"; import "google/api/resource.proto"; import "google/api/routing.proto"; import "google/bigtable/v2/data.proto"; +import "google/bigtable/v2/request_stats.proto"; import "google/protobuf/duration.proto"; import "google/protobuf/timestamp.proto"; import "google/protobuf/wrappers.proto"; @@ -34,14 +35,14 @@ option java_outer_classname = "BigtableProto"; option java_package = "com.google.bigtable.v2"; option php_namespace = "Google\\Cloud\\Bigtable\\V2"; option ruby_package = "Google::Cloud::Bigtable::V2"; -option (google.api.resource_definition) = { - type: "bigtableadmin.googleapis.com/Table" - pattern: "projects/{project}/instances/{instance}/tables/{table}" -}; option (google.api.resource_definition) = { type: "bigtableadmin.googleapis.com/Instance" pattern: "projects/{project}/instances/{instance}" }; +option (google.api.resource_definition) = { + type: "bigtableadmin.googleapis.com/Table" + pattern: "projects/{project}/instances/{instance}/tables/{table}" +}; // Service for reading from and writing to existing Bigtable tables. service Bigtable { @@ -230,6 +231,23 @@ service Bigtable { // Request message for Bigtable.ReadRows. message ReadRowsRequest { + // + // The desired view into RequestStats that should be returned in the response. + // + // See also: RequestStats message. + enum RequestStatsView { + // The default / unset value. The API will default to the NONE option below. + REQUEST_STATS_VIEW_UNSPECIFIED = 0; + + // Do not include any RequestStats in the response. This will leave the + // RequestStats embedded message unset in the response. + REQUEST_STATS_NONE = 1; + + // Include the full set of available RequestStats in the response, + // applicable to this read. + REQUEST_STATS_FULL = 2; + } + // Required. The unique name of the table from which to read. // Values are of the form // `projects//instances//tables/
`. @@ -240,8 +258,8 @@ message ReadRowsRequest { } ]; - // This value specifies routing for replication. If not specified, the - // "default" application profile will be used. + // This value specifies routing for replication. This API only accepts the + // empty value of app_profile_id. string app_profile_id = 5; // The row keys and/or ranges to read sequentially. If not specified, reads @@ -255,6 +273,9 @@ message ReadRowsRequest { // The read will stop after committing to N rows' worth of results. The // default (zero) is to return all results. int64 rows_limit = 4; + + // The view into RequestStats, as described above. + RequestStatsView request_stats_view = 6; } // Response message for Bigtable.ReadRows. @@ -334,6 +355,28 @@ message ReadRowsResponse { // lot of data that was filtered out since the last committed row // key, allowing the client to skip that work on a retry. bytes last_scanned_row_key = 2; + + // + // If requested, provide enhanced query performance statistics. The semantics + // dictate: + // * request_stats is empty on every (streamed) response, except + // * request_stats has non-empty information after all chunks have been + // streamed, where the ReadRowsResponse message only contains + // request_stats. + // * For example, if a read request would have returned an empty + // response instead a single ReadRowsResponse is streamed with empty + // chunks and request_stats filled. + // + // Visually, response messages will stream as follows: + // ... -> {chunks: [...]} -> {chunks: [], request_stats: {...}} + // \______________________/ \________________________________/ + // Primary response Trailer of RequestStats info + // + // Or if the read did not return any values: + // {chunks: [], request_stats: {...}} + // \________________________________/ + // Trailer of RequestStats info + RequestStats request_stats = 3; } // Request message for Bigtable.SampleRowKeys. diff --git a/proto-google-cloud-bigtable-v2/src/main/proto/google/bigtable/v2/request_stats.proto b/proto-google-cloud-bigtable-v2/src/main/proto/google/bigtable/v2/request_stats.proto new file mode 100644 index 0000000000..f650abe09c --- /dev/null +++ b/proto-google-cloud-bigtable-v2/src/main/proto/google/bigtable/v2/request_stats.proto @@ -0,0 +1,113 @@ +// Copyright 2022 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. + +syntax = "proto3"; + +package google.bigtable.v2; + +import "google/protobuf/duration.proto"; + +option csharp_namespace = "Google.Cloud.Bigtable.V2"; +option go_package = "google.golang.org/genproto/googleapis/bigtable/v2;bigtable"; +option java_multiple_files = true; +option java_outer_classname = "RequestStatsProto"; +option java_package = "com.google.bigtable.v2"; +option php_namespace = "Google\\Cloud\\Bigtable\\V2"; +option ruby_package = "Google::Cloud::Bigtable::V2"; + +// +// Messages related to RequestStats, part of the Query Stats feature, that can +// help understand the performance of requests. +// +// The layout of requests below is as follows: +// * RequestStats serves as the top-level container for statistics and +// measures related to Bigtable requests. This common object is returned as +// part of methods in the Data API. +// * RequestStats contains multiple *views* of related data, chosen by an +// option in the source Data API method. The view that is returned is +// designed to have all submessages (and their submessages, and so on) +// filled-in, to provide a comprehensive selection of statistics and +// measures related to the requested view. + +// ReadIterationStats captures information about the iteration of rows or cells +// over the course of a read, e.g. how many results were scanned in a read +// operation versus the results returned. +message ReadIterationStats { + // The rows seen (scanned) as part of the request. This includes the count of + // rows returned, as captured below. + int64 rows_seen_count = 1; + + // The rows returned as part of the request. + int64 rows_returned_count = 2; + + // The cells seen (scanned) as part of the request. This includes the count of + // cells returned, as captured below. + int64 cells_seen_count = 3; + + // The cells returned as part of the request. + int64 cells_returned_count = 4; +} + +// RequestLatencyStats provides a measurement of the latency of the request as +// it interacts with different systems over its lifetime, e.g. how long the +// request took to execute within a frontend server. +message RequestLatencyStats { + // The latency measured by the frontend server handling this request, from + // when the request was received, to when this value is sent back in the + // response. For more context on the component that is measuring this latency, + // see: https://cloud.google.com/bigtable/docs/overview + // + // Note: This value may be slightly shorter than the value reported into + // aggregate latency metrics in Monitoring for this request + // (https://cloud.google.com/bigtable/docs/monitoring-instance) as this value + // needs to be sent in the response before the latency measurement including + // that transmission is finalized. + // + // Note: This value includes the end-to-end latency of contacting nodes in + // the targeted cluster, e.g. measuring from when the first byte arrives at + // the frontend server, to when this value is sent back as the last value in + // the response, including any latency incurred by contacting nodes, waiting + // for results from nodes, and finally sending results from nodes back to the + // caller. + google.protobuf.Duration frontend_server_latency = 1; +} + +// FullReadStatsView captures all known information about a read. +message FullReadStatsView { + // Iteration stats describe how efficient the read is, e.g. comparing + // rows seen vs. rows returned or cells seen vs cells returned can provide an + // indication of read efficiency (the higher the ratio of seen to retuned the + // better). + ReadIterationStats read_iteration_stats = 1; + + // Request latency stats describe the time taken to complete a request, from + // the server side. + RequestLatencyStats request_latency_stats = 2; +} + +// RequestStats is the container for additional information pertaining to a +// single request, helpful for evaluating the performance of the sent request. +// Currently, there are the following supported methods: +// * google.bigtable.v2.ReadRows +message RequestStats { + // Information pertaining to each request type received. The type is chosen + // based on the requested view. + // + // See the messages above for additional context. + oneof stats_view { + // Available with the ReadRowsRequest.RequestStatsView.REQUEST_STATS_FULL + // view, see package google.bigtable.v2. + FullReadStatsView full_read_stats_view = 1; + } +} diff --git a/renovate.json b/renovate.json index c28944e2e2..2543edb1a8 100644 --- a/renovate.json +++ b/renovate.json @@ -10,6 +10,7 @@ ":maintainLockFilesDisabled", ":autodetectPinVersions" ], + "ignorePaths": [".kokoro/requirements.txt"], "packageRules": [ { "packagePatterns": [ diff --git a/samples/install-without-bom/pom.xml b/samples/install-without-bom/pom.xml index 0684cdc321..656b7cf8ed 100644 --- a/samples/install-without-bom/pom.xml +++ b/samples/install-without-bom/pom.xml @@ -29,7 +29,7 @@ com.google.cloud google-cloud-bigtable - 2.11.1 + 2.17.0 diff --git a/samples/native-image-sample/pom.xml b/samples/native-image-sample/pom.xml index 6fc55d073d..d0552e807d 100644 --- a/samples/native-image-sample/pom.xml +++ b/samples/native-image-sample/pom.xml @@ -29,7 +29,7 @@ com.google.cloud libraries-bom - 26.1.1 + 26.1.5 pom import @@ -83,13 +83,21 @@ org.junit.vintage junit-vintage-engine +<<<<<<< HEAD 5.9.0 +======= + 5.9.1 +>>>>>>> main test org.graalvm.buildtools junit-platform-native +<<<<<<< HEAD 0.9.13 +======= + 0.9.19 +>>>>>>> main test @@ -99,7 +107,11 @@ org.graalvm.buildtools native-maven-plugin +<<<<<<< HEAD 0.9.13 +======= + 0.9.19 +>>>>>>> main true com.example.bigtable.NativeImageBigtableSample diff --git a/samples/snapshot/pom.xml b/samples/snapshot/pom.xml index d5a74eb608..d57cced056 100644 --- a/samples/snapshot/pom.xml +++ b/samples/snapshot/pom.xml @@ -28,7 +28,7 @@ com.google.cloud google-cloud-bigtable - 2.11.2-SNAPSHOT + 2.17.1-SNAPSHOT diff --git a/samples/snippets/pom.xml b/samples/snippets/pom.xml index b75c4c14c8..7083717877 100644 --- a/samples/snippets/pom.xml +++ b/samples/snippets/pom.xml @@ -30,7 +30,7 @@ com.google.cloud libraries-bom - 26.1.1 + 26.1.5 pom import diff --git a/samples/snippets/src/main/java/com/example/bigtable/KeySalting.java b/samples/snippets/src/main/java/com/example/bigtable/KeySalting.java new file mode 100644 index 0000000000..da5e401347 --- /dev/null +++ b/samples/snippets/src/main/java/com/example/bigtable/KeySalting.java @@ -0,0 +1,95 @@ +/* + * Copyright 2022 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. + */ + +package com.example.bigtable; + +import com.google.api.core.ApiFuture; +import com.google.cloud.bigtable.data.v2.BigtableDataClient; +import com.google.cloud.bigtable.data.v2.models.Query; +import com.google.cloud.bigtable.data.v2.models.Row; +import com.google.cloud.bigtable.data.v2.models.RowMutation; +import java.io.IOException; +import java.util.ArrayList; +import java.util.List; +import java.util.concurrent.ExecutionException; + +public class KeySalting { + private static final String COLUMN_FAMILY_NAME = "stats_summary"; + public static final int SALT_RANGE = 4; + + public static void writeSaltedRow( + String projectId, String instanceId, String tableId, String rowKey) throws IOException { + BigtableDataClient dataClient = BigtableDataClient.create(projectId, instanceId); + String saltedRowKey = getSaltedRowKey(rowKey, SALT_RANGE); + RowMutation rowMutation = + RowMutation.create(tableId, saltedRowKey) + .setCell(COLUMN_FAMILY_NAME, "os_build", "PQ2A.190405.003"); + + dataClient.mutateRow(rowMutation); + System.out.printf("Successfully wrote row %s as %s\n", rowKey, saltedRowKey); + + dataClient.close(); + } + + public static void readSaltedRow( + String projectId, String instanceId, String tableId, String rowKey) throws IOException { + BigtableDataClient dataClient = BigtableDataClient.create(projectId, instanceId); + Row row = dataClient.readRow(tableId, getSaltedRowKey(rowKey, SALT_RANGE)); + System.out.printf("Successfully read row %s\n", row.getKey().toStringUtf8()); + } + + public static void scanSaltedRows( + String projectId, String instanceId, String tableId, String prefix) + throws IOException, ExecutionException, InterruptedException { + BigtableDataClient dataClient = BigtableDataClient.create(projectId, instanceId); + + List queries = new ArrayList<>(); + for (int i = 0; i < SALT_RANGE; i++) { + queries.add(Query.create(tableId).prefix(i + "-" + prefix)); + } + + List>> futures = new ArrayList<>(); + for (Query q : queries) { + futures.add(dataClient.readRowsCallable().all().futureCall(q)); + } + + List rows = new ArrayList<>(); + for (ApiFuture> future : futures) { + rows.addAll(future.get()); + } + + System.out.printf("Successfully fetched %s rows\n", rows.size()); + for (Row row : rows) { + System.out.printf("Successfully read row %s\n", row.getKey().toStringUtf8()); + } + } + + /** + * Generates a salted version of the row key. + * + *

Some Bigtable schema designs will always have hot spots, and a salted row key breaks up + * individual rows and groups of rows that are hot. Row keys are stored in sorted order, so + * prepending a numeric prefix allows those hot rows to be stored in different locations. + * + *

The salted row key is created by hashing the existing row key and taking a modulo of how + * large a prefix range you want to create; then prepending the existing row key with that result. + * This produces a deterministic output, so each row key will always produce the same salted key. + */ + public static String getSaltedRowKey(String rowKey, int saltRange) { + int prefix = rowKey.hashCode() % saltRange; + return prefix + "-" + rowKey; + } +} diff --git a/samples/snippets/src/test/java/com/example/bigtable/KeySaltingTest.java b/samples/snippets/src/test/java/com/example/bigtable/KeySaltingTest.java new file mode 100644 index 0000000000..085d992cea --- /dev/null +++ b/samples/snippets/src/test/java/com/example/bigtable/KeySaltingTest.java @@ -0,0 +1,92 @@ +/* + * Copyright 2022 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. + */ + +package com.example.bigtable; + +import static org.junit.Assert.assertEquals; + +import java.io.IOException; +import java.util.HashMap; +import java.util.Map; +import java.util.concurrent.ExecutionException; +import org.junit.AfterClass; +import org.junit.BeforeClass; +import org.junit.FixMethodOrder; +import org.junit.Test; +import org.junit.runners.MethodSorters; + +@FixMethodOrder(MethodSorters.NAME_ASCENDING) +public class KeySaltingTest extends MobileTimeSeriesBaseTest { + public static final String ROW_KEY = "phone#4c410523#20190501"; + + @BeforeClass + public static void beforeClass() throws IOException { + initializeVariables(); + createTable(); + } + + @AfterClass + public static void afterClass() throws IOException { + cleanupTable(); + } + + @Test + public void testWriteAndRead() throws IOException { + KeySalting.writeSaltedRow(projectId, instanceId, TABLE_ID, ROW_KEY); + KeySalting.readSaltedRow(projectId, instanceId, TABLE_ID, ROW_KEY); + + String output = bout.toString(); + assertEquals( + "Successfully wrote row phone#4c410523#20190501 as 0-phone#4c410523#20190501\n" + + "Successfully read row 0-phone#4c410523#20190501\n", + output); + } + + @Test + public void testScans() throws IOException, ExecutionException, InterruptedException { + String prefix = "abc-"; + for (int i = 0; i < 8; i++) { + KeySalting.writeSaltedRow(projectId, instanceId, TABLE_ID, prefix + i); + } + bout.reset(); + + KeySalting.scanSaltedRows(projectId, instanceId, TABLE_ID, prefix); + + String output = bout.toString(); + assertEquals( + "Successfully fetched 8 rows\n" + + "Successfully read row 0-abc-3\n" + + "Successfully read row 0-abc-7\n" + + "Successfully read row 1-abc-0\n" + + "Successfully read row 1-abc-4\n" + + "Successfully read row 2-abc-1\n" + + "Successfully read row 2-abc-5\n" + + "Successfully read row 3-abc-2\n" + + "Successfully read row 3-abc-6\n", + output); + } + + @Test + public void testKeySalting() { + Map exampleKeys = new HashMap(); + exampleKeys.put("abc-1", "2-abc-1"); + exampleKeys.put("abc-2", "3-abc-2"); + exampleKeys.put("abc-3", "0-abc-3"); + exampleKeys.put("abc-4", "1-abc-4"); + + exampleKeys.forEach((k, v) -> assertEquals(v, KeySalting.getSaltedRowKey(k, 4))); + } +} diff --git a/test-proxy/EnableAutoValue.txt b/test-proxy/EnableAutoValue.txt new file mode 100644 index 0000000000..e8237e1cbc --- /dev/null +++ b/test-proxy/EnableAutoValue.txt @@ -0,0 +1,2 @@ +This is a marker file to trigger auto-value injection into the annotation processor path +https://github.com/googleapis/java-shared-config/blob/51c9f68ff1736761b21c921f078ab2c8675ff268/pom.xml#L758 \ No newline at end of file diff --git a/test-proxy/README.md b/test-proxy/README.md new file mode 100644 index 0000000000..a97f40094e --- /dev/null +++ b/test-proxy/README.md @@ -0,0 +1,48 @@ +# CBT Java Test Proxy + +The CBT test proxy is intended for running confromance tests for Cloug Bigtable Java Client. + +## Set up + +If you have not already done so, [install golang](https://go.dev/doc/install), then clone the go test library: + +``` +git clone https://github.com/googleapis/cloud-bigtable-clients-test.git +``` + +## Start test proxy + +Build the proxy with the latest version of the client + +``` +cd java-bigtable +mvn clean install -DskipTests +cd test-proxy +mvn clean install +``` + +Start the proxy on default port 9999 + +``` +mvn exec:java -Dexec.mainClass=com.google.cloud.bigtable.testproxy.CbtTestProxyMain +``` + +Start the proxy on a different port + +``` +mvn exec:java -Dexec.mainClass=com.google.cloud.bigtable.testproxy.CbtTestProxyMain -Dport=1 +``` + +Build and start the proxy with an older version of the client + +``` +mvn clean install -Dbigtable.client.version= -Denforcer.skip +mvn exec:java -Dexec.mainClass=com.google.cloud.bigtable.testproxy.CbtTestProxyMain +``` + +## Run the test cases + +``` +cd cloud-bigtable-clients-test/tests +go test -v -proxy_addr=:9999 +``` diff --git a/test-proxy/pom.xml b/test-proxy/pom.xml new file mode 100644 index 0000000000..5792703442 --- /dev/null +++ b/test-proxy/pom.xml @@ -0,0 +1,140 @@ + + 4.0.0 + com.google.cloud + google-cloud-bigtable-test-proxy + 0.0.1-SNAPSHOT + jar + Google Cloud Bigtable Test Proxy + https://github.com/googleapis/java-bigtable + Cloud Bigtable Java Client test proxy for running conformance tests. + + + google-cloud-bigtable-parent + com.google.cloud + 2.17.1-SNAPSHOT + + + + 2.17.1-SNAPSHOT + + + + + + com.google.cloud + google-cloud-bigtable-bom + ${bigtable.client.version} + pom + import + + + com.google.cloud + google-cloud-bigtable-deps-bom + ${bigtable.client.version} + pom + import + + + + + + + com.google.cloud + google-cloud-bigtable + + + io.grpc + grpc-netty + + + io.grpc + grpc-stub + + + com.google.protobuf + protobuf-java + + + + + + + kr.motd.maven + os-maven-plugin + 1.7.1 + + + + + org.xolstice.maven.plugins + protobuf-maven-plugin + 0.6.1 + + com.google.protobuf:protoc:3.9.0:exe:${os.detected.classifier} + grpc-java + io.grpc:protoc-gen-grpc-java:1.24.0:exe:${os.detected.classifier} + + + + + compile + compile-custom + + + + + + + org.apache.maven.plugins + maven-deploy-plugin + + true + + + + org.sonatype.plugins + nexus-staging-maven-plugin + + true + + + + org.apache.maven.plugins + maven-site-plugin + + true + + + + org.apache.maven.plugins + maven-source-plugin + + true + + + + org.apache.maven.plugins + maven-javadoc-plugin + + true + + + + org.apache.maven.plugins + maven-gpg-plugin + + true + + + + org.codehaus.mojo + clirr-maven-plugin + + true + + + + + + diff --git a/test-proxy/src/main/java/com/google/cloud/bigtable/testproxy/CbtTestProxy.java b/test-proxy/src/main/java/com/google/cloud/bigtable/testproxy/CbtTestProxy.java new file mode 100644 index 0000000000..18e9be1e92 --- /dev/null +++ b/test-proxy/src/main/java/com/google/cloud/bigtable/testproxy/CbtTestProxy.java @@ -0,0 +1,758 @@ +/* + * Copyright 2022 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. + */ +package com.google.cloud.bigtable.testproxy; + +import static com.google.cloud.bigtable.data.v2.models.Filters.FILTERS; +import static java.nio.charset.StandardCharsets.UTF_8; + +import com.google.api.core.ApiFunction; +import com.google.api.gax.core.CredentialsProvider; +import com.google.api.gax.core.FixedCredentialsProvider; +import com.google.api.gax.core.NoCredentialsProvider; +import com.google.api.gax.grpc.InstantiatingGrpcChannelProvider; +import com.google.api.gax.rpc.ApiException; +import com.google.api.gax.rpc.ServerStream; +import com.google.auth.oauth2.GoogleCredentials; +import com.google.auto.value.AutoValue; +import com.google.bigtable.v2.Column; +import com.google.bigtable.v2.Family; +import com.google.bigtable.v2.Row; +import com.google.cloud.bigtable.data.v2.BigtableDataClient; +import com.google.cloud.bigtable.data.v2.BigtableDataSettings; +import com.google.cloud.bigtable.data.v2.models.BulkMutation; +import com.google.cloud.bigtable.data.v2.models.ConditionalRowMutation; +import com.google.cloud.bigtable.data.v2.models.KeyOffset; +import com.google.cloud.bigtable.data.v2.models.MutateRowsException; +import com.google.cloud.bigtable.data.v2.models.Query; +import com.google.cloud.bigtable.data.v2.models.ReadModifyWriteRow; +import com.google.cloud.bigtable.data.v2.models.RowCell; +import com.google.cloud.bigtable.data.v2.models.RowMutation; +import com.google.cloud.bigtable.data.v2.stub.EnhancedBigtableStubSettings; +import com.google.cloud.bigtable.testproxy.CloudBigtableV2TestProxyGrpc.CloudBigtableV2TestProxyImplBase; +import com.google.common.base.Preconditions; +import com.google.protobuf.ByteString; +import com.google.protobuf.util.Durations; +import com.google.rpc.Code; +import io.grpc.ManagedChannelBuilder; +import io.grpc.Status; +import io.grpc.StatusException; +import io.grpc.netty.GrpcSslContexts; +import io.grpc.netty.NettyChannelBuilder; +import io.grpc.stub.StreamObserver; +import io.netty.handler.ssl.SslContext; +import java.io.ByteArrayInputStream; +import java.io.Closeable; +import java.io.IOException; +import java.nio.file.Files; +import java.nio.file.Path; +import java.nio.file.Paths; +import java.util.Iterator; +import java.util.List; +import java.util.Map; +import java.util.concurrent.ConcurrentHashMap; +import java.util.logging.Logger; +import java.util.regex.Matcher; +import java.util.regex.Pattern; +import java.util.stream.Collectors; +import javax.annotation.Nullable; +import org.threeten.bp.Duration; + +/** Java implementation of the CBT test proxy. Used to test the Java CBT client. */ +public class CbtTestProxy extends CloudBigtableV2TestProxyImplBase implements Closeable { + + /** + * Class that holds BigtableDataSettings and a BigtableDataClient created with those settings. + * Used so users can retrieve settings for a particular client. + */ + @AutoValue + abstract static class CbtClient { + static CbtClient create(BigtableDataSettings settings, BigtableDataClient dataClient) { + return new AutoValue_CbtTestProxy_CbtClient(settings, dataClient); + } + + abstract BigtableDataSettings settings(); + + abstract BigtableDataClient dataClient(); + } + + private static final Logger logger = Logger.getLogger(CbtTestProxy.class.getName()); + + private CbtTestProxy( + boolean encrypted, + @Nullable String rootCerts, + @Nullable String sslTarget, + @Nullable String credential) { + this.encrypted = encrypted; + this.rootCerts = rootCerts; + this.sslTarget = sslTarget; + this.credential = credential; + this.idClientMap = new ConcurrentHashMap<>(); + } + + /** + * Factory method to return a proxy instance that interacts with server unencrypted and + * unauthenticated. + */ + public static CbtTestProxy createUnencrypted() { + return new CbtTestProxy(false, null, null, null); + } + + /** + * Factory method to return a proxy instance that interacts with server encrypted. Default + * authority and public certificates are used if null values are passed in. + * + * @param rootCertsPemPath The path to a root certificate PEM file + * @param sslTarget The override of SSL target name + * @param credentialJsonPath The path to a credential JSON file + */ + public static CbtTestProxy createEncrypted( + @Nullable String rootCertsPemPath, + @Nullable String sslTarget, + @Nullable String credentialJsonPath) + throws IOException { + String tmpRootCerts = null, tmpCredential = null; + if (rootCertsPemPath != null) { + Path file = Paths.get(rootCertsPemPath); + tmpRootCerts = new String(Files.readAllBytes(file), UTF_8); + } + if (credentialJsonPath != null) { + Path file = Paths.get(credentialJsonPath); + tmpCredential = new String(Files.readAllBytes(file), UTF_8); + } + + return new CbtTestProxy(true, tmpRootCerts, sslTarget, tmpCredential); + } + + /** + * Helper method to override the timeout settings of data APIs. TODO(developer): per-attempt + * timeout may also be overridden, which will involve test harness update. + * + * @param settingsBuilder The Builder object of BigtableDataSettings. + * @param newTimeout The value that is used to set the timeout. + */ + private static BigtableDataSettings.Builder overrideTimeoutSetting( + Duration newTimeout, BigtableDataSettings.Builder settingsBuilder) { + // TODO(developer): remove the initialRpcTimeout update below by updating the client library. + Duration initialRpcTimeout = + settingsBuilder + .stubSettings() + .bulkMutateRowsSettings() + .getRetrySettings() + .getInitialRpcTimeout(); + if (initialRpcTimeout.compareTo(newTimeout) > 0) { + // Total timeout is smaller than initialRpcTimeout, which will cause deadline-related problem. + initialRpcTimeout = newTimeout; + } + settingsBuilder + .stubSettings() + .bulkMutateRowsSettings() + .retrySettings() + .setTotalTimeout(newTimeout) + .setInitialRpcTimeout(initialRpcTimeout); + + settingsBuilder.stubSettings().mutateRowSettings().retrySettings().setTotalTimeout(newTimeout); + + settingsBuilder.stubSettings().readRowSettings().retrySettings().setTotalTimeout(newTimeout); + + settingsBuilder.stubSettings().readRowsSettings().retrySettings().setTotalTimeout(newTimeout); + + settingsBuilder + .stubSettings() + .sampleRowKeysSettings() + .retrySettings() + .setTotalTimeout(newTimeout); + + settingsBuilder + .stubSettings() + .checkAndMutateRowSettings() + .retrySettings() + .setTotalTimeout(newTimeout); + + settingsBuilder + .stubSettings() + .readModifyWriteRowSettings() + .retrySettings() + .setTotalTimeout(newTimeout); + + return settingsBuilder; + } + + /** Helper method to get a client object by its id. */ + private CbtClient getClient(String id) throws StatusException { + CbtClient client = idClientMap.get(id); + if (client == null) { + throw Status.NOT_FOUND.withDescription("Client " + id + " not found.").asException(); + } + return client; + } + + @Override + public synchronized void createClient( + CreateClientRequest request, StreamObserver responseObserver) { + Preconditions.checkArgument(!request.getClientId().isEmpty(), "client id must be provided"); + Preconditions.checkArgument(!request.getProjectId().isEmpty(), "project id must be provided"); + Preconditions.checkArgument(!request.getInstanceId().isEmpty(), "instance id must be provided"); + Preconditions.checkArgument(!request.getDataTarget().isEmpty(), "data target must be provided"); + + if (idClientMap.contains(request.getClientId())) { + responseObserver.onError( + Status.ALREADY_EXISTS + .withDescription("Client " + request.getClientId() + " already exists.") + .asException()); + return; + } + + BigtableDataSettings.Builder settingsBuilder = + BigtableDataSettings.newBuilder() + .setProjectId(request.getProjectId()) + .setInstanceId(request.getInstanceId()) + .setAppProfileId(request.getAppProfileId()); + + if (request.hasPerOperationTimeout()) { + Duration newTimeout = Duration.ofMillis(Durations.toMillis(request.getPerOperationTimeout())); + settingsBuilder = overrideTimeoutSetting(newTimeout, settingsBuilder); + logger.info( + String.format( + "Total timeout is set to %s for all the methods", + Durations.toString(request.getPerOperationTimeout()))); + } + + // Create and store CbtClient for later use + try { + if (!request.getDataTarget().equals("emulator")) { + settingsBuilder + .stubSettings() + .setEndpoint(request.getDataTarget()) + .setTransportChannelProvider(getTransportChannel()) + .setCredentialsProvider(getCredentialsProvider()); + } + BigtableDataSettings settings = settingsBuilder.build(); + BigtableDataClient client = BigtableDataClient.create(settings); + CbtClient cbtClient = CbtClient.create(settings, client); + idClientMap.put(request.getClientId(), cbtClient); + } catch (IOException e) { + responseObserver.onError(Status.INTERNAL.withDescription(e.getMessage()).asException()); + return; + } + + responseObserver.onNext(CreateClientResponse.getDefaultInstance()); + responseObserver.onCompleted(); + } + + @Override + public void closeClient( + CloseClientRequest request, StreamObserver responseObserver) { + CbtClient client; + try { + client = getClient(request.getClientId()); + } catch (StatusException e) { + responseObserver.onError(e); + return; + } + + client.dataClient().close(); + + responseObserver.onNext(CloseClientResponse.getDefaultInstance()); + responseObserver.onCompleted(); + } + + @Override + public void removeClient( + RemoveClientRequest request, StreamObserver responseObserver) { + CbtClient client = idClientMap.remove(request.getClientId()); + if (client == null) { + responseObserver.onError( + Status.NOT_FOUND + .withDescription("Client " + request.getClientId() + " not found.") + .asException()); + return; + } + + responseObserver.onNext(RemoveClientResponse.getDefaultInstance()); + responseObserver.onCompleted(); + } + + @Override + public void mutateRow( + MutateRowRequest request, StreamObserver responseObserver) { + CbtClient client; + try { + client = getClient(request.getClientId()); + } catch (StatusException e) { + responseObserver.onError(e); + return; + } + + // TODO(developer): evaluate if we want to manually unpack the proto into a model, instead of + // using fromProto. Same for the other methods. + RowMutation mutation = RowMutation.fromProto(request.getRequest()); + try { + // This response is empty. + client.dataClient().mutateRow(mutation); + } catch (ApiException e) { + responseObserver.onNext( + MutateRowResult.newBuilder() + .setStatus( + com.google.rpc.Status.newBuilder() + .setCode(e.getStatusCode().getCode().ordinal()) + .setMessage(e.getMessage()) + .build()) + .build()); + responseObserver.onCompleted(); + return; + } + + responseObserver.onNext( + MutateRowResult.newBuilder().setStatus(com.google.rpc.Status.getDefaultInstance()).build()); + responseObserver.onCompleted(); + } + + @Override + public void bulkMutateRows( + MutateRowsRequest request, StreamObserver responseObserver) { + CbtClient client; + try { + client = getClient(request.getClientId()); + } catch (StatusException e) { + responseObserver.onError(e); + return; + } + + BulkMutation batch = BulkMutation.fromProto(request.getRequest()); + try { + client.dataClient().bulkMutateRows(batch); + } catch (MutateRowsException e) { + MutateRowsResult.Builder resultBuilder = MutateRowsResult.newBuilder(); + for (MutateRowsException.FailedMutation failed : e.getFailedMutations()) { + resultBuilder + .addEntryBuilder() + .setIndex(failed.getIndex()) + .setStatus( + com.google.rpc.Status.newBuilder() + .setCode(failed.getError().getStatusCode().getCode().ordinal()) + .setMessage(failed.getError().getMessage()) + .build()); + } + responseObserver.onNext( + resultBuilder.setStatus(com.google.rpc.Status.getDefaultInstance()).build()); + responseObserver.onCompleted(); + return; + } catch (ApiException e) { + responseObserver.onNext( + MutateRowsResult.newBuilder() + .setStatus( + com.google.rpc.Status.newBuilder() + .setCode(e.getStatusCode().getCode().ordinal()) + .setMessage(e.getMessage()) + .build()) + .build()); + responseObserver.onCompleted(); + return; + } + + responseObserver.onNext( + MutateRowsResult.newBuilder() + .setStatus(com.google.rpc.Status.getDefaultInstance()) + .build()); + responseObserver.onCompleted(); + } + + @Override + public void readRow(ReadRowRequest request, StreamObserver responseObserver) { + CbtClient client; + try { + client = getClient(request.getClientId()); + } catch (StatusException e) { + responseObserver.onError(e); + return; + } + + String tableId; + try { + tableId = extractTableIdFromTableName(request.getTableName()); + } catch (IllegalArgumentException e) { + responseObserver.onError( + Status.INVALID_ARGUMENT.withDescription(e.getMessage()).asException()); + return; + } + + com.google.cloud.bigtable.data.v2.models.Row row; + try { + row = + client + .dataClient() + .readRow(tableId, request.getRowKey(), FILTERS.fromProto(request.getFilter())); + } catch (ApiException e) { + responseObserver.onNext( + RowResult.newBuilder() + .setStatus( + com.google.rpc.Status.newBuilder() + .setCode(e.getStatusCode().getCode().ordinal()) + .setMessage(e.getMessage()) + .build()) + .build()); + responseObserver.onCompleted(); + return; + } + + if (row != null) { + try { + RowResult.Builder resultBuilder = convertRowResult(row); + responseObserver.onNext( + resultBuilder.setStatus(com.google.rpc.Status.getDefaultInstance()).build()); + } catch (RuntimeException e) { + // If client encounters problem, don't return any row result. + responseObserver.onNext( + RowResult.newBuilder() + .setStatus( + com.google.rpc.Status.newBuilder() + .setCode(Code.INTERNAL.getNumber()) + .setMessage(e.getMessage()) + .build()) + .build()); + responseObserver.onCompleted(); + return; + } + } else { + logger.info(String.format("readRow() did not find row: %s", request.getRowKey())); + responseObserver.onNext( + RowResult.newBuilder().setStatus(com.google.rpc.Status.getDefaultInstance()).build()); + } + responseObserver.onCompleted(); + } + + @Override + public void readRows(ReadRowsRequest request, StreamObserver responseObserver) { + CbtClient client; + try { + client = getClient(request.getClientId()); + } catch (StatusException e) { + responseObserver.onError(e); + return; + } + + ServerStream rows; + Query query = Query.fromProto(request.getRequest()); + try { + rows = client.dataClient().readRows(query); + } catch (ApiException e) { + responseObserver.onNext( + RowsResult.newBuilder() + .setStatus( + com.google.rpc.Status.newBuilder() + .setCode(e.getStatusCode().getCode().ordinal()) + .setMessage(e.getMessage()) + .build()) + .build()); + responseObserver.onCompleted(); + return; + } + + int cancelAfterRows = request.getCancelAfterRows(); + try { + RowsResult.Builder resultBuilder = convertRowsResult(rows, cancelAfterRows); + responseObserver.onNext( + resultBuilder.setStatus(com.google.rpc.Status.getDefaultInstance()).build()); + } catch (RuntimeException e) { + // If client encounters problem, don't return any row result. + responseObserver.onNext( + RowsResult.newBuilder() + .setStatus( + com.google.rpc.Status.newBuilder() + .setCode(Code.INTERNAL.getNumber()) + .setMessage(e.getMessage()) + .build()) + .build()); + responseObserver.onCompleted(); + return; + } + + responseObserver.onCompleted(); + } + + /** + * Helper method to convert row from type com.google.cloud.bigtable.data.v2.models.Row to type + * com.google.bigtable.v2.Row. After conversion, row cells within the same column and family are + * grouped and ordered; but the ordering of family and qualifier is not preserved. + * + * @param row Logical row of type com.google.cloud.bigtable.data.v2.models.Row + * @return the converted row in RowResult Builder + */ + private static RowResult.Builder convertRowResult( + com.google.cloud.bigtable.data.v2.models.Row row) { + Row.Builder rowBuilder = Row.newBuilder(); + rowBuilder.setKey(row.getKey()); + + Map>> grouped = + row.getCells().stream() + .collect( + Collectors.groupingBy( + RowCell::getFamily, Collectors.groupingBy(RowCell::getQualifier))); + for (Map.Entry>> e : grouped.entrySet()) { + Family.Builder family = rowBuilder.addFamiliesBuilder().setName(e.getKey()); + + for (Map.Entry> e2 : e.getValue().entrySet()) { + Column.Builder column = family.addColumnsBuilder().setQualifier(e2.getKey()); + + for (RowCell rowCell : e2.getValue()) { + column + .addCellsBuilder() + .setTimestampMicros(rowCell.getTimestamp()) + .setValue(rowCell.getValue()) + .addAllLabels(rowCell.getLabels()); + } + } + } + + RowResult.Builder resultBuilder = RowResult.newBuilder(); + resultBuilder.setRow(rowBuilder.build()); + return resultBuilder; + } + + /** + * Helper method to convert rows from type com.google.cloud.bigtable.data.v2.models.Row to type + * com.google.bigtable.v2.Row. Row order is preserved. + * + * @param rows Logical rows in ServerStream + * @param cancelAfterRows Ignore the results after this row if set positive + * @return the converted rows in RowsResult Builder + */ + private static RowsResult.Builder convertRowsResult( + ServerStream rows, int cancelAfterRows) { + RowsResult.Builder resultBuilder = RowsResult.newBuilder(); + int rowCounter = 0; + for (com.google.cloud.bigtable.data.v2.models.Row row : rows) { + rowCounter++; + RowResult.Builder rowResultBuilder = convertRowResult(row); + resultBuilder.addRow(rowResultBuilder.getRow()); + + if (cancelAfterRows > 0 && rowCounter >= cancelAfterRows) { + logger.info( + String.format("Canceling ReadRows() to respect cancel_after_rows=%d", cancelAfterRows)); + break; + } + } + return resultBuilder; + } + + @Override + public void sampleRowKeys( + SampleRowKeysRequest request, StreamObserver responseObserver) { + CbtClient client; + try { + client = getClient(request.getClientId()); + } catch (StatusException e) { + responseObserver.onError(e); + return; + } + + String tableId; + try { + tableId = extractTableIdFromTableName(request.getRequest().getTableName()); + } catch (IllegalArgumentException e) { + responseObserver.onError( + Status.INVALID_ARGUMENT.withDescription(e.getMessage()).asException()); + return; + } + + List keyOffsets; + try { + keyOffsets = client.dataClient().sampleRowKeys(tableId); + } catch (ApiException e) { + responseObserver.onNext( + SampleRowKeysResult.newBuilder() + .setStatus( + com.google.rpc.Status.newBuilder() + .setCode(e.getStatusCode().getCode().ordinal()) + .setMessage(e.getMessage()) + .build()) + .build()); + responseObserver.onCompleted(); + return; + } + + SampleRowKeysResult.Builder resultBuilder = SampleRowKeysResult.newBuilder(); + for (KeyOffset keyOffset : keyOffsets) { + resultBuilder + .addSampleBuilder() + .setRowKey(keyOffset.getKey()) + .setOffsetBytes(keyOffset.getOffsetBytes()); + } + responseObserver.onNext( + resultBuilder.setStatus(com.google.rpc.Status.getDefaultInstance()).build()); + responseObserver.onCompleted(); + } + + @Override + public void checkAndMutateRow( + CheckAndMutateRowRequest request, StreamObserver responseObserver) { + CbtClient client; + try { + client = getClient(request.getClientId()); + } catch (StatusException e) { + responseObserver.onError(e); + return; + } + + ConditionalRowMutation mutation = ConditionalRowMutation.fromProto(request.getRequest()); + Boolean matched; + try { + matched = client.dataClient().checkAndMutateRow(mutation); + } catch (ApiException e) { + responseObserver.onNext( + CheckAndMutateRowResult.newBuilder() + .setStatus( + com.google.rpc.Status.newBuilder() + .setCode(e.getStatusCode().getCode().ordinal()) + .setMessage(e.getMessage()) + .build()) + .build()); + responseObserver.onCompleted(); + return; + } + + CheckAndMutateRowResult.Builder resultBuilder = CheckAndMutateRowResult.newBuilder(); + resultBuilder.getResultBuilder().setPredicateMatched(matched); + responseObserver.onNext( + resultBuilder.setStatus(com.google.rpc.Status.getDefaultInstance()).build()); + responseObserver.onCompleted(); + } + + @Override + public void readModifyWriteRow( + ReadModifyWriteRowRequest request, StreamObserver responseObserver) { + CbtClient client; + try { + client = getClient(request.getClientId()); + } catch (StatusException e) { + responseObserver.onError(e); + return; + } + + com.google.cloud.bigtable.data.v2.models.Row row; + ReadModifyWriteRow mutation = ReadModifyWriteRow.fromProto(request.getRequest()); + try { + row = client.dataClient().readModifyWriteRow(mutation); + } catch (ApiException e) { + responseObserver.onNext( + RowResult.newBuilder() + .setStatus( + com.google.rpc.Status.newBuilder() + .setCode(e.getStatusCode().getCode().ordinal()) + .setMessage(e.getMessage()) + .build()) + .build()); + responseObserver.onCompleted(); + return; + } + + if (row != null) { + try { + RowResult.Builder resultBuilder = convertRowResult(row); + responseObserver.onNext( + resultBuilder.setStatus(com.google.rpc.Status.getDefaultInstance()).build()); + } catch (RuntimeException e) { + // If client encounters problem, fail the whole operation. + responseObserver.onNext( + RowResult.newBuilder() + .setStatus( + com.google.rpc.Status.newBuilder() + .setCode(Code.INTERNAL.getNumber()) + .setMessage(e.getMessage()) + .build()) + .build()); + responseObserver.onCompleted(); + return; + } + } else { + logger.info( + String.format( + "readModifyWriteRow() did not find row: %s", request.getRequest().getRowKey())); + responseObserver.onNext( + RowResult.newBuilder().setStatus(com.google.rpc.Status.getDefaultInstance()).build()); + } + responseObserver.onCompleted(); + } + + @Override + public synchronized void close() { + Iterator> it = idClientMap.entrySet().iterator(); + while (it.hasNext()) { + Map.Entry entry = it.next(); + entry.getValue().dataClient().close(); + it.remove(); + } + } + + private static String extractTableIdFromTableName(String fullTableName) + throws IllegalArgumentException { + Matcher matcher = tablePattern.matcher(fullTableName); + if (!matcher.matches()) { + throw new IllegalArgumentException("Invalid table name: " + fullTableName); + } + return matcher.group(3); + } + + private InstantiatingGrpcChannelProvider getTransportChannel() throws IOException { + if (!encrypted) { + return EnhancedBigtableStubSettings.defaultGrpcTransportProviderBuilder() + .setChannelConfigurator(ManagedChannelBuilder::usePlaintext) + .build(); + } + + if (rootCerts == null) { + return EnhancedBigtableStubSettings.defaultGrpcTransportProviderBuilder().build(); + } + + final SslContext secureContext = + GrpcSslContexts.forClient() + .trustManager(new ByteArrayInputStream(rootCerts.getBytes(UTF_8))) + .build(); + return EnhancedBigtableStubSettings.defaultGrpcTransportProviderBuilder() + .setChannelConfigurator( + new ApiFunction() { + @Override + public ManagedChannelBuilder apply(ManagedChannelBuilder input) { + NettyChannelBuilder channelBuilder = (NettyChannelBuilder) input; + channelBuilder.sslContext(secureContext).overrideAuthority(sslTarget); + return channelBuilder; + } + }) + .build(); + } + + private CredentialsProvider getCredentialsProvider() throws IOException { + if (credential == null) { + return NoCredentialsProvider.create(); + } + + final GoogleCredentials creds = + GoogleCredentials.fromStream(new ByteArrayInputStream(credential.getBytes(UTF_8))); + + return FixedCredentialsProvider.create(creds); + } + + private final ConcurrentHashMap idClientMap; + private final boolean encrypted; + + // Parameters that may be needed when "encrypted" is true. + private final String rootCerts; + private final String sslTarget; + private final String credential; + + private static final Pattern tablePattern = + Pattern.compile("projects/([^/]+)/instances/([^/]+)/tables/([^/]+)"); +} diff --git a/test-proxy/src/main/java/com/google/cloud/bigtable/testproxy/CbtTestProxyMain.java b/test-proxy/src/main/java/com/google/cloud/bigtable/testproxy/CbtTestProxyMain.java new file mode 100644 index 0000000000..8750909f1a --- /dev/null +++ b/test-proxy/src/main/java/com/google/cloud/bigtable/testproxy/CbtTestProxyMain.java @@ -0,0 +1,51 @@ +/* + * Copyright 2022 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. + */ +package com.google.cloud.bigtable.testproxy; + +import io.grpc.ServerBuilder; +import java.io.IOException; +import java.util.logging.Logger; + +/** Starts a CbtTestProxy server. */ +public final class CbtTestProxyMain { + + private CbtTestProxyMain() {} + + private static final Logger logger = Logger.getLogger(CbtTestProxyMain.class.getName()); + + public static void main(String[] args) throws InterruptedException, IOException { + int port = Integer.getInteger("port", 9999); + if (port <= 0) { + throw new IllegalArgumentException(String.format("Port %d is not > 0.", port)); + } + + CbtTestProxy cbtTestProxy; + + // If encryption is specified + boolean encrypted = Boolean.getBoolean("encrypted"); + if (encrypted) { + String rootCertsPemPath = System.getProperty("root.certs.pem.path"); + String sslTarget = System.getProperty("ssl.target"); + String credentialJsonPath = System.getProperty("credential.json.path"); + cbtTestProxy = CbtTestProxy.createEncrypted(rootCertsPemPath, sslTarget, credentialJsonPath); + } else { + cbtTestProxy = CbtTestProxy.createUnencrypted(); + } + + logger.info(String.format("Test proxy starting on %d", port)); + ServerBuilder.forPort(port).addService(cbtTestProxy).build().start().awaitTermination(); + } +} diff --git a/test-proxy/src/main/proto/v2_test_proxy.proto b/test-proxy/src/main/proto/v2_test_proxy.proto new file mode 100644 index 0000000000..43b540c463 --- /dev/null +++ b/test-proxy/src/main/proto/v2_test_proxy.proto @@ -0,0 +1,223 @@ +// Copyright 2022 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. + +syntax = "proto3"; + +package bigtable.client.test; + +import "google/bigtable/v2/bigtable.proto"; +import "google/bigtable/v2/data.proto"; +import "google/protobuf/duration.proto"; +import "google/rpc/status.proto"; + +option java_multiple_files = true; +option java_package = "com.google.cloud.bigtable.testproxy"; +option go_package = "./testproxypb"; + +// The `status` field of response messages always represents an error returned +// by the client binding, e.g. never a problem in either the proxy logic or +// test driver to proxy communication. After receiving a response from the +// proxy, the test driver should always check its `status` field. +// +// [test driver] <--> [test proxy <--> client binding] <--> [Cloud Bigtable] +// ^^^^ +// `status` represents success or errors +// returned from the client binding. +// +// Status propagation design examples, assuming the C++ client: +// +// // For CloudBigtableV2TestProxy.ReadRow +// StatusOr> result = table.ReadRow(row_key, filter); +// +// Set RowResult.status to OK iff result.status() is OK. +// OK is required even if the bool is false, indicating the row wasn't found. +// +// // For CloudBigtableV2TestProxy.BulkMutateRows +// std::vector failed = table.BulkApply(bulk_mutation); +// +// The semantics are less obvious for BulkApply(), because some mutations +// failing doesn't indicate the overall RPC fails. In such case, test proxy +// should disambiguate between RPC failure and individual entry failure, and +// set MutateRowsResult.status according to the overall RPC status. +// +// The final decision regarding semantics must be documented for the +// CloudBigtableV2TestProxy service in this file. + +message CreateClientRequest { + string client_id = 1; + // The "host:port" address of the data API endpoint (i.e. the backend being + // proxied to). Example: 127.0.0.1:38543. If you want to connect to a local + // emulator via BIGTABLE_EMULATOR_HOST environment variable, you can use + // "emulator" instead of "host:port" for this field. + string data_target = 2; + // The project for all calls on this client. + string project_id = 3; + // The instance for all calls on this client. + string instance_id = 4; + // Optional app profile for all calls on this client. + // Some client bindings allow specifying the app profile on a per-operation + // basis. We don't yet support this in the proxy API, but may in the future. + string app_profile_id = 5; + // If provided, a custom timeout will be set for each API call conducted by + // the created client. Otherwise, the default timeout from the client library + // will be used. Note that the override applies to all the methods. + google.protobuf.Duration per_operation_timeout = 6; +} + +message CreateClientResponse {} + +message CloseClientRequest { + string client_id = 1; +} + +message CloseClientResponse {} + +message RemoveClientRequest { + string client_id = 1; +} + +message RemoveClientResponse {} + +message ReadRowRequest { + string client_id = 1; + // The unique name of the table from which to read the row. + // Values are of the form + // `projects//instances//tables/

`. + string table_name = 4; + string row_key = 2; + google.bigtable.v2.RowFilter filter = 3; +} + +message RowResult { + google.rpc.Status status = 1; + google.bigtable.v2.Row row = 2; +} + +message ReadRowsRequest { + string client_id = 1; + google.bigtable.v2.ReadRowsRequest request = 2; + // The streaming read can be canceled before all items are seen. + // Has no effect if non-positive. + int32 cancel_after_rows = 3; +} + +message RowsResult { + google.rpc.Status status = 1; + repeated google.bigtable.v2.Row row = 2; +} + +message MutateRowRequest { + string client_id = 1; + google.bigtable.v2.MutateRowRequest request = 2; +} + +message MutateRowResult { + google.rpc.Status status = 1; +} + +message MutateRowsRequest { + string client_id = 1; + google.bigtable.v2.MutateRowsRequest request = 2; +} + +message MutateRowsResult { + // Overall RPC status + google.rpc.Status status = 1; + // To record individual entry failures + repeated google.bigtable.v2.MutateRowsResponse.Entry entry = 2; +} + +message CheckAndMutateRowRequest { + string client_id = 1; + google.bigtable.v2.CheckAndMutateRowRequest request = 2; +} + +message CheckAndMutateRowResult { + google.rpc.Status status = 1; + google.bigtable.v2.CheckAndMutateRowResponse result = 2; +} + +message SampleRowKeysRequest { + string client_id = 1; + google.bigtable.v2.SampleRowKeysRequest request = 2; +} + +message SampleRowKeysResult { + google.rpc.Status status = 1; + repeated google.bigtable.v2.SampleRowKeysResponse sample = 2; +} + +message ReadModifyWriteRowRequest { + string client_id = 1; + google.bigtable.v2.ReadModifyWriteRowRequest request = 2; +} + +// Note that all RPCs are unary, even when the equivalent client binding call +// may be streaming. This is an intentional simplification. +// +// Most methods have sync (default) and async variants. For async variants, +// the proxy is expected to perform the async operation, then wait for results +// before delivering them back to the driver client. +// +// Operations that may have interesting concurrency characteristics are +// represented explicitly in the API (see ReadRowsRequest.cancel_after_rows). +// We include such operations only when they can be meaningfully performed +// through client bindings. +// +// Users should generally avoid setting deadlines for requests to the Proxy +// because operations are not cancelable. If the deadline is set anyway, please +// understand that the underlying operation will continue to be executed even +// after the deadline expires. +service CloudBigtableV2TestProxy { + // Client management: + // + // Creates a client in the proxy. + // Each client has its own dedicated channel(s), and can be used concurrently + // and independently with other clients. + rpc CreateClient(CreateClientRequest) returns (CreateClientResponse); + // Closes a client in the proxy, making it not accept new requests. + rpc CloseClient(CloseClientRequest) returns (CloseClientResponse); + // Removes a client in the proxy, making it inaccessible. Client closing + // should be done by CloseClient() separately. + rpc RemoveClient(RemoveClientRequest) returns (RemoveClientResponse); + + // Bigtable operations: for each operation, you should use the synchronous or + // asynchronous variant of the client method based on the `use_async_method` + // setting of the client instance. For starters, you can choose to implement + // one variant, and return UNIMPLEMENTED status for the other. + // + // Reads a row with the client instance. + // The result row may not be present in the response. + // Callers should check for it (e.g. calling has_row() in C++). + rpc ReadRow(ReadRowRequest) returns (RowResult); + + // Reads rows with the client instance. + rpc ReadRows(ReadRowsRequest) returns (RowsResult); + + // Writes a row with the client instance. + rpc MutateRow(MutateRowRequest) returns (MutateRowResult); + + // Writes multiple rows with the client instance. + rpc BulkMutateRows(MutateRowsRequest) returns (MutateRowsResult); + + // Performs a check-and-mutate-row operation with the client instance. + rpc CheckAndMutateRow(CheckAndMutateRowRequest) + returns (CheckAndMutateRowResult); + + // Obtains a row key sampling with the client instance. + rpc SampleRowKeys(SampleRowKeysRequest) returns (SampleRowKeysResult); + + // Performs a read-modify-write operation with the client. + rpc ReadModifyWriteRow(ReadModifyWriteRowRequest) returns (RowResult); +} diff --git a/versions.txt b/versions.txt index ff186e3606..7666861b93 100644 --- a/versions.txt +++ b/versions.txt @@ -1,10 +1,10 @@ # Format: # module:released-version:current-version -google-cloud-bigtable:2.11.1:2.11.2-SNAPSHOT -grpc-google-cloud-bigtable-admin-v2:2.11.1:2.11.2-SNAPSHOT -grpc-google-cloud-bigtable-v2:2.11.1:2.11.2-SNAPSHOT -proto-google-cloud-bigtable-admin-v2:2.11.1:2.11.2-SNAPSHOT -proto-google-cloud-bigtable-v2:2.11.1:2.11.2-SNAPSHOT -google-cloud-bigtable-emulator:0.148.1:0.148.2-SNAPSHOT -google-cloud-bigtable-emulator-core:2.11.1:2.11.2-SNAPSHOT +google-cloud-bigtable:2.17.0:2.17.1-SNAPSHOT +grpc-google-cloud-bigtable-admin-v2:2.17.0:2.17.1-SNAPSHOT +grpc-google-cloud-bigtable-v2:2.17.0:2.17.1-SNAPSHOT +proto-google-cloud-bigtable-admin-v2:2.17.0:2.17.1-SNAPSHOT +proto-google-cloud-bigtable-v2:2.17.0:2.17.1-SNAPSHOT +google-cloud-bigtable-emulator:0.154.0:0.154.1-SNAPSHOT +google-cloud-bigtable-emulator-core:2.17.0:2.17.1-SNAPSHOT