-
Notifications
You must be signed in to change notification settings - Fork 387
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
storagenodedb: buffer up piece expirations
- use callback style interfaces rather than a bunch of slices. lowers memory usage - don't individually delete pieces from the db and do bulk deletes. it doesn't matter if we fail to delete a piece and remove it from the ttl database because garbage collection will pick it up - batch up writes to the ttl database to do 1000 at a time. this reduces database writes at the cost of potentially losing records but who cares becuase gc will pick it up - remove the concept of recording if a piece failed to be deleted. it doesn't matter if we end up trying to delete a piece that's already deleted for some reason. just move on. - adds a DeleteSkipV0 call that skips trying the delete on the V0 database used by the process that deletes expired objects. all the V0 pieces left that would have expired already have, and if not GC will get them eventually anyway. Change-Id: I85066f124685a7495f917ff92c681dd1c27c6803
- Loading branch information
Showing
8 changed files
with
186 additions
and
363 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
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
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
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
Oops, something went wrong.