diff --git a/.github/scripts/update_generation_config.sh b/.github/scripts/update_generation_config.sh index 3b890a76b2..92efcf8819 100644 --- a/.github/scripts/update_generation_config.sh +++ b/.github/scripts/update_generation_config.sh @@ -1,5 +1,5 @@ #!/bin/bash -set -e +set -ex # This script should be run at the root of the repository. # This script is used to update googleapis_commitish, gapic_generator_version, # and libraries_bom_version in generation configuration at the time of running diff --git a/.github/workflows/hermetic_library_generation.yaml b/.github/workflows/hermetic_library_generation.yaml index 5912d6f069..5a97a43802 100644 --- a/.github/workflows/hermetic_library_generation.yaml +++ b/.github/workflows/hermetic_library_generation.yaml @@ -37,7 +37,7 @@ jobs: with: fetch-depth: 0 token: ${{ secrets.CLOUD_JAVA_BOT_TOKEN }} - - uses: googleapis/sdk-platform-java/.github/scripts@v2.60.2 + - uses: googleapis/sdk-platform-java/.github/scripts@v2.61.0 if: env.SHOULD_RUN == 'true' with: base_ref: ${{ github.base_ref }} diff --git a/.kokoro/presubmit/graalvm-native-a.cfg b/.kokoro/presubmit/graalvm-native-a.cfg index 96b4fed86f..783727ef01 100644 --- a/.kokoro/presubmit/graalvm-native-a.cfg +++ b/.kokoro/presubmit/graalvm-native-a.cfg @@ -3,7 +3,7 @@ # Configure the docker image for kokoro-trampoline. env_vars: { key: "TRAMPOLINE_IMAGE" - value: "gcr.io/cloud-devrel-public-resources/graalvm_sdk_platform_a:3.50.2" # {x-version-update:google-cloud-shared-dependencies:current} + value: "gcr.io/cloud-devrel-public-resources/graalvm_sdk_platform_a:3.51.0" # {x-version-update:google-cloud-shared-dependencies:current} } env_vars: { diff --git a/.kokoro/presubmit/graalvm-native-b.cfg b/.kokoro/presubmit/graalvm-native-b.cfg index 76f0483314..83c7afee07 100644 --- a/.kokoro/presubmit/graalvm-native-b.cfg +++ b/.kokoro/presubmit/graalvm-native-b.cfg @@ -3,7 +3,7 @@ # Configure the docker image for kokoro-trampoline. env_vars: { key: "TRAMPOLINE_IMAGE" - value: "gcr.io/cloud-devrel-public-resources/graalvm_sdk_platform_b:3.50.2" # {x-version-update:google-cloud-shared-dependencies:current} + value: "gcr.io/cloud-devrel-public-resources/graalvm_sdk_platform_b:3.51.0" # {x-version-update:google-cloud-shared-dependencies:current} } env_vars: { diff --git a/.kokoro/presubmit/graalvm-native-c.cfg b/.kokoro/presubmit/graalvm-native-c.cfg index 277aa2338d..3a9bbf8c3a 100644 --- a/.kokoro/presubmit/graalvm-native-c.cfg +++ b/.kokoro/presubmit/graalvm-native-c.cfg @@ -3,7 +3,7 @@ # Configure the docker image for kokoro-trampoline. env_vars: { key: "TRAMPOLINE_IMAGE" - value: "gcr.io/cloud-devrel-public-resources/graalvm_sdk_platform_c:3.50.2" # {x-version-update:google-cloud-shared-dependencies:current} + value: "gcr.io/cloud-devrel-public-resources/graalvm_sdk_platform_c:3.51.0" # {x-version-update:google-cloud-shared-dependencies:current} } env_vars: { diff --git a/README.md b/README.md index e08716ae08..8e2349cb53 100644 --- a/README.md +++ b/README.md @@ -49,7 +49,7 @@ If you are using Maven without the 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.64.0') +implementation platform('com.google.cloud:libraries-bom:26.65.0') implementation 'com.google.cloud:google-cloud-bigtable' ``` diff --git a/generation_config.yaml b/generation_config.yaml index 0885338bf2..4d5df91da1 100644 --- a/generation_config.yaml +++ b/generation_config.yaml @@ -1,6 +1,6 @@ -gapic_generator_version: 2.60.2 -googleapis_commitish: 64e82d17e410ff5e71ab3e040ea393db362f2850 -libraries_bom_version: 26.64.0 +gapic_generator_version: 2.61.0 +googleapis_commitish: b0316578aaf7434e3c5bb93badd252f67aacf8d5 +libraries_bom_version: 26.65.0 template_excludes: - .gitignore - .kokoro/presubmit/integration.cfg 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 4de5ebb1e8..46660a8774 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 @@ -644,6 +644,7 @@ public final UnaryCallable listInst * .setCreateTime(Timestamp.newBuilder().build()) * .setSatisfiesPzs(true) * .setSatisfiesPzi(true) + * .putAllTags(new HashMap()) * .build(); * Instance response = baseBigtableInstanceAdminClient.updateInstance(request); * } @@ -679,6 +680,7 @@ public final Instance updateInstance(Instance request) { * .setCreateTime(Timestamp.newBuilder().build()) * .setSatisfiesPzs(true) * .setSatisfiesPzi(true) + * .putAllTags(new HashMap()) * .build(); * ApiFuture future = * baseBigtableInstanceAdminClient.updateInstanceCallable().futureCall(request); 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 383e8e6aba..ab2d542080 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 @@ -157,6 +157,7 @@ public void createInstanceTest() throws Exception { .setCreateTime(Timestamp.newBuilder().build()) .setSatisfiesPzs(true) .setSatisfiesPzi(true) + .putAllTags(new HashMap()) .build(); Operation resultOperation = Operation.newBuilder() @@ -218,6 +219,7 @@ public void createInstanceTest2() throws Exception { .setCreateTime(Timestamp.newBuilder().build()) .setSatisfiesPzs(true) .setSatisfiesPzi(true) + .putAllTags(new HashMap()) .build(); Operation resultOperation = Operation.newBuilder() @@ -279,6 +281,7 @@ public void getInstanceTest() throws Exception { .setCreateTime(Timestamp.newBuilder().build()) .setSatisfiesPzs(true) .setSatisfiesPzi(true) + .putAllTags(new HashMap()) .build(); mockBigtableInstanceAdmin.addResponse(expectedResponse); @@ -322,6 +325,7 @@ public void getInstanceTest2() throws Exception { .setCreateTime(Timestamp.newBuilder().build()) .setSatisfiesPzs(true) .setSatisfiesPzi(true) + .putAllTags(new HashMap()) .build(); mockBigtableInstanceAdmin.addResponse(expectedResponse); @@ -445,6 +449,7 @@ public void updateInstanceTest() throws Exception { .setCreateTime(Timestamp.newBuilder().build()) .setSatisfiesPzs(true) .setSatisfiesPzi(true) + .putAllTags(new HashMap()) .build(); mockBigtableInstanceAdmin.addResponse(expectedResponse); @@ -456,6 +461,7 @@ public void updateInstanceTest() throws Exception { .setCreateTime(Timestamp.newBuilder().build()) .setSatisfiesPzs(true) .setSatisfiesPzi(true) + .putAllTags(new HashMap()) .build(); Instance actualResponse = client.updateInstance(request); @@ -473,6 +479,7 @@ public void updateInstanceTest() throws Exception { Assert.assertEquals(request.getCreateTime(), actualRequest.getCreateTime()); Assert.assertEquals(request.getSatisfiesPzs(), actualRequest.getSatisfiesPzs()); Assert.assertEquals(request.getSatisfiesPzi(), actualRequest.getSatisfiesPzi()); + Assert.assertEquals(request.getTagsMap(), actualRequest.getTagsMap()); Assert.assertTrue( channelProvider.isHeaderSent( ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), @@ -493,6 +500,7 @@ public void updateInstanceExceptionTest() throws Exception { .setCreateTime(Timestamp.newBuilder().build()) .setSatisfiesPzs(true) .setSatisfiesPzi(true) + .putAllTags(new HashMap()) .build(); client.updateInstance(request); Assert.fail("No exception raised"); @@ -511,6 +519,7 @@ public void partialUpdateInstanceTest() throws Exception { .setCreateTime(Timestamp.newBuilder().build()) .setSatisfiesPzs(true) .setSatisfiesPzi(true) + .putAllTags(new HashMap()) .build(); Operation resultOperation = Operation.newBuilder() 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 7f44f48469..5f8b3a057a 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 @@ -4707,7 +4707,7 @@ public com.google.bigtable.admin.v2.AppProfile.SingleClusterRouting getSingleClu * .google.bigtable.admin.v2.AppProfile.Priority priority = 7 [deprecated = true]; * * @deprecated google.bigtable.admin.v2.AppProfile.priority is deprecated. See - * google/bigtable/admin/v2/instance.proto;l=406 + * google/bigtable/admin/v2/instance.proto;l=421 * @return Whether the priority field is set. */ @java.lang.Deprecated @@ -4728,7 +4728,7 @@ public boolean hasPriority() { * .google.bigtable.admin.v2.AppProfile.Priority priority = 7 [deprecated = true]; * * @deprecated google.bigtable.admin.v2.AppProfile.priority is deprecated. See - * google/bigtable/admin/v2/instance.proto;l=406 + * google/bigtable/admin/v2/instance.proto;l=421 * @return The enum numeric value on the wire for priority. */ @java.lang.Deprecated @@ -4752,7 +4752,7 @@ public int getPriorityValue() { * .google.bigtable.admin.v2.AppProfile.Priority priority = 7 [deprecated = true]; * * @deprecated google.bigtable.admin.v2.AppProfile.priority is deprecated. See - * google/bigtable/admin/v2/instance.proto;l=406 + * google/bigtable/admin/v2/instance.proto;l=421 * @return The priority. */ @java.lang.Deprecated @@ -6386,7 +6386,7 @@ public Builder clearSingleClusterRouting() { * .google.bigtable.admin.v2.AppProfile.Priority priority = 7 [deprecated = true]; * * @deprecated google.bigtable.admin.v2.AppProfile.priority is deprecated. See - * google/bigtable/admin/v2/instance.proto;l=406 + * google/bigtable/admin/v2/instance.proto;l=421 * @return Whether the priority field is set. */ @java.lang.Override @@ -6408,7 +6408,7 @@ public boolean hasPriority() { * .google.bigtable.admin.v2.AppProfile.Priority priority = 7 [deprecated = true]; * * @deprecated google.bigtable.admin.v2.AppProfile.priority is deprecated. See - * google/bigtable/admin/v2/instance.proto;l=406 + * google/bigtable/admin/v2/instance.proto;l=421 * @return The enum numeric value on the wire for priority. */ @java.lang.Override @@ -6433,7 +6433,7 @@ public int getPriorityValue() { * .google.bigtable.admin.v2.AppProfile.Priority priority = 7 [deprecated = true]; * * @deprecated google.bigtable.admin.v2.AppProfile.priority is deprecated. See - * google/bigtable/admin/v2/instance.proto;l=406 + * google/bigtable/admin/v2/instance.proto;l=421 * @param value The enum numeric value on the wire for priority to set. * @return This builder for chaining. */ @@ -6458,7 +6458,7 @@ public Builder setPriorityValue(int value) { * .google.bigtable.admin.v2.AppProfile.Priority priority = 7 [deprecated = true]; * * @deprecated google.bigtable.admin.v2.AppProfile.priority is deprecated. See - * google/bigtable/admin/v2/instance.proto;l=406 + * google/bigtable/admin/v2/instance.proto;l=421 * @return The priority. */ @java.lang.Override @@ -6488,7 +6488,7 @@ public com.google.bigtable.admin.v2.AppProfile.Priority getPriority() { * .google.bigtable.admin.v2.AppProfile.Priority priority = 7 [deprecated = true]; * * @deprecated google.bigtable.admin.v2.AppProfile.priority is deprecated. See - * google/bigtable/admin/v2/instance.proto;l=406 + * google/bigtable/admin/v2/instance.proto;l=421 * @param value The priority to set. * @return This builder for chaining. */ @@ -6516,7 +6516,7 @@ public Builder setPriority(com.google.bigtable.admin.v2.AppProfile.Priority valu * .google.bigtable.admin.v2.AppProfile.Priority priority = 7 [deprecated = true]; * * @deprecated google.bigtable.admin.v2.AppProfile.priority is deprecated. See - * google/bigtable/admin/v2/instance.proto;l=406 + * google/bigtable/admin/v2/instance.proto;l=421 * @return This builder for chaining. */ @java.lang.Deprecated diff --git a/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/AppProfileOrBuilder.java b/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/AppProfileOrBuilder.java index e0250ede66..66bd6fcd50 100644 --- a/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/AppProfileOrBuilder.java +++ b/proto-google-cloud-bigtable-admin-v2/src/main/java/com/google/bigtable/admin/v2/AppProfileOrBuilder.java @@ -216,7 +216,7 @@ public interface AppProfileOrBuilder * .google.bigtable.admin.v2.AppProfile.Priority priority = 7 [deprecated = true]; * * @deprecated google.bigtable.admin.v2.AppProfile.priority is deprecated. See - * google/bigtable/admin/v2/instance.proto;l=406 + * google/bigtable/admin/v2/instance.proto;l=421 * @return Whether the priority field is set. */ @java.lang.Deprecated @@ -235,7 +235,7 @@ public interface AppProfileOrBuilder * .google.bigtable.admin.v2.AppProfile.Priority priority = 7 [deprecated = true]; * * @deprecated google.bigtable.admin.v2.AppProfile.priority is deprecated. See - * google/bigtable/admin/v2/instance.proto;l=406 + * google/bigtable/admin/v2/instance.proto;l=421 * @return The enum numeric value on the wire for priority. */ @java.lang.Deprecated @@ -254,7 +254,7 @@ public interface AppProfileOrBuilder * .google.bigtable.admin.v2.AppProfile.Priority priority = 7 [deprecated = true]; * * @deprecated google.bigtable.admin.v2.AppProfile.priority is deprecated. See - * google/bigtable/admin/v2/instance.proto;l=406 + * google/bigtable/admin/v2/instance.proto;l=421 * @return The priority. */ @java.lang.Deprecated 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 b308902511..48d4b3687b 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 @@ -67,6 +67,8 @@ protected com.google.protobuf.MapFieldReflectionAccessor internalGetMapFieldRefl switch (number) { case 5: return internalGetLabels(); + case 12: + return internalGetTags(); default: throw new RuntimeException("Invalid map field number: " + number); } @@ -878,6 +880,153 @@ public boolean getSatisfiesPzi() { return satisfiesPzi_; } + public static final int TAGS_FIELD_NUMBER = 12; + + private static final class TagsDefaultEntryHolder { + static final com.google.protobuf.MapEntry defaultEntry = + com.google.protobuf.MapEntry.newDefaultInstance( + com.google.bigtable.admin.v2.InstanceProto + .internal_static_google_bigtable_admin_v2_Instance_TagsEntry_descriptor, + com.google.protobuf.WireFormat.FieldType.STRING, + "", + com.google.protobuf.WireFormat.FieldType.STRING, + ""); + } + + @SuppressWarnings("serial") + private com.google.protobuf.MapField tags_; + + private com.google.protobuf.MapField internalGetTags() { + if (tags_ == null) { + return com.google.protobuf.MapField.emptyMapField(TagsDefaultEntryHolder.defaultEntry); + } + return tags_; + } + + public int getTagsCount() { + return internalGetTags().getMap().size(); + } + + /** + * + * + *
+   * Optional. Input only. Immutable. Tag keys/values directly bound to this
+   * resource. For example:
+   * - "123/environment": "production",
+   * - "123/costCenter": "marketing"
+   *
+   * Tags and Labels (above) are both used to bind metadata to resources, with
+   * different use-cases. See
+   * https://cloud.google.com/resource-manager/docs/tags/tags-overview for an
+   * in-depth overview on the difference between tags and labels.
+   * 
+ * + * + * map<string, string> tags = 12 [(.google.api.field_behavior) = INPUT_ONLY, (.google.api.field_behavior) = IMMUTABLE, (.google.api.field_behavior) = OPTIONAL]; + * + */ + @java.lang.Override + public boolean containsTags(java.lang.String key) { + if (key == null) { + throw new NullPointerException("map key"); + } + return internalGetTags().getMap().containsKey(key); + } + + /** Use {@link #getTagsMap()} instead. */ + @java.lang.Override + @java.lang.Deprecated + public java.util.Map getTags() { + return getTagsMap(); + } + + /** + * + * + *
+   * Optional. Input only. Immutable. Tag keys/values directly bound to this
+   * resource. For example:
+   * - "123/environment": "production",
+   * - "123/costCenter": "marketing"
+   *
+   * Tags and Labels (above) are both used to bind metadata to resources, with
+   * different use-cases. See
+   * https://cloud.google.com/resource-manager/docs/tags/tags-overview for an
+   * in-depth overview on the difference between tags and labels.
+   * 
+ * + * + * map<string, string> tags = 12 [(.google.api.field_behavior) = INPUT_ONLY, (.google.api.field_behavior) = IMMUTABLE, (.google.api.field_behavior) = OPTIONAL]; + * + */ + @java.lang.Override + public java.util.Map getTagsMap() { + return internalGetTags().getMap(); + } + + /** + * + * + *
+   * Optional. Input only. Immutable. Tag keys/values directly bound to this
+   * resource. For example:
+   * - "123/environment": "production",
+   * - "123/costCenter": "marketing"
+   *
+   * Tags and Labels (above) are both used to bind metadata to resources, with
+   * different use-cases. See
+   * https://cloud.google.com/resource-manager/docs/tags/tags-overview for an
+   * in-depth overview on the difference between tags and labels.
+   * 
+ * + * + * map<string, string> tags = 12 [(.google.api.field_behavior) = INPUT_ONLY, (.google.api.field_behavior) = IMMUTABLE, (.google.api.field_behavior) = OPTIONAL]; + * + */ + @java.lang.Override + public /* nullable */ java.lang.String getTagsOrDefault( + java.lang.String key, + /* nullable */ + java.lang.String defaultValue) { + if (key == null) { + throw new NullPointerException("map key"); + } + java.util.Map map = internalGetTags().getMap(); + return map.containsKey(key) ? map.get(key) : defaultValue; + } + + /** + * + * + *
+   * Optional. Input only. Immutable. Tag keys/values directly bound to this
+   * resource. For example:
+   * - "123/environment": "production",
+   * - "123/costCenter": "marketing"
+   *
+   * Tags and Labels (above) are both used to bind metadata to resources, with
+   * different use-cases. See
+   * https://cloud.google.com/resource-manager/docs/tags/tags-overview for an
+   * in-depth overview on the difference between tags and labels.
+   * 
+ * + * + * map<string, string> tags = 12 [(.google.api.field_behavior) = INPUT_ONLY, (.google.api.field_behavior) = IMMUTABLE, (.google.api.field_behavior) = OPTIONAL]; + * + */ + @java.lang.Override + public java.lang.String getTagsOrThrow(java.lang.String key) { + if (key == null) { + throw new NullPointerException("map key"); + } + java.util.Map map = internalGetTags().getMap(); + if (!map.containsKey(key)) { + throw new java.lang.IllegalArgumentException(); + } + return map.get(key); + } + private byte memoizedIsInitialized = -1; @java.lang.Override @@ -915,6 +1064,8 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io if (((bitField0_ & 0x00000004) != 0)) { output.writeBool(11, satisfiesPzi_); } + com.google.protobuf.GeneratedMessageV3.serializeStringMapTo( + output, internalGetTags(), TagsDefaultEntryHolder.defaultEntry, 12); getUnknownFields().writeTo(output); } @@ -955,6 +1106,16 @@ public int getSerializedSize() { if (((bitField0_ & 0x00000004) != 0)) { size += com.google.protobuf.CodedOutputStream.computeBoolSize(11, satisfiesPzi_); } + for (java.util.Map.Entry entry : + internalGetTags().getMap().entrySet()) { + com.google.protobuf.MapEntry tags__ = + TagsDefaultEntryHolder.defaultEntry + .newBuilderForType() + .setKey(entry.getKey()) + .setValue(entry.getValue()) + .build(); + size += com.google.protobuf.CodedOutputStream.computeMessageSize(12, tags__); + } size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; @@ -987,6 +1148,7 @@ public boolean equals(final java.lang.Object obj) { if (hasSatisfiesPzi()) { if (getSatisfiesPzi() != other.getSatisfiesPzi()) return false; } + if (!internalGetTags().equals(other.internalGetTags())) return false; if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -1022,6 +1184,10 @@ public int hashCode() { hash = (37 * hash) + SATISFIES_PZI_FIELD_NUMBER; hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean(getSatisfiesPzi()); } + if (!internalGetTags().getMap().isEmpty()) { + hash = (37 * hash) + TAGS_FIELD_NUMBER; + hash = (53 * hash) + internalGetTags().hashCode(); + } hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; @@ -1149,6 +1315,8 @@ protected com.google.protobuf.MapFieldReflectionAccessor internalGetMapFieldRefl switch (number) { case 5: return internalGetLabels(); + case 12: + return internalGetTags(); default: throw new RuntimeException("Invalid map field number: " + number); } @@ -1160,6 +1328,8 @@ protected com.google.protobuf.MapFieldReflectionAccessor internalGetMutableMapFi switch (number) { case 5: return internalGetMutableLabels(); + case 12: + return internalGetMutableTags(); default: throw new RuntimeException("Invalid map field number: " + number); } @@ -1207,6 +1377,7 @@ public Builder clear() { } satisfiesPzs_ = false; satisfiesPzi_ = false; + internalGetMutableTags().clear(); return this; } @@ -1272,6 +1443,10 @@ private void buildPartial0(com.google.bigtable.admin.v2.Instance result) { result.satisfiesPzi_ = satisfiesPzi_; to_bitField0_ |= 0x00000004; } + if (((from_bitField0_ & 0x00000100) != 0)) { + result.tags_ = internalGetTags(); + result.tags_.makeImmutable(); + } result.bitField0_ |= to_bitField0_; } @@ -1347,6 +1522,8 @@ public Builder mergeFrom(com.google.bigtable.admin.v2.Instance other) { if (other.hasSatisfiesPzi()) { setSatisfiesPzi(other.getSatisfiesPzi()); } + internalGetMutableTags().mergeFrom(other.internalGetTags()); + bitField0_ |= 0x00000100; this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; @@ -1427,6 +1604,15 @@ public Builder mergeFrom( bitField0_ |= 0x00000080; break; } // case 88 + case 98: + { + com.google.protobuf.MapEntry tags__ = + input.readMessage( + TagsDefaultEntryHolder.defaultEntry.getParserForType(), extensionRegistry); + internalGetMutableTags().getMutableMap().put(tags__.getKey(), tags__.getValue()); + bitField0_ |= 0x00000100; + break; + } // case 98 default: { if (!super.parseUnknownField(input, extensionRegistry, tag)) { @@ -2499,6 +2685,248 @@ public Builder clearSatisfiesPzi() { return this; } + private com.google.protobuf.MapField tags_; + + private com.google.protobuf.MapField internalGetTags() { + if (tags_ == null) { + return com.google.protobuf.MapField.emptyMapField(TagsDefaultEntryHolder.defaultEntry); + } + return tags_; + } + + private com.google.protobuf.MapField + internalGetMutableTags() { + if (tags_ == null) { + tags_ = com.google.protobuf.MapField.newMapField(TagsDefaultEntryHolder.defaultEntry); + } + if (!tags_.isMutable()) { + tags_ = tags_.copy(); + } + bitField0_ |= 0x00000100; + onChanged(); + return tags_; + } + + public int getTagsCount() { + return internalGetTags().getMap().size(); + } + + /** + * + * + *
+     * Optional. Input only. Immutable. Tag keys/values directly bound to this
+     * resource. For example:
+     * - "123/environment": "production",
+     * - "123/costCenter": "marketing"
+     *
+     * Tags and Labels (above) are both used to bind metadata to resources, with
+     * different use-cases. See
+     * https://cloud.google.com/resource-manager/docs/tags/tags-overview for an
+     * in-depth overview on the difference between tags and labels.
+     * 
+ * + * + * map<string, string> tags = 12 [(.google.api.field_behavior) = INPUT_ONLY, (.google.api.field_behavior) = IMMUTABLE, (.google.api.field_behavior) = OPTIONAL]; + * + */ + @java.lang.Override + public boolean containsTags(java.lang.String key) { + if (key == null) { + throw new NullPointerException("map key"); + } + return internalGetTags().getMap().containsKey(key); + } + + /** Use {@link #getTagsMap()} instead. */ + @java.lang.Override + @java.lang.Deprecated + public java.util.Map getTags() { + return getTagsMap(); + } + + /** + * + * + *
+     * Optional. Input only. Immutable. Tag keys/values directly bound to this
+     * resource. For example:
+     * - "123/environment": "production",
+     * - "123/costCenter": "marketing"
+     *
+     * Tags and Labels (above) are both used to bind metadata to resources, with
+     * different use-cases. See
+     * https://cloud.google.com/resource-manager/docs/tags/tags-overview for an
+     * in-depth overview on the difference between tags and labels.
+     * 
+ * + * + * map<string, string> tags = 12 [(.google.api.field_behavior) = INPUT_ONLY, (.google.api.field_behavior) = IMMUTABLE, (.google.api.field_behavior) = OPTIONAL]; + * + */ + @java.lang.Override + public java.util.Map getTagsMap() { + return internalGetTags().getMap(); + } + + /** + * + * + *
+     * Optional. Input only. Immutable. Tag keys/values directly bound to this
+     * resource. For example:
+     * - "123/environment": "production",
+     * - "123/costCenter": "marketing"
+     *
+     * Tags and Labels (above) are both used to bind metadata to resources, with
+     * different use-cases. See
+     * https://cloud.google.com/resource-manager/docs/tags/tags-overview for an
+     * in-depth overview on the difference between tags and labels.
+     * 
+ * + * + * map<string, string> tags = 12 [(.google.api.field_behavior) = INPUT_ONLY, (.google.api.field_behavior) = IMMUTABLE, (.google.api.field_behavior) = OPTIONAL]; + * + */ + @java.lang.Override + public /* nullable */ java.lang.String getTagsOrDefault( + java.lang.String key, + /* nullable */ + java.lang.String defaultValue) { + if (key == null) { + throw new NullPointerException("map key"); + } + java.util.Map map = internalGetTags().getMap(); + return map.containsKey(key) ? map.get(key) : defaultValue; + } + + /** + * + * + *
+     * Optional. Input only. Immutable. Tag keys/values directly bound to this
+     * resource. For example:
+     * - "123/environment": "production",
+     * - "123/costCenter": "marketing"
+     *
+     * Tags and Labels (above) are both used to bind metadata to resources, with
+     * different use-cases. See
+     * https://cloud.google.com/resource-manager/docs/tags/tags-overview for an
+     * in-depth overview on the difference between tags and labels.
+     * 
+ * + * + * map<string, string> tags = 12 [(.google.api.field_behavior) = INPUT_ONLY, (.google.api.field_behavior) = IMMUTABLE, (.google.api.field_behavior) = OPTIONAL]; + * + */ + @java.lang.Override + public java.lang.String getTagsOrThrow(java.lang.String key) { + if (key == null) { + throw new NullPointerException("map key"); + } + java.util.Map map = internalGetTags().getMap(); + if (!map.containsKey(key)) { + throw new java.lang.IllegalArgumentException(); + } + return map.get(key); + } + + public Builder clearTags() { + bitField0_ = (bitField0_ & ~0x00000100); + internalGetMutableTags().getMutableMap().clear(); + return this; + } + + /** + * + * + *
+     * Optional. Input only. Immutable. Tag keys/values directly bound to this
+     * resource. For example:
+     * - "123/environment": "production",
+     * - "123/costCenter": "marketing"
+     *
+     * Tags and Labels (above) are both used to bind metadata to resources, with
+     * different use-cases. See
+     * https://cloud.google.com/resource-manager/docs/tags/tags-overview for an
+     * in-depth overview on the difference between tags and labels.
+     * 
+ * + * + * map<string, string> tags = 12 [(.google.api.field_behavior) = INPUT_ONLY, (.google.api.field_behavior) = IMMUTABLE, (.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder removeTags(java.lang.String key) { + if (key == null) { + throw new NullPointerException("map key"); + } + internalGetMutableTags().getMutableMap().remove(key); + return this; + } + + /** Use alternate mutation accessors instead. */ + @java.lang.Deprecated + public java.util.Map getMutableTags() { + bitField0_ |= 0x00000100; + return internalGetMutableTags().getMutableMap(); + } + + /** + * + * + *
+     * Optional. Input only. Immutable. Tag keys/values directly bound to this
+     * resource. For example:
+     * - "123/environment": "production",
+     * - "123/costCenter": "marketing"
+     *
+     * Tags and Labels (above) are both used to bind metadata to resources, with
+     * different use-cases. See
+     * https://cloud.google.com/resource-manager/docs/tags/tags-overview for an
+     * in-depth overview on the difference between tags and labels.
+     * 
+ * + * + * map<string, string> tags = 12 [(.google.api.field_behavior) = INPUT_ONLY, (.google.api.field_behavior) = IMMUTABLE, (.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder putTags(java.lang.String key, java.lang.String value) { + if (key == null) { + throw new NullPointerException("map key"); + } + if (value == null) { + throw new NullPointerException("map value"); + } + internalGetMutableTags().getMutableMap().put(key, value); + bitField0_ |= 0x00000100; + return this; + } + + /** + * + * + *
+     * Optional. Input only. Immutable. Tag keys/values directly bound to this
+     * resource. For example:
+     * - "123/environment": "production",
+     * - "123/costCenter": "marketing"
+     *
+     * Tags and Labels (above) are both used to bind metadata to resources, with
+     * different use-cases. See
+     * https://cloud.google.com/resource-manager/docs/tags/tags-overview for an
+     * in-depth overview on the difference between tags and labels.
+     * 
+ * + * + * map<string, string> tags = 12 [(.google.api.field_behavior) = INPUT_ONLY, (.google.api.field_behavior) = IMMUTABLE, (.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder putAllTags(java.util.Map values) { + internalGetMutableTags().getMutableMap().putAll(values); + bitField0_ |= 0x00000100; + return this; + } + @java.lang.Override public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { return super.setUnknownFields(unknownFields); 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 981f2572f7..600b20b9a8 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 @@ -348,4 +348,117 @@ java.lang.String getLabelsOrDefault( * @return The satisfiesPzi. */ boolean getSatisfiesPzi(); + + /** + * + * + *
+   * Optional. Input only. Immutable. Tag keys/values directly bound to this
+   * resource. For example:
+   * - "123/environment": "production",
+   * - "123/costCenter": "marketing"
+   *
+   * Tags and Labels (above) are both used to bind metadata to resources, with
+   * different use-cases. See
+   * https://cloud.google.com/resource-manager/docs/tags/tags-overview for an
+   * in-depth overview on the difference between tags and labels.
+   * 
+ * + * + * map<string, string> tags = 12 [(.google.api.field_behavior) = INPUT_ONLY, (.google.api.field_behavior) = IMMUTABLE, (.google.api.field_behavior) = OPTIONAL]; + * + */ + int getTagsCount(); + + /** + * + * + *
+   * Optional. Input only. Immutable. Tag keys/values directly bound to this
+   * resource. For example:
+   * - "123/environment": "production",
+   * - "123/costCenter": "marketing"
+   *
+   * Tags and Labels (above) are both used to bind metadata to resources, with
+   * different use-cases. See
+   * https://cloud.google.com/resource-manager/docs/tags/tags-overview for an
+   * in-depth overview on the difference between tags and labels.
+   * 
+ * + * + * map<string, string> tags = 12 [(.google.api.field_behavior) = INPUT_ONLY, (.google.api.field_behavior) = IMMUTABLE, (.google.api.field_behavior) = OPTIONAL]; + * + */ + boolean containsTags(java.lang.String key); + + /** Use {@link #getTagsMap()} instead. */ + @java.lang.Deprecated + java.util.Map getTags(); + + /** + * + * + *
+   * Optional. Input only. Immutable. Tag keys/values directly bound to this
+   * resource. For example:
+   * - "123/environment": "production",
+   * - "123/costCenter": "marketing"
+   *
+   * Tags and Labels (above) are both used to bind metadata to resources, with
+   * different use-cases. See
+   * https://cloud.google.com/resource-manager/docs/tags/tags-overview for an
+   * in-depth overview on the difference between tags and labels.
+   * 
+ * + * + * map<string, string> tags = 12 [(.google.api.field_behavior) = INPUT_ONLY, (.google.api.field_behavior) = IMMUTABLE, (.google.api.field_behavior) = OPTIONAL]; + * + */ + java.util.Map getTagsMap(); + + /** + * + * + *
+   * Optional. Input only. Immutable. Tag keys/values directly bound to this
+   * resource. For example:
+   * - "123/environment": "production",
+   * - "123/costCenter": "marketing"
+   *
+   * Tags and Labels (above) are both used to bind metadata to resources, with
+   * different use-cases. See
+   * https://cloud.google.com/resource-manager/docs/tags/tags-overview for an
+   * in-depth overview on the difference between tags and labels.
+   * 
+ * + * + * map<string, string> tags = 12 [(.google.api.field_behavior) = INPUT_ONLY, (.google.api.field_behavior) = IMMUTABLE, (.google.api.field_behavior) = OPTIONAL]; + * + */ + /* nullable */ + java.lang.String getTagsOrDefault( + java.lang.String key, + /* nullable */ + java.lang.String defaultValue); + + /** + * + * + *
+   * Optional. Input only. Immutable. Tag keys/values directly bound to this
+   * resource. For example:
+   * - "123/environment": "production",
+   * - "123/costCenter": "marketing"
+   *
+   * Tags and Labels (above) are both used to bind metadata to resources, with
+   * different use-cases. See
+   * https://cloud.google.com/resource-manager/docs/tags/tags-overview for an
+   * in-depth overview on the difference between tags and labels.
+   * 
+ * + * + * map<string, string> tags = 12 [(.google.api.field_behavior) = INPUT_ONLY, (.google.api.field_behavior) = IMMUTABLE, (.google.api.field_behavior) = OPTIONAL]; + * + */ + java.lang.String getTagsOrThrow(java.lang.String key); } 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 df921fcbf8..6b13c7cd56 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 @@ -36,6 +36,10 @@ public static void registerAllExtensions(com.google.protobuf.ExtensionRegistry r internal_static_google_bigtable_admin_v2_Instance_LabelsEntry_descriptor; static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internal_static_google_bigtable_admin_v2_Instance_LabelsEntry_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_bigtable_admin_v2_Instance_TagsEntry_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_bigtable_admin_v2_Instance_TagsEntry_fieldAccessorTable; static final com.google.protobuf.Descriptors.Descriptor internal_static_google_bigtable_admin_v2_AutoscalingTargets_descriptor; static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable @@ -110,7 +114,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "o\022\030google.bigtable.admin.v2\032\037google/api/" + "field_behavior.proto\032\031google/api/resourc" + "e.proto\032%google/bigtable/admin/v2/common" - + ".proto\032\037google/protobuf/timestamp.proto\"\223\005\n" + + ".proto\032\037google/protobuf/timestamp.proto\"\207\006\n" + "\010Instance\022\014\n" + "\004name\030\001 \001(\t\022\031\n" + "\014display_name\030\002 \001(\tB\003\340A\002\022<\n" @@ -121,9 +125,14 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\013create_time\030\007" + " \001(\0132\032.google.protobuf.TimestampB\003\340A\003\022\037\n\r" + "satisfies_pzs\030\010 \001(\010B\003\340A\003H\000\210\001\001\022\037\n\r" - + "satisfies_pzi\030\013 \001(\010B\003\340A\003H\001\210\001\001\032-\n" + + "satisfies_pzi\030\013 \001(\010B\003\340A\003H\001\210\001\001\022E\n" + + "\004tags\030\014 \003(\0132,.google.bigtable.admin.v2.Instance.TagsEntryB" + + "\t\340A\004\340A\005\340A\001\032-\n" + "\013LabelsEntry\022\013\n" + "\003key\030\001 \001(\t\022\r\n" + + "\005value\030\002 \001(\t:\0028\001\032+\n" + + "\tTagsEntry\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" @@ -150,14 +159,14 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\005state\030\003" + " \001(\0162\'.google.bigtable.admin.v2.Cluster.StateB\003\340A\003\022\023\n" + "\013serve_nodes\030\004 \001(\005\022U\n" - + "\023node_scaling_factor\030\t \001(\01623." - + "google.bigtable.admin.v2.Cluster.NodeScalingFactorB\003\340A\005\022I\n" - + "\016cluster_config\030\007 \001(\0132" - + "/.google.bigtable.admin.v2.Cluster.ClusterConfigH\000\022H\n" - + "\024default_storage_type\030\005 \001(\016" - + "2%.google.bigtable.admin.v2.StorageTypeB\003\340A\005\022R\n" - + "\021encryption_config\030\006 \001(\01322.google" - + ".bigtable.admin.v2.Cluster.EncryptionConfigB\003\340A\005\032\270\001\n" + + "\023node_scaling_factor\030\t \001(\01623.goog" + + "le.bigtable.admin.v2.Cluster.NodeScalingFactorB\003\340A\005\022I\n" + + "\016cluster_config\030\007 \001(\0132/.go" + + "ogle.bigtable.admin.v2.Cluster.ClusterConfigH\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" + "\022autoscaling_limits\030\001" + " \001(\0132+.google.bigtable.admin.v2.AutoscalingLimitsB\003\340A\002\022N\n" @@ -179,28 +188,28 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\037NODE_SCALING_FACTOR_UNSPECIFIED\020\000\022\032\n" + "\026NODE_SCALING_FACTOR_1X\020\001\022\032\n" + "\026NODE_SCALING_FACTOR_2X\020\002:x\352Au\n" - + "$bigtableadmin.googleapis.com/Cluster\022:projects" - + "/{project}/instances/{instance}/clusters/{cluster}*\010clusters2\007clusterB\010\n" + + "$bigtableadmin.googleapis.com/Cluster\022:projects/{pr" + + "oject}/instances/{instance}/clusters/{cluster}*\010clusters2\007clusterB\010\n" + "\006config\"\355\n\n\n" + "AppProfile\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.AppProfile.MultiClusterRoutingUseAnyH\000\022[\n" - + "\026single_cluster_routing\030\006 \001(\013" - + "29.google.bigtable.admin.v2.AppProfile.SingleClusterRoutingH\000\022E\n" - + "\010priority\030\007 \001(\0162" - + "-.google.bigtable.admin.v2.AppProfile.PriorityB\002\030\001H\001\022T\n" - + "\022standard_isolation\030\013 \001(\013" - + "26.google.bigtable.admin.v2.AppProfile.StandardIsolationH\001\022i\n" + + "\035multi_cluster_routing_use_any\030\005 \001(\0132>.google.bigtable.adm" + + "in.v2.AppProfile.MultiClusterRoutingUseAnyH\000\022[\n" + + "\026single_cluster_routing\030\006 \001(\01329.g" + + "oogle.bigtable.admin.v2.AppProfile.SingleClusterRoutingH\000\022E\n" + + "\010priority\030\007 \001(\0162-.go" + + "ogle.bigtable.admin.v2.AppProfile.PriorityB\002\030\001H\001\022T\n" + + "\022standard_isolation\030\013 \001(\01326.g" + + "oogle.bigtable.admin.v2.AppProfile.StandardIsolationH\001\022i\n" + "\036data_boost_isolation_read_only\030\n" - + " \001(\0132?.google.bigtable.adm" - + "in.v2.AppProfile.DataBoostIsolationReadOnlyH\001\032\257\001\n" + + " \001(\0132?.google.bigtable.admin.v" + + "2.AppProfile.DataBoostIsolationReadOnlyH\001\032\257\001\n" + "\031MultiClusterRoutingUseAny\022\023\n" + "\013cluster_ids\030\001 \003(\t\022b\n" - + "\014row_affinity\030\003 \001(\0132J" - + ".google.bigtable.admin.v2.AppProfile.MultiClusterRoutingUseAny.RowAffinityH\000\032\r\n" + + "\014row_affinity\030\003 \001(\0132J.goo" + + "gle.bigtable.admin.v2.AppProfile.MultiClusterRoutingUseAny.RowAffinityH\000\032\r\n" + "\013RowAffinityB\n\n" + "\010affinity\032N\n" + "\024SingleClusterRouting\022\022\n\n" @@ -210,8 +219,8 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\010priority\030\001" + " \001(\0162-.google.bigtable.admin.v2.AppProfile.Priority\032\374\001\n" + "\032DataBoostIsolationReadOnly\022w\n" - + "\025compute_billing_owner\030\001 \001(\0162S.google.bigtable.admin.v2.A" - + "ppProfile.DataBoostIsolationReadOnly.ComputeBillingOwnerH\000\210\001\001\"K\n" + + "\025compute_billing_owner\030\001 \001(\0162S.google.bigtable.admin.v2.AppPr" + + "ofile.DataBoostIsolationReadOnly.ComputeBillingOwnerH\000\210\001\001\"K\n" + "\023ComputeBillingOwner\022%\n" + "!COMPUTE_BILLING_OWNER_UNSPECIFIED\020\000\022\r\n" + "\tHOST_PAYS\020\001B\030\n" @@ -219,10 +228,11 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\010Priority\022\030\n" + "\024PRIORITY_UNSPECIFIED\020\000\022\020\n" + "\014PRIORITY_LOW\020\001\022\023\n" - + "\017PRIORITY_MEDIUM\020\002\022\021\n\r" + + "\017PRIORITY_MEDIUM\020\002\022\021\n" + + "\r" + "PRIORITY_HIGH\020\003:\211\001\352A\205\001\n" - + "\'bigtableadmin.googleapis.com/AppProfile\022Aprojects/{" - + "project}/instances/{instance}/appProfiles/{app_profile}*\013appProfiles2\n" + + "\'bigtableadmin.googleapis.com/AppProfile\022Aprojects/{proj" + + "ect}/instances/{instance}/appProfiles/{app_profile}*\013appProfiles2\n" + "appProfileB\020\n" + "\016routing_policyB\013\n" + "\tisolation\"\241\003\n" @@ -235,30 +245,30 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\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:\227\001\352A\223\001\n" - + "&bigtableadmin.googleapis.com/HotTablet\022Rprojects/{proj" - + "ect}/instances/{instance}/clusters/{cluster}/hotTablets/{hot_tablet}*\n" + + "&bigtableadmin.googleapis.com/HotTablet\022Rprojects/{project}" + + "/instances/{instance}/clusters/{cluster}/hotTablets/{hot_tablet}*\n" + "hotTablets2\thotTablet\"\372\001\n" + "\013LogicalView\022\021\n" + "\004name\030\001 \001(\tB\003\340A\010\022\022\n" + "\005query\030\002 \001(\tB\003\340A\002\022\021\n" + "\004etag\030\003 \001(\tB\003\340A\001\022 \n" + "\023deletion_protection\030\006 \001(\010B\003\340A\001:\216\001\352A\212\001\n" - + "(bigtableadmin.googleapis.com/LogicalView\022Cprojects/{project}/instances/{" - + "instance}/logicalViews/{logical_view}*\014logicalViews2\013logicalView\"\226\002\n" + + "(bigtableadmin.googleapis.com/LogicalView\022Cprojects/{project}/instances/{inst" + + "ance}/logicalViews/{logical_view}*\014logicalViews2\013logicalView\"\226\002\n" + "\020MaterializedView\022\021\n" + "\004name\030\001 \001(\tB\003\340A\010\022\025\n" + "\005query\030\002 \001(\tB\006\340A\002\340A\005\022\021\n" + "\004etag\030\003 \001(\tB\003\340A\001\022\033\n" + "\023deletion_protection\030\006 \001(\010:\247\001\352A\243\001\n" - + "-bigtableadmin.googleapis.com/MaterializedView\022Mprojects/" - + "{project}/instances/{instance}/materiali" - + "zedViews/{materialized_view}*\021materializedViews2\020materializedViewB\313\002\n" + + "-bigtableadmin.googleapis.com/MaterializedView\022Mprojects/{pro" + + "ject}/instances/{instance}/materializedV" + + "iews/{materialized_view}*\021materializedViews2\020materializedViewB\313\002\n" + "\034com.google.bigtable.admin.v2B\r" - + "InstanceProtoP\001Z8cloud.google.com/go/bigtable/admin/apiv2/ad" - + "minpb;adminpb\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\022Sprojects/{project}/locations/{location}/keyR" - + "ings/{key_ring}/cryptoKeys/{crypto_key}b\006proto3" + + "InstanceProtoP\001Z8cloud.google.com/go/bigtable/admin/apiv2/adminp" + + "b;adminpb\252\002\036Google.Cloud.Bigtable.Admin." + + "V2\312\002\036Google\\Cloud\\Bigtable\\Admin\\V2\352\002\"Google::Cloud::Bigtable::Admin::V2\352Ax\n" + + "!cloudkms.googleapis.com/CryptoKey\022Sprojects" + + "/{project}/locations/{location}/keyRings/{key_ring}/cryptoKeys/{crypto_key}b\006proto3" }; descriptor = com.google.protobuf.Descriptors.FileDescriptor.internalBuildGeneratedFileFrom( @@ -283,6 +293,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "CreateTime", "SatisfiesPzs", "SatisfiesPzi", + "Tags", }); internal_static_google_bigtable_admin_v2_Instance_LabelsEntry_descriptor = internal_static_google_bigtable_admin_v2_Instance_descriptor.getNestedTypes().get(0); @@ -292,6 +303,14 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { new java.lang.String[] { "Key", "Value", }); + internal_static_google_bigtable_admin_v2_Instance_TagsEntry_descriptor = + internal_static_google_bigtable_admin_v2_Instance_descriptor.getNestedTypes().get(1); + internal_static_google_bigtable_admin_v2_Instance_TagsEntry_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_bigtable_admin_v2_Instance_TagsEntry_descriptor, + new java.lang.String[] { + "Key", "Value", + }); internal_static_google_bigtable_admin_v2_AutoscalingTargets_descriptor = getDescriptor().getMessageTypes().get(1); internal_static_google_bigtable_admin_v2_AutoscalingTargets_fieldAccessorTable = 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 5ab1e5c693..5baa006a9c 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 @@ -114,6 +114,21 @@ message Instance { // Output only. Reserved for future use. optional bool satisfies_pzi = 11 [(google.api.field_behavior) = OUTPUT_ONLY]; + + // Optional. Input only. Immutable. Tag keys/values directly bound to this + // resource. For example: + // - "123/environment": "production", + // - "123/costCenter": "marketing" + // + // Tags and Labels (above) are both used to bind metadata to resources, with + // different use-cases. See + // https://cloud.google.com/resource-manager/docs/tags/tags-overview for an + // in-depth overview on the difference between tags and labels. + map tags = 12 [ + (google.api.field_behavior) = INPUT_ONLY, + (google.api.field_behavior) = IMMUTABLE, + (google.api.field_behavior) = OPTIONAL + ]; } // The Autoscaling targets for a Cluster. These determine the recommended nodes.