Page MenuHomePhabricator

mempool: Save & restore mempool entry acceptance height on reorg
ClosedPublic

Authored by Fabien on Feb 17 2023, 12:08.

Details

Summary
MR !1128 introduced a regression whereby mempool entry acceptance height
would be lost across reorgs and just set to the new tip height after the
block unwind is done.  This MR fixes that and restores previous behavior
where a mempool entry's acceptance height is remembered until a
node restart (at which point it is lost since it is not serialized).

The `mempool_reorg.py` functional test was modified to also test that the
height is preserved properly across reorgs.

Port of bchn#1162. Depends on D13133.

Test Plan
ninja all check-all