())
.setEncryptionSpec(EncryptionSpec.newBuilder().build())
+ .setModelSourceInfo(ModelSourceInfo.newBuilder().build())
.build();
mockModelService.addResponse(expectedResponse);
diff --git a/java-aiplatform/proto-google-cloud-aiplatform-v1beta1/src/main/java/com/google/cloud/aiplatform/v1beta1/Model.java b/java-aiplatform/proto-google-cloud-aiplatform-v1beta1/src/main/java/com/google/cloud/aiplatform/v1beta1/Model.java
index b86d0caab1a0..c81eac4dc00b 100644
--- a/java-aiplatform/proto-google-cloud-aiplatform-v1beta1/src/main/java/com/google/cloud/aiplatform/v1beta1/Model.java
+++ b/java-aiplatform/proto-google-cloud-aiplatform-v1beta1/src/main/java/com/google/cloud/aiplatform/v1beta1/Model.java
@@ -383,6 +383,23 @@ private Model(
versionUpdateTime_ = subBuilder.buildPartial();
}
+ break;
+ }
+ case 306:
+ {
+ com.google.cloud.aiplatform.v1beta1.ModelSourceInfo.Builder subBuilder = null;
+ if (modelSourceInfo_ != null) {
+ subBuilder = modelSourceInfo_.toBuilder();
+ }
+ modelSourceInfo_ =
+ input.readMessage(
+ com.google.cloud.aiplatform.v1beta1.ModelSourceInfo.parser(),
+ extensionRegistry);
+ if (subBuilder != null) {
+ subBuilder.mergeFrom(modelSourceInfo_);
+ modelSourceInfo_ = subBuilder.buildPartial();
+ }
+
break;
}
default:
@@ -4032,6 +4049,64 @@ public com.google.cloud.aiplatform.v1beta1.EncryptionSpecOrBuilder getEncryption
return getEncryptionSpec();
}
+ public static final int MODEL_SOURCE_INFO_FIELD_NUMBER = 38;
+ private com.google.cloud.aiplatform.v1beta1.ModelSourceInfo modelSourceInfo_;
+ /**
+ *
+ *
+ *
+ * Output only. Source of a model. It can either be automl training pipeline, custom
+ * training pipeline, BigQuery ML, or existing Vertex AI Model.
+ *
+ *
+ *
+ * .google.cloud.aiplatform.v1beta1.ModelSourceInfo model_source_info = 38 [(.google.api.field_behavior) = OUTPUT_ONLY];
+ *
+ *
+ * @return Whether the modelSourceInfo field is set.
+ */
+ @java.lang.Override
+ public boolean hasModelSourceInfo() {
+ return modelSourceInfo_ != null;
+ }
+ /**
+ *
+ *
+ *
+ * Output only. Source of a model. It can either be automl training pipeline, custom
+ * training pipeline, BigQuery ML, or existing Vertex AI Model.
+ *
+ *
+ *
+ * .google.cloud.aiplatform.v1beta1.ModelSourceInfo model_source_info = 38 [(.google.api.field_behavior) = OUTPUT_ONLY];
+ *
+ *
+ * @return The modelSourceInfo.
+ */
+ @java.lang.Override
+ public com.google.cloud.aiplatform.v1beta1.ModelSourceInfo getModelSourceInfo() {
+ return modelSourceInfo_ == null
+ ? com.google.cloud.aiplatform.v1beta1.ModelSourceInfo.getDefaultInstance()
+ : modelSourceInfo_;
+ }
+ /**
+ *
+ *
+ *
+ * Output only. Source of a model. It can either be automl training pipeline, custom
+ * training pipeline, BigQuery ML, or existing Vertex AI Model.
+ *
+ *
+ *
+ * .google.cloud.aiplatform.v1beta1.ModelSourceInfo model_source_info = 38 [(.google.api.field_behavior) = OUTPUT_ONLY];
+ *
+ */
+ @java.lang.Override
+ public com.google.cloud.aiplatform.v1beta1.ModelSourceInfoOrBuilder
+ getModelSourceInfoOrBuilder() {
+ return getModelSourceInfo();
+ }
+
private byte memoizedIsInitialized = -1;
@java.lang.Override
@@ -4127,6 +4202,9 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io
if (versionUpdateTime_ != null) {
output.writeMessage(32, getVersionUpdateTime());
}
+ if (modelSourceInfo_ != null) {
+ output.writeMessage(38, getModelSourceInfo());
+ }
unknownFields.writeTo(output);
}
@@ -4246,6 +4324,9 @@ public int getSerializedSize() {
if (versionUpdateTime_ != null) {
size += com.google.protobuf.CodedOutputStream.computeMessageSize(32, getVersionUpdateTime());
}
+ if (modelSourceInfo_ != null) {
+ size += com.google.protobuf.CodedOutputStream.computeMessageSize(38, getModelSourceInfo());
+ }
size += unknownFields.getSerializedSize();
memoizedSize = size;
return size;
@@ -4318,6 +4399,10 @@ public boolean equals(final java.lang.Object obj) {
if (hasEncryptionSpec()) {
if (!getEncryptionSpec().equals(other.getEncryptionSpec())) return false;
}
+ if (hasModelSourceInfo() != other.hasModelSourceInfo()) return false;
+ if (hasModelSourceInfo()) {
+ if (!getModelSourceInfo().equals(other.getModelSourceInfo())) return false;
+ }
if (!unknownFields.equals(other.unknownFields)) return false;
return true;
}
@@ -4411,6 +4496,10 @@ public int hashCode() {
hash = (37 * hash) + ENCRYPTION_SPEC_FIELD_NUMBER;
hash = (53 * hash) + getEncryptionSpec().hashCode();
}
+ if (hasModelSourceInfo()) {
+ hash = (37 * hash) + MODEL_SOURCE_INFO_FIELD_NUMBER;
+ hash = (53 * hash) + getModelSourceInfo().hashCode();
+ }
hash = (29 * hash) + unknownFields.hashCode();
memoizedHashCode = hash;
return hash;
@@ -4672,6 +4761,12 @@ public Builder clear() {
encryptionSpec_ = null;
encryptionSpecBuilder_ = null;
}
+ if (modelSourceInfoBuilder_ == null) {
+ modelSourceInfo_ = null;
+ } else {
+ modelSourceInfo_ = null;
+ modelSourceInfoBuilder_ = null;
+ }
return this;
}
@@ -4795,6 +4890,11 @@ public com.google.cloud.aiplatform.v1beta1.Model buildPartial() {
} else {
result.encryptionSpec_ = encryptionSpecBuilder_.build();
}
+ if (modelSourceInfoBuilder_ == null) {
+ result.modelSourceInfo_ = modelSourceInfo_;
+ } else {
+ result.modelSourceInfo_ = modelSourceInfoBuilder_.build();
+ }
onBuilt();
return result;
}
@@ -5002,6 +5102,9 @@ public Builder mergeFrom(com.google.cloud.aiplatform.v1beta1.Model other) {
if (other.hasEncryptionSpec()) {
mergeEncryptionSpec(other.getEncryptionSpec());
}
+ if (other.hasModelSourceInfo()) {
+ mergeModelSourceInfo(other.getModelSourceInfo());
+ }
this.mergeUnknownFields(other.unknownFields);
onChanged();
return this;
@@ -10588,6 +10691,220 @@ public com.google.cloud.aiplatform.v1beta1.EncryptionSpec.Builder getEncryptionS
return encryptionSpecBuilder_;
}
+ private com.google.cloud.aiplatform.v1beta1.ModelSourceInfo modelSourceInfo_;
+ private com.google.protobuf.SingleFieldBuilderV3<
+ com.google.cloud.aiplatform.v1beta1.ModelSourceInfo,
+ com.google.cloud.aiplatform.v1beta1.ModelSourceInfo.Builder,
+ com.google.cloud.aiplatform.v1beta1.ModelSourceInfoOrBuilder>
+ modelSourceInfoBuilder_;
+ /**
+ *
+ *
+ *
+ * Output only. Source of a model. It can either be automl training pipeline, custom
+ * training pipeline, BigQuery ML, or existing Vertex AI Model.
+ *
+ *
+ *
+ * .google.cloud.aiplatform.v1beta1.ModelSourceInfo model_source_info = 38 [(.google.api.field_behavior) = OUTPUT_ONLY];
+ *
+ *
+ * @return Whether the modelSourceInfo field is set.
+ */
+ public boolean hasModelSourceInfo() {
+ return modelSourceInfoBuilder_ != null || modelSourceInfo_ != null;
+ }
+ /**
+ *
+ *
+ *
+ * Output only. Source of a model. It can either be automl training pipeline, custom
+ * training pipeline, BigQuery ML, or existing Vertex AI Model.
+ *
+ *
+ *
+ * .google.cloud.aiplatform.v1beta1.ModelSourceInfo model_source_info = 38 [(.google.api.field_behavior) = OUTPUT_ONLY];
+ *
+ *
+ * @return The modelSourceInfo.
+ */
+ public com.google.cloud.aiplatform.v1beta1.ModelSourceInfo getModelSourceInfo() {
+ if (modelSourceInfoBuilder_ == null) {
+ return modelSourceInfo_ == null
+ ? com.google.cloud.aiplatform.v1beta1.ModelSourceInfo.getDefaultInstance()
+ : modelSourceInfo_;
+ } else {
+ return modelSourceInfoBuilder_.getMessage();
+ }
+ }
+ /**
+ *
+ *
+ *
+ * Output only. Source of a model. It can either be automl training pipeline, custom
+ * training pipeline, BigQuery ML, or existing Vertex AI Model.
+ *
+ *
+ *
+ * .google.cloud.aiplatform.v1beta1.ModelSourceInfo model_source_info = 38 [(.google.api.field_behavior) = OUTPUT_ONLY];
+ *
+ */
+ public Builder setModelSourceInfo(com.google.cloud.aiplatform.v1beta1.ModelSourceInfo value) {
+ if (modelSourceInfoBuilder_ == null) {
+ if (value == null) {
+ throw new NullPointerException();
+ }
+ modelSourceInfo_ = value;
+ onChanged();
+ } else {
+ modelSourceInfoBuilder_.setMessage(value);
+ }
+
+ return this;
+ }
+ /**
+ *
+ *
+ *
+ * Output only. Source of a model. It can either be automl training pipeline, custom
+ * training pipeline, BigQuery ML, or existing Vertex AI Model.
+ *
+ *
+ *
+ * .google.cloud.aiplatform.v1beta1.ModelSourceInfo model_source_info = 38 [(.google.api.field_behavior) = OUTPUT_ONLY];
+ *
+ */
+ public Builder setModelSourceInfo(
+ com.google.cloud.aiplatform.v1beta1.ModelSourceInfo.Builder builderForValue) {
+ if (modelSourceInfoBuilder_ == null) {
+ modelSourceInfo_ = builderForValue.build();
+ onChanged();
+ } else {
+ modelSourceInfoBuilder_.setMessage(builderForValue.build());
+ }
+
+ return this;
+ }
+ /**
+ *
+ *
+ *
+ * Output only. Source of a model. It can either be automl training pipeline, custom
+ * training pipeline, BigQuery ML, or existing Vertex AI Model.
+ *
+ *
+ *
+ * .google.cloud.aiplatform.v1beta1.ModelSourceInfo model_source_info = 38 [(.google.api.field_behavior) = OUTPUT_ONLY];
+ *
+ */
+ public Builder mergeModelSourceInfo(com.google.cloud.aiplatform.v1beta1.ModelSourceInfo value) {
+ if (modelSourceInfoBuilder_ == null) {
+ if (modelSourceInfo_ != null) {
+ modelSourceInfo_ =
+ com.google.cloud.aiplatform.v1beta1.ModelSourceInfo.newBuilder(modelSourceInfo_)
+ .mergeFrom(value)
+ .buildPartial();
+ } else {
+ modelSourceInfo_ = value;
+ }
+ onChanged();
+ } else {
+ modelSourceInfoBuilder_.mergeFrom(value);
+ }
+
+ return this;
+ }
+ /**
+ *
+ *
+ *
+ * Output only. Source of a model. It can either be automl training pipeline, custom
+ * training pipeline, BigQuery ML, or existing Vertex AI Model.
+ *
+ *
+ *
+ * .google.cloud.aiplatform.v1beta1.ModelSourceInfo model_source_info = 38 [(.google.api.field_behavior) = OUTPUT_ONLY];
+ *
+ */
+ public Builder clearModelSourceInfo() {
+ if (modelSourceInfoBuilder_ == null) {
+ modelSourceInfo_ = null;
+ onChanged();
+ } else {
+ modelSourceInfo_ = null;
+ modelSourceInfoBuilder_ = null;
+ }
+
+ return this;
+ }
+ /**
+ *
+ *
+ *
+ * Output only. Source of a model. It can either be automl training pipeline, custom
+ * training pipeline, BigQuery ML, or existing Vertex AI Model.
+ *
+ *
+ *
+ * .google.cloud.aiplatform.v1beta1.ModelSourceInfo model_source_info = 38 [(.google.api.field_behavior) = OUTPUT_ONLY];
+ *
+ */
+ public com.google.cloud.aiplatform.v1beta1.ModelSourceInfo.Builder getModelSourceInfoBuilder() {
+
+ onChanged();
+ return getModelSourceInfoFieldBuilder().getBuilder();
+ }
+ /**
+ *
+ *
+ *
+ * Output only. Source of a model. It can either be automl training pipeline, custom
+ * training pipeline, BigQuery ML, or existing Vertex AI Model.
+ *
+ *
+ *
+ * .google.cloud.aiplatform.v1beta1.ModelSourceInfo model_source_info = 38 [(.google.api.field_behavior) = OUTPUT_ONLY];
+ *
+ */
+ public com.google.cloud.aiplatform.v1beta1.ModelSourceInfoOrBuilder
+ getModelSourceInfoOrBuilder() {
+ if (modelSourceInfoBuilder_ != null) {
+ return modelSourceInfoBuilder_.getMessageOrBuilder();
+ } else {
+ return modelSourceInfo_ == null
+ ? com.google.cloud.aiplatform.v1beta1.ModelSourceInfo.getDefaultInstance()
+ : modelSourceInfo_;
+ }
+ }
+ /**
+ *
+ *
+ *
+ * Output only. Source of a model. It can either be automl training pipeline, custom
+ * training pipeline, BigQuery ML, or existing Vertex AI Model.
+ *
+ *
+ *
+ * .google.cloud.aiplatform.v1beta1.ModelSourceInfo model_source_info = 38 [(.google.api.field_behavior) = OUTPUT_ONLY];
+ *
+ */
+ private com.google.protobuf.SingleFieldBuilderV3<
+ com.google.cloud.aiplatform.v1beta1.ModelSourceInfo,
+ com.google.cloud.aiplatform.v1beta1.ModelSourceInfo.Builder,
+ com.google.cloud.aiplatform.v1beta1.ModelSourceInfoOrBuilder>
+ getModelSourceInfoFieldBuilder() {
+ if (modelSourceInfoBuilder_ == null) {
+ modelSourceInfoBuilder_ =
+ new com.google.protobuf.SingleFieldBuilderV3<
+ com.google.cloud.aiplatform.v1beta1.ModelSourceInfo,
+ com.google.cloud.aiplatform.v1beta1.ModelSourceInfo.Builder,
+ com.google.cloud.aiplatform.v1beta1.ModelSourceInfoOrBuilder>(
+ getModelSourceInfo(), getParentForChildren(), isClean());
+ modelSourceInfo_ = null;
+ }
+ return modelSourceInfoBuilder_;
+ }
+
@java.lang.Override
public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) {
return super.setUnknownFields(unknownFields);
diff --git a/java-aiplatform/proto-google-cloud-aiplatform-v1beta1/src/main/java/com/google/cloud/aiplatform/v1beta1/ModelOrBuilder.java b/java-aiplatform/proto-google-cloud-aiplatform-v1beta1/src/main/java/com/google/cloud/aiplatform/v1beta1/ModelOrBuilder.java
index be6ef9ff3b4f..6c9f53239e8a 100644
--- a/java-aiplatform/proto-google-cloud-aiplatform-v1beta1/src/main/java/com/google/cloud/aiplatform/v1beta1/ModelOrBuilder.java
+++ b/java-aiplatform/proto-google-cloud-aiplatform-v1beta1/src/main/java/com/google/cloud/aiplatform/v1beta1/ModelOrBuilder.java
@@ -1467,4 +1467,48 @@ java.lang.String getLabelsOrDefault(
* .google.cloud.aiplatform.v1beta1.EncryptionSpec encryption_spec = 24;
*/
com.google.cloud.aiplatform.v1beta1.EncryptionSpecOrBuilder getEncryptionSpecOrBuilder();
+
+ /**
+ *
+ *
+ *
+ * Output only. Source of a model. It can either be automl training pipeline, custom
+ * training pipeline, BigQuery ML, or existing Vertex AI Model.
+ *
+ *
+ *
+ * .google.cloud.aiplatform.v1beta1.ModelSourceInfo model_source_info = 38 [(.google.api.field_behavior) = OUTPUT_ONLY];
+ *
+ *
+ * @return Whether the modelSourceInfo field is set.
+ */
+ boolean hasModelSourceInfo();
+ /**
+ *
+ *
+ *
+ * Output only. Source of a model. It can either be automl training pipeline, custom
+ * training pipeline, BigQuery ML, or existing Vertex AI Model.
+ *
+ *
+ *
+ * .google.cloud.aiplatform.v1beta1.ModelSourceInfo model_source_info = 38 [(.google.api.field_behavior) = OUTPUT_ONLY];
+ *
+ *
+ * @return The modelSourceInfo.
+ */
+ com.google.cloud.aiplatform.v1beta1.ModelSourceInfo getModelSourceInfo();
+ /**
+ *
+ *
+ *
+ * Output only. Source of a model. It can either be automl training pipeline, custom
+ * training pipeline, BigQuery ML, or existing Vertex AI Model.
+ *
+ *
+ *
+ * .google.cloud.aiplatform.v1beta1.ModelSourceInfo model_source_info = 38 [(.google.api.field_behavior) = OUTPUT_ONLY];
+ *
+ */
+ com.google.cloud.aiplatform.v1beta1.ModelSourceInfoOrBuilder getModelSourceInfoOrBuilder();
}
diff --git a/java-aiplatform/proto-google-cloud-aiplatform-v1beta1/src/main/java/com/google/cloud/aiplatform/v1beta1/ModelProto.java b/java-aiplatform/proto-google-cloud-aiplatform-v1beta1/src/main/java/com/google/cloud/aiplatform/v1beta1/ModelProto.java
index 6489449acc2b..b142130084d2 100644
--- a/java-aiplatform/proto-google-cloud-aiplatform-v1beta1/src/main/java/com/google/cloud/aiplatform/v1beta1/ModelProto.java
+++ b/java-aiplatform/proto-google-cloud-aiplatform-v1beta1/src/main/java/com/google/cloud/aiplatform/v1beta1/ModelProto.java
@@ -51,6 +51,10 @@ public static void registerAllExtensions(com.google.protobuf.ExtensionRegistry r
internal_static_google_cloud_aiplatform_v1beta1_Port_descriptor;
static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internal_static_google_cloud_aiplatform_v1beta1_Port_fieldAccessorTable;
+ static final com.google.protobuf.Descriptors.Descriptor
+ internal_static_google_cloud_aiplatform_v1beta1_ModelSourceInfo_descriptor;
+ static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
+ internal_static_google_cloud_aiplatform_v1beta1_ModelSourceInfo_fieldAccessorTable;
public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() {
return descriptor;
@@ -70,7 +74,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() {
+ "eta1/env_var.proto\0321google/cloud/aiplatf"
+ "orm/v1beta1/explanation.proto\032\034google/pr"
+ "otobuf/struct.proto\032\037google/protobuf/tim"
- + "estamp.proto\"\266\016\n\005Model\022\014\n\004name\030\001 \001(\t\022\032\n\n"
+ + "estamp.proto\"\210\017\n\005Model\022\014\n\004name\030\001 \001(\t\022\032\n\n"
+ "version_id\030\034 \001(\tB\006\340A\005\340A\003\022\027\n\017version_alia"
+ "ses\030\035 \003(\t\022<\n\023version_create_time\030\037 \001(\0132\032"
+ ".google.protobuf.TimestampB\003\340A\003\022<\n\023versi"
@@ -103,37 +107,44 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() {
+ "\022\014\n\004etag\030\020 \001(\t\022B\n\006labels\030\021 \003(\01322.google."
+ "cloud.aiplatform.v1beta1.Model.LabelsEnt"
+ "ry\022H\n\017encryption_spec\030\030 \001(\0132/.google.clo"
- + "ud.aiplatform.v1beta1.EncryptionSpec\032\332\001\n"
- + "\014ExportFormat\022\017\n\002id\030\001 \001(\tB\003\340A\003\022g\n\023export"
- + "able_contents\030\002 \003(\0162E.google.cloud.aipla"
- + "tform.v1beta1.Model.ExportFormat.Exporta"
- + "bleContentB\003\340A\003\"P\n\021ExportableContent\022\"\n\036"
- + "EXPORTABLE_CONTENT_UNSPECIFIED\020\000\022\014\n\010ARTI"
- + "FACT\020\001\022\t\n\005IMAGE\020\002\032-\n\013LabelsEntry\022\013\n\003key\030"
- + "\001 \001(\t\022\r\n\005value\030\002 \001(\t:\0028\001\"\214\001\n\027DeploymentR"
- + "esourcesType\022)\n%DEPLOYMENT_RESOURCES_TYP"
- + "E_UNSPECIFIED\020\000\022\027\n\023DEDICATED_RESOURCES\020\001"
- + "\022\027\n\023AUTOMATIC_RESOURCES\020\002\022\024\n\020SHARED_RESO"
- + "URCES\020\003:\\\352AY\n\037aiplatform.googleapis.com/"
- + "Model\0226projects/{project}/locations/{loc"
- + "ation}/models/{model}\"{\n\017PredictSchemata"
- + "\022 \n\023instance_schema_uri\030\001 \001(\tB\003\340A\005\022\"\n\025pa"
- + "rameters_schema_uri\030\002 \001(\tB\003\340A\005\022\"\n\025predic"
- + "tion_schema_uri\030\003 \001(\tB\003\340A\005\"\205\002\n\022ModelCont"
- + "ainerSpec\022\031\n\timage_uri\030\001 \001(\tB\006\340A\002\340A\005\022\024\n\007"
- + "command\030\002 \003(\tB\003\340A\005\022\021\n\004args\030\003 \003(\tB\003\340A\005\0229\n"
- + "\003env\030\004 \003(\0132\'.google.cloud.aiplatform.v1b"
- + "eta1.EnvVarB\003\340A\005\0229\n\005ports\030\005 \003(\0132%.google"
- + ".cloud.aiplatform.v1beta1.PortB\003\340A\005\022\032\n\rp"
- + "redict_route\030\006 \001(\tB\003\340A\005\022\031\n\014health_route\030"
- + "\007 \001(\tB\003\340A\005\"\036\n\004Port\022\026\n\016container_port\030\003 \001"
- + "(\005B\347\001\n#com.google.cloud.aiplatform.v1bet"
- + "a1B\nModelProtoP\001ZIgoogle.golang.org/genp"
- + "roto/googleapis/cloud/aiplatform/v1beta1"
- + ";aiplatform\252\002\037Google.Cloud.AIPlatform.V1"
- + "Beta1\312\002\037Google\\Cloud\\AIPlatform\\V1beta1\352"
- + "\002\"Google::Cloud::AIPlatform::V1beta1b\006pr"
- + "oto3"
+ + "ud.aiplatform.v1beta1.EncryptionSpec\022P\n\021"
+ + "model_source_info\030& \001(\01320.google.cloud.a"
+ + "iplatform.v1beta1.ModelSourceInfoB\003\340A\003\032\332"
+ + "\001\n\014ExportFormat\022\017\n\002id\030\001 \001(\tB\003\340A\003\022g\n\023expo"
+ + "rtable_contents\030\002 \003(\0162E.google.cloud.aip"
+ + "latform.v1beta1.Model.ExportFormat.Expor"
+ + "tableContentB\003\340A\003\"P\n\021ExportableContent\022\""
+ + "\n\036EXPORTABLE_CONTENT_UNSPECIFIED\020\000\022\014\n\010AR"
+ + "TIFACT\020\001\022\t\n\005IMAGE\020\002\032-\n\013LabelsEntry\022\013\n\003ke"
+ + "y\030\001 \001(\t\022\r\n\005value\030\002 \001(\t:\0028\001\"\214\001\n\027Deploymen"
+ + "tResourcesType\022)\n%DEPLOYMENT_RESOURCES_T"
+ + "YPE_UNSPECIFIED\020\000\022\027\n\023DEDICATED_RESOURCES"
+ + "\020\001\022\027\n\023AUTOMATIC_RESOURCES\020\002\022\024\n\020SHARED_RE"
+ + "SOURCES\020\003:\\\352AY\n\037aiplatform.googleapis.co"
+ + "m/Model\0226projects/{project}/locations/{l"
+ + "ocation}/models/{model}\"{\n\017PredictSchema"
+ + "ta\022 \n\023instance_schema_uri\030\001 \001(\tB\003\340A\005\022\"\n\025"
+ + "parameters_schema_uri\030\002 \001(\tB\003\340A\005\022\"\n\025pred"
+ + "iction_schema_uri\030\003 \001(\tB\003\340A\005\"\205\002\n\022ModelCo"
+ + "ntainerSpec\022\031\n\timage_uri\030\001 \001(\tB\006\340A\002\340A\005\022\024"
+ + "\n\007command\030\002 \003(\tB\003\340A\005\022\021\n\004args\030\003 \003(\tB\003\340A\005\022"
+ + "9\n\003env\030\004 \003(\0132\'.google.cloud.aiplatform.v"
+ + "1beta1.EnvVarB\003\340A\005\0229\n\005ports\030\005 \003(\0132%.goog"
+ + "le.cloud.aiplatform.v1beta1.PortB\003\340A\005\022\032\n"
+ + "\rpredict_route\030\006 \001(\tB\003\340A\005\022\031\n\014health_rout"
+ + "e\030\007 \001(\tB\003\340A\005\"\036\n\004Port\022\026\n\016container_port\030\003"
+ + " \001(\005\"\300\001\n\017ModelSourceInfo\022U\n\013source_type\030"
+ + "\001 \001(\0162@.google.cloud.aiplatform.v1beta1."
+ + "ModelSourceInfo.ModelSourceType\"V\n\017Model"
+ + "SourceType\022!\n\035MODEL_SOURCE_TYPE_UNSPECIF"
+ + "IED\020\000\022\n\n\006AUTOML\020\001\022\n\n\006CUSTOM\020\002\022\010\n\004BQML\020\003B"
+ + "\347\001\n#com.google.cloud.aiplatform.v1beta1B"
+ + "\nModelProtoP\001ZIgoogle.golang.org/genprot"
+ + "o/googleapis/cloud/aiplatform/v1beta1;ai"
+ + "platform\252\002\037Google.Cloud.AIPlatform.V1Bet"
+ + "a1\312\002\037Google\\Cloud\\AIPlatform\\V1beta1\352\002\"G"
+ + "oogle::Cloud::AIPlatform::V1beta1b\006proto"
+ + "3"
};
descriptor =
com.google.protobuf.Descriptors.FileDescriptor.internalBuildGeneratedFileFrom(
@@ -179,6 +190,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() {
"Etag",
"Labels",
"EncryptionSpec",
+ "ModelSourceInfo",
});
internal_static_google_cloud_aiplatform_v1beta1_Model_ExportFormat_descriptor =
internal_static_google_cloud_aiplatform_v1beta1_Model_descriptor.getNestedTypes().get(0);
@@ -220,6 +232,14 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() {
new java.lang.String[] {
"ContainerPort",
});
+ internal_static_google_cloud_aiplatform_v1beta1_ModelSourceInfo_descriptor =
+ getDescriptor().getMessageTypes().get(4);
+ internal_static_google_cloud_aiplatform_v1beta1_ModelSourceInfo_fieldAccessorTable =
+ new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable(
+ internal_static_google_cloud_aiplatform_v1beta1_ModelSourceInfo_descriptor,
+ new java.lang.String[] {
+ "SourceType",
+ });
com.google.protobuf.ExtensionRegistry registry =
com.google.protobuf.ExtensionRegistry.newInstance();
registry.add(com.google.api.FieldBehaviorProto.fieldBehavior);
diff --git a/java-aiplatform/proto-google-cloud-aiplatform-v1beta1/src/main/java/com/google/cloud/aiplatform/v1beta1/ModelSourceInfo.java b/java-aiplatform/proto-google-cloud-aiplatform-v1beta1/src/main/java/com/google/cloud/aiplatform/v1beta1/ModelSourceInfo.java
new file mode 100644
index 000000000000..86b5d723a8a5
--- /dev/null
+++ b/java-aiplatform/proto-google-cloud-aiplatform-v1beta1/src/main/java/com/google/cloud/aiplatform/v1beta1/ModelSourceInfo.java
@@ -0,0 +1,808 @@
+/*
+ * 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/cloud/aiplatform/v1beta1/model.proto
+
+package com.google.cloud.aiplatform.v1beta1;
+
+/**
+ *
+ *
+ *
+ * Detail description of the source information of the model.
+ *
+ *
+ * Protobuf type {@code google.cloud.aiplatform.v1beta1.ModelSourceInfo}
+ */
+public final class ModelSourceInfo extends com.google.protobuf.GeneratedMessageV3
+ implements
+ // @@protoc_insertion_point(message_implements:google.cloud.aiplatform.v1beta1.ModelSourceInfo)
+ ModelSourceInfoOrBuilder {
+ private static final long serialVersionUID = 0L;
+ // Use ModelSourceInfo.newBuilder() to construct.
+ private ModelSourceInfo(com.google.protobuf.GeneratedMessageV3.Builder> builder) {
+ super(builder);
+ }
+
+ private ModelSourceInfo() {
+ sourceType_ = 0;
+ }
+
+ @java.lang.Override
+ @SuppressWarnings({"unused"})
+ protected java.lang.Object newInstance(UnusedPrivateParameter unused) {
+ return new ModelSourceInfo();
+ }
+
+ @java.lang.Override
+ public final com.google.protobuf.UnknownFieldSet getUnknownFields() {
+ return this.unknownFields;
+ }
+
+ private ModelSourceInfo(
+ 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;
+ }
+ 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.cloud.aiplatform.v1beta1.ModelProto
+ .internal_static_google_cloud_aiplatform_v1beta1_ModelSourceInfo_descriptor;
+ }
+
+ @java.lang.Override
+ protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
+ internalGetFieldAccessorTable() {
+ return com.google.cloud.aiplatform.v1beta1.ModelProto
+ .internal_static_google_cloud_aiplatform_v1beta1_ModelSourceInfo_fieldAccessorTable
+ .ensureFieldAccessorsInitialized(
+ com.google.cloud.aiplatform.v1beta1.ModelSourceInfo.class,
+ com.google.cloud.aiplatform.v1beta1.ModelSourceInfo.Builder.class);
+ }
+
+ /**
+ *
+ *
+ *
+ * Source of the model.
+ *
+ *
+ * Protobuf enum {@code google.cloud.aiplatform.v1beta1.ModelSourceInfo.ModelSourceType}
+ */
+ public enum ModelSourceType implements com.google.protobuf.ProtocolMessageEnum {
+ /**
+ *
+ *
+ *
+ * Should not be used.
+ *
+ *
+ * MODEL_SOURCE_TYPE_UNSPECIFIED = 0;
+ */
+ MODEL_SOURCE_TYPE_UNSPECIFIED(0),
+ /**
+ *
+ *
+ *
+ * The Model is uploaded by automl training pipeline.
+ *
+ *
+ * AUTOML = 1;
+ */
+ AUTOML(1),
+ /**
+ *
+ *
+ *
+ * The Model is uploaded by user or custom training pipeline.
+ *
+ *
+ * CUSTOM = 2;
+ */
+ CUSTOM(2),
+ /**
+ *
+ *
+ *
+ * The Model is registered and sync'ed from BigQuery ML.
+ *
+ *
+ * BQML = 3;
+ */
+ BQML(3),
+ UNRECOGNIZED(-1),
+ ;
+
+ /**
+ *
+ *
+ *
+ * Should not be used.
+ *
+ *
+ * MODEL_SOURCE_TYPE_UNSPECIFIED = 0;
+ */
+ public static final int MODEL_SOURCE_TYPE_UNSPECIFIED_VALUE = 0;
+ /**
+ *
+ *
+ *
+ * The Model is uploaded by automl training pipeline.
+ *
+ *
+ * AUTOML = 1;
+ */
+ public static final int AUTOML_VALUE = 1;
+ /**
+ *
+ *
+ *
+ * The Model is uploaded by user or custom training pipeline.
+ *
+ *
+ * CUSTOM = 2;
+ */
+ public static final int CUSTOM_VALUE = 2;
+ /**
+ *
+ *
+ *
+ * The Model is registered and sync'ed from BigQuery ML.
+ *
+ *
+ * BQML = 3;
+ */
+ public static final int BQML_VALUE = 3;
+
+ 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 ModelSourceType 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 ModelSourceType forNumber(int value) {
+ switch (value) {
+ case 0:
+ return MODEL_SOURCE_TYPE_UNSPECIFIED;
+ case 1:
+ return AUTOML;
+ case 2:
+ return CUSTOM;
+ case 3:
+ return BQML;
+ 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 ModelSourceType findValueByNumber(int number) {
+ return ModelSourceType.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.cloud.aiplatform.v1beta1.ModelSourceInfo.getDescriptor()
+ .getEnumTypes()
+ .get(0);
+ }
+
+ private static final ModelSourceType[] VALUES = values();
+
+ public static ModelSourceType 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 ModelSourceType(int value) {
+ this.value = value;
+ }
+
+ // @@protoc_insertion_point(enum_scope:google.cloud.aiplatform.v1beta1.ModelSourceInfo.ModelSourceType)
+ }
+
+ public static final int SOURCE_TYPE_FIELD_NUMBER = 1;
+ private int sourceType_;
+ /**
+ *
+ *
+ *
+ * Type of the model source.
+ *
+ *
+ * .google.cloud.aiplatform.v1beta1.ModelSourceInfo.ModelSourceType source_type = 1;
+ *
+ * @return The enum numeric value on the wire for sourceType.
+ */
+ @java.lang.Override
+ public int getSourceTypeValue() {
+ return sourceType_;
+ }
+ /**
+ *
+ *
+ *
+ * Type of the model source.
+ *
+ *
+ * .google.cloud.aiplatform.v1beta1.ModelSourceInfo.ModelSourceType source_type = 1;
+ *
+ * @return The sourceType.
+ */
+ @java.lang.Override
+ public com.google.cloud.aiplatform.v1beta1.ModelSourceInfo.ModelSourceType getSourceType() {
+ @SuppressWarnings("deprecation")
+ com.google.cloud.aiplatform.v1beta1.ModelSourceInfo.ModelSourceType result =
+ com.google.cloud.aiplatform.v1beta1.ModelSourceInfo.ModelSourceType.valueOf(sourceType_);
+ return result == null
+ ? com.google.cloud.aiplatform.v1beta1.ModelSourceInfo.ModelSourceType.UNRECOGNIZED
+ : result;
+ }
+
+ 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 (sourceType_
+ != com.google.cloud.aiplatform.v1beta1.ModelSourceInfo.ModelSourceType
+ .MODEL_SOURCE_TYPE_UNSPECIFIED
+ .getNumber()) {
+ output.writeEnum(1, sourceType_);
+ }
+ unknownFields.writeTo(output);
+ }
+
+ @java.lang.Override
+ public int getSerializedSize() {
+ int size = memoizedSize;
+ if (size != -1) return size;
+
+ size = 0;
+ if (sourceType_
+ != com.google.cloud.aiplatform.v1beta1.ModelSourceInfo.ModelSourceType
+ .MODEL_SOURCE_TYPE_UNSPECIFIED
+ .getNumber()) {
+ size += com.google.protobuf.CodedOutputStream.computeEnumSize(1, sourceType_);
+ }
+ size += unknownFields.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.cloud.aiplatform.v1beta1.ModelSourceInfo)) {
+ return super.equals(obj);
+ }
+ com.google.cloud.aiplatform.v1beta1.ModelSourceInfo other =
+ (com.google.cloud.aiplatform.v1beta1.ModelSourceInfo) obj;
+
+ if (sourceType_ != other.sourceType_) return false;
+ if (!unknownFields.equals(other.unknownFields)) 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) + SOURCE_TYPE_FIELD_NUMBER;
+ hash = (53 * hash) + sourceType_;
+ hash = (29 * hash) + unknownFields.hashCode();
+ memoizedHashCode = hash;
+ return hash;
+ }
+
+ public static com.google.cloud.aiplatform.v1beta1.ModelSourceInfo parseFrom(
+ java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException {
+ return PARSER.parseFrom(data);
+ }
+
+ public static com.google.cloud.aiplatform.v1beta1.ModelSourceInfo parseFrom(
+ java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
+ throws com.google.protobuf.InvalidProtocolBufferException {
+ return PARSER.parseFrom(data, extensionRegistry);
+ }
+
+ public static com.google.cloud.aiplatform.v1beta1.ModelSourceInfo parseFrom(
+ com.google.protobuf.ByteString data)
+ throws com.google.protobuf.InvalidProtocolBufferException {
+ return PARSER.parseFrom(data);
+ }
+
+ public static com.google.cloud.aiplatform.v1beta1.ModelSourceInfo 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.cloud.aiplatform.v1beta1.ModelSourceInfo parseFrom(byte[] data)
+ throws com.google.protobuf.InvalidProtocolBufferException {
+ return PARSER.parseFrom(data);
+ }
+
+ public static com.google.cloud.aiplatform.v1beta1.ModelSourceInfo parseFrom(
+ byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
+ throws com.google.protobuf.InvalidProtocolBufferException {
+ return PARSER.parseFrom(data, extensionRegistry);
+ }
+
+ public static com.google.cloud.aiplatform.v1beta1.ModelSourceInfo parseFrom(
+ java.io.InputStream input) throws java.io.IOException {
+ return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input);
+ }
+
+ public static com.google.cloud.aiplatform.v1beta1.ModelSourceInfo 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.cloud.aiplatform.v1beta1.ModelSourceInfo parseDelimitedFrom(
+ java.io.InputStream input) throws java.io.IOException {
+ return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input);
+ }
+
+ public static com.google.cloud.aiplatform.v1beta1.ModelSourceInfo 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.cloud.aiplatform.v1beta1.ModelSourceInfo parseFrom(
+ com.google.protobuf.CodedInputStream input) throws java.io.IOException {
+ return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input);
+ }
+
+ public static com.google.cloud.aiplatform.v1beta1.ModelSourceInfo 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.cloud.aiplatform.v1beta1.ModelSourceInfo 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;
+ }
+ /**
+ *
+ *
+ *
+ * Detail description of the source information of the model.
+ *
+ *
+ * Protobuf type {@code google.cloud.aiplatform.v1beta1.ModelSourceInfo}
+ */
+ public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder
+ implements
+ // @@protoc_insertion_point(builder_implements:google.cloud.aiplatform.v1beta1.ModelSourceInfo)
+ com.google.cloud.aiplatform.v1beta1.ModelSourceInfoOrBuilder {
+ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() {
+ return com.google.cloud.aiplatform.v1beta1.ModelProto
+ .internal_static_google_cloud_aiplatform_v1beta1_ModelSourceInfo_descriptor;
+ }
+
+ @java.lang.Override
+ protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
+ internalGetFieldAccessorTable() {
+ return com.google.cloud.aiplatform.v1beta1.ModelProto
+ .internal_static_google_cloud_aiplatform_v1beta1_ModelSourceInfo_fieldAccessorTable
+ .ensureFieldAccessorsInitialized(
+ com.google.cloud.aiplatform.v1beta1.ModelSourceInfo.class,
+ com.google.cloud.aiplatform.v1beta1.ModelSourceInfo.Builder.class);
+ }
+
+ // Construct using com.google.cloud.aiplatform.v1beta1.ModelSourceInfo.newBuilder()
+ private Builder() {
+ maybeForceBuilderInitialization();
+ }
+
+ 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();
+ sourceType_ = 0;
+
+ return this;
+ }
+
+ @java.lang.Override
+ public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() {
+ return com.google.cloud.aiplatform.v1beta1.ModelProto
+ .internal_static_google_cloud_aiplatform_v1beta1_ModelSourceInfo_descriptor;
+ }
+
+ @java.lang.Override
+ public com.google.cloud.aiplatform.v1beta1.ModelSourceInfo getDefaultInstanceForType() {
+ return com.google.cloud.aiplatform.v1beta1.ModelSourceInfo.getDefaultInstance();
+ }
+
+ @java.lang.Override
+ public com.google.cloud.aiplatform.v1beta1.ModelSourceInfo build() {
+ com.google.cloud.aiplatform.v1beta1.ModelSourceInfo result = buildPartial();
+ if (!result.isInitialized()) {
+ throw newUninitializedMessageException(result);
+ }
+ return result;
+ }
+
+ @java.lang.Override
+ public com.google.cloud.aiplatform.v1beta1.ModelSourceInfo buildPartial() {
+ com.google.cloud.aiplatform.v1beta1.ModelSourceInfo result =
+ new com.google.cloud.aiplatform.v1beta1.ModelSourceInfo(this);
+ result.sourceType_ = sourceType_;
+ 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.cloud.aiplatform.v1beta1.ModelSourceInfo) {
+ return mergeFrom((com.google.cloud.aiplatform.v1beta1.ModelSourceInfo) other);
+ } else {
+ super.mergeFrom(other);
+ return this;
+ }
+ }
+
+ public Builder mergeFrom(com.google.cloud.aiplatform.v1beta1.ModelSourceInfo other) {
+ if (other == com.google.cloud.aiplatform.v1beta1.ModelSourceInfo.getDefaultInstance())
+ return this;
+ if (other.sourceType_ != 0) {
+ setSourceTypeValue(other.getSourceTypeValue());
+ }
+ this.mergeUnknownFields(other.unknownFields);
+ 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 {
+ com.google.cloud.aiplatform.v1beta1.ModelSourceInfo parsedMessage = null;
+ try {
+ parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry);
+ } catch (com.google.protobuf.InvalidProtocolBufferException e) {
+ parsedMessage =
+ (com.google.cloud.aiplatform.v1beta1.ModelSourceInfo) e.getUnfinishedMessage();
+ throw e.unwrapIOException();
+ } finally {
+ if (parsedMessage != null) {
+ mergeFrom(parsedMessage);
+ }
+ }
+ return this;
+ }
+
+ private int sourceType_ = 0;
+ /**
+ *
+ *
+ *
+ * Type of the model source.
+ *
+ *
+ * .google.cloud.aiplatform.v1beta1.ModelSourceInfo.ModelSourceType source_type = 1;
+ *
+ *
+ * @return The enum numeric value on the wire for sourceType.
+ */
+ @java.lang.Override
+ public int getSourceTypeValue() {
+ return sourceType_;
+ }
+ /**
+ *
+ *
+ *
+ * Type of the model source.
+ *
+ *
+ * .google.cloud.aiplatform.v1beta1.ModelSourceInfo.ModelSourceType source_type = 1;
+ *
+ *
+ * @param value The enum numeric value on the wire for sourceType to set.
+ * @return This builder for chaining.
+ */
+ public Builder setSourceTypeValue(int value) {
+
+ sourceType_ = value;
+ onChanged();
+ return this;
+ }
+ /**
+ *
+ *
+ *
+ * Type of the model source.
+ *
+ *
+ * .google.cloud.aiplatform.v1beta1.ModelSourceInfo.ModelSourceType source_type = 1;
+ *
+ *
+ * @return The sourceType.
+ */
+ @java.lang.Override
+ public com.google.cloud.aiplatform.v1beta1.ModelSourceInfo.ModelSourceType getSourceType() {
+ @SuppressWarnings("deprecation")
+ com.google.cloud.aiplatform.v1beta1.ModelSourceInfo.ModelSourceType result =
+ com.google.cloud.aiplatform.v1beta1.ModelSourceInfo.ModelSourceType.valueOf(sourceType_);
+ return result == null
+ ? com.google.cloud.aiplatform.v1beta1.ModelSourceInfo.ModelSourceType.UNRECOGNIZED
+ : result;
+ }
+ /**
+ *
+ *
+ *
+ * Type of the model source.
+ *
+ *
+ * .google.cloud.aiplatform.v1beta1.ModelSourceInfo.ModelSourceType source_type = 1;
+ *
+ *
+ * @param value The sourceType to set.
+ * @return This builder for chaining.
+ */
+ public Builder setSourceType(
+ com.google.cloud.aiplatform.v1beta1.ModelSourceInfo.ModelSourceType value) {
+ if (value == null) {
+ throw new NullPointerException();
+ }
+
+ sourceType_ = value.getNumber();
+ onChanged();
+ return this;
+ }
+ /**
+ *
+ *
+ *
+ * Type of the model source.
+ *
+ *
+ * .google.cloud.aiplatform.v1beta1.ModelSourceInfo.ModelSourceType source_type = 1;
+ *
+ *
+ * @return This builder for chaining.
+ */
+ public Builder clearSourceType() {
+
+ sourceType_ = 0;
+ 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.cloud.aiplatform.v1beta1.ModelSourceInfo)
+ }
+
+ // @@protoc_insertion_point(class_scope:google.cloud.aiplatform.v1beta1.ModelSourceInfo)
+ private static final com.google.cloud.aiplatform.v1beta1.ModelSourceInfo DEFAULT_INSTANCE;
+
+ static {
+ DEFAULT_INSTANCE = new com.google.cloud.aiplatform.v1beta1.ModelSourceInfo();
+ }
+
+ public static com.google.cloud.aiplatform.v1beta1.ModelSourceInfo getDefaultInstance() {
+ return DEFAULT_INSTANCE;
+ }
+
+ private static final com.google.protobuf.Parser PARSER =
+ new com.google.protobuf.AbstractParser() {
+ @java.lang.Override
+ public ModelSourceInfo parsePartialFrom(
+ com.google.protobuf.CodedInputStream input,
+ com.google.protobuf.ExtensionRegistryLite extensionRegistry)
+ throws com.google.protobuf.InvalidProtocolBufferException {
+ return new ModelSourceInfo(input, extensionRegistry);
+ }
+ };
+
+ 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.cloud.aiplatform.v1beta1.ModelSourceInfo getDefaultInstanceForType() {
+ return DEFAULT_INSTANCE;
+ }
+}
diff --git a/java-aiplatform/proto-google-cloud-aiplatform-v1beta1/src/main/java/com/google/cloud/aiplatform/v1beta1/ModelSourceInfoOrBuilder.java b/java-aiplatform/proto-google-cloud-aiplatform-v1beta1/src/main/java/com/google/cloud/aiplatform/v1beta1/ModelSourceInfoOrBuilder.java
new file mode 100644
index 000000000000..e08579c1db58
--- /dev/null
+++ b/java-aiplatform/proto-google-cloud-aiplatform-v1beta1/src/main/java/com/google/cloud/aiplatform/v1beta1/ModelSourceInfoOrBuilder.java
@@ -0,0 +1,50 @@
+/*
+ * 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/cloud/aiplatform/v1beta1/model.proto
+
+package com.google.cloud.aiplatform.v1beta1;
+
+public interface ModelSourceInfoOrBuilder
+ extends
+ // @@protoc_insertion_point(interface_extends:google.cloud.aiplatform.v1beta1.ModelSourceInfo)
+ com.google.protobuf.MessageOrBuilder {
+
+ /**
+ *
+ *
+ *
+ * Type of the model source.
+ *
+ *
+ * .google.cloud.aiplatform.v1beta1.ModelSourceInfo.ModelSourceType source_type = 1;
+ *
+ * @return The enum numeric value on the wire for sourceType.
+ */
+ int getSourceTypeValue();
+ /**
+ *
+ *
+ *
+ * Type of the model source.
+ *
+ *
+ * .google.cloud.aiplatform.v1beta1.ModelSourceInfo.ModelSourceType source_type = 1;
+ *
+ * @return The sourceType.
+ */
+ com.google.cloud.aiplatform.v1beta1.ModelSourceInfo.ModelSourceType getSourceType();
+}
diff --git a/java-aiplatform/proto-google-cloud-aiplatform-v1beta1/src/main/proto/google/cloud/aiplatform/v1beta1/model.proto b/java-aiplatform/proto-google-cloud-aiplatform-v1beta1/src/main/proto/google/cloud/aiplatform/v1beta1/model.proto
index ba9b2cd5a365..9e408aebda49 100644
--- a/java-aiplatform/proto-google-cloud-aiplatform-v1beta1/src/main/proto/google/cloud/aiplatform/v1beta1/model.proto
+++ b/java-aiplatform/proto-google-cloud-aiplatform-v1beta1/src/main/proto/google/cloud/aiplatform/v1beta1/model.proto
@@ -328,6 +328,10 @@ message Model {
// Customer-managed encryption key spec for a Model. If set, this
// Model and all sub-resources of this Model will be secured by this key.
EncryptionSpec encryption_spec = 24;
+
+ // Output only. Source of a model. It can either be automl training pipeline, custom
+ // training pipeline, BigQuery ML, or existing Vertex AI Model.
+ ModelSourceInfo model_source_info = 38 [(google.api.field_behavior) = OUTPUT_ONLY];
}
// Contains the schemata used in Model's predictions and explanations via
@@ -590,3 +594,24 @@ message Port {
// Must be a valid port number, between 1 and 65535 inclusive.
int32 container_port = 3;
}
+
+// Detail description of the source information of the model.
+message ModelSourceInfo {
+ // Source of the model.
+ enum ModelSourceType {
+ // Should not be used.
+ MODEL_SOURCE_TYPE_UNSPECIFIED = 0;
+
+ // The Model is uploaded by automl training pipeline.
+ AUTOML = 1;
+
+ // The Model is uploaded by user or custom training pipeline.
+ CUSTOM = 2;
+
+ // The Model is registered and sync'ed from BigQuery ML.
+ BQML = 3;
+ }
+
+ // Type of the model source.
+ ModelSourceType source_type = 1;
+}