The crash-injection seam, ported VERBATIM from the legacy owner (owner.rs `owner_failpoint`). The env names are load-bearing: the legacy test suite spawns owners (now daemons) with them and asserts the process aborts and the retry converges.
(name: &str)
| 87 | /// legacy test suite spawns owners (now daemons) with them and asserts |
| 88 | /// the process aborts and the retry converges. |
| 89 | pub fn owner_failpoint(name: &str) { |
| 90 | if std::env::var("ATOMIC_OWNER_FAILPOINT").ok().as_deref() != Some(name) { |
| 91 | return; |
| 92 | } |
| 93 | let should_trip = match std::env::var_os("ATOMIC_OWNER_FAILPOINT_MARKER") { |
| 94 | Some(path) => OpenOptions::new() |
| 95 | .create_new(true) |
| 96 | .write(true) |
| 97 | .open(path) |
| 98 | .is_ok(), |
| 99 | None => true, |
| 100 | }; |
| 101 | if should_trip { |
| 102 | std::process::abort(); |
| 103 | } |
| 104 | } |
| 105 | |
| 106 | /// Reserve or retrieve the stable identity for a session turn. The first |
| 107 | /// reserve claims the turn; a committed reservation returns only after the |
no test coverage detected