hubcio commented on code in PR #2675:
URL: https://github.com/apache/iggy/pull/2675#discussion_r2797925881
##########
core/metadata/src/stm/mod.rs:
##########
@@ -87,6 +88,19 @@ where
read: Arc<ReadHandle<T>>,
}
+impl<T, C> LeftRight<T, C>
+where
+ T: Absorb<C>,
+{
+ pub fn read<F, R>(&self, f: F) -> R
+ where
+ F: FnOnce(&T) -> R,
+ {
+ let guard = self.read.enter().expect("read handle should be
accessible");
+ f(&*guard)
+ }
+}
Review Comment:
you are right! instead of looking at master branch I looked at my own
branch: `invert-state-handler-dep`
ignore this :)
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]