OrcFileMetrics

Struct OrcFileMetrics 

Source
pub struct OrcFileMetrics {
    pub bytes_scanned: Count,
    pub file_size: Count,
    pub io_requests: Count,
    pub metadata_load_time: Time,
    pub stripes_pruned_statistics: PruningMetrics,
    pub statistics_eval_time: Time,
    pub predicate_evaluation_errors: Count,
    pub pushdown_rows_pruned: Count,
    pub pushdown_rows_matched: Count,
    pub decode_time: Time,
    pub rows_decoded: Count,
    pub batches_produced: Count,
}
Expand description

Metrics for ORC file operations.

Tracks performance statistics for reading ORC files, including I/O, metadata loading, stripe pruning, and predicate evaluation.

Fields§

§bytes_scanned: Count

Total number of bytes scanned from the file.

This includes all data read from the object store, including metadata, stripe data, and index data.

§file_size: Count

Total file size in bytes (for calculating scan efficiency).

§io_requests: Count

Number of I/O requests made to the object store.

§metadata_load_time: Time

Time spent reading and parsing ORC file metadata (footer, postscript).

§stripes_pruned_statistics: PruningMetrics

Number of stripes pruned or matched by statistics.

This uses PruningMetrics which tracks both pruned and matched counts.

  • pruned: Stripes skipped due to statistics not matching the predicate
  • matched: Stripes that were read because they might contain matching rows
§statistics_eval_time: Time

Time spent evaluating stripe-level statistics for pruning.

§predicate_evaluation_errors: Count

Number of times predicate evaluation encountered errors.

This can happen when statistics are malformed or when the predicate cannot be evaluated against the available metadata.

§pushdown_rows_pruned: Count

Number of rows filtered out by predicates pushed into the ORC scan.

§pushdown_rows_matched: Count

Number of rows that passed predicates pushed into the ORC scan.

§decode_time: Time

Time spent decoding ORC data into Arrow arrays.

§rows_decoded: Count

Total number of rows decoded from the file.

§batches_produced: Count

Number of RecordBatches produced.

Implementations§

Source§

impl OrcFileMetrics

Source

pub fn new( partition: usize, filename: &str, metrics: &ExecutionPlanMetricsSet, ) -> Self

Create new ORC file metrics.

§Arguments
  • partition - The partition index for this scan
  • filename - The name of the ORC file being scanned
  • metrics - The metrics set to register metrics with
Source

pub fn scan_efficiency(&self) -> Option<f64>

Calculate the scan efficiency ratio.

Returns the ratio of bytes scanned to total file size.

  • 1.0 = entire file was read
  • 0.5 = half the file was read (due to projection/filtering)
  • 0.0 = no data read (all stripes pruned)

Returns None if file size is zero.

Trait Implementations§

Source§

impl Clone for OrcFileMetrics

Source§

fn clone(&self) -> OrcFileMetrics

Returns a duplicate of the value. Read more
1.0.0 · Source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
Source§

impl Debug for OrcFileMetrics

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more

Auto Trait Implementations§

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> CloneToUninit for T
where T: Clone,

Source§

unsafe fn clone_to_uninit(&self, dest: *mut u8)

🔬This is a nightly-only experimental API. (clone_to_uninit)
Performs copy-assignment from self to dest. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T> IntoEither for T

Source§

fn into_either(self, into_left: bool) -> Either<Self, Self>

Converts self into a Left variant of Either<Self, Self> if into_left is true. Converts self into a Right variant of Either<Self, Self> otherwise. Read more
Source§

fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
where F: FnOnce(&Self) -> bool,

Converts self into a Left variant of Either<Self, Self> if into_left(&self) returns true. Converts self into a Right variant of Either<Self, Self> otherwise. Read more
Source§

impl<T> ToOwned for T
where T: Clone,

Source§

type Owned = T

The resulting type after obtaining ownership.
Source§

fn to_owned(&self) -> T

Creates owned data from borrowed data, usually by cloning. Read more
Source§

fn clone_into(&self, target: &mut T)

Uses borrowed data to replace owned data, usually by cloning. Read more
Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = Infallible

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.
Source§

impl<V, T> VZip<V> for T
where V: MultiLane<T>,

Source§

fn vzip(self) -> V

Source§

impl<T> Allocation for T
where T: RefUnwindSafe + Send + Sync,