DEV Community

Discussion on: Simple Dependency Injection In AWS Lambda .net core

Collapse
 
hagatorn profile image
Hagatorn • Edited

Have you a typo in the example above?

You have a private ILambdaConfiguration property named Configuration, but you seem to try and access it using the LambdaConfiguration.Configuration["hello"] in the Hello method?
Nice article by the way, I was looking for a way not to instantiate a bunch of shared classes, for example dynamo db clients, in the constructor of my Lambda function and DI is a good alternative. Can find out about layers once I've got my head around the above.