Commit 23eb12e
committed
Track ChannelTransactionParameters in RevokedOutput
The `ChannelMonitor` and `OnchainTxHandler` have historically been tied
together, often tracking some of the same state twice. As we introduce
support for splices in the `ChannelMonitor`, we'd like to avoid leaking
some of those details to the `OnchainTxHandler`. Ultimately, the
`OnchainTxHandler` should stand on its own and support claiming funds
from multiple `ChannelMonitor`s, allowing us to save on fees by batching
aggregatable claims across multiple in-flight closing channels.
Once splices are supported, we may run into cases where we are
attempting to claim an output from a specific `FundingScope`, while also
having an additional pending `FundingScope` for a splice. If the pending
splice confirms over the output claim, we need to cancel the claim and
re-offer it with the set of relevant parameters in the new
`FundingScope`.
This commit tracks the `ChannelTransactionParameters` for the specific
`FundingScope` the `RevokedOutput` claim originated from. This allows us
to remove the dependency on `OnchainTxHandler` when obtaining the
current `ChannelTransactionParameters` and ensures any alternative state
due to splicing does not leak into the `OnchainTxHandler`.1 parent 97348c7 commit 23eb12e
2 files changed
+26
-17
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
3734 | 3734 | | |
3735 | 3735 | | |
3736 | 3736 | | |
3737 | | - | |
3738 | | - | |
3739 | | - | |
3740 | | - | |
3741 | | - | |
3742 | | - | |
| 3737 | + | |
| 3738 | + | |
| 3739 | + | |
3743 | 3740 | | |
3744 | 3741 | | |
3745 | 3742 | | |
| |||
3936 | 3933 | | |
3937 | 3934 | | |
3938 | 3935 | | |
3939 | | - | |
3940 | | - | |
3941 | | - | |
3942 | | - | |
| 3936 | + | |
| 3937 | + | |
3943 | 3938 | | |
3944 | 3939 | | |
3945 | 3940 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
136 | 136 | | |
137 | 137 | | |
138 | 138 | | |
| 139 | + | |
139 | 140 | | |
140 | 141 | | |
141 | 142 | | |
142 | | - | |
| 143 | + | |
| 144 | + | |
| 145 | + | |
| 146 | + | |
| 147 | + | |
| 148 | + | |
| 149 | + | |
| 150 | + | |
| 151 | + | |
143 | 152 | | |
144 | 153 | | |
145 | 154 | | |
| |||
148 | 157 | | |
149 | 158 | | |
150 | 159 | | |
151 | | - | |
| 160 | + | |
| 161 | + | |
152 | 162 | | |
153 | 163 | | |
154 | 164 | | |
| |||
161 | 171 | | |
162 | 172 | | |
163 | 173 | | |
164 | | - | |
| 174 | + | |
| 175 | + | |
165 | 176 | | |
166 | 177 | | |
167 | 178 | | |
| |||
778 | 789 | | |
779 | 790 | | |
780 | 791 | | |
781 | | - | |
782 | | - | |
| 792 | + | |
| 793 | + | |
783 | 794 | | |
784 | 795 | | |
785 | 796 | | |
| |||
1589 | 1600 | | |
1590 | 1601 | | |
1591 | 1602 | | |
1592 | | - | |
1593 | 1603 | | |
1594 | 1604 | | |
1595 | 1605 | | |
| |||
1627 | 1637 | | |
1628 | 1638 | | |
1629 | 1639 | | |
1630 | | - | |
| 1640 | + | |
| 1641 | + | |
| 1642 | + | |
| 1643 | + | |
| 1644 | + | |
1631 | 1645 | | |
1632 | 1646 | | |
1633 | 1647 | | |
| |||
0 commit comments