Refactor naming for background tasks.

This commit is contained in:
Christian
2020-11-25 21:07:50 +01:00
parent 7738c5faa1
commit ec015e7620
6 changed files with 10 additions and 8 deletions
@@ -78,7 +78,7 @@ namespace MQTTnet.Implementations
_socket.Bind(_localEndPoint);
_socket.Listen(_options.ConnectionBacklog);
Task.Run(() => AcceptClientConnectionsAsync(cancellationToken), cancellationToken).Forget(_logger);
Task.Run(() => AcceptClientConnectionsAsync(cancellationToken), cancellationToken).RunInBackground(_logger);
return true;
}
@@ -115,7 +115,7 @@ namespace MQTTnet.Implementations
continue;
}
Task.Run(() => TryHandleClientConnectionAsync(clientSocket), cancellationToken).Forget(_logger);
Task.Run(() => TryHandleClientConnectionAsync(clientSocket), cancellationToken).RunInBackground(_logger);
}
catch (OperationCanceledException)
{