feat(indexes): remove sync-v1 indexes#1200
Conversation
|
| Branch | feat/remove-sync-v1-indexes |
| Testbed | ubuntu-22.04 |
Click to view all benchmark results
| Benchmark | Latency | Benchmark Result minutes (m) (Result Δ%) | Lower Boundary minutes (m) (Limit %) | Upper Boundary minutes (m) (Limit %) |
|---|---|---|---|---|
| sync-v2 (up to 20000 blocks) | 📈 view plot 🚷 view threshold | 1.68 m(-3.01%)Baseline: 1.73 m | 1.56 m (92.79%) | 2.08 m (80.82%) |
b6bdf57 to
0e6013a
Compare
Codecov Report❌ Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## master #1200 +/- ##
==========================================
+ Coverage 86.19% 86.23% +0.04%
==========================================
Files 440 437 -3
Lines 34056 33725 -331
Branches 5327 5265 -62
==========================================
- Hits 29353 29082 -271
+ Misses 3677 3628 -49
+ Partials 1026 1015 -11 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
0e6013a to
752b56a
Compare
0a38b06 to
ea7d72c
Compare
752b56a to
cbfd6f1
Compare
cbfd6f1 to
105ee8d
Compare
|
This PR greatly reduces memory usage, see https://github.com/HathorNetwork/on-call-incidents/issues/196. |
eb49f63 to
f32a3f9
Compare
105ee8d to
11d5dd1
Compare
f32a3f9 to
e11dfd3
Compare
11d5dd1 to
796f9a2
Compare
e11dfd3 to
4b3736f
Compare
4b3736f to
5e88bb8
Compare
796f9a2 to
9692db5
Compare
5e88bb8 to
b65c060
Compare
9692db5 to
86d519d
Compare
b65c060 to
299608f
Compare
86d519d to
221618e
Compare
299608f to
dd0b9fe
Compare
9341e49 to
dda0697
Compare
248b99e to
08a48da
Compare
4e7c26c to
941485d
Compare
b06697d to
2942f66
Compare
941485d to
52e64ef
Compare
2942f66 to
5e3d848
Compare
52e64ef to
342762e
Compare
342762e to
a6245b8
Compare
hathor/indexes/manager.py
Outdated
| # We need to check r1 as well to make sure we don't count twice the transactions/blocks that are | ||
| # just changing from voided to executed or vice-versa | ||
| if r1 and r3: | ||
| if r1: |
There was a problem hiding this comment.
Before, this was r1 and r3 which was equivalent to r2 and r4 which is equivalent to self.sorted_all.add_tx(tx) and self.sorted_blocks.add_tx(tx) (in the case of blocks, and analogous for txs).
Then new code is just equivalent to the sorted_all parts and is missing the sorted_blocks parts, which would mean r1 and r2 now. Is this correct?
hathor/simulator/fake_connection.py
Outdated
| tips1 = {tx.hash for tx in state1.protocol.node.tx_storage.iter_mempool()} | ||
| tips2 = {tx.hash for tx in state2.protocol.node.tx_storage.iter_mempool()} |
a6245b8 to
0f8cb8d
Compare
Motivation
After removing sync-v1 (#1197) and removing block ties (#673) there is no need to have the sync-v1 indexes (tx-tips, block-tips and all-tips). There should be a slight runtime benefit (no measurement has been made), but more noticeably, there will be a substantial improvement in startup time.
Acceptance Criteria
Checklist
master, confirm this code is production-ready and can be included in future releases as soon as it gets merged