mirror of
https://github.com/overcuriousity/autopsy-flatpak.git
synced 2025-07-06 21:00:22 +00:00
logging for long polling
This commit is contained in:
parent
3e7e331aa1
commit
eb6f7a4f78
@ -694,6 +694,7 @@ class MalwareScanIngestModule implements FileIngestModule {
|
||||
Bundle.MalwareScanIngestModule_longPollForNotFound_fileLookupPolling_title(),
|
||||
Bundle.MalwareScanIngestModule_longPollForNotFound_fileLookupPolling_desc()
|
||||
);
|
||||
logger.log(Level.INFO, "Begin polling for malware status of file uploads.");
|
||||
|
||||
Map<String, List<Long>> remaining = new HashMap<>(ingestJobState.getUnidentifiedHashes());
|
||||
|
||||
@ -729,6 +730,9 @@ class MalwareScanIngestModule implements FileIngestModule {
|
||||
|
||||
// exponential backoff before trying again
|
||||
long waitMultiplier = ((long) Math.pow(2, retry));
|
||||
|
||||
logger.log(Level.INFO, MessageFormat.format("Waiting {0} milliseconds before polling again for malware status of file uploads.", (waitMultiplier * FILE_UPLOAD_RETRY_SLEEP_MILLIS)));
|
||||
|
||||
for (int i = 0; i < waitMultiplier; i++) {
|
||||
if (!ingestJobState.isDoFileLookups() || ingestJobState.getIngestJobContext().fileIngestIsCancelled()) {
|
||||
return;
|
||||
|
Loading…
x
Reference in New Issue
Block a user