diff options
| author | tv <tv@krebsco.de> | 2026-10-31 05:01:17 +0100 |
|---|---|---|
| committer | tv <tv@krebsco.de> | 2026-10-31 05:01:17 +0100 |
| commit | 69bc5ae4ce1c0e8ff2fe03091b1ba022edc13ad1 (patch) | |
| tree | 73650e158f1872cb04a42d92da4ff41a2f4edd9e /src/remake/records.rs | |
| parent | 6c7809103f62c89fc10cc82228a28a0f39db5277 (diff) | |
replace EpochInfo by EpochRecord
Diffstat (limited to 'src/remake/records.rs')
| -rw-r--r-- | src/remake/records.rs | 17 |
1 files changed, 1 insertions, 16 deletions
diff --git a/src/remake/records.rs b/src/remake/records.rs index 720aea1..463d085 100644 --- a/src/remake/records.rs +++ b/src/remake/records.rs @@ -45,22 +45,7 @@ const DAY_MS: u64 = 24 * 60 * 60 * 1000; // --- record types ------------------------------------------------------------ -/// An epoch in a record: generation plus hex-encoded snapshot hash. -#[derive(Clone, Debug, PartialEq, Eq, Serialize, Deserialize)] -#[serde(rename_all = "camelCase")] -pub(crate) struct EpochRecord { - pub(crate) generation: u64, - pub(crate) id: String, -} - -impl From<Epoch> for EpochRecord { - fn from(epoch: Epoch) -> Self { - Self { - generation: epoch.generation, - id: epoch.id_hex(), - } - } -} +pub(crate) use crate::document::replica::EpochRecord; impl EpochRecord { pub(crate) fn to_epoch(&self) -> Option<Epoch> { |
