Commit 1c1fe71
committed
Rebuild manager forwarded htlcs maps from Channels
We have an overarching goal of (mostly) getting rid of ChannelManager
persistence and rebuilding the ChannelManager's state from existing
ChannelMonitors, due to issues when the two structs are out-of-sync on restart.
The main issue that can arise is channel force closure.
Here we start this process by rebuilding
ChannelManager::decode_update_add_htlcs, forward_htlcs, and
pending_intercepted_htlcs from Channel data, which will soon be included in the
ChannelMonitors as part of a different series of PRs.
We also fix the reload_node test util to use the node's pre-reload config after
restart. The previous behavior was a bit surprising and led to one of this
commit's tests failing.1 parent cfd2bd9 commit 1c1fe71
File tree
3 files changed
+159
-3
lines changed- lightning/src/ln
3 files changed
+159
-3
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
18271 | 18271 | | |
18272 | 18272 | | |
18273 | 18273 | | |
| 18274 | + | |
| 18275 | + | |
| 18276 | + | |
| 18277 | + | |
| 18278 | + | |
| 18279 | + | |
| 18280 | + | |
| 18281 | + | |
| 18282 | + | |
| 18283 | + | |
| 18284 | + | |
| 18285 | + | |
| 18286 | + | |
| 18287 | + | |
| 18288 | + | |
| 18289 | + | |
| 18290 | + | |
| 18291 | + | |
| 18292 | + | |
| 18293 | + | |
| 18294 | + | |
| 18295 | + | |
| 18296 | + | |
| 18297 | + | |
| 18298 | + | |
| 18299 | + | |
| 18300 | + | |
| 18301 | + | |
| 18302 | + | |
| 18303 | + | |
| 18304 | + | |
| 18305 | + | |
| 18306 | + | |
| 18307 | + | |
| 18308 | + | |
| 18309 | + | |
| 18310 | + | |
| 18311 | + | |
| 18312 | + | |
| 18313 | + | |
| 18314 | + | |
| 18315 | + | |
| 18316 | + | |
| 18317 | + | |
| 18318 | + | |
| 18319 | + | |
| 18320 | + | |
| 18321 | + | |
| 18322 | + | |
| 18323 | + | |
| 18324 | + | |
| 18325 | + | |
| 18326 | + | |
| 18327 | + | |
| 18328 | + | |
| 18329 | + | |
| 18330 | + | |
| 18331 | + | |
| 18332 | + | |
| 18333 | + | |
| 18334 | + | |
| 18335 | + | |
| 18336 | + | |
| 18337 | + | |
| 18338 | + | |
| 18339 | + | |
| 18340 | + | |
| 18341 | + | |
| 18342 | + | |
| 18343 | + | |
18274 | 18344 | | |
18275 | 18345 | | |
18276 | 18346 | | |
| |||
18300 | 18370 | | |
18301 | 18371 | | |
18302 | 18372 | | |
18303 | | - | |
| 18373 | + | |
18304 | 18374 | | |
18305 | 18375 | | |
18306 | 18376 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1382 | 1382 | | |
1383 | 1383 | | |
1384 | 1384 | | |
| 1385 | + | |
1385 | 1386 | | |
1386 | 1387 | | |
1387 | | - | |
| 1388 | + | |
1388 | 1389 | | |
1389 | 1390 | | |
1390 | 1391 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
508 | 508 | | |
509 | 509 | | |
510 | 510 | | |
511 | | - | |
| 511 | + | |
512 | 512 | | |
513 | 513 | | |
514 | 514 | | |
| |||
1173 | 1173 | | |
1174 | 1174 | | |
1175 | 1175 | | |
| 1176 | + | |
| 1177 | + | |
| 1178 | + | |
| 1179 | + | |
| 1180 | + | |
| 1181 | + | |
| 1182 | + | |
| 1183 | + | |
| 1184 | + | |
| 1185 | + | |
| 1186 | + | |
| 1187 | + | |
| 1188 | + | |
| 1189 | + | |
| 1190 | + | |
| 1191 | + | |
| 1192 | + | |
| 1193 | + | |
| 1194 | + | |
| 1195 | + | |
| 1196 | + | |
| 1197 | + | |
| 1198 | + | |
| 1199 | + | |
| 1200 | + | |
| 1201 | + | |
| 1202 | + | |
| 1203 | + | |
| 1204 | + | |
| 1205 | + | |
| 1206 | + | |
| 1207 | + | |
| 1208 | + | |
| 1209 | + | |
| 1210 | + | |
| 1211 | + | |
| 1212 | + | |
| 1213 | + | |
| 1214 | + | |
| 1215 | + | |
| 1216 | + | |
| 1217 | + | |
| 1218 | + | |
| 1219 | + | |
| 1220 | + | |
| 1221 | + | |
| 1222 | + | |
| 1223 | + | |
| 1224 | + | |
| 1225 | + | |
| 1226 | + | |
| 1227 | + | |
| 1228 | + | |
| 1229 | + | |
| 1230 | + | |
| 1231 | + | |
| 1232 | + | |
| 1233 | + | |
| 1234 | + | |
| 1235 | + | |
| 1236 | + | |
| 1237 | + | |
| 1238 | + | |
| 1239 | + | |
| 1240 | + | |
| 1241 | + | |
| 1242 | + | |
| 1243 | + | |
| 1244 | + | |
| 1245 | + | |
| 1246 | + | |
| 1247 | + | |
| 1248 | + | |
| 1249 | + | |
| 1250 | + | |
| 1251 | + | |
| 1252 | + | |
| 1253 | + | |
| 1254 | + | |
| 1255 | + | |
| 1256 | + | |
| 1257 | + | |
| 1258 | + | |
| 1259 | + | |
| 1260 | + | |
1176 | 1261 | | |
1177 | 1262 | | |
1178 | 1263 | | |
| |||
0 commit comments