Skip to content

Commit c9be7cf

Browse files
committed
db-analyser: document pitfall of --repro-mempool-and-forge 2
1 parent 49d3143 commit c9be7cf

File tree

2 files changed

+18
-1
lines changed

2 files changed

+18
-1
lines changed

ouroboros-consensus-cardano/README.md

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -166,6 +166,16 @@ Lastly the user can provide the analysis that should be run on the chain:
166166
- time spent in the mutator in microseconds
167167
- time spent in GC in microseconds
168168

169+
Currently, only NUM=1 or NUM=2 are supported. Note that with NUM=2, even for a
170+
fully valid chain (like mainnet), you might get an error like this:
171+
172+
```
173+
Mempool rejected some of the on-chain txs: ... (OutsideValidityIntervalUTxO ...) ...
174+
```
175+
176+
Therefore, it is recommended to start with NUM=1, and only use NUM=2 when you
177+
want to test the performance impact of a more filled mempool.
178+
169179
* `--get-block-application-metrics NUM` computes different block application metrics every `NUM` blocks.
170180
It currently outputs block number, slot number, UTxO size in MB, and UTxO map size.
171181
In the [`scripts`](./scripts) directory we provide a `plot_utxo-growth.py` script that can be used to plot the these results.

ouroboros-consensus-cardano/src/unstable-cardano-tools/Cardano/Tools/DBAnalyser/Analysis.hs

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -816,7 +816,14 @@ reproMempoolForge numBlks env = do
816816
| rej@(Mempool.MempoolTxRejected tx _) <- results
817817
]
818818
unless (null rejs) $ do
819-
fail $ "Mempool rejected some of the on-chain txs: " <> show rejs
819+
fail $ unlines $
820+
["Mempool rejected some of the on-chain txs: " <> show rejs]
821+
<> case howManyBlocks of
822+
ReproMempoolForgeOneBlk -> []
823+
ReproMempoolForgeTwoBlks ->
824+
[ "This might be expected, see the db-analyser README."
825+
, "Consider trying again with `--repro-mempool-and-forge 1`."
826+
]
820827

821828
let scrutinee = case howManyBlocks of
822829
ReproMempoolForgeOneBlk -> Just blk'

0 commit comments

Comments
 (0)