Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

(optimization) Reuse non-changed (region) files when restoring. #2

Open
Alvinn8 opened this issue Oct 17, 2023 · 1 comment
Open

(optimization) Reuse non-changed (region) files when restoring. #2

Alvinn8 opened this issue Oct 17, 2023 · 1 comment

Comments

@Alvinn8
Copy link
Owner

Alvinn8 commented Oct 17, 2023

Large worlds that are being restored will take a long time to restore from mch objects, and chances are many region files will be unchanged since the commit in question, for example, chunks that were explored to find a woodland mansion or something and then never touched again.

What we can do when restoring is read the current live state of the world, and if the region file has not been changed since the commit we want to restore to, we can just download/open that region file and copy it as-is, without having to parse it which should save quite a bit of time.

@Alvinn8
Copy link
Owner Author

Alvinn8 commented Oct 18, 2023

Investigate when/if this would be faster. I was able to restore a 150 MB world in only a few seconds completely from mch storage. When the files are from a remote it will probably just be slower to download them from the remote than to create them locally.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant