Commit ac677a0
Implement Retention Period Support (#592)
* Implement Retention Period support
- new cli flag retention_period_days allows the user to retain more days of data
* Replace get_source with get_retention_root
* Set retention period default to 0
* Rename references to source to retention root
* Update retention root advancement to use pruning point samples
* Default retention period point to pruning point only and not including history root
* Move new root check outside
* Rename history root to retention checkpoint
* Use Option for retention_period_days
* Fix get timestamp; change end condition of retention root advance loop
* Show logs for retention period disk usage and require min 3 days if set
* Minor comment fixes
* Consistent naming to retention period root
* consistent comments
* simplify retention root search loop
* important: handle archival upgrade correctly
* daemon check: fix constants and msg
* ergonomic rust style
* keep retention root in place for archives
* update tn10 doc to the upcoming version
---------
Co-authored-by: Michael Sutton <msutton@cs.huji.ac.il>1 parent 036fa8c commit ac677a0
File tree
13 files changed
+235
-82
lines changed- components/consensusmanager/src
- consensus
- core/src
- api
- config
- src
- consensus
- model/stores
- pipeline
- pruning_processor
- virtual_processor
- processes/pruning_proof
- database/src
- docs
- kaspad/src
13 files changed
+235
-82
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
254 | 254 | | |
255 | 255 | | |
256 | 256 | | |
257 | | - | |
258 | | - | |
259 | | - | |
| 257 | + | |
| 258 | + | |
| 259 | + | |
260 | 260 | | |
261 | 261 | | |
262 | 262 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
143 | 143 | | |
144 | 144 | | |
145 | 145 | | |
146 | | - | |
147 | | - | |
| 146 | + | |
| 147 | + | |
148 | 148 | | |
149 | 149 | | |
150 | 150 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
68 | 68 | | |
69 | 69 | | |
70 | 70 | | |
| 71 | + | |
| 72 | + | |
| 73 | + | |
71 | 74 | | |
72 | 75 | | |
73 | 76 | | |
| |||
95 | 98 | | |
96 | 99 | | |
97 | 100 | | |
| 101 | + | |
98 | 102 | | |
99 | 103 | | |
100 | 104 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
307 | 307 | | |
308 | 308 | | |
309 | 309 | | |
310 | | - | |
311 | | - | |
312 | | - | |
| 310 | + | |
| 311 | + | |
313 | 312 | | |
314 | 313 | | |
315 | 314 | | |
316 | 315 | | |
| 316 | + | |
| 317 | + | |
| 318 | + | |
| 319 | + | |
| 320 | + | |
| 321 | + | |
| 322 | + | |
| 323 | + | |
| 324 | + | |
| 325 | + | |
| 326 | + | |
| 327 | + | |
| 328 | + | |
| 329 | + | |
| 330 | + | |
| 331 | + | |
| 332 | + | |
| 333 | + | |
| 334 | + | |
| 335 | + | |
| 336 | + | |
| 337 | + | |
| 338 | + | |
| 339 | + | |
| 340 | + | |
| 341 | + | |
| 342 | + | |
317 | 343 | | |
318 | 344 | | |
319 | 345 | | |
| |||
565 | 591 | | |
566 | 592 | | |
567 | 593 | | |
568 | | - | |
569 | | - | |
| 594 | + | |
| 595 | + | |
570 | 596 | | |
571 | 597 | | |
572 | 598 | | |
| |||
621 | 647 | | |
622 | 648 | | |
623 | 649 | | |
624 | | - | |
625 | | - | |
626 | | - | |
627 | | - | |
628 | | - | |
629 | | - | |
| 650 | + | |
| 651 | + | |
630 | 652 | | |
631 | 653 | | |
632 | | - | |
| 654 | + | |
633 | 655 | | |
634 | | - | |
| 656 | + | |
635 | 657 | | |
636 | 658 | | |
637 | | - | |
638 | | - | |
| 659 | + | |
| 660 | + | |
639 | 661 | | |
640 | 662 | | |
641 | 663 | | |
642 | | - | |
| 664 | + | |
643 | 665 | | |
644 | | - | |
645 | 666 | | |
646 | 667 | | |
647 | | - | |
648 | | - | |
| 668 | + | |
| 669 | + | |
649 | 670 | | |
650 | 671 | | |
651 | 672 | | |
| |||
668 | 689 | | |
669 | 690 | | |
670 | 691 | | |
671 | | - | |
| 692 | + | |
672 | 693 | | |
673 | 694 | | |
674 | | - | |
| 695 | + | |
675 | 696 | | |
676 | | - | |
| 697 | + | |
677 | 698 | | |
678 | 699 | | |
679 | 700 | | |
| |||
748 | 769 | | |
749 | 770 | | |
750 | 771 | | |
751 | | - | |
| 772 | + | |
752 | 773 | | |
753 | 774 | | |
754 | 775 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
39 | 39 | | |
40 | 40 | | |
41 | 41 | | |
42 | | - | |
43 | | - | |
44 | | - | |
| 42 | + | |
| 43 | + | |
| 44 | + | |
| 45 | + | |
| 46 | + | |
| 47 | + | |
| 48 | + | |
| 49 | + | |
| 50 | + | |
| 51 | + | |
45 | 52 | | |
46 | 53 | | |
47 | 54 | | |
| |||
53 | 60 | | |
54 | 61 | | |
55 | 62 | | |
56 | | - | |
| 63 | + | |
| 64 | + | |
57 | 65 | | |
58 | 66 | | |
59 | 67 | | |
60 | 68 | | |
61 | 69 | | |
62 | 70 | | |
63 | 71 | | |
64 | | - | |
| 72 | + | |
| 73 | + | |
65 | 74 | | |
66 | 75 | | |
67 | 76 | | |
| |||
73 | 82 | | |
74 | 83 | | |
75 | 84 | | |
76 | | - | |
77 | | - | |
| 85 | + | |
| 86 | + | |
| 87 | + | |
| 88 | + | |
| 89 | + | |
| 90 | + | |
78 | 91 | | |
79 | 92 | | |
80 | 93 | | |
| |||
95 | 108 | | |
96 | 109 | | |
97 | 110 | | |
98 | | - | |
99 | | - | |
| 111 | + | |
| 112 | + | |
| 113 | + | |
| 114 | + | |
| 115 | + | |
| 116 | + | |
100 | 117 | | |
101 | 118 | | |
102 | 119 | | |
| |||
0 commit comments