store compiled regex patterns for performance optimization

This commit is contained in:
Jeff Thompson
2017-09-14 23:21:30 -05:00
parent 3cf3ad06fa
commit 805f6fd15d
3 changed files with 46 additions and 19 deletions

View File

@@ -708,6 +708,8 @@ func restoreRepository(context *cli.Context) {
}
duplicacy.LOG_DEBUG("REGEX_DEBUG", "There are %d compiled regular expressions stored", len(duplicacy.RegexMap))
storage.SetRateLimits(context.Int("limit-rate"), 0)
backupManager := duplicacy.CreateBackupManager(preference.SnapshotID, storage, repository, password)
duplicacy.SavePassword(*preference, "password", password)