v0.3.12-pre.007-fix.001
This commit is contained in:
@@ -1,5 +1,5 @@
|
||||
// file: crates/ksp-worker-raw-transaction-ingest-lib/src/runtime.rs
|
||||
// version: 10
|
||||
// version: 11
|
||||
|
||||
type PersistencePort = std::sync::Arc<dyn crate::RawTransactionIngestPersistencePort + 'static>;
|
||||
type PersistenceTasks = tokio::task::JoinSet<ksp_core_lib::Result<crate::RawTransactionIngestPersistenceOutcome>>;
|
||||
@@ -189,7 +189,6 @@ async fn drain_admission_and_persistence(
|
||||
persistence: &mut PersistenceTasks,
|
||||
port: &std::option::Option<PersistencePort>,
|
||||
snapshots: &mut crate::RawTransactionIngestSnapshotPublisher,
|
||||
processing_frontier_receiver: &mut std::option::Option<ProcessingFrontierReceiver>,
|
||||
) -> std::option::Option<ksp_core_lib::ErrorCode> {
|
||||
let mut fault = std::option::Option::None;
|
||||
admission.close();
|
||||
@@ -448,13 +447,7 @@ where
|
||||
Spawner:
|
||||
FnOnce(&mut SourceTasks, tokio::sync::watch::Receiver<bool>, tokio::sync::mpsc::Sender<crate::RawTransactionIngress>) + std::marker::Send + 'static,
|
||||
{
|
||||
return start_foundation_with_port_source_spawner_and_frontier(
|
||||
settings,
|
||||
runtime,
|
||||
port,
|
||||
std::option::Option::None,
|
||||
source_spawner,
|
||||
);
|
||||
return start_foundation_with_port_source_spawner_and_frontier(settings, runtime, port, std::option::Option::None, source_spawner);
|
||||
}
|
||||
|
||||
fn start_foundation_with_port_source_spawner_and_frontier<Spawner>(
|
||||
@@ -480,15 +473,7 @@ where
|
||||
let (stop_sender, stop_receiver) = tokio::sync::watch::channel(false);
|
||||
let (snapshots, snapshot_source) = crate::RawTransactionIngestSnapshotPublisher::new(&settings, &lifecycle);
|
||||
let handle = crate::RawTransactionIngestHandle { snapshots: snapshot_source, stop_sender, stop_token };
|
||||
std::mem::drop(runtime.spawn(run_supervisor(
|
||||
settings,
|
||||
lifecycle,
|
||||
port,
|
||||
stop_receiver,
|
||||
snapshots,
|
||||
processing_frontier_receiver,
|
||||
source_spawner,
|
||||
)));
|
||||
std::mem::drop(runtime.spawn(run_supervisor(settings, lifecycle, port, stop_receiver, snapshots, processing_frontier_receiver, source_spawner)));
|
||||
return std::result::Result::Ok(handle);
|
||||
}
|
||||
|
||||
@@ -522,6 +507,7 @@ async fn supervise_until_stop(
|
||||
persistence: &mut PersistenceTasks,
|
||||
port: &std::option::Option<PersistencePort>,
|
||||
snapshots: &mut crate::RawTransactionIngestSnapshotPublisher,
|
||||
processing_frontier_receiver: &mut std::option::Option<ProcessingFrontierReceiver>,
|
||||
) -> std::option::Option<ksp_core_lib::ErrorCode> {
|
||||
let mut admission_open = true;
|
||||
loop {
|
||||
|
||||
Reference in New Issue
Block a user