mirror of
https://github.com/Qortal/qortal.git
synced 2025-04-14 23:35:54 +00:00
added error handling
This commit is contained in:
parent
e48fd96c1e
commit
4188f18a9a
@ -58,17 +58,22 @@ public class ArbitraryDataCacheManager extends Thread {
|
||||
|
||||
try {
|
||||
while (!Controller.isStopping()) {
|
||||
Thread.sleep(500L);
|
||||
try {
|
||||
Thread.sleep(500L);
|
||||
|
||||
// Process queue
|
||||
processResourceQueue();
|
||||
// Process queue
|
||||
processResourceQueue();
|
||||
} catch (Exception e) {
|
||||
LOGGER.error(e.getMessage(), e);
|
||||
Thread.sleep(600_000L); // wait 10 minutes to continue
|
||||
}
|
||||
}
|
||||
} catch (InterruptedException e) {
|
||||
// Fall through to exit thread
|
||||
}
|
||||
|
||||
// Clear queue before terminating thread
|
||||
processResourceQueue();
|
||||
// Clear queue before terminating thread
|
||||
processResourceQueue();
|
||||
} catch (Exception e) {
|
||||
LOGGER.error(e.getMessage(), e);
|
||||
}
|
||||
}
|
||||
|
||||
public void shutdown() {
|
||||
|
Loading…
x
Reference in New Issue
Block a user