58 Status WriteAddedEntry(std::shared_ptr<DataFile> file,
59 std::optional<int64_t> data_sequence_number = std::nullopt);
74 Status WriteExistingEntry(std::shared_ptr<DataFile> file, int64_t file_snapshot_id,
75 int64_t data_sequence_number,
76 std::optional<int64_t> file_sequence_number = std::nullopt);
91 Status WriteDeletedEntry(std::shared_ptr<DataFile> file, int64_t data_sequence_number,
92 std::optional<int64_t> file_sequence_number = std::nullopt);
100 Status AddAll(
const std::vector<ManifestEntry>& entries);
110 Result<Metrics> metrics()
const;
114 Result<int64_t> length()
const;
118 Result<ManifestFile> ToManifestFile()
const;
132 static Result<std::unique_ptr<ManifestWriter>> MakeWriter(
133 int8_t format_version, std::optional<int64_t> snapshot_id,
134 std::string_view manifest_location, std::shared_ptr<FileIO> file_io,
135 std::shared_ptr<PartitionSpec> partition_spec,
136 std::shared_ptr<Schema> current_schema,
138 std::optional<int64_t> first_row_id = std::nullopt);
144 std::unique_ptr<class ManifestEntryAdapter> adapter,
145 std::string_view manifest_location, std::optional<int64_t> first_row_id);
147 Status CheckDataFile(
const DataFile& file)
const;
149 static constexpr int64_t kBatchSize = 1024;
150 std::unique_ptr<Writer> writer_;
151 std::unique_ptr<class ManifestEntryAdapter> adapter_;
153 std::string manifest_location_;
154 std::optional<int64_t> first_row_id_;
156 int32_t add_files_count_{0};
157 int32_t existing_files_count_{0};
158 int32_t delete_files_count_{0};
159 int64_t add_rows_count_{0L};
160 int64_t existing_rows_count_{0L};
161 int64_t delete_rows_count_{0L};
162 std::optional<int64_t> min_sequence_number_{std::nullopt};
163 std::unique_ptr<PartitionSummary> partition_summary_;
179 Status AddAll(
const std::vector<ManifestFile>& files);
185 std::optional<int64_t> next_row_id()
const;
198 static Result<std::unique_ptr<ManifestListWriter>> MakeWriter(
199 int8_t format_version, int64_t snapshot_id,
200 std::optional<int64_t> parent_snapshot_id, std::string_view manifest_list_location,
201 std::shared_ptr<FileIO> file_io,
202 std::optional<int64_t> sequence_number = std::nullopt,
203 std::optional<int64_t> first_row_id = std::nullopt);
209 std::unique_ptr<class ManifestFileAdapter> adapter);
211 static constexpr int64_t kBatchSize = 1024;
212 std::unique_ptr<Writer> writer_;
213 std::unique_ptr<class ManifestFileAdapter> adapter_;
DataFile carries data file path, partition tuple, metrics, ...
Definition manifest_entry.h:62
A manifest is an immutable Avro file that lists data files or delete files, along with each file's pa...
Definition manifest_entry.h:307