Browse Source

Merge branch 'master' of https://github.com/dotnetcore/CAP

master
Savorboard 3 years ago
parent
commit
6111221095
1 changed files with 9 additions and 1 deletions
  1. +9
    -1
      src/DotNetCore.CAP/Processor/IDispatcher.Default.cs

+ 9
- 1
src/DotNetCore.CAP/Processor/IDispatcher.Default.cs View File

@@ -98,7 +98,15 @@ namespace DotNetCore.CAP.Processor
{
while (_receivedChannel.Reader.TryRead(out var message))
{
await _executor.DispatchAsync(message.Item1, message.Item2, _cts.Token);
try
{
await _executor.DispatchAsync(message.Item1, message.Item2, _cts.Token);
}
catch (Exception e)
{
_logger.LogError(e,
$"An exception occurred when invoke subscriber. MessageId:{message.Item1.DbId}");
}
}
}
}


Loading…
Cancel
Save