|
| Kind | kind () const override |
| | Return the kind of this pending update.
|
| |
| bool | IsRetryable () const override |
| | Whether this update can be retried after a commit conflict.
|
| |
| auto & | DeleteWith (this auto &self, std::function< Status(const std::string &)> delete_func) |
| | Set a callback to delete files instead of the table's default.
|
| |
| auto & | StageOnly (this auto &self) |
| | Stage a snapshot in table metadata, but not update the current snapshot id.
|
| |
| auto & | SetTargetBranch (this auto &self, const std::string &branch) |
| | Perform operations on a particular branch.
|
| |
| auto & | Set (this auto &self, const std::string &property, const std::string &value) |
| | Set a summary property.
|
| |
| Result< ApplyResult > | Apply () |
| | Apply the update's changes to create a new snapshot.
|
| |
| Status | Finalize (Result< const TableMetadata * > commit_result) override |
| | Finalize the snapshot update, cleaning up any uncommitted files.
|
| |
| virtual Status | Commit () |
| | Apply the pending changes and commit.
|
| |
|
| PendingUpdate (const PendingUpdate &)=delete |
| |
|
PendingUpdate & | operator= (const PendingUpdate &)=delete |
| |
|
| PendingUpdate (PendingUpdate &&) noexcept=default |
| |
|
PendingUpdate & | operator= (PendingUpdate &&) noexcept=default |
| |
|
| ErrorCollector (ErrorCollector &&)=default |
| |
|
ErrorCollector & | operator= (ErrorCollector &&)=default |
| |
|
| ErrorCollector (const ErrorCollector &)=default |
| |
|
ErrorCollector & | operator= (const ErrorCollector &)=default |
| |
| template<typename... Args> |
| auto & | AddError (this auto &self, ErrorKind kind, const std::format_string< Args... > fmt, Args &&... args) |
| | Add a specific error and return reference to derived class.
|
| |
| auto & | AddError (this auto &self, Error err) |
| | Add an existing error object and return reference to derived class.
|
| |
| auto & | AddError (this auto &self, std::unexpected< Error > err) |
| | Add an unexpected result's error and return reference to derived class.
|
| |
| bool | has_errors () const |
| | Check if any errors have been collected.
|
| |
| size_t | error_count () const |
| | Get the number of errors collected.
|
| |
| Status | CheckErrors () const |
| | Check for accumulated errors and return them if any exist.
|
| |
| void | ClearErrors () |
| | Clear all accumulated errors.
|
| |
|
const std::vector< Error > & | errors () const |
| | Get read-only access to all collected errors.
|
| |
|
|
| SnapshotUpdate (std::shared_ptr< TransactionContext > ctx) |
| |
| Result< std::vector< ManifestFile > > | WriteDataManifests (std::span< const std::shared_ptr< DataFile > > files, const std::shared_ptr< PartitionSpec > &spec, std::optional< int64_t > data_sequence_number=std::nullopt) |
| | Write data manifests for the given data files.
|
| |
| Result< std::vector< ManifestFile > > | WriteDeleteManifests (std::span< const std::shared_ptr< DataFile > > files, const std::shared_ptr< PartitionSpec > &spec) |
| | Write delete manifests for the given delete files.
|
| |
|
const std::string & | target_branch () const |
| |
|
bool | can_inherit_snapshot_id () const |
| |
|
const std::string & | commit_uuid () const |
| |
|
int32_t | manifest_count () const |
| |
|
int32_t | attempt () const |
| |
|
int64_t | target_manifest_size_bytes () const |
| |
| virtual void | CleanUncommitted (const std::unordered_set< std::string > &committed)=0 |
| | Clean up any uncommitted manifests that were created.
|
| |
| virtual std::string | operation ()=0 |
| | A string that describes the action that produced the new snapshot.
|
| |
| virtual Status | Validate (const TableMetadata ¤t_metadata, const std::shared_ptr< Snapshot > &snapshot) |
| | Validate the current metadata.
|
| |
| virtual Result< std::vector< ManifestFile > > | Apply (const TableMetadata &metadata_to_update, const std::shared_ptr< Snapshot > &snapshot)=0 |
| | Apply the update's changes to the given metadata and snapshot.
|
| |
| virtual std::unordered_map< std::string, std::string > | Summary ()=0 |
| | Get the summary map for this operation.
|
| |
| virtual bool | CleanupAfterCommit () const |
| | Check if cleanup should happen after commit.
|
| |
|
int64_t | SnapshotId () |
| | Get or generate the snapshot ID for the new snapshot.
|
| |
| Status | DeleteFile (const std::string &path) |
| | Delete a file at the given path.
|
| |
|
std::string | ManifestPath () |
| |
|
std::string | ManifestListPath () |
| |
|
SnapshotSummaryBuilder & | summary_builder () |
| |
|
| PendingUpdate (std::shared_ptr< TransactionContext > ctx) |
| |
|
const TableMetadata & | base () const |
| |
Base class for operations that produce snapshots.
This class provides common functionality for creating new snapshots, including manifest list writing and cleanup.