RFC: Move Peer and PeerManagerImpl declarations to separate header#20925
RFC: Move Peer and PeerManagerImpl declarations to separate header#20925jnewbery wants to merge 3 commits intobitcoin:masterfrom
Conversation
|
This is a minimal implementation of what was first discussed here: #20758 (comment). Thoughts, @ajtowns? |
|
The following sections might be updated with supplementary metadata relevant to reviewers and maintainers. ConflictsReviewers, this pull request conflicts with the following ones:
If you consider this pull request important, please also help to review the conflicting pull requests. Ideally, start with the one that should be merged first. |
ajtowns
left a comment
There was a problem hiding this comment.
I'm not going to think seriously about this until having tried to pull orphan handling or similar into its own module, in the hopes that that alone will be enough to make testing work better.
be52d7e to
1363e90
Compare
|
Fixed the typo. I'll fix the linter and fuzzer errors if this PR gets some concept ACKs. |
|
Closing this for now. Let's revisit once #21148 is merged. |
Not sure whether this is desirable, so marking as a proof of concept.
This moves the
PeerandPeerManagerImpldeclarations to their own header file,peerman_impl.h, which can be included bynet_processing.cppand the test/bench/fuzz files.The benefits of this are:
PeerManagerImplfunctions which are exposed through thePeerManagerinterface for testing, but would otherwise be private can be removed fromPeerManager. That means thatPeerManagertruly is net_processing's minimal interface to expose to the rest of the program.Peerobjects, it can do so, since they're exposed in peerman_impl header.