weopqrst/moonroll/examples/resync does not have a README file

    Healing

    type Healing

    恢复过程的中间状态。放在一个可变结构里,是因为它同时被三条路径改写: 收包(检测 / 应用状态)、发包(请求 / 应答)、收尾(继续重试)。

    ResyncStats

    pub(all) struct ResyncStats {
    p0_confirmed : Int
    p1_confirmed : Int
    detected : Int
    repaired : Int
    asked : Int
    resyncs : Int
    mismatch_before : Int
    mismatch_after : Int
    bad_after : Int
    state_bytes : Int
    p0_rollbacks : Int
    p1_rollbacks : Int
    dropped : Int
    }

    一局的重同步过程记录。

    run

    fn run(spec :
    LinkSpec
    , total : Int, corrupt : Int) -> ResyncStats

    跑一局:corrupt 不为 0 时,P1 在那一帧发出与本地执行不一致的输入。

    Source Files