This is an experimental RPC service definition for the BigQuery Job Service.
It should not be relied on for production use cases at this time.
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
JobServiceClient(JobServiceClient const &)
Copy and move support
Parameter | |
---|---|
Name | Description |
|
JobServiceClient const &
|
JobServiceClient(JobServiceClient &&)
Copy and move support
Parameter | |
---|---|
Name | Description |
|
JobServiceClient &&
|
JobServiceClient(std::shared_ptr< JobServiceConnection >, Options)
Parameters | |
---|---|
Name | Description |
connection |
std::shared_ptr< JobServiceConnection >
|
opts |
Options
|
Operators
operator=(JobServiceClient const &)
Copy and move support
Parameter | |
---|---|
Name | Description |
|
JobServiceClient const &
|
Returns | |
---|---|
Type | Description |
JobServiceClient & |
operator=(JobServiceClient &&)
Copy and move support
Parameter | |
---|---|
Name | Description |
|
JobServiceClient &&
|
Returns | |
---|---|
Type | Description |
JobServiceClient & |
Functions
CancelJob(google::cloud::bigquery::v2::CancelJobRequest const &, Options)
Requests that a job be cancelled.
This call will return immediately, and the client will need to poll for the job status to see if the cancel completed successfully. Cancelled jobs may still incur costs.
Parameters | |
---|---|
Name | Description |
request |
google::cloud::bigquery::v2::CancelJobRequest const &
Unary RPCs, such as the one wrapped by this function, receive a single |
opts |
Options
Optional. Override the class-level options, such as retry and backoff policies. |
Returns | |
---|---|
Type | Description |
StatusOr< google::cloud::bigquery::v2::JobCancelResponse > |
the result of the RPC. The response message type (google.cloud.bigquery.v2.JobCancelResponse) is mapped to a C++ class using the Protobuf mapping rules. If the request fails, the |
GetJob(google::cloud::bigquery::v2::GetJobRequest const &, Options)
Returns information about a specific job.
Job information is available for a six month period after creation. Requires that you're the person who ran the job, or have the Is Owner project role.
Parameters | |
---|---|
Name | Description |
request |
google::cloud::bigquery::v2::GetJobRequest const &
Unary RPCs, such as the one wrapped by this function, receive a single |
opts |
Options
Optional. Override the class-level options, such as retry and backoff policies. |
Returns | |
---|---|
Type | Description |
StatusOr< google::cloud::bigquery::v2::Job > |
the result of the RPC. The response message type (google.cloud.bigquery.v2.Job) is mapped to a C++ class using the Protobuf mapping rules. If the request fails, the |
InsertJob(google::cloud::bigquery::v2::InsertJobRequest const &, Options)
Starts a new asynchronous job.
This API has two different kinds of endpoint URIs, as this method supports a variety of use cases.
- The Metadata URI is used for most interactions, as it accepts the job configuration directly.
- The Upload URI is ONLY for the case when you're sending both a load job configuration and a data stream together. In this case, the Upload URI accepts the job configuration and the data as two distinct multipart MIME parts.
Parameters | |
---|---|
Name | Description |
request |
google::cloud::bigquery::v2::InsertJobRequest const &
Unary RPCs, such as the one wrapped by this function, receive a single |
opts |
Options
Optional. Override the class-level options, such as retry and backoff policies. |
Returns | |
---|---|
Type | Description |
StatusOr< google::cloud::bigquery::v2::Job > |
the result of the RPC. The response message type (google.cloud.bigquery.v2.Job) is mapped to a C++ class using the Protobuf mapping rules. If the request fails, the |
DeleteJob(google::cloud::bigquery::v2::DeleteJobRequest const &, Options)
Requests the deletion of the metadata of a job.
This call returns when the job's metadata is deleted.
Parameters | |
---|---|
Name | Description |
request |
google::cloud::bigquery::v2::DeleteJobRequest const &
Unary RPCs, such as the one wrapped by this function, receive a single |
opts |
Options
Optional. Override the class-level options, such as retry and backoff policies. |
Returns | |
---|---|
Type | Description |
Status |
a |
ListJobs(google::cloud::bigquery::v2::ListJobsRequest, Options)
Lists all jobs that you started in the specified project.
Job information is available for a six month period after creation. The job list is sorted in reverse chronological order, by job creation time. Requires the Can View project role, or the Is Owner project role if you set the allUsers property.
Parameters | |
---|---|
Name | Description |
request |
google::cloud::bigquery::v2::ListJobsRequest
Unary RPCs, such as the one wrapped by this function, receive a single |
opts |
Options
Optional. Override the class-level options, such as retry and backoff policies. |
Returns | |
---|---|
Type | Description |
StreamRange< google::cloud::bigquery::v2::ListFormatJob > |
a StreamRange to iterate of the results. See the documentation of this type for details. In brief, this class has |
GetQueryResults(google::cloud::bigquery::v2::GetQueryResultsRequest const &, Options)
RPC to get the results of a query job.
Parameters | |
---|---|
Name | Description |
request |
google::cloud::bigquery::v2::GetQueryResultsRequest const &
Unary RPCs, such as the one wrapped by this function, receive a single |
opts |
Options
Optional. Override the class-level options, such as retry and backoff policies. |
Returns | |
---|---|
Type | Description |
StatusOr< google::cloud::bigquery::v2::GetQueryResultsResponse > |
the result of the RPC. The response message type (google.cloud.bigquery.v2.GetQueryResultsResponse) is mapped to a C++ class using the Protobuf mapping rules. If the request fails, the |
Query(google::cloud::bigquery::v2::PostQueryRequest const &, Options)
Runs a BigQuery SQL query synchronously and returns query results if the query completes within a specified timeout.
Parameters | |
---|---|
Name | Description |
request |
google::cloud::bigquery::v2::PostQueryRequest const &
Unary RPCs, such as the one wrapped by this function, receive a single |
opts |
Options
Optional. Override the class-level options, such as retry and backoff policies. |
Returns | |
---|---|
Type | Description |
StatusOr< google::cloud::bigquery::v2::QueryResponse > |
the result of the RPC. The response message type (google.cloud.bigquery.v2.QueryResponse) is mapped to a C++ class using the Protobuf mapping rules. If the request fails, the |