diff --git a/src/Jobs/NodeChannelSubscribeJob.cs b/src/Jobs/NodeChannelSubscribeJob.cs index 24995818..98b82ff4 100644 --- a/src/Jobs/NodeChannelSubscribeJob.cs +++ b/src/Jobs/NodeChannelSubscribeJob.cs @@ -87,11 +87,18 @@ public async Task Execute(IJobExecutionContext context) _logger.LogError(e, "Error reading and update event of node {NodeId}", nodeId); throw new JobExecutionException(e, true); } + + } + + } catch (Exception e) { _logger.LogError(e, "Error while subscribing for the channel updates of node {NodeId}", nodeId); + //Sleep to avoid massive requests + await Task.Delay(1000); + throw new JobExecutionException(e, true); } diff --git a/src/Jobs/ProcessNodeChannelAcceptorJob.cs b/src/Jobs/ProcessNodeChannelAcceptorJob.cs index 89a33a83..413bcb5c 100644 --- a/src/Jobs/ProcessNodeChannelAcceptorJob.cs +++ b/src/Jobs/ProcessNodeChannelAcceptorJob.cs @@ -241,7 +241,12 @@ await AcceptChannelOpeningRequestWithUpfrontShutdown(_nBXplorerService, catch (Exception e) { _logger.LogError(e, "Error on {JobName}", nameof(ProcessNodeChannelAcceptorJob)); + + //Sleep to avoid massive requests + await Task.Delay(1000); + throw new JobExecutionException(e, true); + } } } \ No newline at end of file