mutation_partition: add an upgrading variant of lazy_row::apply()

A helper which will be used during upcoming changes to
mutation_partition_v2::apply_monotonically(), which will extend it to merging
versions with different schemas.
This commit is contained in:
Michał Chojnowski
2023-03-01 01:10:10 +01:00
parent dce1b3e820
commit effd1fe70f

View File

@@ -422,6 +422,14 @@ public:
get_existing().apply_monotonically(s, kind, std::move(src.get_existing()));
}
// Monotonic exception guarantees
void apply_monotonically(const schema& our_schema, const schema& their_schema, column_kind kind, lazy_row&& src) {
if (src.empty()) {
return;
}
maybe_create().apply_monotonically(our_schema, their_schema, kind, std::move(src.get_existing()));
}
// Expires cells based on query_time. Expires tombstones based on gc_before
// and max_purgeable. Removes cells covered by tomb.
// Returns true iff there are any live cells left.