rust-lightning icon indicating copy to clipboard operation
rust-lightning copied to clipboard

Log available liquidity on each channel when starting routefinding

Open TheBlueMatt opened this issue 1 year ago • 2 comments

One of the most common first-steps in troubleshooting routefinding issues is we ask for the local channel state to determine what the available HTLC bounds are. Thus, we really should be logging the bounds instead, which we do here.

TheBlueMatt avatar Mar 12 '24 14:03 TheBlueMatt

Isn't this more or less redundant since we already log next_outbound_htlc_limit_msat for any first-hops we ignore?:

https://github.com/lightningdevkit/rust-lightning/blob/f5ee8c23a1a52bc51c00eb8a62b0b5226acee80b/lightning/src/routing/router.rs#L2178-L2183

tnull avatar Mar 14 '24 09:03 tnull

That won't tell us if the channel is disabled or otherwise missing, but, fair point, it does answer it in some cases.

TheBlueMatt avatar Mar 18 '24 14:03 TheBlueMatt

Rebased and updated a bit, I think this this is worth doing, and also took the opportunity to log the limit that is violated any time we log that we're not using a channel, rather than only when its a first-hop.

TheBlueMatt avatar May 30 '24 15:05 TheBlueMatt