@@ -36,16 +36,10 @@ pub use crate::supervisor::WasiClockOverride;
3636use crate :: supervisor:: { self , Supervisor } ;
3737
3838/// Ambient inputs the imperative launcher reads: the executor that spawns the
39- /// long-lived subscription and event-loop tasks, the resolved data directory,
40- /// and the loaded config.
39+ /// long-lived subscription and event-loop tasks, and the loaded config.
4140pub struct LaunchContext < ' a > {
4241 /// Spawns the subscription and event-loop tasks.
4342 pub executor : & ' a dyn TaskExecutor ,
44- /// Directory the backends root their on-disk state at. Advisory: the
45- /// launcher receives pre-built backends, so it does not open the data
46- /// directory itself; a builder that opens the backends reads the data
47- /// directory at build time, not here.
48- pub data_dir : & ' a Path ,
4943 /// The loaded engine config.
5044 pub config : & ' a EngineConfig ,
5145}
@@ -261,7 +255,7 @@ impl<T: RuntimeTypes> LaunchRuntime for AssembledRuntime<'_, T> {
261255 ( ) = signal => { } ,
262256 }
263257 } ;
264- let mut supervisor = supervisor;
258+ let mut supervisor = supervisor; // rebind as mut: the dispatch calls below take &mut self
265259 event_loop:: run (
266260 & mut supervisor,
267261 block_streams,
@@ -399,7 +393,6 @@ impl<'a, R: Runtime> PresetBuilder<'a, R> {
399393 } ;
400394 let ctx = LaunchContext {
401395 executor : self . executor . unwrap_or ( & TokioExecutor ) ,
402- data_dir : & data_dir,
403396 config : self . config ,
404397 } ;
405398 runtime. launch ( ctx) . await
@@ -538,7 +531,6 @@ where
538531 } ;
539532 let ctx = LaunchContext {
540533 executor : self . executor . unwrap_or ( & TokioExecutor ) ,
541- data_dir : & data_dir,
542534 config : self . config ,
543535 } ;
544536 runtime. launch ( ctx) . await
@@ -618,7 +610,6 @@ mod tests {
618610 let executor = TokioExecutor ;
619611 let ctx = LaunchContext {
620612 executor : & executor,
621- data_dir : & data_dir,
622613 config : & config,
623614 } ;
624615
0 commit comments