Pruning batches - #664
Conversation
bcc0bc0 to
852e007
Compare
|
Using However, I have not been able to find a way to use Benchmark of pruning 10000 batches (Remove batch data vs Clear batch data): Pruning 100 batches out of 2000 batches takes over 1 second. Tally end block of 100 tallies is 0.1 seconds according to the benchmark. |
1d90c43 to
8a43e08
Compare
8a43e08 to
d0a1cf2
Compare
c07ec25 to
a143e6a
Compare
6f13484 to
b11a9f8
Compare
|
I have tried a few different strategies, including one where I kept the first batch number as a state to completely remove the need for Will do a little more digging on how exactly Clear can be efficient with composite keys, but for now the first commit a143e6a seems to be the best performance Clear can give us. |
c6dd3c9 to
a143e6a
Compare
Prune batches and their associated data at every block based on two new module parameters NumBatchesToKeep and MaxBatchPrunePerBlock.
Use Clear instead of Remove wherever possible to dramatically reduce compute time.
Add additional mappings without SchemaBuilder validation so that we can clear batches without unmarshalling each Batch.
a143e6a to
90b2ef4
Compare
Explanation of Changes
Prune batches and their associated data at every block based on two new module parameters NumBatchesToKeep and MaxBatchPrunePerBlock.
See #667 for pruning data results.
See the branch
hy/batch-prune-optfor further optimization attempts.Testing
Added an integration test
Related PRs and Issues
Related #663