Page MenuHomePhabricator

[avalanche] Remove obsolete orphan proofs
AbandonedPublic

Authored by Fabien on Jun 17 2022, 15:54.

Details

Reviewers
deadalnix
Group Reviewers
Restricted Project
Summary

This adds a cleanup method to the peer manager for removing the inactive proofs.
For now only the obsolete orphans are cleaned up, i.e. orphans that have been registered for 30 minutes or more and did not make it into the valid pool.
Since it is trivial to fill the orphan pool with garbage, this is a best effort attempt to recover from such a bad state should it happen.
More cleanups will be added later.

Depends on D11630 and D11636.

Test Plan
ninja all check-all

Diff Detail

Event Timeline

Fabien requested review of this revision.Jun 17 2022, 15:54
deadalnix requested changes to this revision.Jun 17 2022, 19:42
deadalnix added a subscriber: deadalnix.
deadalnix added inline comments.
src/avalanche/proofpool.cpp
144–154

There is not much in there that tell me this is the orphan proofs we are talking about, but, considering the orphan pool need to be limited in size, why does this needs to happen at all?

And if it really needs to happen, why is the avalanche processor doing it?

None of this makes sense to me.

This revision now requires changes to proceed.Jun 17 2022, 19:42

Keep the cleanup located in the peer manager, expand on the rationale in the summary

deadalnix requested changes to this revision.Jun 21 2022, 00:44

The rationale makes no sense. It is possible to balloon the pool in 30mins, so this is insufficient. So you need another criteria to evict from the pool, but it you have that other criteria, it is more likely than not that this one becomes useless.

This serves no purpose.

This revision now requires changes to proceed.Jun 21 2022, 00:44