Increasing clear protection period to 10 minutes.

This commit is contained in:
softsimon 2021-01-24 19:33:05 +07:00
parent 86902d6f33
commit cca95bbd66
No known key found for this signature in database
GPG Key ID: 488D7DCFB5A430D7

View File

@ -10,6 +10,7 @@ import loadingIndicators from './loading-indicators';
class Mempool {
private static WEBSOCKET_REFRESH_RATE_MS = 10000;
private static CLEAR_PROTECTION_MINUTES = 10;
private inSync: boolean = false;
private mempoolCache: { [txId: string]: TransactionExtended } = {};
private mempoolInfo: IBitcoinApi.MempoolInfo = { loaded: false, size: 0, bytes: 0, usage: 0,
@ -143,7 +144,7 @@ class Mempool {
setTimeout(() => {
this.mempoolProtection = 2;
logger.warn('Mempool clear protection resumed.');
}, 1000 * 60 * 2);
}, 1000 * 60 * Mempool.CLEAR_PROTECTION_MINUTES);
}
let newMempool = {};