Skip to content

Commit cb606dd

Browse files
committed
Increase the default liquidity_offset_half_life to six hours
Even at relatively high payment volumes, decaying knowledge of each individual channel every hour causes aggressive retrying of channels as we quickly forget the state of a channel. Even with the historical tracker, this isn't fully remedied, as we'll track the history bounds with the decayed value. Instead, we decay every six hours here, reducing how often we'll retry a channel due to decay. In addition to this, the decay likely needs to be substantially more linear, as tracked in #1752.
1 parent ecdcffa commit cb606dd

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

lightning/src/routing/scoring.rs

+3-3
Original file line numberDiff line numberDiff line change
@@ -419,7 +419,7 @@ pub struct ProbabilisticScoringParameters {
419419
/// liquidity bounds are 200,000 sats and 600,000 sats, after this amount of time the upper-
420420
/// and lower- liquidity bounds will be decayed to 100,000 and 800,000 sats.
421421
///
422-
/// Default value: hour
422+
/// Default value: 6 hours
423423
///
424424
/// # Note
425425
///
@@ -604,7 +604,7 @@ impl ProbabilisticScoringParameters {
604604
base_penalty_msat: 0,
605605
base_penalty_amount_multiplier_msat: 0,
606606
liquidity_penalty_multiplier_msat: 0,
607-
liquidity_offset_half_life: Duration::from_secs(3600),
607+
liquidity_offset_half_life: Duration::from_secs(6 * 60 * 60),
608608
liquidity_penalty_amount_multiplier_msat: 0,
609609
manual_node_penalties: HashMap::new(),
610610
anti_probing_penalty_msat: 0,
@@ -627,7 +627,7 @@ impl Default for ProbabilisticScoringParameters {
627627
base_penalty_msat: 500,
628628
base_penalty_amount_multiplier_msat: 8192,
629629
liquidity_penalty_multiplier_msat: 40_000,
630-
liquidity_offset_half_life: Duration::from_secs(3600),
630+
liquidity_offset_half_life: Duration::from_secs(6 * 60 * 60),
631631
liquidity_penalty_amount_multiplier_msat: 256,
632632
manual_node_penalties: HashMap::new(),
633633
anti_probing_penalty_msat: 250,

0 commit comments

Comments
 (0)