mirror of
https://github.com/fluencelabs/tendermint
synced 2025-04-24 22:32:15 +00:00
config: reduce default mempool size (#2300)
* config: reduce default mempool size This reduces the mempool size from 100k to 5k. Note that each secp256k1 sig takes .5ms to compute. Therefore an adversary could previously delay every node on the network's computation time upon receiving a block by 50 seconds. This now reduces that ability to being able to only delay each node by 2.5 seconds. This change should be reverted once ABCI recheck is implemented. * (squash this) fix test
This commit is contained in:
parent
3a6cc5e6af
commit
61ab10d655
@ -32,6 +32,7 @@ IMPROVEMENTS:
|
|||||||
- [mempool] Now stores txs by hash inside of the cache, to mitigate memory leakage
|
- [mempool] Now stores txs by hash inside of the cache, to mitigate memory leakage
|
||||||
- [config] Replace db_path with db_dir from automatically generated configuration files.
|
- [config] Replace db_path with db_dir from automatically generated configuration files.
|
||||||
Issue reported to Cosmos SDK ([#1712](https://github.com/cosmos/cosmos-sdk/issues/1712))
|
Issue reported to Cosmos SDK ([#1712](https://github.com/cosmos/cosmos-sdk/issues/1712))
|
||||||
|
- [config] Reduce default mempool size from 100k to 5k, until ABCI rechecking is implemented.
|
||||||
|
|
||||||
BUG FIXES:
|
BUG FIXES:
|
||||||
- [mempool] No longer possible to fill up linked list without getting caching
|
- [mempool] No longer possible to fill up linked list without getting caching
|
||||||
|
@ -421,8 +421,10 @@ func DefaultMempoolConfig() *MempoolConfig {
|
|||||||
RecheckEmpty: true,
|
RecheckEmpty: true,
|
||||||
Broadcast: true,
|
Broadcast: true,
|
||||||
WalPath: filepath.Join(defaultDataDir, "mempool.wal"),
|
WalPath: filepath.Join(defaultDataDir, "mempool.wal"),
|
||||||
Size: 100000,
|
// Each signature verification takes .5ms, size reduced until we implement
|
||||||
CacheSize: 100000,
|
// ABCI Recheck
|
||||||
|
Size: 5000,
|
||||||
|
CacheSize: 10000,
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -99,7 +99,7 @@ func TestMempoolTxConcurrentWithCommit(t *testing.T) {
|
|||||||
height, round := cs.Height, cs.Round
|
height, round := cs.Height, cs.Round
|
||||||
newBlockCh := subscribe(cs.eventBus, types.EventQueryNewBlock)
|
newBlockCh := subscribe(cs.eventBus, types.EventQueryNewBlock)
|
||||||
|
|
||||||
NTxs := 10000
|
NTxs := 3000
|
||||||
go deliverTxsRange(cs, 0, NTxs)
|
go deliverTxsRange(cs, 0, NTxs)
|
||||||
|
|
||||||
startTestRound(cs, height, round)
|
startTestRound(cs, height, round)
|
||||||
|
Loading…
x
Reference in New Issue
Block a user