db: persist jupes across restart (event-source them)
All checks were successful
CI / check (push) Successful in 3m50s
All checks were successful
CI / check (push) Successful in 3m50s
A fold-parity property test caught it: jupes were plain in-memory Db fields that logged no event, so after any services restart every juped server was silently un-juped and could relink. Moved jupes into NetData (like akills/ forbids/groups) and event-sourced them with JupeAdded/JupeRemoved (Local scope), so a jupe now replays from the log. Adds the round-trip property test (live state == replayed state) as a permanent guard against this bug class.
This commit is contained in:
parent
61005f52f5
commit
90167dd46f
6 changed files with 119 additions and 13 deletions
|
|
@ -179,6 +179,8 @@ fn to_wire(entry: &LogEntry) -> Option<ReplicationEvent> {
|
|||
| Event::AkillRemoved { .. }
|
||||
| Event::ForbidAdded { .. }
|
||||
| Event::ForbidRemoved { .. }
|
||||
| Event::JupeAdded { .. }
|
||||
| Event::JupeRemoved { .. }
|
||||
| Event::AccountExpiryWarned { .. }
|
||||
| Event::ChannelExpiryWarned { .. }
|
||||
| Event::AccountOperNoteSet { .. }
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue