Class FeaturestoreOnlineServingServiceClient (2.23.0-rc)

A service for serving online feature values.

Equality

Instances of this class created via copy-construction or copy-assignment always compare equal. Instances created with equal std::shared_ptr<*Connection> objects compare equal. Objects that compare equal share the same underlying resources.

Performance

Creating a new instance of this class is a relatively expensive operation, new objects establish new connections to the service. In contrast, copy-construction, move-construction, and the corresponding assignment operations are relatively efficient as the copies share all underlying resources.

Thread Safety

Concurrent access to different instances of this class, even if they compare equal, is guaranteed to work. Two or more threads operating on the same instance of this class is not guaranteed to work. Since copy-construction and move-construction is a relatively efficient operation, consider using such a copy when using this class from multiple threads.

Constructors

FeaturestoreOnlineServingServiceClient(FeaturestoreOnlineServingServiceClient const &)

Copy and move support

Parameter
NameDescription
FeaturestoreOnlineServingServiceClient const &

FeaturestoreOnlineServingServiceClient(FeaturestoreOnlineServingServiceClient &&)

Copy and move support

Parameter
NameDescription
FeaturestoreOnlineServingServiceClient &&

FeaturestoreOnlineServingServiceClient(std::shared_ptr< FeaturestoreOnlineServingServiceConnection >, Options)

Parameters
NameDescription
connection std::shared_ptr< FeaturestoreOnlineServingServiceConnection >
opts Options

Operators

operator=(FeaturestoreOnlineServingServiceClient const &)

Copy and move support

Parameter
NameDescription
FeaturestoreOnlineServingServiceClient const &
Returns
TypeDescription
FeaturestoreOnlineServingServiceClient &

operator=(FeaturestoreOnlineServingServiceClient &&)

Copy and move support

Parameter
NameDescription
FeaturestoreOnlineServingServiceClient &&
Returns
TypeDescription
FeaturestoreOnlineServingServiceClient &

Functions

ReadFeatureValues(std::string const &, Options)

Reads Feature values of a specific entity of an EntityType.

For reading feature values of multiple entities of an EntityType, please use StreamingReadFeatureValues.

Parameters
NameDescription
entity_type std::string const &

Required. The resource name of the EntityType for the entity being read. Value format: projects/{project}/locations/{location}/featurestores/{featurestore}/entityTypes/{entityType}. For example, for a machine learning model predicting user clicks on a website, an EntityType ID could be user.

opts Options

Optional. Override the class-level options, such as retry and backoff policies.

Returns
TypeDescription
StatusOr< google::cloud::aiplatform::v1::ReadFeatureValuesResponse >

the result of the RPC. The response message type (google.cloud.aiplatform.v1.ReadFeatureValuesResponse) is mapped to a C++ class using the Protobuf mapping rules. If the request fails, the StatusOr contains the error details.

ReadFeatureValues(google::cloud::aiplatform::v1::ReadFeatureValuesRequest const &, Options)

Reads Feature values of a specific entity of an EntityType.

For reading feature values of multiple entities of an EntityType, please use StreamingReadFeatureValues.

Parameters
NameDescription
request google::cloud::aiplatform::v1::ReadFeatureValuesRequest const &

Unary RPCs, such as the one wrapped by this function, receive a single request proto message which includes all the inputs for the RPC. In this case, the proto message is a google.cloud.aiplatform.v1.ReadFeatureValuesRequest. Proto messages are converted to C++ classes by Protobuf, using the Protobuf mapping rules.

opts Options

Optional. Override the class-level options, such as retry and backoff policies.

Returns
TypeDescription
StatusOr< google::cloud::aiplatform::v1::ReadFeatureValuesResponse >

the result of the RPC. The response message type (google.cloud.aiplatform.v1.ReadFeatureValuesResponse) is mapped to a C++ class using the Protobuf mapping rules. If the request fails, the StatusOr contains the error details.

StreamingReadFeatureValues(std::string const &, Options)

Reads Feature values for multiple entities.

