v0.3.13-pre.011

This commit is contained in:
2026-09-10 21:27:18 +02:00
parent f636169783
commit 06319655b0
15 changed files with 778 additions and 69 deletions

View File

@@ -1,5 +1,5 @@
// file: crates/ksp-worker-raw-transaction-ingest-lib/tests/dependency_boundary.rs
// version: 27
// version: 28
//! Dependency firewall canaries for the RAW transaction ingest Worker foundation.
@@ -663,3 +663,42 @@ fn v0_3_13_pre_010_multi_source_snapshot_health_remains_source_neutral_and_backe
}
return;
}
#[test]
fn v0_3_13_pre_011_shutdown_race_hardening_stays_inside_worker_and_existing_facades() {
let runtime = include_str!("../src/runtime.rs");
let resources = include_str!("../src/runtime_resources.rs");
for required in [
"tokio::time::timeout(settings.shutdown_drain_timeout(), drain).await",
"persistence.abort_all()",
"children.abort_all()",
"while persistence.join_next().await.is_some() {}",
"while children.join_next().await.is_some() {}",
"ERROR_CODE_RAW_TRANSACTION_INGEST_COUNTER_EXHAUSTED",
] {
assert!(runtime.contains(required), "required pre.011 runtime shutdown guard missing: {required}");
}
for required in [
"RawTransactionIngestHydrationLeaderGuard",
"publish_and_remove",
"pending.remove(key)",
"source.inventory_key_mismatch",
"checked_add(projection.hydration_pending())",
"checked_add(projection.source_reconnect_total())",
] {
assert!(resources.contains(required), "required pre.011 source-race guard missing: {required}");
}
for forbidden in [
"unbounded_channel",
"ksp_store_postgres_lib::",
"ksp_config_lib::",
"ksp_job_backfill_lib::",
"reqwest::",
"tokio_tungstenite::",
"tonic::",
"yellowstone_grpc_proto::",
] {
assert!(!runtime.contains(forbidden) && !resources.contains(forbidden), "pre.011 crossed a Worker/facade boundary: {forbidden}");
}
return;
}