From 8c449fff304e89167179aa62af1947fdb3828b9c Mon Sep 17 00:00:00 2001 From: Claudia Murialdo Date: Tue, 31 May 2022 19:07:13 -0300 Subject: [PATCH] Remove unused GxHttpAzureResponseExtension. Fix error on last commit in GXMultiCall when reading inputstream, is must be synchronous. --- .../GxClasses/Middleware/GXHttpServices.cs | 10 ++-------- .../Handlers/HttpHandler/GXHttpAzureContextAccessor.cs | 7 ------- 2 files changed, 2 insertions(+), 15 deletions(-) diff --git a/dotnet/src/dotnetframework/GxClasses/Middleware/GXHttpServices.cs b/dotnet/src/dotnetframework/GxClasses/Middleware/GXHttpServices.cs index cbb85fc1d..c6b87401c 100644 --- a/dotnet/src/dotnetframework/GxClasses/Middleware/GXHttpServices.cs +++ b/dotnet/src/dotnetframework/GxClasses/Middleware/GXHttpServices.cs @@ -62,24 +62,18 @@ GXRouting GetRouting() return gxRouting; } #endif -#if NETCORE - public override async void webExecute() + public override void webExecute() { +#if NETCORE GxRestWrapper handler = null; #else - public override void webExecute() - { Utils.GxRestService handler = null; #endif try { HttpRequest req = context.HttpContext.Request; string gxobj = GetNextPar().ToLower(); -#if NETCORE - string jsonStr = await new StreamReader(req.GetInputStream()).ReadToEndAsync(); -#else string jsonStr = (new StreamReader(req.GetInputStream())).ReadToEnd(); -#endif GxSimpleCollection parmsColl = new GxSimpleCollection(); if (!string.IsNullOrEmpty(jsonStr)) { diff --git a/dotnet/src/extensions/Azure/Handlers/HttpHandler/GXHttpAzureContextAccessor.cs b/dotnet/src/extensions/Azure/Handlers/HttpHandler/GXHttpAzureContextAccessor.cs index 88a3d61c8..14172f9b5 100644 --- a/dotnet/src/extensions/Azure/Handlers/HttpHandler/GXHttpAzureContextAccessor.cs +++ b/dotnet/src/extensions/Azure/Handlers/HttpHandler/GXHttpAzureContextAccessor.cs @@ -277,11 +277,4 @@ public override PipeWriter BodyWriter } } } - public static class GxHttpAzureResponseExtension - { - public static void Write(this GxHttpAzureResponse response, string value) - { - response.Body.Write(Encoding.UTF8.GetBytes(value)); - } - } }