Merged
Conversation
- Add OrcFileFragment class extending FileFragment with ORC-specific predicate pushdown - Add StripeStatisticsCache structure for caching stripe-level statistics expressions - Add OrcCacheStatus enum for tracking metadata loading state - Implement public API: stripes(), metadata(), EnsureCompleteMetadata(), Subset(), SplitByStripe() - Add private methods: FilterStripes(), TestStripes(), TryCountRows() (stubs for later tasks) - Mirror ParquetFileFragment structure adapted for ORC stripes - Use void* for orc::Reader to avoid exposing ORC headers in public API - Thread-safe with mutex locking following Fragment base class pattern Implementation notes: - stripes_ replaces Parquet's row_groups_ - statistics_cache_ stores per-stripe guarantee expressions - Forward declarations for ORC types to minimize header dependencies - Most methods are stubs marked with TODO for subsequent tasks Verified: Manual code review following Parquet reference patterns Co-Authored-By: Claude Sonnet 4.5 <[email protected]>
02686fe to
79710d0
Compare
cbb330
added a commit
that referenced
this pull request
Feb 20, 2026
- Added BuildOrcSchemaManifest function to build schema manifest from Arrow schema - Walks Arrow schema using depth-first pre-order traversal - Assigns ORC column indices starting from 1 (column 0 is root struct) - Handles container types: STRUCT, LIST, LARGE_LIST, MAP (marked as non-leaf) - Handles leaf types: primitives (marked as leaf with column index) - Recursively processes children for nested types - Foundation for GetOrcColumnIndex (Task 3) Verified: Code compiles with manifest builder function. Co-authored-by: Claude Sonnet 4.5 <[email protected]>
cbb330
added a commit
that referenced
this pull request
Feb 20, 2026
Main entry point for stripe filtering with predicate pushdown. Mirrors Parquet's FilterRowGroups pattern. Implementation: 1. Ensure complete metadata is loaded (file, manifest, statistics cache) 2. Call TestStripes to evaluate predicate against stripe statistics 3. Filter results to include only stripes where: - Predicate is satisfiable (not literal(false)) - Stripe is non-empty (num_rows > 0) 4. Return vector of selected stripe indices Stripes are skipped if: - The predicate simplifies to literal(false) given statistics - The stripe contains zero rows This function is called by: - ScanBatchesAsync (for scan optimization) - Subset (for fragment splitting) - TryCountRows (for count optimization) Verified: Mirrors cpp/src/arrow/dataset/file_parquet.cc FilterRowGroups (lines 918-931) Co-authored-by: Claude Sonnet 4.5 <[email protected]>
cbb330
added a commit
that referenced
this pull request
Feb 20, 2026
cbb330
added a commit
that referenced
this pull request
Feb 24, 2026
- Added BuildOrcSchemaManifest function to build schema manifest from Arrow schema - Walks Arrow schema using depth-first pre-order traversal - Assigns ORC column indices starting from 1 (column 0 is root struct) - Handles container types: STRUCT, LIST, LARGE_LIST, MAP (marked as non-leaf) - Handles leaf types: primitives (marked as leaf with column index) - Recursively processes children for nested types - Foundation for GetOrcColumnIndex (Task 3) Verified: Code compiles with manifest builder function. Co-authored-by: Claude Sonnet 4.5 <[email protected]>
cbb330
added a commit
that referenced
this pull request
Feb 24, 2026
Main entry point for stripe filtering with predicate pushdown. Mirrors Parquet's FilterRowGroups pattern. Implementation: 1. Ensure complete metadata is loaded (file, manifest, statistics cache) 2. Call TestStripes to evaluate predicate against stripe statistics 3. Filter results to include only stripes where: - Predicate is satisfiable (not literal(false)) - Stripe is non-empty (num_rows > 0) 4. Return vector of selected stripe indices Stripes are skipped if: - The predicate simplifies to literal(false) given statistics - The stripe contains zero rows This function is called by: - ScanBatchesAsync (for scan optimization) - Subset (for fragment splitting) - TryCountRows (for count optimization) Verified: Mirrors cpp/src/arrow/dataset/file_parquet.cc FilterRowGroups (lines 918-931) Co-authored-by: Claude Sonnet 4.5 <[email protected]>
cbb330
added a commit
that referenced
this pull request
Feb 24, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Implements OrcFileFragment class with ORC-specific predicate pushdown capabilities.
Changes
Implementation Details
Testing
Manual code review following Parquet reference patterns
Task Reference
Completes Task #4 from task_list.json
Depends on: Task #1 (OrcSchemaManifest - complete)
Enables: Tasks #5, #6 (next in dependency chain)