Esempio n. 1
0
        private static async Task HandleRequest(IISHttpContext context)
        {
            bool successfulRequest = false;

            try
            {
                successfulRequest = await context.ProcessRequestAsync();
            }
            catch (Exception ex)
            {
                context.Server._logger.LogError("Exception in ProcessRequestAsync", ex);
            }
            finally
            {
                CompleteRequest(context, successfulRequest);
            }
        }
Esempio n. 2
0
        private static async Task HandleRequest(IISHttpContext context)
        {
            bool successfulRequest = false;

            try
            {
                successfulRequest = await context.ProcessRequestAsync();
            }
            catch (Exception ex)
            {
                context.Server._logger.LogError(0, ex, $"Unexpected exception in {nameof(IISHttpServer)}.{nameof(HandleRequest)}.");
            }
            finally
            {
                CompleteRequest(context, successfulRequest);
            }
        }