I spotted that with bedrock server now supports taking backups via command line (at least as of version 1.21.30.03).
What's cool about it that it doesn't require server stop, so basically you can take backups as frequently as you wish and it's not going to disrupt gameplay.
Concept is that you send it a command to prepare to backup, then poll it if it's ready. When it's ready, it gives you exact list of files to backup and their lengths. They you copy and trim them, if anything is longer, and that's exactly your backup. You can check minecraft's bedrock_server_how_to.html for more details.
So, I've replaced current backup routine (stop, copy everything, start) with logic based on those commands. It works, though I can't say I thoroughly tested it: I played on it for a bit, it was taking backups, and I tried few of those backups afterwards, they seemed ok.
I spotted that with bedrock server now supports taking backups via command line (at least as of version 1.21.30.03).
What's cool about it that it doesn't require server stop, so basically you can take backups as frequently as you wish and it's not going to disrupt gameplay.
Concept is that you send it a command to prepare to backup, then poll it if it's ready. When it's ready, it gives you exact list of files to backup and their lengths. They you copy and trim them, if anything is longer, and that's exactly your backup. You can check minecraft's bedrock_server_how_to.html for more details.
So, I've replaced current backup routine (stop, copy everything, start) with logic based on those commands. It works, though I can't say I thoroughly tested it: I played on it for a bit, it was taking backups, and I tried few of those backups afterwards, they seemed ok.