You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Allow operators to enable either built-in probing strategy through the
config file, CLI arguments, or environment variables. Validate strategy
settings and document the risk of probes locking outbound liquidity.
AI assistance: OpenAI Codex was used to implement and verify this
change.
dir_path = "/tmp/ldk-server/"# Path for LDK and BDK data persistence, optional, defaults to ~/Library/Application Support/ldk-server/ on macOS, ~/.ldk-server/ on Linux
Copy file name to clipboardExpand all lines: docs/configuration.md
+38Lines changed: 38 additions & 0 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -59,6 +59,44 @@ this node to go offline. Set `async_payments_role = "server"` to hold async paym
59
59
and onion messages for peers. The server role requires an announceable node configuration.
60
60
Leave the field unset to disable async payments.
61
61
62
+
### `[probing]`
63
+
64
+
Enables LDK Node's background probing service to train the payment scorer with current
65
+
channel-liquidity information. Probing is disabled when this section and the corresponding
66
+
CLI/environment options are absent.
67
+
68
+
The `strategy` field selects one of two path-selection methods:
69
+
70
+
-**`"high_degree"`** probes toward highly connected public nodes. The service uses the
71
+
payment scorer to select a path.
72
+
-**`"random_walk"`** constructs random paths through the public graph. This strategy does
73
+
not use the payment scorer to select a path.
74
+
75
+
The section accepts these fields:
76
+
77
+
| Field | Requirement and default | Description |
78
+
| --- | --- | --- |
79
+
|`strategy`| Required. No default. | Selects `"high_degree"` or `"random_walk"`. Start with `"random_walk"` for a payment node. Use `"high_degree"` for a dedicated probing node. |
80
+
|`top_node_count`| Required for `"high_degree"`. No default. Start with `100`. | Sets the number of highly connected public nodes in the destination set. The strategy cycles through this set. The value must be greater than `0`. |
81
+
|`max_hops`| Required for `"random_walk"`. No default. Start with `5`. | Sets the maximum number of hops in a random path. The value must be at least `2`. LDK Node changes values greater than `19` to `19`. |
82
+
|`interval_secs`| Optional. The default is `10`. | Sets the number of seconds between probe attempts. LDK Node changes `0` to its minimum interval of 100 milliseconds. |
83
+
|`max_locked_msat`| Optional. The default is `100000000` (100,000 satoshis). | Limits the total amount and pending fees of in-flight probes. The service skips a probe that exceeds the remaining limit. Built-in probes use 1,000,000 through 10,000,000 millisatoshis before routing fees. |
84
+
|`diversity_penalty_msat`| Optional. The default is `0`. | Adds a virtual routing cost to recently probed channels. The service does not pay this amount. The cost decreases to zero over 24 hours and encourages different paths. This field only affects `"high_degree"`. |
85
+
|`cooldown_secs`| Optional. The default is `3600`. | Sets the time before `"high_degree"` can select the same destination again. The strategy starts a new cycle immediately after it probes all destinations. |
86
+
87
+
```toml
88
+
[probing]
89
+
strategy = "high_degree"
90
+
top_node_count = 100
91
+
interval_secs = 30
92
+
max_locked_msat = 100000000
93
+
diversity_penalty_msat = 250
94
+
cooldown_secs = 3600
95
+
```
96
+
97
+
> **Caution:** Probes send real HTLCs over real channels. A probe can lock outbound liquidity
98
+
> until its HTLC expires. Use `max_locked_msat` to limit this risk.
99
+
62
100
### `[storage.disk]`
63
101
64
102
Where persistent data is stored. Defaults to `~/.ldk-server/` on Linux and
0 commit comments