CTTY opened a new pull request, #1657:
URL: https://github.com/apache/iceberg-rust/pull/1657

   ## Which issue does this PR close?
   
   <!--
   We generally require a GitHub issue to be filed for all bug fixes and 
enhancements and this helps us generate change logs for our releases. You can 
link an issue to this PR using the GitHub syntax. For example `Closes #123` 
indicates that this PR will close issue #123.
   -->
   
   - Closes #1650
   
   ## What changes are included in this PR?
   Refactored the writer layers; from a bird’s-eye view, the structure now 
looks like this:
   ```mermaid
   flowchart TD
       subgraph PartitioningWriter
           PW[PartitioningWriter]
   
           subgraph RollingWriter
               RW[RollingWriter]
   
               subgraph DataFileWriter
                   DFW[DataFileWriter]
   
                   subgraph FileWriter
                       FW[FileWriter]
                   end
   
                   DFW --> FW
               end
   
               RW --> DFW
           end
   
           PW --> RW
       end
   
   
   ```
   
   - __Modified Writer Interfaces__:
   
     - Updated the `FileWriterBuilder` and `IcebergWriterBuilder` interfaces to 
accept an `OutputFile` parameter in their `build` methods
     - Added a new `PartitioningWriter` trait in `writer/mod.rs` with methods 
for writing to multiple partitions (not implemented yet, we can use a separate 
PR to add this trait if needed)
   
   - __Transformed RollingFileWriter to RollingWriter__:
   
     - Renamed `RollingFileWriter` to `RollingWriter` and significantly 
enhanced its capabilities
     - Changed from implementing `FileWriter` to being a standalone writer that 
uses `IcebergWriterBuilder`
     - Added support for location generation and file naming within the writer 
itself
     - Made it generic over `IcebergWriterBuilder`, `LocationGenerator`, and 
`FileNameGenerator`
     - Added methods to create new writers for partitions
   
   - __Updated ParquetWriter__:
   
     - Removed direct dependencies on `LocationGenerator` and 
`FileNameGenerator`
     - Renamed `out_file` to `output_file` for consistency
     - Simplified the interface to focus on writing to a provided output file
   
   - __Updated DataFileWriter and EqualityDeleteWriter__:
   
     - Modified to pass the `OutputFile` parameter to their inner writers
   
   - __Updated DataFusion Integration__:
   
     - Modified `IcebergWriteExec` to use the new `RollingWriter` directly 
instead of using builder patterns
     - Simplified the writer creation process in the execution plan
   
   <!--
   Provide a summary of the modifications in this PR. List the main changes 
such as new features, bug fixes, refactoring, or any other updates.
   -->
   
   ## Are these changes tested?
   Not yet, but changing the existing tests accordingly should be enough
   <!--
   Specify what test covers (unit test, integration test, etc.).
   
   If tests are not included in your PR, please explain why (for example, are 
they covered by existing tests)?
   -->


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to