Reference documentation and code samples for the google-cloud-bigquery class Google::Cloud::Bigquery::QueryJob::Stage.
Represents a stage in the execution plan for the query.
Inherits
- Object
Example
require "google/cloud/bigquery" bigquery = Google::Cloud::Bigquery.new sql = "SELECT word FROM `bigquery-public-data.samples.shakespeare`" job = bigquery.query_job sql job.wait_until_done! stages = job.query_plan stages.each do |stage| puts stage.name stage.steps.each do |step| puts step.kind puts step.substeps.inspect end end
Methods
#compute_ratio_avg
def compute_ratio_avg() -> Float
Relative amount of time the average shard spent on CPU-bound tasks.
- (Float) — the current value of compute_ratio_avg
#compute_ratio_max
def compute_ratio_max() -> Float
Relative amount of time the slowest shard spent on CPU-bound tasks.
- (Float) — the current value of compute_ratio_max
#id
def id() -> Integer
Unique ID for the stage within the query plan.
- (Integer) — the current value of id
#name
def name() -> String
Human-readable name for the stage.
- (String) — the current value of name
#read_ratio_avg
def read_ratio_avg() -> Float
Relative amount of time the average shard spent reading input.
- (Float) — the current value of read_ratio_avg
#read_ratio_max
def read_ratio_max() -> Float
Relative amount of time the slowest shard spent reading input.
- (Float) — the current value of read_ratio_max
#records_read
def records_read() -> Integer
Number of records read into the stage.
- (Integer) — the current value of records_read
#records_written
def records_written() -> Integer
Number of records written by the stage.
- (Integer) — the current value of records_written
#status
def status()
Returns the value of attribute status.
#steps
def steps() -> Array<Step>
List of operations within the stage in dependency order (approximately chronological).
- (Array<Step>) — the current value of steps
#wait_ratio_avg
def wait_ratio_avg() -> Float
Relative amount of time the average shard spent waiting to be scheduled.
- (Float) — the current value of wait_ratio_avg
#wait_ratio_max
def wait_ratio_max() -> Float
Relative amount of time the slowest shard spent waiting to be scheduled.
- (Float) — the current value of wait_ratio_max
#write_ratio_avg
def write_ratio_avg() -> Float
Relative amount of time the average shard spent on writing output.
- (Float) — the current value of write_ratio_avg
#write_ratio_max
def write_ratio_max() -> Float
Relative amount of time the slowest shard spent on writing output.
- (Float) — the current value of write_ratio_max