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

Support an operation to compact the history without writing an archive #86

Open
haasn opened this issue May 25, 2017 · 1 comment
Open

Comments

@haasn
Copy link

haasn commented May 25, 2017

This would be semantically equivalent to createArchive, but instead of storing the archive on the disk, just delete it.

I have a pathological case where my working set is a few kB but my archive folder is several gigabytes. I could include my own removeDirectory (xapianDir </> "Archive") call but it feels hacky and arbitrary. Can't acid-state do this as well?

In fact, why doesn't acid-state do this out of the box? It feels like acid-state is designed to fail eventually by running the host out of disk space for history from years ago.

@dmjio
Copy link
Member

dmjio commented May 26, 2017

Per the docs,

createArchive: Move all log files that are no longer necessary for state restoration into the Archive folder in the state directory. This folder can then be backed up or thrown out as you see fit. Reverting to a state before the last checkpoint will not be possible if the Archive folder has been thrown out.

Might be beneficial to have a separate thread monitoring that directory. I don't think acid-state does this out of the box since it probably doesn't want to be responsible for data loss. Since deleting old archives assures you won't be able to rollback to an earlier version.

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

3 participants