-
Notifications
You must be signed in to change notification settings - Fork 217
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Monitor memory allocation and stress wallet primitives #100
Comments
It'd be nice if we could then set some thresholds that would make the CI fails if they are crossed. Also, the ticket only mentions space benchmarking, but would it make sense to also do some time benchmarking on some operations (like coin selection, wallet restoration against mainnet, address discovery for BIG set of addresses)? |
@rvl What do you think about using mainnet or testnet data for this? (at least initially). One "fun" thing maybe, would be to provide an 'isOurs' implementation that pretty much recognize ALL addresses as ours, (or one every other) which will such out pretty much everything from mainnet / testnet. Not sure how many transactions is represents, but probably something like 21600 * 110 ~ 2M 🤷♂️ |
That is something we should definitely do -- an acceptance test like we have for the old wallet. The nightly test also measures time taken and heap usage. I am happy to use the existing chains initially. However we will only be testing historical data, not future possible inputs. And there are other drawbacks. Adding special |
@rvl let's not tackle the Better section as part of this ticket but, keep that for another ticket later on. |
lgtm 👍 For that matter I have added also the idea from the comment -> https://github.com/input-output-hk/cardano-wallet/wiki/Blackboard#benchmark-tests---automatically-check-the-results |
Context
We need automated tests to ensure that our wallet meets its performance requirements.
In particular, we need these test cases to detect space leaks, or wrong algorithmic complexity.
Decision
Acceptance Criteria
Development Plan
Basic
listen
polling function (5s interval) will make executing the test more tricky (and testing when it has finished applying blocks) -- make some workaround.+RTS -h
option to get memory usage statistics.More interesting
mkWalletLayer
so that the address derivation scheme can be swapped out.Better
Moved to https://github.com/input-output-hk/cardano-wallet/wiki/Blackboard#better-restoration-stress-benchmark
PR
rvl/100/bench
master
rvl/100/address-discovery
rvl/100/bench
master
master
QA
We now run nightly build restoration benchmarks on buildkite against both
mainnet
andtestnet
.For each network, we run three benchmarks, playing with different version of 'isOurs' (address discovery)
The 'classic' one for sequential wallet. Downside is that we are restoring a wallet from a public arbitrary mnemonic and end up with an empty wallet. Still, we go through the whole chain and process every non-empty block
To step-up a bit the game, we also run a 10% isOurs, which recognize, at random, 10% of the address on the chain (using the crc on each address). This allows us to create artificially big(ger) wallets and observe the memory usage for those.
Even more, and to observe how the backend scale, we run a 50% isOurs heuristic where half of the chain gets recognized as "ours".
Builds (with status visible on the README via the
NIGHTLY
base currently generate a single artifact, which is a heap memory visualization of the benchmark). We don't have any ways of automatically checking the benchmark results at the moment, so this is still something which requires a manual checks. A bullet point to the release checklist has been added to remind ourselves to do so.The text was updated successfully, but these errors were encountered: