Dependency Injection In Azure Functions V2

With the Azure Functions v2 runtime, supporting .NET Core it has become easier to do dependency injection. It can be done in a similar way that ASP.NET Core does via Microsoft.Extensions.DependencyInjection.

ASP.NET Core encourages the use of dependency injection by the built-in DI container. This feature of ASP.NET Core is very handy as many extensions such as logging and configuration via IOptions pattern are registered using during startup in Startup.cs. ASP.NET Core registers these services, along with any custom services you need using the built-in DI container via IServiceCollection.… [Keep reading] “Dependency Injection In Azure Functions V2”

Make Your Azure WebJobs Unit Testable Again

In my previous posts, we had a look at testability for serverless applications. In this post, we’re going to apply a similar approach to Azure WebJobs.

The sample code used in this post can be found here.

For either scheduled WebJob instance or on-demand WebJob instance, it’s just a console application that we’re not dealing with. However, when we look at the continuous running WebJob instance, it will be a different story. Let’s have a look at the basic WebJob code.… [Keep reading] “Make Your Azure WebJobs Unit Testable Again”

Dependency Injection in Vue.js App with TypeScript

Dependency management is one of critical points while developing applications. In the back-end world, there are many IoC container libraries that we can make use of, like Autofac, Ninject, etc. Similarly, many modern front-end frameworks also provide DI features. However, those features work way differently from how back-end libraries do. In this post, we’re going to use TypeScript and Vue.js for development and apply an IoC container library called InversifyJS that offers very similar development experiences to back-end application development.… [Keep reading] “Dependency Injection in Vue.js App with TypeScript”

Managing Dependencies in Azure Functions

Just before the Connect(); event, Azure Functions has become GA. Now more and more developers and IT pros are interested in it. One of the main attractions of using Azure Functions is, as a developer using C# codes, we can directly import existing private assemblies into Functions. In other words, we can easily migrate our existing applications to Azure Functions with minimal changes!
However, as we all know, migration is not that easy, especially if a huge architectural change is required.… [Keep reading] “Managing Dependencies in Azure Functions”

Testable Entity Filtering for Service Context on Dynamics CRM 2015

MS Dynamics CRM provides several web service endpoints. This is one of those endpoints, for organisation service.

One of the greatest benefits using this endpoint is to create a context class derived from CrmOrganizationServiceContext, which works as like DbContext from Entity Framework. The context class can be generated by CrmSvcUtil.exe that is shipped in CRM SDK.

When you directly run the following command in the Command Prompt screen, or put the command in build.bat[Keep reading] “Testable Entity Filtering for Service Context on Dynamics CRM 2015”