Checkpoints
Filesuite/30-shop.ymlA checkpoint is a named copy of what plugins keep on disk. It lets a scenario start from a known state without rebuilding that state step by step.
java -jar IgniteTestTool.jar call checkpoint/save name=clean
java -jar IgniteTestTool.jar call checkpoint/save name=arenas paths=plugins/IgniteZombies/arenas,world
java -jar IgniteTestTool.jar call checkpoint/restore name=cleanWhat gets saved
Without paths a checkpoint holds the data folder of every plugin. Paths are relative to the server folder and can be a file or a folder. A path that did not exist at the save is deleted by a restore.
Checkpoints live in checkpoints/ in the data dir.
Server restarts
Save and restore stop the server the tool started, copy, and start it again, since a running plugin would write its memory over the files. After a save or restore without live the bots are offline and have to join again.
live=1 copies under a running server, for data the plugin reloads on a command. A file the server holds locked during a live save is left out and named in the message.
In a scenario
| Where | What it does |
|---|---|
checkpoint: clean at the top of a file | Restores that checkpoint before the file runs. The result cache keys on it: saving the checkpoint again brings the file back |
{do: checkpoint, save: clean} | At the end of a setup file, saves the state the other files start from |
{do: checkpoint, restore: clean, live: true} | Restores under a running server; follow it with the plugin's reload command |
name: shop
checkpoint: clean
steps:
- {do: join}Managing them
| Call | What it does |
|---|---|
/checkpoint | Lists the checkpoints |
/checkpoint/save?name=&paths= | Saves one. Needs the API token |
/checkpoint/restore?name= | Restores one. Needs the API token |
/checkpoint/drop?name= | Deletes one. Needs the API token |
Over HTTP the three that change something need the token, see HTTP API. call sends it for you.
The Checkpoints page is a list with a page per checkpoint: what it holds, when it was saved, Restore and Delete right there.
