Class DataprocMetastoreClient (2.23.0-rc)

Configures and manages metastore services.

Metastore services are fully managed, highly available, autoscaled, autohealing, OSS-native deployments of technical metadata management software. Each metastore service exposes a network endpoint through which metadata queries are served. Metadata queries can originate from a variety of sources, including Apache Hive, Apache Presto, and Apache Spark.

The Dataproc Metastore API defines the following resource model:

  • The service works with a collection of Google Cloud projects, named: /projects/*
  • Each project has a collection of available locations, named: /locations/* (a location must refer to a Google Cloud region)
  • Each location has a collection of services, named: /services/*
  • Dataproc Metastore services are resources with names of the form:

    /projects/{project_number}/locations/{location_id}/services/{service_id}.

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

DataprocMetastoreClient(DataprocMetastoreClient const &)

Copy and move support

Parameter
NameDescription
DataprocMetastoreClient const &

DataprocMetastoreClient(DataprocMetastoreClient &&)

Copy and move support

Parameter
NameDescription
DataprocMetastoreClient &&

DataprocMetastoreClient(std::shared_ptr< DataprocMetastoreConnection >, Options)

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

Operators

operator=(DataprocMetastoreClient const &)

Copy and move support

Parameter
NameDescription
DataprocMetastoreClient const &
Returns
TypeDescription
DataprocMetastoreClient &

operator=(DataprocMetastoreClient &&)

Copy and move support

Parameter
NameDescription
DataprocMetastoreClient &&
Returns
TypeDescription
DataprocMetastoreClient &

Functions

ListServices(std::string const &, Options)

Lists services in a project and location.

Parameters
NameDescription
parent std::string const &

Required. The relative resource name of the location of metastore services to list, in the following form:
projects/{project_number}/locations/{location_id}.

opts Options

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

Returns
TypeDescription
StreamRange< google::cloud::metastore::v1::Service >

a StreamRange to iterate of the results. See the documentation of this type for details. In brief, this class has begin() and end() member functions returning a iterator class meeting the input iterator requirements. The value type for this iterator is a StatusOr as the iteration may fail even after some values are retrieved successfully, for example, if there is a network disconnect. An empty set of results does not indicate an error, it indicates that there are no resources meeting the request criteria. On a successful iteration the StatusOr<T> contains elements of type google.cloud.metastore.v1.Service, or rather, the C++ class generated by Protobuf from that type. Please consult the Protobuf documentation for details on the Protobuf mapping rules.

ListServices(google::cloud::metastore::v1::ListServicesRequest, Options)

Lists services in a project and location.

Parameters
NameDescription
request google::cloud::metastore::v1::ListServicesRequest

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.metastore.v1.ListServicesRequest. 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::metastore::v1::Service >

a StreamRange to iterate of the results. See the documentation of this type for details. In brief, this class has begin() and end() member functions returning a iterator class meeting the input iterator requirements. The value type for this iterator is a StatusOr as the iteration may fail even after some values are retrieved successfully, for example, if there is a network disconnect. An empty set of results does not indicate an error, it indicates that there are no resources meeting the request criteria. On a successful iteration the StatusOr<T> contains elements of type google.cloud.metastore.v1.Service, or rather, the C++ class generated by Protobuf from that type. Please consult the Protobuf documentation for details on the Protobuf mapping rules.

GetService(std::string const &, Options)

Gets the details of a single service.

Parameters
NameDescription
name std::string const &

Required. The relative resource name of the metastore service to retrieve, in the following form:
projects/{project_number}/locations/{location_id}/services/{service_id}.

opts Options

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

Returns
TypeDescription
StatusOr< google::cloud::metastore::v1::Service >

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

GetService(google::cloud::metastore::v1::GetServiceRequest const &, Options)

Gets the details of a single service.

Parameters
NameDescription
request google::cloud::metastore::v1::GetServiceRequest 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.metastore.v1.GetServiceRequest. 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::metastore::v1::Service >

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

CreateService(std::string const &, google::cloud::metastore::v1::Service const &, std::string const &, Options)

Creates a metastore service in a project and location.

Parameters
NameDescription
parent std::string const &

Required. The relative resource name of the location in which to create a metastore service, in the following form:
projects/{project_number}/locations/{location_id}.

service google::cloud::metastore::v1::Service const &

Required. The Metastore service to create. The name field is ignored. The ID of the created metastore service must be provided in the request's service_id field.

service_id std::string const &

Required. The ID of the metastore service, which is used as the final component of the metastore service's name.
This value must be between 2 and 63 characters long inclusive, begin with a letter, end with a letter or number, and consist of alpha-numeric ASCII characters or hyphens.

opts Options

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

Returns
TypeDescription
future< StatusOr< google::cloud::metastore::v1::Service > >

A future that becomes satisfied when the LRO (Long Running Operation) completes or the polling policy in effect for this call is exhausted. The future is satisfied with an error if the LRO completes with an error or the polling policy is exhausted. In this case the StatusOr returned by the future contains the error. If the LRO completes successfully the value of the future contains the LRO's result. For this RPC the result is a google.cloud.metastore.v1.Service proto message. The C++ class representing this message is created by Protobuf, using the Protobuf mapping rules.

CreateService(google::cloud::metastore::v1::CreateServiceRequest const &, Options)

Creates a metastore service in a project and location.

Parameters
NameDescription
request google::cloud::metastore::v1::CreateServiceRequest 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.metastore.v1.CreateServiceRequest. 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
future< StatusOr< google::cloud::metastore::v1::Service > >

A future that becomes satisfied when the LRO (Long Running Operation) completes or the polling policy in effect for this call is exhausted. The future is satisfied with an error if the LRO completes with an error or the polling policy is exhausted. In this case the StatusOr returned by the future contains the error. If the LRO completes successfully the value of the future contains the LRO's result. For this RPC the result is a google.cloud.metastore.v1.Service proto message. The C++ class representing this message is created by Protobuf, using the Protobuf mapping rules.

UpdateService(google::cloud::metastore::v1::Service const &, google::protobuf::FieldMask const &, Options)

Updates the parameters of a single service.

Parameters
NameDescription
service google::cloud::metastore::v1::Service const &

Required. The metastore service to update. The server only merges fields in the service if they are specified in update_mask.
The metastore service's name field is used to identify the metastore service to be updated.

update_mask google::protobuf::FieldMask const &

Required. A field mask used to specify the fields to be overwritten in the metastore service resource by the update. Fields specified in the update_mask are relative to the resource (not to the full request). A field is overwritten if it is in the mask.

opts Options

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

Returns
TypeDescription
future< StatusOr< google::cloud::metastore::v1::Service > >

A future that becomes satisfied when the LRO (Long Running Operation) completes or the polling policy in effect for this call is exhausted. The future is satisfied with an error if the LRO completes with an error or the polling policy is exhausted. In this case the StatusOr returned by the future contains the error. If the LRO completes successfully the value of the future contains the LRO's result. For this RPC the result is a google.cloud.metastore.v1.Service proto message. The C++ class representing this message is created by Protobuf, using the Protobuf mapping rules.

UpdateService(google::cloud::metastore::v1::UpdateServiceRequest const &, Options)

Updates the parameters of a single service.

Parameters
NameDescription
request google::cloud::metastore::v1::UpdateServiceRequest 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.metastore.v1.UpdateServiceRequest. 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
future< StatusOr< google::cloud::metastore::v1::Service > >

A future that becomes satisfied when the LRO (Long Running Operation) completes or the polling policy in effect for this call is exhausted. The future is satisfied with an error if the LRO completes with an error or the polling policy is exhausted. In this case the StatusOr returned by the future contains the error. If the LRO completes successfully the value of the future contains the LRO's result. For this RPC the result is a google.cloud.metastore.v1.Service proto message. The C++ class representing this message is created by Protobuf, using the Protobuf mapping rules.

DeleteService(std::string const &, Options)

Deletes a single service.

Parameters
NameDescription
name std::string const &

Required. The relative resource name of the metastore service to delete, in the following form:
projects/{project_number}/locations/{location_id}/services/{service_id}.

opts Options

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

Returns
TypeDescription
future< StatusOr< google::cloud::metastore::v1::OperationMetadata > >

A future that becomes satisfied when the LRO (Long Running Operation) completes or the polling policy in effect for this call is exhausted. The future is satisfied with an error if the LRO completes with an error or the polling policy is exhausted. In this case the StatusOr returned by the future contains the error. If the LRO completes successfully the value of the future contains the LRO's result. For this RPC the result is a google.cloud.metastore.v1.OperationMetadata proto message. The C++ class representing this message is created by Protobuf, using the Protobuf mapping rules.

DeleteService(google::cloud::metastore::v1::DeleteServiceRequest const &, Options)

Deletes a single service.

Parameters
NameDescription
request google::cloud::metastore::v1::DeleteServiceRequest 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.metastore.v1.DeleteServiceRequest. 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
future< StatusOr< google::cloud::metastore::v1::OperationMetadata > >

A future that becomes satisfied when the LRO (Long Running Operation) completes or the polling policy in effect for this call is exhausted. The future is satisfied with an error if the LRO completes with an error or the polling policy is exhausted. In this case the StatusOr returned by the future contains the error. If the LRO completes successfully the value of the future contains the LRO's result. For this RPC the result is a google.cloud.metastore.v1.OperationMetadata proto message. The C++ class representing this message is created by Protobuf, using the Protobuf mapping rules.

ListMetadataImports(std::string const &, Options)

Lists imports in a service.

Parameters
NameDescription
parent std::string const &

Required. The relative resource name of the service whose metadata imports to list, in the following form:
projects/{project_number}/locations/{location_id}/services/{service_id}/metadataImports.

opts Options

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

Returns
TypeDescription
StreamRange< google::cloud::metastore::v1::MetadataImport >

a StreamRange to iterate of the results. See the documentation of this type for details. In brief, this class has begin() and end() member functions returning a iterator class meeting the input iterator requirements. The value type for this iterator is a StatusOr as the iteration may fail even after some values are retrieved successfully, for example, if there is a network disconnect. An empty set of results does not indicate an error, it indicates that there are no resources meeting the request criteria. On a successful iteration the StatusOr<T> contains elements of type google.cloud.metastore.v1.MetadataImport, or rather, the C++ class generated by Protobuf from that type. Please consult the Protobuf documentation for details on the Protobuf mapping rules.

ListMetadataImports(google::cloud::metastore::v1::ListMetadataImportsRequest, Options)

Lists imports in a service.

Parameters
NameDescription
request google::cloud::metastore::v1::ListMetadataImportsRequest

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.metastore.v1.ListMetadataImportsRequest. 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::metastore::v1::MetadataImport >

a StreamRange to iterate of the results. See the documentation of this type for details. In brief, this class has begin() and end() member functions returning a iterator class meeting the input iterator requirements. The value type for this iterator is a StatusOr as the iteration may fail even after some values are retrieved successfully, for example, if there is a network disconnect. An empty set of results does not indicate an error, it indicates that there are no resources meeting the request criteria. On a successful iteration the StatusOr<T> contains elements of type google.cloud.metastore.v1.MetadataImport, or rather, the C++ class generated by Protobuf from that type. Please consult the Protobuf documentation for details on the Protobuf mapping rules.

GetMetadataImport(std::string const &, Options)

Gets details of a single import.

Parameters
NameDescription
name std::string const &

Required. The relative resource name of the metadata import to retrieve, in the following form:
projects/{project_number}/locations/{location_id}/services/{service_id}/metadataImports/{import_id}.

opts Options

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

Returns
TypeDescription
StatusOr< google::cloud::metastore::v1::MetadataImport >

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

GetMetadataImport(google::cloud::metastore::v1::GetMetadataImportRequest const &, Options)

Gets details of a single import.

Parameters
NameDescription
request google::cloud::metastore::v1::GetMetadataImportRequest 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.metastore.v1.GetMetadataImportRequest. 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::metastore::v1::MetadataImport >

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

CreateMetadataImport(std::string const &, google::cloud::metastore::v1::MetadataImport const &, std::string const &, Options)

Creates a new MetadataImport in a given project and location.

Parameters
NameDescription
parent std::string const &

Required. The relative resource name of the service in which to create a metastore import, in the following form:
projects/{project_number}/locations/{location_id}/services/{service_id}.

metadata_import google::cloud::metastore::v1::MetadataImport const &

Required. The metadata import to create. The name field is ignored. The ID of the created metadata import must be provided in the request's metadata_import_id field.

metadata_import_id std::string const &

Required. The ID of the metadata import, which is used as the final component of the metadata import's name.
This value must be between 1 and 64 characters long, begin with a letter, end with a letter or number, and consist of alpha-numeric ASCII characters or hyphens.

opts Options

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

Returns
TypeDescription
future< StatusOr< google::cloud::metastore::v1::MetadataImport > >

A future that becomes satisfied when the LRO (Long Running Operation) completes or the polling policy in effect for this call is exhausted. The future is satisfied with an error if the LRO completes with an error or the polling policy is exhausted. In this case the StatusOr returned by the future contains the error. If the LRO completes successfully the value of the future contains the LRO's result. For this RPC the result is a google.cloud.metastore.v1.MetadataImport proto message. The C++ class representing this message is created by Protobuf, using the Protobuf mapping rules.

CreateMetadataImport(google::cloud::metastore::v1::CreateMetadataImportRequest const &, Options)

Creates a new MetadataImport in a given project and location.

Parameters
NameDescription
request google::cloud::metastore::v1::CreateMetadataImportRequest 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.metastore.v1.CreateMetadataImportRequest. 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
future< StatusOr< google::cloud::metastore::v1::MetadataImport > >

A future that becomes satisfied when the LRO (Long Running Operation) completes or the polling policy in effect for this call is exhausted. The future is satisfied with an error if the LRO completes with an error or the polling policy is exhausted. In this case the StatusOr returned by the future contains the error. If the LRO completes successfully the value of the future contains the LRO's result. For this RPC the result is a google.cloud.metastore.v1.MetadataImport proto message. The C++ class representing this message is created by Protobuf, using the Protobuf mapping rules.

UpdateMetadataImport(google::cloud::metastore::v1::MetadataImport const &, google::protobuf::FieldMask const &, Options)

Updates a single import.

Only the description field of MetadataImport is supported to be updated.

Parameters
NameDescription
metadata_import google::cloud::metastore::v1::MetadataImport const &

Required. The metadata import to update. The server only merges fields in the import if they are specified in update_mask.
The metadata import's name field is used to identify the metastore import to be updated.

update_mask google::protobuf::FieldMask const &

Required. A field mask used to specify the fields to be overwritten in the metadata import resource by the update. Fields specified in the update_mask are relative to the resource (not to the full request). A field is overwritten if it is in the mask.

opts Options

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

Returns
TypeDescription
future< StatusOr< google::cloud::metastore::v1::MetadataImport > >

A future that becomes satisfied when the LRO (Long Running Operation) completes or the polling policy in effect for this call is exhausted. The future is satisfied with an error if the LRO completes with an error or the polling policy is exhausted. In this case the StatusOr returned by the future contains the error. If the LRO completes successfully the value of the future contains the LRO's result. For this RPC the result is a google.cloud.metastore.v1.MetadataImport proto message. The C++ class representing this message is created by Protobuf, using the Protobuf mapping rules.

UpdateMetadataImport(google::cloud::metastore::v1::UpdateMetadataImportRequest const &, Options)

Updates a single import.

Only the description field of MetadataImport is supported to be updated.

Parameters
NameDescription
request google::cloud::metastore::v1::UpdateMetadataImportRequest 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.metastore.v1.UpdateMetadataImportRequest. 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
future< StatusOr< google::cloud::metastore::v1::MetadataImport > >

A future that becomes satisfied when the LRO (Long Running Operation) completes or the polling policy in effect for this call is exhausted. The future is satisfied with an error if the LRO completes with an error or the polling policy is exhausted. In this case the StatusOr returned by the future contains the error. If the LRO completes successfully the value of the future contains the LRO's result. For this RPC the result is a google.cloud.metastore.v1.MetadataImport proto message. The C++ class representing this message is created by Protobuf, using the Protobuf mapping rules.

ExportMetadata(google::cloud::metastore::v1::ExportMetadataRequest const &, Options)

Exports metadata from a service.

Parameters
NameDescription
request google::cloud::metastore::v1::ExportMetadataRequest 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.metastore.v1.ExportMetadataRequest. 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
future< StatusOr< google::cloud::metastore::v1::MetadataExport > >

A future that becomes satisfied when the LRO (Long Running Operation) completes or the polling policy in effect for this call is exhausted. The future is satisfied with an error if the LRO completes with an error or the polling policy is exhausted. In this case the StatusOr returned by the future contains the error. If the LRO completes successfully the value of the future contains the LRO's result. For this RPC the result is a google.cloud.metastore.v1.MetadataExport proto message. The C++ class representing this message is created by Protobuf, using the Protobuf mapping rules.

RestoreService(std::string const &, std::string const &, Options)

Restores a service from a backup.

Parameters
NameDescription
service std::string const &

Required. The relative resource name of the metastore service to run restore, in the following form:
projects/{project_id}/locations/{location_id}/services/{service_id}.

backup std::string const &

Required. The relative resource name of the metastore service backup to restore from, in the following form:
projects/{project_id}/locations/{location_id}/services/{service_id}/backups/{backup_id}.

opts Options

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

Returns
TypeDescription
future< StatusOr< google::cloud::metastore::v1::Restore > >

A future that becomes satisfied when the LRO (Long Running Operation) completes or the polling policy in effect for this call is exhausted. The future is satisfied with an error if the LRO completes with an error or the polling policy is exhausted. In this case the StatusOr returned by the future contains the error. If the LRO completes successfully the value of the future contains the LRO's result. For this RPC the result is a google.cloud.metastore.v1.Restore proto message. The C++ class representing this message is created by Protobuf, using the Protobuf mapping rules.

RestoreService(google::cloud::metastore::v1::RestoreServiceRequest const &, Options)

Restores a service from a backup.

Parameters
NameDescription
request google::cloud::metastore::v1::RestoreServiceRequest 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.metastore.v1.RestoreServiceRequest. 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
future< StatusOr< google::cloud::metastore::v1::Restore > >

A future that becomes satisfied when the LRO (Long Running Operation) completes or the polling policy in effect for this call is exhausted. The future is satisfied with an error if the LRO completes with an error or the polling policy is exhausted. In this case the StatusOr returned by the future contains the error. If the LRO completes successfully the value of the future contains the LRO's result. For this RPC the result is a google.cloud.metastore.v1.Restore proto message. The C++ class representing this message is created by Protobuf, using the Protobuf mapping rules.

ListBackups(std::string const &, Options)

Lists backups in a service.

Parameters
NameDescription
parent std::string const &

Required. The relative resource name of the service whose backups to list, in the following form:
projects/{project_number}/locations/{location_id}/services/{service_id}/backups.

opts Options

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

Returns
TypeDescription
StreamRange< google::cloud::metastore::v1::Backup >

a StreamRange to iterate of the results. See the documentation of this type for details. In brief, this class has begin() and end() member functions returning a iterator class meeting the input iterator requirements. The value type for this iterator is a StatusOr as the iteration may fail even after some values are retrieved successfully, for example, if there is a network disconnect. An empty set of results does not indicate an error, it indicates that there are no resources meeting the request criteria. On a successful iteration the StatusOr<T> contains elements of type google.cloud.metastore.v1.Backup, or rather, the C++ class generated by Protobuf from that type. Please consult the Protobuf documentation for details on the Protobuf mapping rules.

ListBackups(google::cloud::metastore::v1::ListBackupsRequest, Options)

Lists backups in a service.

Parameters
NameDescription
request google::cloud::metastore::v1::ListBackupsRequest

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.metastore.v1.ListBackupsRequest. 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::metastore::v1::Backup >

a StreamRange to iterate of the results. See the documentation of this type for details. In brief, this class has begin() and end() member functions returning a iterator class meeting the input iterator requirements. The value type for this iterator is a StatusOr as the iteration may fail even after some values are retrieved successfully, for example, if there is a network disconnect. An empty set of results does not indicate an error, it indicates that there are no resources meeting the request criteria. On a successful iteration the StatusOr<T> contains elements of type google.cloud.metastore.v1.Backup, or rather, the C++ class generated by Protobuf from that type. Please consult the Protobuf documentation for details on the Protobuf mapping rules.

GetBackup(std::string const &, Options)

Gets details of a single backup.

Parameters
NameDescription
name std::string const &

Required. The relative resource name of the backup to retrieve, in the following form:
projects/{project_number}/locations/{location_id}/services/{service_id}/backups/{backup_id}.

opts Options

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

Returns
TypeDescription
StatusOr< google::cloud::metastore::v1::Backup >

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

GetBackup(google::cloud::metastore::v1::GetBackupRequest const &, Options)

Gets details of a single backup.

Parameters
NameDescription
request google::cloud::metastore::v1::GetBackupRequest 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.metastore.v1.GetBackupRequest. 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::metastore::v1::Backup >

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

CreateBackup(std::string const &, google::cloud::metastore::v1::Backup const &, std::string const &, Options)

Creates a new backup in a given project and location.

Parameters
NameDescription
parent std::string const &

Required. The relative resource name of the service in which to create a backup of the following form:
projects/{project_number}/locations/{location_id}/services/{service_id}.

backup google::cloud::metastore::v1::Backup const &

Required. The backup to create. The name field is ignored. The ID of the created backup must be provided in the request's backup_id field.

backup_id std::string const &

Required. The ID of the backup, which is used as the final component of the backup's name.
This value must be between 1 and 64 characters long, begin with a letter, end with a letter or number, and consist of alpha-numeric ASCII characters or hyphens.

opts Options

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

Returns
TypeDescription
future< StatusOr< google::cloud::metastore::v1::Backup > >

A future that becomes satisfied when the LRO (Long Running Operation) completes or the polling policy in effect for this call is exhausted. The future is satisfied with an error if the LRO completes with an error or the polling policy is exhausted. In this case the StatusOr returned by the future contains the error. If the LRO completes successfully the value of the future contains the LRO's result. For this RPC the result is a google.cloud.metastore.v1.Backup proto message. The C++ class representing this message is created by Protobuf, using the Protobuf mapping rules.

CreateBackup(google::cloud::metastore::v1::CreateBackupRequest const &, Options)

Creates a new backup in a given project and location.

Parameters
NameDescription
request google::cloud::metastore::v1::CreateBackupRequest 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.metastore.v1.CreateBackupRequest. 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
future< StatusOr< google::cloud::metastore::v1::Backup > >

A future that becomes satisfied when the LRO (Long Running Operation) completes or the polling policy in effect for this call is exhausted. The future is satisfied with an error if the LRO completes with an error or the polling policy is exhausted. In this case the StatusOr returned by the future contains the error. If the LRO completes successfully the value of the future contains the LRO's result. For this RPC the result is a google.cloud.metastore.v1.Backup proto message. The C++ class representing this message is created by Protobuf, using the Protobuf mapping rules.

DeleteBackup(std::string const &, Options)

Deletes a single backup.

Parameters
NameDescription
name std::string const &

Required. The relative resource name of the backup to delete, in the following form:
projects/{project_number}/locations/{location_id}/services/{service_id}/backups/{backup_id}.

opts Options

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

Returns
TypeDescription
future< StatusOr< google::cloud::metastore::v1::OperationMetadata > >

A future that becomes satisfied when the LRO (Long Running Operation) completes or the polling policy in effect for this call is exhausted. The future is satisfied with an error if the LRO completes with an error or the polling policy is exhausted. In this case the StatusOr returned by the future contains the error. If the LRO completes successfully the value of the future contains the LRO's result. For this RPC the result is a google.cloud.metastore.v1.OperationMetadata proto message. The C++ class representing this message is created by Protobuf, using the Protobuf mapping rules.

DeleteBackup(google::cloud::metastore::v1::DeleteBackupRequest const &, Options)

Deletes a single backup.

Parameters
NameDescription
request google::cloud::metastore::v1::DeleteBackupRequest 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.metastore.v1.DeleteBackupRequest. 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
future< StatusOr< google::cloud::metastore::v1::OperationMetadata > >

A future that becomes satisfied when the LRO (Long Running Operation) completes or the polling policy in effect for this call is exhausted. The future is satisfied with an error if the LRO completes with an error or the polling policy is exhausted. In this case the StatusOr returned by the future contains the error. If the LRO completes successfully the value of the future contains the LRO's result. For this RPC the result is a google.cloud.metastore.v1.OperationMetadata proto message. The C++ class representing this message is created by Protobuf, using the Protobuf mapping rules.

QueryMetadata(google::cloud::metastore::v1::QueryMetadataRequest const &, Options)

Query DPMS metadata.

Parameters
NameDescription
request google::cloud::metastore::v1::QueryMetadataRequest 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.metastore.v1.QueryMetadataRequest. 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
future< StatusOr< google::cloud::metastore::v1::QueryMetadataResponse > >

A future that becomes satisfied when the LRO (Long Running Operation) completes or the polling policy in effect for this call is exhausted. The future is satisfied with an error if the LRO completes with an error or the polling policy is exhausted. In this case the StatusOr returned by the future contains the error. If the LRO completes successfully the value of the future contains the LRO's result. For this RPC the result is a google.cloud.metastore.v1.QueryMetadataResponse proto message. The C++ class representing this message is created by Protobuf, using the Protobuf mapping rules.

MoveTableToDatabase(google::cloud::metastore::v1::MoveTableToDatabaseRequest const &, Options)

Move a table to another database.

Parameters
NameDescription
request google::cloud::metastore::v1::MoveTableToDatabaseRequest 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.metastore.v1.MoveTableToDatabaseRequest. 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
future< StatusOr< google::cloud::metastore::v1::MoveTableToDatabaseResponse > >

A future that becomes satisfied when the LRO (Long Running Operation) completes or the polling policy in effect for this call is exhausted. The future is satisfied with an error if the LRO completes with an error or the polling policy is exhausted. In this case the StatusOr returned by the future contains the error. If the LRO completes successfully the value of the future contains the LRO's result. For this RPC the result is a google.cloud.metastore.v1.MoveTableToDatabaseResponse proto message. The C++ class representing this message is created by Protobuf, using the Protobuf mapping rules.

AlterMetadataResourceLocation(google::cloud::metastore::v1::AlterMetadataResourceLocationRequest const &, Options)

Alter metadata resource location.

The metadata resource can be a database, table, or partition. This functionality only updates the parent directory for the respective metadata resource and does not transfer any existing data to the new location.

Parameters
NameDescription
request google::cloud::metastore::v1::AlterMetadataResourceLocationRequest 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.metastore.v1.AlterMetadataResourceLocationRequest. 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
future< StatusOr< google::cloud::metastore::v1::AlterMetadataResourceLocationResponse > >

A future that becomes satisfied when the LRO (Long Running Operation) completes or the polling policy in effect for this call is exhausted. The future is satisfied with an error if the LRO completes with an error or the polling policy is exhausted. In this case the StatusOr returned by the future contains the error. If the LRO completes successfully the value of the future contains the LRO's result. For this RPC the result is a google.cloud.metastore.v1.AlterMetadataResourceLocationResponse proto message. The C++ class representing this message is created by Protobuf, using the Protobuf mapping rules.