public HttpClientHandlerBase Handle ( IClient client, Func <IHttpContext, Task> requestHandler, IHttpRequestProvider requestProvider, ILogger logger ) { return(_child.Handle(client, requestHandler, requestProvider, logger)); }
private async void Listen(IHttpListener listener) { var aggregatedHandler = _handlers.Aggregate(); while (_isActive) { try { _requestProvider.Handle ( await listener.GetClient().ConfigureAwait(false), aggregatedHandler, _requestProvider, LoggerProvider?.CreateLogger("ClientHandler") ); } catch (Exception e) { Logger?.LogWarning("Error while getting client - " + e); } } Logger?.LogInformation("Spirit has stopped."); }