glozow
77ebe8f280
[prep/test] have TxOrphanage remember its own limits in LimitOrphans
...
Move towards a model where TxOrphanage is initialized with limits that
it remembers throughout its lifetime.
Remove the param. Limiting by number of unique orphans will be removed
in a later commit.
Now that -maxorphantx is gone, this does not change the node behavior.
The parameter is only used in tests.
2025-07-14 16:13:10 -04:00
glozow
08e58fa911
[prep/refactor] move txorphanage to node namespace and directory
...
This is move-only.
2025-07-11 13:52:50 -04:00
marcofleon
a60f863d3e
scripted-diff: Replace GenTxidVariant with GenTxid
...
-BEGIN VERIFY SCRIPT-
sed -i 's/GenTxidVariant/GenTxid/g' $(git grep -l 'GenTxidVariant')
-END VERIFY SCRIPT-
2025-07-08 20:00:51 +01:00
marcofleon
1b528391c7
Convert txrequest to GenTxidVariant
...
Switch all instances of GenTxid to the new variant
in `txrequest` and complete `txdownloadman_impl` by
converting `GetRequestsToSend`.
2025-07-08 20:00:51 +01:00
marcofleon
bde4579b07
Convert txdownloadman_impl to GenTxidVariant
...
Convert all of `txdownloadman_impl` to the new variant except for
`GetRequestsToSend`, which will be easier to switch at the same
time as `txrequest`.
2025-07-08 20:00:43 +01:00
glozow
f7658d9b14
[cleanup] remove p2p_inv from AddTxAnnouncement
...
This param is no longer needed since orphan parent requests are added to
the TxRequestTracker directly.
2025-01-06 09:02:05 -05:00
glozow
62a9ff1870
[refactor] change type of unique_parents to Txid
2025-01-06 09:02:05 -05:00
glozow
917ab810d9
[doc] comment fixups from n30110
2024-10-30 21:13:01 -04:00
glozow
fa584cbe72
[p2p] add TxDownloadOptions bool to make TxRequestTracker deterministic
...
Forward this bool to the TxRequestTracker ctor. This is needed for
stablity in TxDownloadManager fuzzers
2024-10-24 21:23:56 -04:00
glozow
fa7027d0fc
[refactor] add CheckIsEmpty and GetOrphanTransactions, remove access to TxDownloadMan internals
2024-10-24 21:23:56 -04:00
glozow
969b07237b
[refactor] wrap {Have,Get}TxToReconsider in txdownload
2024-10-24 21:23:56 -04:00
glozow
f150fb94e7
[refactor] make AlreadyHaveTx and Find1P1CPackage private to TxDownloadImpl
2024-10-24 21:23:56 -04:00
glozow
1e08195135
[refactor] move new tx logic to txdownload
...
Also delete external RecentRejectsReconsiderableFilter() access since it
is no longer necessary.
2024-10-24 21:23:56 -04:00
glozow
257568eab5
[refactor] move invalid package processing to TxDownload
2024-10-24 21:23:56 -04:00
glozow
c4ce0c1218
[refactor] move invalid tx processing to TxDownload
...
Move-only. Also delete external RecentRejectsFilter() access since it is
no longer necessary.
2024-10-24 21:23:56 -04:00
glozow
c6b21749ca
[refactor] move valid tx processing to TxDownload
2024-10-24 21:23:56 -04:00
glozow
a8cf3b6e84
[refactor] move Find1P1CPackage to txdownload
...
Move-only.
2024-10-24 21:23:56 -04:00
glozow
3a41926d1b
[refactor] move notfound processing to txdownload
2024-10-24 21:23:56 -04:00
glozow
042a97ce7f
[refactor] move tx inv/getdata handling to txdownload
2024-10-24 21:23:56 -04:00
glozow
f48d36cd97
[refactor] move peer (dis)connection logic to TxDownload
...
The information stored in TxDownloadConnectionInfo isn't used until the
next commit.
2024-10-24 21:23:56 -04:00
glozow
f61d9e4b4b
[refactor] move AlreadyHaveTx to TxDownload
...
This is move-only.
Also delete external RecentConfirmedTransactionsFilter() access since it
is no longer necessary.
2024-10-24 21:23:56 -04:00
glozow
84e4ef843d
[txdownload] add read-only reference to mempool
...
This will become necessary in later commits that query mempool. We also
introduce the TxDownloadOptions in this commit to make the later diff
easier to review.
2024-10-24 21:23:56 -04:00
glozow
af918349de
[refactor] move ValidationInterface functions to TxDownloadManager
...
This is move-only.
2024-10-24 21:23:56 -04:00
glozow
5f9004e155
[refactor] add TxDownloadManager wrapping TxOrphanage, TxRequestTracker, and bloom filters
...
This module is going to be responsible for managing everything related
to transaction download, including txrequest, orphan transactions and
package relay. It will be responsible for managing usage of the
TxOrphanage and instructing PeerManager:
- what tx or package-related messages to send to which peer
- whether a tx or package-related message is allowed or useful
- what transactions are available to try accepting to mempool
Future commits will consolidate the interface and re-delegate
interactions from PeerManager to TxDownloadManager.
2024-10-24 21:23:55 -04:00