DEV Community

Cover image for Leveraging the Dependency Injection support in Azure Functions
Cecil L. Phillip πŸ‡¦πŸ‡¬ for Microsoft Azure

Posted on • Updated on

Leveraging the Dependency Injection support in Azure Functions

This article is part of #ServerlessSeptember. You'll find other helpful articles, detailed tutorials, and videos in this all-things-Serverless content collection. New articles are published every day β€” that's right, every day β€” from community members and cloud advocates in the month of September.

Find out more about how Microsoft Azure enables your Serverless functions at https://docs.microsoft.com/azure/azure-functions.

For many developers, techniques such as dependency injection and inversion of control have become commonplace in their codebases. Particularly in the .NET space, there are tons of open source frameworks and libraries that make incorporating these practices much easier.

As the software industry continues to steadily adopt more serverless technologies, development teams continue to search for ways to leverage their existing investments into this new serverless world. They want to be able to create modular components and dynamically swap out their implementations without having to rewrite or deploy their code. They want to be able to write focused unit tests for their code and create mock implementations that abstract away external dependencies.

These are just some of the reasons why support for dependency injection was added to serverless functions targeting .NET Core in Azure Functions v2.

We were so excited about this feature, we decided to invite Fabio Cavalcante from the Azure Functions team to come on the On .NET show to give us a demo of how it all works.

If you liked this video and would like to see some more of our .NET content, please subscribe to our .NET Developers YouTube Channel.

Useful Links

Top comments (0)