We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 9b6e4dc commit 9600a17Copy full SHA for 9600a17
1 file changed
crates/core/src/db/snapshot.rs
@@ -98,6 +98,11 @@ impl SnapshotWorker {
98
}
99
100
101
+ /// Create a new [SnapshotWorker] on the current Tokio runtime.
102
+ pub fn new_tokio_current(snapshot_repository: Arc<DynSnapshotRepo>, compression: Compression) -> Self {
103
+ Self::new(snapshot_repository, compression, Handle::tokio_current())
104
+ }
105
+
106
/// Finish the initialization of [Self] by passing a [SnapshotDatabaseState],
107
/// or replace the current [SnapshotDatabaseState] with a new one.
108
///
0 commit comments