feat: /save admin command to force a world snapshot #41
Labels
No labels
alpha:wave-0
alpha:wave-1
alpha:wave-2
alpha:wave-3
area:assets
area:combat
area:ecology
area:infra
area:render
area:scripting
area:ui
area:world
enhancement
epic
migration
post-alpha
roadmap
tech-debt
type:bug
type:chore
type:design
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
marco/IsoMmo#41
Loading…
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Give admins a chat command to force an immediate world save instead of waiting for the 15s periodic snapshot (e.g. before a restart or after a notable event).
Scope
PersistenceService) into a sharedWorldPersisterservice, with concurrent-save dedupe (a single shared instance so the periodic save and a manual save never write the file at the same time).PersistenceServiceusesWorldPersister(timer + shutdown)./saveGmCommand(admin-only, authorized server-side by the signedadminJWT claim viaCanExecute) that triggers a save and returns aSystemMessagewith the outcome./saverow todocs/gm-commands.md.Definition of Done
/saverun by an admin writesworld.savimmediately (not waiting the 15s periodic) and replies with a system message reporting how many players were saved./savegetsYou are not allowed to do that.and their command writes no file./savewith no players online replies that there is nothing to save and writes no file.WorldPersister).PersistenceServiceand the/savecommand both persist throughWorldPersister(one code path, identical on-disk result).docs/gm-commands.mdlists a/saverow.Depends on the binary-persistence PR (#40):
PlayerStore/world.savland there.