Skip to content

Commit 969613d

Browse files
committed
Drop verbose log entries in BP when no network graph is provided
If no network graph is provided to the `BackgroundProcessor`, we log every time the processor loop goes around (at least every 100ms, if not more) which fille up logs with useless indications that we have no network graph.
1 parent a4c4301 commit 969613d

File tree

1 file changed

+1
-3
lines changed
  • lightning-background-processor/src

1 file changed

+1
-3
lines changed

lightning-background-processor/src/lib.rs

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -283,8 +283,8 @@ macro_rules! define_run_body {
283283
// continuing our normal cadence.
284284
if last_prune_call.elapsed().as_secs() > if have_pruned { NETWORK_PRUNE_TIMER } else { FIRST_NETWORK_PRUNE_TIMER } {
285285
// The network graph must not be pruned while rapid sync completion is pending
286-
log_trace!($logger, "Assessing prunability of network graph");
287286
if let Some(network_graph) = $gossip_sync.prunable_network_graph() {
287+
log_trace!($logger, "Pruning and persisting network graph.");
288288
network_graph.remove_stale_channels_and_tracking();
289289

290290
if let Err(e) = $persister.persist_graph(network_graph) {
@@ -293,8 +293,6 @@ macro_rules! define_run_body {
293293

294294
last_prune_call = Instant::now();
295295
have_pruned = true;
296-
} else {
297-
log_trace!($logger, "Not pruning network graph, either due to pending rapid gossip sync or absence of a prunable graph.");
298296
}
299297
}
300298

0 commit comments

Comments
 (0)