xref: /aosp_15_r20/external/googleapis/google/cloud/aiplatform/v1/featurestore.proto (revision d5c09012810ac0c9f33fe448fb6da8260d444cc9)
1// Copyright 2023 Google LLC
2//
3// Licensed under the Apache License, Version 2.0 (the "License");
4// you may not use this file except in compliance with the License.
5// You may obtain a copy of the License at
6//
7//     http://www.apache.org/licenses/LICENSE-2.0
8//
9// Unless required by applicable law or agreed to in writing, software
10// distributed under the License is distributed on an "AS IS" BASIS,
11// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12// See the License for the specific language governing permissions and
13// limitations under the License.
14
15syntax = "proto3";
16
17package google.cloud.aiplatform.v1;
18
19import "google/api/field_behavior.proto";
20import "google/api/resource.proto";
21import "google/cloud/aiplatform/v1/encryption_spec.proto";
22import "google/protobuf/timestamp.proto";
23
24option csharp_namespace = "Google.Cloud.AIPlatform.V1";
25option go_package = "cloud.google.com/go/aiplatform/apiv1/aiplatformpb;aiplatformpb";
26option java_multiple_files = true;
27option java_outer_classname = "FeaturestoreProto";
28option java_package = "com.google.cloud.aiplatform.v1";
29option php_namespace = "Google\\Cloud\\AIPlatform\\V1";
30option ruby_package = "Google::Cloud::AIPlatform::V1";
31
32// Vertex AI Feature Store provides a centralized repository for organizing,
33// storing, and serving ML features. The Featurestore is a top-level container
34// for your features and their values.
35message Featurestore {
36  option (google.api.resource) = {
37    type: "aiplatform.googleapis.com/Featurestore"
38    pattern: "projects/{project}/locations/{location}/featurestores/{featurestore}"
39  };
40
41  // OnlineServingConfig specifies the details for provisioning online serving
42  // resources.
43  message OnlineServingConfig {
44    // Online serving scaling configuration. If min_node_count and
45    // max_node_count are set to the same value, the cluster will be configured
46    // with the fixed number of node (no auto-scaling).
47    message Scaling {
48      // Required. The minimum number of nodes to scale down to. Must be greater
49      // than or equal to 1.
50      int32 min_node_count = 1 [(google.api.field_behavior) = REQUIRED];
51
52      // The maximum number of nodes to scale up to. Must be greater than
53      // min_node_count, and less than or equal to 10 times of 'min_node_count'.
54      int32 max_node_count = 2;
55
56      // Optional. The cpu utilization that the Autoscaler should be trying to
57      // achieve. This number is on a scale from 0 (no utilization) to 100
58      // (total utilization), and is limited between 10 and 80. When a cluster's
59      // CPU utilization exceeds the target that you have set, Bigtable
60      // immediately adds nodes to the cluster. When CPU utilization is
61      // substantially lower than the target, Bigtable removes nodes. If not set
62      // or set to 0, default to 50.
63      int32 cpu_utilization_target = 3 [(google.api.field_behavior) = OPTIONAL];
64    }
65
66    // The number of nodes for the online store. The number of nodes doesn't
67    // scale automatically, but you can manually update the number of
68    // nodes. If set to 0, the featurestore will not have an
69    // online store and cannot be used for online serving.
70    int32 fixed_node_count = 2;
71
72    // Online serving scaling configuration.
73    // Only one of `fixed_node_count` and `scaling` can be set. Setting one will
74    // reset the other.
75    Scaling scaling = 4;
76  }
77
78  // Possible states a featurestore can have.
79  enum State {
80    // Default value. This value is unused.
81    STATE_UNSPECIFIED = 0;
82
83    // State when the featurestore configuration is not being updated and the
84    // fields reflect the current configuration of the featurestore. The
85    // featurestore is usable in this state.
86    STABLE = 1;
87
88    // The state of the featurestore configuration when it is being updated.
89    // During an update, the fields reflect either the original configuration
90    // or the updated configuration of the featurestore. For example,
91    // `online_serving_config.fixed_node_count` can take minutes to update.
92    // While the update is in progress, the featurestore is in the UPDATING
93    // state, and the value of `fixed_node_count` can be the original value or
94    // the updated value, depending on the progress of the operation. Until the
95    // update completes, the actual number of nodes can still be the original
96    // value of `fixed_node_count`. The featurestore is still usable in this
97    // state.
98    UPDATING = 2;
99  }
100
101  // Output only. Name of the Featurestore. Format:
102  // `projects/{project}/locations/{location}/featurestores/{featurestore}`
103  string name = 1 [(google.api.field_behavior) = OUTPUT_ONLY];
104
105  // Output only. Timestamp when this Featurestore was created.
106  google.protobuf.Timestamp create_time = 3
107      [(google.api.field_behavior) = OUTPUT_ONLY];
108
109  // Output only. Timestamp when this Featurestore was last updated.
110  google.protobuf.Timestamp update_time = 4
111      [(google.api.field_behavior) = OUTPUT_ONLY];
112
113  // Optional. Used to perform consistent read-modify-write updates. If not set,
114  // a blind "overwrite" update happens.
115  string etag = 5 [(google.api.field_behavior) = OPTIONAL];
116
117  // Optional. The labels with user-defined metadata to organize your
118  // Featurestore.
119  //
120  // Label keys and values can be no longer than 64 characters
121  // (Unicode codepoints), can only contain lowercase letters, numeric
122  // characters, underscores and dashes. International characters are allowed.
123  //
124  // See https://goo.gl/xmQnxf for more information on and examples of labels.
125  // No more than 64 user labels can be associated with one Featurestore(System
126  // labels are excluded)."
127  // System reserved label keys are prefixed with "aiplatform.googleapis.com/"
128  // and are immutable.
129  map<string, string> labels = 6 [(google.api.field_behavior) = OPTIONAL];
130
131  // Optional. Config for online storage resources. The field should not
132  // co-exist with the field of `OnlineStoreReplicationConfig`. If both of it
133  // and OnlineStoreReplicationConfig are unset, the feature store will not have
134  // an online store and cannot be used for online serving.
135  OnlineServingConfig online_serving_config = 7
136      [(google.api.field_behavior) = OPTIONAL];
137
138  // Output only. State of the featurestore.
139  State state = 8 [(google.api.field_behavior) = OUTPUT_ONLY];
140
141  // Optional. TTL in days for feature values that will be stored in online
142  // serving storage. The Feature Store online storage periodically removes
143  // obsolete feature values older than `online_storage_ttl_days` since the
144  // feature generation time. Note that `online_storage_ttl_days` should be less
145  // than or equal to `offline_storage_ttl_days` for each EntityType under a
146  // featurestore. If not set, default to 4000 days
147  int32 online_storage_ttl_days = 13 [(google.api.field_behavior) = OPTIONAL];
148
149  // Optional. Customer-managed encryption key spec for data storage. If set,
150  // both of the online and offline data storage will be secured by this key.
151  EncryptionSpec encryption_spec = 10 [(google.api.field_behavior) = OPTIONAL];
152}
153