forked from victorb/arch-mirror
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Since currently the verify and add of filestore is slow, and there is no way to get hashes from just filenames something else is needed. IPFS already has these features in the mfs functions. By adding the files with --nocopy, and then copy them into the ipfs files structures All of this can be tracked Recently modified files (by rsync) are now added, and then mfs is update. The old hash is fetched before being replaced, that way it can be cleaned up from mfs and pins. Similarly for deleted files rsync dry-run is used to get list of files that should be deleted Hash is fetched from mfs, and mfs, pin and actual file are removed by bash loop instead of rsync. This also updates the hash tree in mfs, so we can grab the new root hash that way, which seems to be much faster. As fallback full add is still used (when no hash exists in mfs)
- Loading branch information
Showing
1 changed file
with
102 additions
and
37 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters