Skip to content

BigQuery - No way to create a Job from just a Job ID without doing an RPC to create one. #1258

@tswast

Description

@tswast

I wanted to create a Job object for a JobId of a job that doesn't exist. This was to check the Job.exists() method. It also would be useful for an architecture where one process creates a job and then sends the job ID string to another process to check for the status.

It appears that there is no way to create a Job except for BigQuery.create http://googlecloudplatform.github.io/google-cloud-java/0.3.0/apidocs/index.html

All the builder constructors and actual constructors are package-private.
http://googlecloudplatform.github.io/google-cloud-java/0.3.0/apidocs/com/google/cloud/bigquery/Job.html

I tried using some of the of() methods inherited from JobInfo but the compiler complained that they returned a JobInfo, not a Job.

CC @lesv

Metadata

Metadata

Assignees

Labels

api: bigqueryIssues related to the BigQuery API.type: feature request‘Nice-to-have’ improvement, new feature or different behavior or design.

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions