multi: query mempool spend when a new input is received

This commit changes how a new input sweep request is handled - now we
will query the mempool and see if it's already been spent. If so, we'll
update its state as we may need to RBF this input.
This commit is contained in:
yyforyongyu committed 2024-04-19 21:33:22 +08:00
1 parent 6a2e3fb203
commit 47478718d4
4 files changed
+180 -5

No files matched your search

+1
View File
@@ -1073,6 +1073,7 @@ func newServer(cfg *Config, listenAddrs []net.Addr,
Signer: cc.Wallet.Cfg.Signer,
Wallet: newSweeperWallet(cc.Wallet),
TickerDuration: cfg.Sweeper.BatchWindowDuration,
Mempool: cc.MempoolNotifier,
Notifier: cc.ChainNotifier,
Store: sweeperStore,
MaxInputsPerTx: sweep.DefaultMaxInputsPerTx,