-
Notifications
You must be signed in to change notification settings - Fork 494
Seeking guidance on using PostMarshallHttpAuthenticationFeature with Minimal API #1679
-
Grateful for the release of the .NET 8 managed runtime for Lambda, I set out to upgrade a number of our Lambdas.
One particular Web API (originally built in .NET 3.1) was set up with a custom implementation of the PostMarshallHttpAuthenticationFeature-override method on the LambdaEntryPoint-class, to allow proper interpretation of incoming APIGatewayCustomAuthorizerContext.
However, it is unclear to me how to migrate this logic over to a Minimal API setup.
The underlying (base) classes are ultimately the same, but I can't find out how I am supposed to use this override method, and whether or not this is even intended in a Minimal API setting.
Any suggestions are welcome!
Beta Was this translation helpful? Give feedback.
All reactions
@ashishdhingra is correct, we haven't provided a mechanism yet for overriding the same PostX methods that are overridable when using the non-minimal api approach. We need to figure a pattern for users to inject their lambda function sub class instead of using the enum for the AddAWSLamdbaHosting.
Replies: 3 comments
-
@AdalbertKhoolsaat Looking at the AddAWSLambdaHosting extension methods in ServiceCollectionExtensions class, I don't see any option in HostingOptions to specify PostMarshallHttpAuthenticationFeature override.
CC @normj for inputs if this is a feature request.
Beta Was this translation helpful? Give feedback.
All reactions
-
@ashishdhingra is correct, we haven't provided a mechanism yet for overriding the same PostX methods that are overridable when using the non-minimal api approach. We need to figure a pattern for users to inject their lambda function sub class instead of using the enum for the AddAWSLamdbaHosting.
Beta Was this translation helpful? Give feedback.
All reactions
-
This is a blocker for our migration to minimal API as well for a bunch of our lambdas.
Beta Was this translation helpful? Give feedback.