Depending on their size, data for different entities may be broken up across multiple responses.

Parameters
NameDescription
entity_type std::string const &

Required. The resource name of the entities' type. Value format: projects/{project}/locations/{location}/featurestores/{featurestore}/entityTypes/{entityType}. For example, for a machine learning model predicting user clicks on a website, an EntityType ID could be user.

opts Options

Optional. Override the class-level options, such as retry and backoff policies.

Returns
TypeDescription
StreamRange< google::cloud::aiplatform::v1::ReadFeatureValuesResponse >

the result of the RPC. The response message type (google.cloud.aiplatform.v1.ReadFeatureValuesResponse) is mapped to a C++ class using the Protobuf mapping rules. If the request fails, the StatusOr contains the error details.

StreamingReadFeatureValues(google::cloud::aiplatform::v1::StreamingReadFeatureValuesRequest const &, Options)

Reads Feature values for multiple entities.

Depending on their size, data for different entities may be broken up across multiple responses.

Parameters
NameDescription
request google::cloud::aiplatform::v1::StreamingReadFeatureValuesRequest const &

Unary RPCs, such as the one wrapped by this function, receive a single request proto message which includes all the inputs for the RPC. In this case, the proto message is a google.cloud.aiplatform.v1.StreamingReadFeatureValuesRequest. Proto messages are converted to C++ classes by Protobuf, using the Protobuf mapping rules.

opts Options

Optional. Override the class-level options, such as retry and backoff policies.

Returns
TypeDescription
StreamRange< google::cloud::aiplatform::v1::ReadFeatureValuesResponse >

the result of the RPC. The response message type (google.cloud.aiplatform.v1.ReadFeatureValuesResponse) is mapped to a C++ class using the Protobuf mapping rules. If the request fails, the StatusOr contains the error details.

WriteFeatureValues(std::string const &, std::vector< google::cloud::aiplatform::v1::WriteFeatureValuesPayload > const &, Options)

Writes Feature values of one or more entities of an EntityType.

The Feature values are merged into existing entities if any. The Feature values to be written must have timestamp within the online storage retention.

Parameters
NameDescription
entity_type std::string const &

Required. The resource name of the EntityType for the entities being written. Value format: projects/{project}/locations/{location}/featurestores/ {featurestore}/entityTypes/{entityType}. For example, for a machine learning model predicting user clicks on a website, an EntityType ID could be user.

payloads std::vector< google::cloud::aiplatform::v1::WriteFeatureValuesPayload > const &

Required. The entities to be written. Up to 100,000 feature values can be written across all payloads.

opts Options

Optional. Override the class-level options, such as retry and backoff policies.

Returns
TypeDescription
StatusOr< google::cloud::aiplatform::v1::WriteFeatureValuesResponse >

the result of the RPC. The response message type (google.cloud.aiplatform.v1.WriteFeatureValuesResponse) is mapped to a C++ class using the Protobuf mapping rules. If the request fails, the StatusOr contains the error details.

WriteFeatureValues(google::cloud::aiplatform::v1::WriteFeatureValuesRequest const &, Options)

Writes Feature values of one or more entities of an EntityType.

The Feature values are merged into existing entities if any. The Feature values to be written must have timestamp within the online storage retention.

Parameters
NameDescription
request google::cloud::aiplatform::v1::WriteFeatureValuesRequest const &

Unary RPCs, such as the one wrapped by this function, receive a single request proto message which includes all the inputs for the RPC. In this case, the proto message is a google.cloud.aiplatform.v1.WriteFeatureValuesRequest. Proto messages are converted to C++ classes by Protobuf, using the Protobuf mapping rules.

opts Options

Optional. Override the class-level options, such as retry and backoff policies.

Returns
TypeDescription
StatusOr< google::cloud::aiplatform::v1::WriteFeatureValuesResponse >

the result of the RPC. The response message type (google.cloud.aiplatform.v1.WriteFeatureValuesResponse) is mapped to a C++ class using the Protobuf mapping rules. If the request fails, the StatusOr contains the error details.