Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit 1b6a033

Browse files
super version debug logging
1 parent c73f1db commit 1b6a033

File tree

1 file changed

+14
-3
lines changed

1 file changed

+14
-3
lines changed

‎src/version/super_version.rs‎

Lines changed: 14 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -121,12 +121,23 @@ impl SuperVersions {
121121
.expect("should always find a SuperVersion");
122122
}
123123

124-
self.0
124+
let version = self
125+
.0
125126
.iter()
126127
.rev()
127128
.find(|version| version.seqno < seqno)
128-
.cloned()
129-
.expect("should always find a SuperVersion")
129+
.cloned();
130+
131+
if version.is_none() {
132+
log::error!("Failed to find a SuperVersion for snapshot with seqno={seqno}");
133+
log::error!("SuperVersions:");
134+
135+
for version in self.0.iter().rev() {
136+
log::error!("-> {}, seqno={}", version.version.id(), version.seqno);
137+
}
138+
}
139+
140+
version.expect("should always find a SuperVersion")
130141
}
131142

132143
pub fn append_sealed_memtable(&mut self, id: MemtableId, memtable: Arc<Memtable>) {

0 commit comments

Comments
(0)

AltStyle によって変換されたページ (->オリジナル) /