public void HandleRequest(IHttpContext context) { IRequest request = context.Request; IResponse response = context.Response; ResponderList responder = new ResponderList(_conf, _responders); try { if (!responder.Respond(context)) { NotResponded?.Invoke(this, request); ResponderNotFoundHandler(context); } else { TriggerResponding(response, responder.HandlingResponder); Respond(response); TriggerResponded(request, responder.HandlingResponder); } } catch (Exception ex) { ExceptionHandler(context, ex); } }
protected internal void OnNotResponded(IHttpContext context) { Task.Run(() => NotResponded?.Invoke(this, context)); }