diff --git a/java-os-login/google-cloud-os-login/src/main/java/com/google/cloud/oslogin/v1/OsLoginServiceClient.java b/java-os-login/google-cloud-os-login/src/main/java/com/google/cloud/oslogin/v1/OsLoginServiceClient.java index 1d0dc6596251..6a047c13bebb 100644 --- a/java-os-login/google-cloud-os-login/src/main/java/com/google/cloud/oslogin/v1/OsLoginServiceClient.java +++ b/java-os-login/google-cloud-os-login/src/main/java/com/google/cloud/oslogin/v1/OsLoginServiceClient.java @@ -1057,6 +1057,7 @@ public final ImportSshPublicKeyResponse importSshPublicKey( * .setParent(UserName.of("[USER]").toString()) * .setSshPublicKey(OsLoginProto.SshPublicKey.newBuilder().build()) * .setProjectId("projectId-894832108") + * .addAllRegions(new ArrayList()) * .build(); * ImportSshPublicKeyResponse response = osLoginServiceClient.importSshPublicKey(request); * } @@ -1088,6 +1089,7 @@ public final ImportSshPublicKeyResponse importSshPublicKey(ImportSshPublicKeyReq * .setParent(UserName.of("[USER]").toString()) * .setSshPublicKey(OsLoginProto.SshPublicKey.newBuilder().build()) * .setProjectId("projectId-894832108") + * .addAllRegions(new ArrayList()) * .build(); * ApiFuture future = * osLoginServiceClient.importSshPublicKeyCallable().futureCall(request); diff --git a/java-os-login/google-cloud-os-login/src/main/java/com/google/cloud/oslogin/v1/stub/HttpJsonOsLoginServiceStub.java b/java-os-login/google-cloud-os-login/src/main/java/com/google/cloud/oslogin/v1/stub/HttpJsonOsLoginServiceStub.java index e5c957d99f35..11e09e0bf083 100644 --- a/java-os-login/google-cloud-os-login/src/main/java/com/google/cloud/oslogin/v1/stub/HttpJsonOsLoginServiceStub.java +++ b/java-os-login/google-cloud-os-login/src/main/java/com/google/cloud/oslogin/v1/stub/HttpJsonOsLoginServiceStub.java @@ -258,6 +258,7 @@ public class HttpJsonOsLoginServiceStub extends OsLoginServiceStub { ProtoRestSerializer serializer = ProtoRestSerializer.create(); serializer.putQueryParam(fields, "projectId", request.getProjectId()); + serializer.putQueryParam(fields, "regions", request.getRegionsList()); serializer.putQueryParam(fields, "$alt", "json;enum-encoding=int"); return fields; }) diff --git a/java-os-login/proto-google-cloud-os-login-v1/src/main/java/com/google/cloud/oslogin/v1/ImportSshPublicKeyRequest.java b/java-os-login/proto-google-cloud-os-login-v1/src/main/java/com/google/cloud/oslogin/v1/ImportSshPublicKeyRequest.java index 2f07ad31a83a..df81f62e4dc3 100644 --- a/java-os-login/proto-google-cloud-os-login-v1/src/main/java/com/google/cloud/oslogin/v1/ImportSshPublicKeyRequest.java +++ b/java-os-login/proto-google-cloud-os-login-v1/src/main/java/com/google/cloud/oslogin/v1/ImportSshPublicKeyRequest.java @@ -40,6 +40,7 @@ private ImportSshPublicKeyRequest(com.google.protobuf.GeneratedMessageV3.Builder private ImportSshPublicKeyRequest() { parent_ = ""; projectId_ = ""; + regions_ = com.google.protobuf.LazyStringArrayList.emptyList(); } @java.lang.Override @@ -226,6 +227,78 @@ public com.google.protobuf.ByteString getProjectIdBytes() { } } + public static final int REGIONS_FIELD_NUMBER = 5; + + @SuppressWarnings("serial") + private com.google.protobuf.LazyStringArrayList regions_ = + com.google.protobuf.LazyStringArrayList.emptyList(); + /** + * + * + *
+   * Optional. The regions to which to assert that the key was written.
+   * If unspecified, defaults to all regions.
+   * Regions are listed at https://cloud.google.com/about/locations#region.
+   * 
+ * + * repeated string regions = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return A list containing the regions. + */ + public com.google.protobuf.ProtocolStringList getRegionsList() { + return regions_; + } + /** + * + * + *
+   * Optional. The regions to which to assert that the key was written.
+   * If unspecified, defaults to all regions.
+   * Regions are listed at https://cloud.google.com/about/locations#region.
+   * 
+ * + * repeated string regions = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The count of regions. + */ + public int getRegionsCount() { + return regions_.size(); + } + /** + * + * + *
+   * Optional. The regions to which to assert that the key was written.
+   * If unspecified, defaults to all regions.
+   * Regions are listed at https://cloud.google.com/about/locations#region.
+   * 
+ * + * repeated string regions = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param index The index of the element to return. + * @return The regions at the given index. + */ + public java.lang.String getRegions(int index) { + return regions_.get(index); + } + /** + * + * + *
+   * Optional. The regions to which to assert that the key was written.
+   * If unspecified, defaults to all regions.
+   * Regions are listed at https://cloud.google.com/about/locations#region.
+   * 
+ * + * repeated string regions = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param index The index of the value to return. + * @return The bytes of the regions at the given index. + */ + public com.google.protobuf.ByteString getRegionsBytes(int index) { + return regions_.getByteString(index); + } + private byte memoizedIsInitialized = -1; @java.lang.Override @@ -249,6 +322,9 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(projectId_)) { com.google.protobuf.GeneratedMessageV3.writeString(output, 3, projectId_); } + for (int i = 0; i < regions_.size(); i++) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 5, regions_.getRaw(i)); + } getUnknownFields().writeTo(output); } @@ -267,6 +343,14 @@ public int getSerializedSize() { if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(projectId_)) { size += com.google.protobuf.GeneratedMessageV3.computeStringSize(3, projectId_); } + { + int dataSize = 0; + for (int i = 0; i < regions_.size(); i++) { + dataSize += computeStringSizeNoTag(regions_.getRaw(i)); + } + size += dataSize; + size += 1 * getRegionsList().size(); + } size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; @@ -289,6 +373,7 @@ public boolean equals(final java.lang.Object obj) { if (!getSshPublicKey().equals(other.getSshPublicKey())) return false; } if (!getProjectId().equals(other.getProjectId())) return false; + if (!getRegionsList().equals(other.getRegionsList())) return false; if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -308,6 +393,10 @@ public int hashCode() { } hash = (37 * hash) + PROJECT_ID_FIELD_NUMBER; hash = (53 * hash) + getProjectId().hashCode(); + if (getRegionsCount() > 0) { + hash = (37 * hash) + REGIONS_FIELD_NUMBER; + hash = (53 * hash) + getRegionsList().hashCode(); + } hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; @@ -455,6 +544,7 @@ public Builder clear() { sshPublicKeyBuilder_ = null; } projectId_ = ""; + regions_ = com.google.protobuf.LazyStringArrayList.emptyList(); return this; } @@ -501,6 +591,10 @@ private void buildPartial0(com.google.cloud.oslogin.v1.ImportSshPublicKeyRequest if (((from_bitField0_ & 0x00000004) != 0)) { result.projectId_ = projectId_; } + if (((from_bitField0_ & 0x00000008) != 0)) { + regions_.makeImmutable(); + result.regions_ = regions_; + } } @java.lang.Override @@ -562,6 +656,16 @@ public Builder mergeFrom(com.google.cloud.oslogin.v1.ImportSshPublicKeyRequest o bitField0_ |= 0x00000004; onChanged(); } + if (!other.regions_.isEmpty()) { + if (regions_.isEmpty()) { + regions_ = other.regions_; + bitField0_ |= 0x00000008; + } else { + ensureRegionsIsMutable(); + regions_.addAll(other.regions_); + } + onChanged(); + } this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; @@ -606,6 +710,13 @@ public Builder mergeFrom( bitField0_ |= 0x00000004; break; } // case 26 + case 42: + { + java.lang.String s = input.readStringRequireUtf8(); + ensureRegionsIsMutable(); + regions_.add(s); + break; + } // case 42 default: { if (!super.parseUnknownField(input, extensionRegistry, tag)) { @@ -1054,6 +1165,198 @@ public Builder setProjectIdBytes(com.google.protobuf.ByteString value) { return this; } + private com.google.protobuf.LazyStringArrayList regions_ = + com.google.protobuf.LazyStringArrayList.emptyList(); + + private void ensureRegionsIsMutable() { + if (!regions_.isModifiable()) { + regions_ = new com.google.protobuf.LazyStringArrayList(regions_); + } + bitField0_ |= 0x00000008; + } + /** + * + * + *
+     * Optional. The regions to which to assert that the key was written.
+     * If unspecified, defaults to all regions.
+     * Regions are listed at https://cloud.google.com/about/locations#region.
+     * 
+ * + * repeated string regions = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return A list containing the regions. + */ + public com.google.protobuf.ProtocolStringList getRegionsList() { + regions_.makeImmutable(); + return regions_; + } + /** + * + * + *
+     * Optional. The regions to which to assert that the key was written.
+     * If unspecified, defaults to all regions.
+     * Regions are listed at https://cloud.google.com/about/locations#region.
+     * 
+ * + * repeated string regions = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The count of regions. + */ + public int getRegionsCount() { + return regions_.size(); + } + /** + * + * + *
+     * Optional. The regions to which to assert that the key was written.
+     * If unspecified, defaults to all regions.
+     * Regions are listed at https://cloud.google.com/about/locations#region.
+     * 
+ * + * repeated string regions = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param index The index of the element to return. + * @return The regions at the given index. + */ + public java.lang.String getRegions(int index) { + return regions_.get(index); + } + /** + * + * + *
+     * Optional. The regions to which to assert that the key was written.
+     * If unspecified, defaults to all regions.
+     * Regions are listed at https://cloud.google.com/about/locations#region.
+     * 
+ * + * repeated string regions = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param index The index of the value to return. + * @return The bytes of the regions at the given index. + */ + public com.google.protobuf.ByteString getRegionsBytes(int index) { + return regions_.getByteString(index); + } + /** + * + * + *
+     * Optional. The regions to which to assert that the key was written.
+     * If unspecified, defaults to all regions.
+     * Regions are listed at https://cloud.google.com/about/locations#region.
+     * 
+ * + * repeated string regions = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param index The index to set the value at. + * @param value The regions to set. + * @return This builder for chaining. + */ + public Builder setRegions(int index, java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + ensureRegionsIsMutable(); + regions_.set(index, value); + bitField0_ |= 0x00000008; + onChanged(); + return this; + } + /** + * + * + *
+     * Optional. The regions to which to assert that the key was written.
+     * If unspecified, defaults to all regions.
+     * Regions are listed at https://cloud.google.com/about/locations#region.
+     * 
+ * + * repeated string regions = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The regions to add. + * @return This builder for chaining. + */ + public Builder addRegions(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + ensureRegionsIsMutable(); + regions_.add(value); + bitField0_ |= 0x00000008; + onChanged(); + return this; + } + /** + * + * + *
+     * Optional. The regions to which to assert that the key was written.
+     * If unspecified, defaults to all regions.
+     * Regions are listed at https://cloud.google.com/about/locations#region.
+     * 
+ * + * repeated string regions = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param values The regions to add. + * @return This builder for chaining. + */ + public Builder addAllRegions(java.lang.Iterable values) { + ensureRegionsIsMutable(); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, regions_); + bitField0_ |= 0x00000008; + onChanged(); + return this; + } + /** + * + * + *
+     * Optional. The regions to which to assert that the key was written.
+     * If unspecified, defaults to all regions.
+     * Regions are listed at https://cloud.google.com/about/locations#region.
+     * 
+ * + * repeated string regions = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return This builder for chaining. + */ + public Builder clearRegions() { + regions_ = com.google.protobuf.LazyStringArrayList.emptyList(); + bitField0_ = (bitField0_ & ~0x00000008); + ; + onChanged(); + return this; + } + /** + * + * + *
+     * Optional. The regions to which to assert that the key was written.
+     * If unspecified, defaults to all regions.
+     * Regions are listed at https://cloud.google.com/about/locations#region.
+     * 
+ * + * repeated string regions = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The bytes of the regions to add. + * @return This builder for chaining. + */ + public Builder addRegionsBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + ensureRegionsIsMutable(); + regions_.add(value); + bitField0_ |= 0x00000008; + onChanged(); + return this; + } + @java.lang.Override public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { return super.setUnknownFields(unknownFields); diff --git a/java-os-login/proto-google-cloud-os-login-v1/src/main/java/com/google/cloud/oslogin/v1/ImportSshPublicKeyRequestOrBuilder.java b/java-os-login/proto-google-cloud-os-login-v1/src/main/java/com/google/cloud/oslogin/v1/ImportSshPublicKeyRequestOrBuilder.java index 40f22705962a..62d643226158 100644 --- a/java-os-login/proto-google-cloud-os-login-v1/src/main/java/com/google/cloud/oslogin/v1/ImportSshPublicKeyRequestOrBuilder.java +++ b/java-os-login/proto-google-cloud-os-login-v1/src/main/java/com/google/cloud/oslogin/v1/ImportSshPublicKeyRequestOrBuilder.java @@ -117,4 +117,63 @@ public interface ImportSshPublicKeyRequestOrBuilder * @return The bytes for projectId. */ com.google.protobuf.ByteString getProjectIdBytes(); + + /** + * + * + *
+   * Optional. The regions to which to assert that the key was written.
+   * If unspecified, defaults to all regions.
+   * Regions are listed at https://cloud.google.com/about/locations#region.
+   * 
+ * + * repeated string regions = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return A list containing the regions. + */ + java.util.List getRegionsList(); + /** + * + * + *
+   * Optional. The regions to which to assert that the key was written.
+   * If unspecified, defaults to all regions.
+   * Regions are listed at https://cloud.google.com/about/locations#region.
+   * 
+ * + * repeated string regions = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The count of regions. + */ + int getRegionsCount(); + /** + * + * + *
+   * Optional. The regions to which to assert that the key was written.
+   * If unspecified, defaults to all regions.
+   * Regions are listed at https://cloud.google.com/about/locations#region.
+   * 
+ * + * repeated string regions = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param index The index of the element to return. + * @return The regions at the given index. + */ + java.lang.String getRegions(int index); + /** + * + * + *
+   * Optional. The regions to which to assert that the key was written.
+   * If unspecified, defaults to all regions.
+   * Regions are listed at https://cloud.google.com/about/locations#region.
+   * 
+ * + * repeated string regions = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param index The index of the value to return. + * @return The bytes of the regions at the given index. + */ + com.google.protobuf.ByteString getRegionsBytes(int index); } diff --git a/java-os-login/proto-google-cloud-os-login-v1/src/main/java/com/google/cloud/oslogin/v1/OsLoginProto.java b/java-os-login/proto-google-cloud-os-login-v1/src/main/java/com/google/cloud/oslogin/v1/OsLoginProto.java index f45c336f028e..ffb50175e21f 100644 --- a/java-os-login/proto-google-cloud-os-login-v1/src/main/java/com/google/cloud/oslogin/v1/OsLoginProto.java +++ b/java-os-login/proto-google-cloud-os-login-v1/src/main/java/com/google/cloud/oslogin/v1/OsLoginProto.java @@ -104,63 +104,63 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\nproject_id\030\002 \001(\t\022\021\n\tsystem_id\030\003 \001(\t\"T\n\026" + "GetSshPublicKeyRequest\022:\n\004name\030\001 \001(\tB,\342A" + "\001\002\372A%\n#oslogin.googleapis.com/SshPublicK" - + "ey\"\266\001\n\031ImportSshPublicKeyRequest\022<\n\006pare" + + "ey\"\315\001\n\031ImportSshPublicKeyRequest\022<\n\006pare" + "nt\030\001 \001(\tB,\342A\001\002\372A%\022#oslogin.googleapis.co" + "m/SshPublicKey\022G\n\016ssh_public_key\030\002 \001(\0132)" + ".google.cloud.oslogin.common.SshPublicKe" - + "yB\004\342A\001\001\022\022\n\nproject_id\030\003 \001(\t\"k\n\032ImportSsh" - + "PublicKeyResponse\022<\n\rlogin_profile\030\001 \001(\013" - + "2%.google.cloud.oslogin.v1.LoginProfile\022" - + "\017\n\007details\030\002 \001(\t\"\321\001\n\031UpdateSshPublicKeyR" - + "equest\022:\n\004name\030\001 \001(\tB,\342A\001\002\372A%\n#oslogin.g" - + "oogleapis.com/SshPublicKey\022G\n\016ssh_public" - + "_key\030\002 \001(\0132).google.cloud.oslogin.common" - + ".SshPublicKeyB\004\342A\001\002\022/\n\013update_mask\030\003 \001(\013" - + "2\032.google.protobuf.FieldMask2\206\014\n\016OsLogin" - + "Service\022\307\001\n\022CreateSshPublicKey\0222.google." - + "cloud.oslogin.v1.CreateSshPublicKeyReque" - + "st\032).google.cloud.oslogin.common.SshPubl" - + "icKey\"R\332A\025parent,ssh_public_key\202\323\344\223\0024\"\"/" - + "v1/{parent=users/*}/sshPublicKeys:\016ssh_p" - + "ublic_key\022\216\001\n\022DeletePosixAccount\0222.googl" - + "e.cloud.oslogin.v1.DeletePosixAccountReq" - + "uest\032\026.google.protobuf.Empty\",\332A\004name\202\323\344" - + "\223\002\037*\035/v1/{name=users/*/projects/*}\022\223\001\n\022D" - + "eleteSshPublicKey\0222.google.cloud.oslogin" - + ".v1.DeleteSshPublicKeyRequest\032\026.google.p" - + "rotobuf.Empty\"1\332A\004name\202\323\344\223\002$*\"/v1/{name=" - + "users/*/sshPublicKeys/*}\022\231\001\n\017GetLoginPro" - + "file\022/.google.cloud.oslogin.v1.GetLoginP" - + "rofileRequest\032%.google.cloud.oslogin.v1." - + "LoginProfile\".\332A\004name\202\323\344\223\002!\022\037/v1/{name=u" - + "sers/*}/loginProfile\022\240\001\n\017GetSshPublicKey" - + "\022/.google.cloud.oslogin.v1.GetSshPublicK" - + "eyRequest\032).google.cloud.oslogin.common." - + "SshPublicKey\"1\332A\004name\202\323\344\223\002$\022\"/v1/{name=u" - + "sers/*/sshPublicKeys/*}\022\371\001\n\022ImportSshPub" - + "licKey\0222.google.cloud.oslogin.v1.ImportS" - + "shPublicKeyRequest\0323.google.cloud.oslogi" - + "n.v1.ImportSshPublicKeyResponse\"z\332A\025pare" - + "nt,ssh_public_key\332A parent,ssh_public_ke" - + "y,project_id\202\323\344\223\0029\"\'/v1/{parent=users/*}" - + ":importSshPublicKey:\016ssh_public_key\022\347\001\n\022" - + "UpdateSshPublicKey\0222.google.cloud.oslogi" - + "n.v1.UpdateSshPublicKeyRequest\032).google." - + "cloud.oslogin.common.SshPublicKey\"r\332A\023na" - + "me,ssh_public_key\332A\037name,ssh_public_key," - + "update_mask\202\323\344\223\00242\"/v1/{name=users/*/ssh" - + "PublicKeys/*}:\016ssh_public_key\032\335\001\312A\026oslog" - + "in.googleapis.com\322A\300\001https://www.googlea" - + "pis.com/auth/cloud-platform,https://www." - + "googleapis.com/auth/cloud-platform.read-" - + "only,https://www.googleapis.com/auth/com" - + "pute,https://www.googleapis.com/auth/com" - + "pute.readonlyB\265\001\n\033com.google.cloud.oslog" - + "in.v1B\014OsLoginProtoP\001Z5cloud.google.com/" - + "go/oslogin/apiv1/osloginpb;osloginpb\252\002\027G" - + "oogle.Cloud.OsLogin.V1\312\002\027Google\\Cloud\\Os" - + "Login\\V1\352\002\032Google::Cloud::OsLogin::V1b\006p" - + "roto3" + + "yB\004\342A\001\001\022\022\n\nproject_id\030\003 \001(\t\022\025\n\007regions\030\005" + + " \003(\tB\004\342A\001\001\"k\n\032ImportSshPublicKeyResponse" + + "\022<\n\rlogin_profile\030\001 \001(\0132%.google.cloud.o" + + "slogin.v1.LoginProfile\022\017\n\007details\030\002 \001(\t\"" + + "\321\001\n\031UpdateSshPublicKeyRequest\022:\n\004name\030\001 " + + "\001(\tB,\342A\001\002\372A%\n#oslogin.googleapis.com/Ssh" + + "PublicKey\022G\n\016ssh_public_key\030\002 \001(\0132).goog" + + "le.cloud.oslogin.common.SshPublicKeyB\004\342A" + + "\001\002\022/\n\013update_mask\030\003 \001(\0132\032.google.protobu" + + "f.FieldMask2\206\014\n\016OsLoginService\022\307\001\n\022Creat" + + "eSshPublicKey\0222.google.cloud.oslogin.v1." + + "CreateSshPublicKeyRequest\032).google.cloud" + + ".oslogin.common.SshPublicKey\"R\332A\025parent," + + "ssh_public_key\202\323\344\223\0024\"\"/v1/{parent=users/" + + "*}/sshPublicKeys:\016ssh_public_key\022\216\001\n\022Del" + + "etePosixAccount\0222.google.cloud.oslogin.v" + + "1.DeletePosixAccountRequest\032\026.google.pro" + + "tobuf.Empty\",\332A\004name\202\323\344\223\002\037*\035/v1/{name=us" + + "ers/*/projects/*}\022\223\001\n\022DeleteSshPublicKey" + + "\0222.google.cloud.oslogin.v1.DeleteSshPubl" + + "icKeyRequest\032\026.google.protobuf.Empty\"1\332A" + + "\004name\202\323\344\223\002$*\"/v1/{name=users/*/sshPublic" + + "Keys/*}\022\231\001\n\017GetLoginProfile\022/.google.clo" + + "ud.oslogin.v1.GetLoginProfileRequest\032%.g" + + "oogle.cloud.oslogin.v1.LoginProfile\".\332A\004" + + "name\202\323\344\223\002!\022\037/v1/{name=users/*}/loginProf" + + "ile\022\240\001\n\017GetSshPublicKey\022/.google.cloud.o" + + "slogin.v1.GetSshPublicKeyRequest\032).googl" + + "e.cloud.oslogin.common.SshPublicKey\"1\332A\004" + + "name\202\323\344\223\002$\022\"/v1/{name=users/*/sshPublicK" + + "eys/*}\022\371\001\n\022ImportSshPublicKey\0222.google.c" + + "loud.oslogin.v1.ImportSshPublicKeyReques" + + "t\0323.google.cloud.oslogin.v1.ImportSshPub" + + "licKeyResponse\"z\332A\025parent,ssh_public_key" + + "\332A parent,ssh_public_key,project_id\202\323\344\223\002" + + "9\"\'/v1/{parent=users/*}:importSshPublicK" + + "ey:\016ssh_public_key\022\347\001\n\022UpdateSshPublicKe" + + "y\0222.google.cloud.oslogin.v1.UpdateSshPub" + + "licKeyRequest\032).google.cloud.oslogin.com" + + "mon.SshPublicKey\"r\332A\023name,ssh_public_key" + + "\332A\037name,ssh_public_key,update_mask\202\323\344\223\0024" + + "2\"/v1/{name=users/*/sshPublicKeys/*}:\016ss" + + "h_public_key\032\335\001\312A\026oslogin.googleapis.com" + + "\322A\300\001https://www.googleapis.com/auth/clou" + + "d-platform,https://www.googleapis.com/au" + + "th/cloud-platform.read-only,https://www." + + "googleapis.com/auth/compute,https://www." + + "googleapis.com/auth/compute.readonlyB\265\001\n" + + "\033com.google.cloud.oslogin.v1B\014OsLoginPro" + + "toP\001Z5cloud.google.com/go/oslogin/apiv1/" + + "osloginpb;osloginpb\252\002\027Google.Cloud.OsLog" + + "in.V1\312\002\027Google\\Cloud\\OsLogin\\V1\352\002\032Google" + + "::Cloud::OsLogin::V1b\006proto3" }; descriptor = com.google.protobuf.Descriptors.FileDescriptor.internalBuildGeneratedFileFrom( @@ -236,7 +236,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( internal_static_google_cloud_oslogin_v1_ImportSshPublicKeyRequest_descriptor, new java.lang.String[] { - "Parent", "SshPublicKey", "ProjectId", + "Parent", "SshPublicKey", "ProjectId", "Regions", }); internal_static_google_cloud_oslogin_v1_ImportSshPublicKeyResponse_descriptor = getDescriptor().getMessageTypes().get(7); diff --git a/java-os-login/proto-google-cloud-os-login-v1/src/main/proto/google/cloud/oslogin/v1/oslogin.proto b/java-os-login/proto-google-cloud-os-login-v1/src/main/proto/google/cloud/oslogin/v1/oslogin.proto index ca890654b62e..7a63ca6db801 100644 --- a/java-os-login/proto-google-cloud-os-login-v1/src/main/proto/google/cloud/oslogin/v1/oslogin.proto +++ b/java-os-login/proto-google-cloud-os-login-v1/src/main/proto/google/cloud/oslogin/v1/oslogin.proto @@ -216,6 +216,11 @@ message ImportSshPublicKeyRequest { // The project ID of the Google Cloud Platform project. string project_id = 3; + + // Optional. The regions to which to assert that the key was written. + // If unspecified, defaults to all regions. + // Regions are listed at https://cloud.google.com/about/locations#region. + repeated string regions = 5 [(google.api.field_behavior) = OPTIONAL]; } // A response message for importing an SSH public key.