50 int64_t target_file_size_in_bytes);
62 std::optional<int64_t> data_sequence_number = std::nullopt);
76 int64_t data_sequence_number,
77 std::optional<int64_t> file_sequence_number = std::nullopt);
91 std::optional<int64_t> file_sequence_number = std::nullopt);
110 bool ShouldRollToNewFile()
const;
113 Status CloseCurrentWriter();
117 static constexpr int64_t kRowsDivisor = 250;
120 int64_t target_file_size_in_bytes_;
121 std::vector<ManifestFile> manifest_files_;
123 int64_t current_file_rows_{0};
124 std::unique_ptr<ManifestWriter> current_writer_{
nullptr};
A rolling manifest writer that can produce multiple manifest files.
Definition rolling_manifest_writer.h:38
Status WriteDeletedEntry(std::shared_ptr< DataFile > file, int64_t data_sequence_number, std::optional< int64_t > file_sequence_number=std::nullopt)
Add a delete entry for a file.
std::function< Result< std::unique_ptr< ManifestWriter > >()> ManifestWriterFactory
Factory function type for creating ManifestWriter instances.
Definition rolling_manifest_writer.h:41
Status WriteExistingEntry(std::shared_ptr< DataFile > file, int64_t file_snapshot_id, int64_t data_sequence_number, std::optional< int64_t > file_sequence_number=std::nullopt)
Add an existing entry for a file.
Result< std::vector< ManifestFile > > ToManifestFiles() const
Get the list of manifest files produced by this writer.
RollingManifestWriter(ManifestWriterFactory manifest_writer_factory, int64_t target_file_size_in_bytes)
Construct a rolling manifest writer.
Status WriteAddedEntry(std::shared_ptr< DataFile > file, std::optional< int64_t > data_sequence_number=std::nullopt)
Add an added entry for a file.
Status Close()
Close the rolling manifest writer.
Define symbol visibility macros for core Iceberg APIs.
Core Apache Iceberg C++ APIs.
Definition arrow_io_util.h:33
std::expected< T, E > Result
Result alias.
Definition result.h:88
Define Result, Status, and error helpers.