Compare commits
8 Commits
ykaul/skip
...
copilot/fi
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
309f1994db | ||
|
|
70e83c7687 | ||
|
|
0f0d30cc34 | ||
|
|
5faee478c4 | ||
|
|
88fb5130b3 | ||
|
|
e5db893125 | ||
|
|
829b85ee46 | ||
|
|
009ab048f1 |
1
.gitignore
vendored
1
.gitignore
vendored
@@ -37,3 +37,4 @@ clang_build
|
||||
.idea/
|
||||
nuke
|
||||
rust/target
|
||||
|
||||
|
||||
@@ -192,7 +192,9 @@ tablet_map_to_mutations(const tablet_map& tablets, table_id id, const sstring& k
|
||||
m.set_clustered_cell(ck, "session", data_value(tr_info->session_id.uuid()), ts);
|
||||
}
|
||||
}
|
||||
tid = *tablets.next_tablet(tid);
|
||||
if (auto next_tid = tablets.next_tablet(tid)) {
|
||||
tid = *next_tid;
|
||||
}
|
||||
}
|
||||
co_await process_mutation(std::move(m));
|
||||
}
|
||||
@@ -575,7 +577,7 @@ void update_tablet_metadata_change_hint(locator::tablet_metadata_change_hint& hi
|
||||
|
||||
namespace {
|
||||
|
||||
tablet_id process_one_row(replica::database* db, table_id table, tablet_map& map, tablet_id tid, const cql3::untyped_result_set_row& row) {
|
||||
std::optional<tablet_id> process_one_row(replica::database* db, table_id table, tablet_map& map, tablet_id tid, const cql3::untyped_result_set_row& row) {
|
||||
tablet_replica_set tablet_replicas;
|
||||
if (row.has("replicas")) {
|
||||
tablet_replicas = deserialize_replica_set(row.get_view("replicas"));
|
||||
@@ -659,7 +661,7 @@ tablet_id process_one_row(replica::database* db, table_id table, tablet_map& map
|
||||
persisted_last_token, current_last_token, table, tid));
|
||||
}
|
||||
|
||||
return *map.next_tablet(tid);
|
||||
return map.next_tablet(tid);
|
||||
}
|
||||
|
||||
struct tablet_metadata_builder {
|
||||
@@ -714,7 +716,9 @@ struct tablet_metadata_builder {
|
||||
}
|
||||
|
||||
if (row.has("last_token")) {
|
||||
current->tid = process_one_row(db, current->table, current->map, current->tid, row);
|
||||
if (auto next_tid = process_one_row(db, current->table, current->map, current->tid, row)) {
|
||||
current->tid = *next_tid;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user