Repository navigation
v2.4.1
HexDB 2.4.1 fixes an election rule that could lose writes when a hex set to prefer the Overseer role came back to a lattice keeping full copies.
Fixed
- A sitting Overseer keeps the role. The election narrowed its candidates to hexes with
identity.role = "overseer"before it honoured a sitting Overseer. So when such a hex came back after handing its role over (with full copies,slicing = false), it took the role at once, and the Overseer that had led meanwhile then copied the returning hex's data, dropping any writes it had accepted while that hex was away. Now a sitting Overseer keeps the role whatever the others prefer. - A preferred hex gets the role back by handover. The hex that prefers to lead follows like any replica until it has every change; then the sitting Overseer hands the role to it, the same way an Overseer hands over before stopping (writes are held for a moment; one caught mid-commit gets 503 with a retry hint), and carries on as a replica. If the handover can't finish, it keeps the role and tries again five minutes later. Each handover is in the audit trail (
lattice.handover).
Upgrading
Restart the hexes one at a time, as usual: replicas first, the Overseer last. Sliced lattices (the default) weren't affected: their Overseer keeps its role across a restart instead of handing it over.
Full Changelog: v2.4.0...v2.4.1