Add convergent recovery and exact staging cleanup

This commit is contained in:
ms2k 2026-07-17 08:36:39 +09:00
commit 9d96c4d563

View file

@ -46,7 +46,7 @@ pub struct AttemptService {
pub(crate) coordination: CoordinationStore,
local_permits: LocalPermitGate,
pub(crate) operation_subject: OpaqueId,
faults: Arc<dyn AttemptFaultInjector>,
pub(crate) faults: Arc<dyn AttemptFaultInjector>,
pub(crate) config: AttemptConfig,
}
@ -733,7 +733,7 @@ fn claim_rejected(reason: ClaimRejection) -> ClaimOutcome {
}
}
fn new_id(prefix: char) -> Result<OpaqueId, AttemptError> {
pub(crate) fn new_id(prefix: char) -> Result<OpaqueId, AttemptError> {
let mut bytes = [0u8; 16];
getrandom::fill(&mut bytes)
.map_err(|error| AttemptError::Invalid(format!("identifier entropy failed: {error}")))?;