@@ -558,6 +558,9 @@ func (s *Server) probePaymentRequest(ctx context.Context, paymentRequest string,
558
558
// payment won't be blocked along the route to the destination. We send
559
559
// a probe payment with unmodified route hints.
560
560
if ! isLSP (hints , s .cfg .RouterBackend .FetchChannelEndpoints ) {
561
+ log .Infof ("No LSP detected, probing destination %x" ,
562
+ probeRequest .Dest )
563
+
561
564
probeRequest .RouteHints = invoicesrpc .CreateRPCRouteHints (hints )
562
565
return s .sendProbePayment (ctx , probeRequest )
563
566
}
@@ -571,9 +574,14 @@ func (s *Server) probePaymentRequest(ctx context.Context, paymentRequest string,
571
574
return nil , err
572
575
}
573
576
577
+ // Set the destination to the LSP node ID.
578
+ lspDest := lspHint .NodeID .SerializeCompressed ()
579
+ probeRequest .Dest = lspDest
580
+
581
+ log .Infof ("LSP detected, probing LSP with destination: %x" , lspDest )
582
+
574
583
// The adjusted route hints serve the payment probe to find the last
575
584
// public hop to the LSP on the route.
576
- probeRequest .Dest = lspHint .NodeID .SerializeCompressed ()
577
585
if len (lspAdjustedRouteHints ) > 0 {
578
586
probeRequest .RouteHints = invoicesrpc .CreateRPCRouteHints (
579
587
lspAdjustedRouteHints ,
@@ -609,7 +617,8 @@ func (s *Server) probePaymentRequest(ctx context.Context, paymentRequest string,
609
617
// Dispatch the payment probe with adjusted fee amount.
610
618
resp , err := s .sendProbePayment (ctx , probeRequest )
611
619
if err != nil {
612
- return nil , err
620
+ return nil , fmt .Errorf ("failed to send probe payment to " +
621
+ "LSP with destination %x: %w" , lspDest , err )
613
622
}
614
623
615
624
// If the payment probe failed we only return the failure reason and
0 commit comments