-
Notifications
You must be signed in to change notification settings - Fork 10.5k
Description
I have recently upgraded an application created in dotnet core 1.0 to 2.1. And ever since HttpContext, the application was using to retrieve information, is only having default values and the following lines of code are failing:
if (!HttpContext.Items.Keys.Contains(Utility.APIGATEWAY_REQUEST)) { //log error }
var apiGatewayRequest = HttpContext.Items[Utility.APIGATEWAY_REQUEST] as APIGatewayProxyRequest;
All the HttpContext is fetching is:
The UI of the same is made in Angular which makes service calls to AWS Lambdas (made using dotnet core) for all the requirements. User data is stored in AWS Cognito and every time a service call is made it first gets verified by fetching data from Cognito. This part stopped working after the framework upgrade.
Custom api gateway authorizer is used for Cognito and also HttpContext is used inside a controller.
I am not sure if this scenario using Angular, DotNet Core 2.1, AWS Lambda, AWS Cognito, Custom api gateway authorizer was ever tested but I am stuck.
Please provide some inputs or some workaround.