Disabled expired transaction data deletion code for now, as this was often causing data to be incorrectly deleted.

This will need to be re-enabled at some point, but only after it's modified to be much less aggressive.
This commit is contained in:
CalDescent 2022-02-24 19:05:29 +00:00
parent cec3e86eef
commit a63ef4010d

View File

@ -222,7 +222,11 @@ public class ArbitraryDataCleanupManager extends Thread {
try (final Repository repository = RepositoryManager.getRepository()) { try (final Repository repository = RepositoryManager.getRepository()) {
// Check if there are any hosted files that don't have matching transactions // Check if there are any hosted files that don't have matching transactions
this.checkForExpiredTransactions(repository); // UPDATE: This has been disabled for now as it was deleting valid transactions
// and causing chunks to go missing on the network. If ever re-enabled, we MUST
// ensure that original copies of data aren't deleted, and that sufficient time
// is allowed (ideally several hours) before treating a transaction as missing.
// this.checkForExpiredTransactions(repository);
// Delete additional data at random if we're over our storage limit // Delete additional data at random if we're over our storage limit
// Use the DELETION_THRESHOLD so that we only start deleting once the hard limit is reached // Use the DELETION_THRESHOLD so that we only start deleting once the hard limit is reached