Posts

ASP.NET Core 6: Taking Advantages of Task Parallel Library

Image
 In this article, we will see the use of the Parallel class of Task Parallel Library in ASP.NET Core 6 MVC Applications. The reason for writing this article is that last week when I was discussing with the client we had a discussion regarding the use of Task Parallel Library in ASP.NET Core 6. There were a couple of scenarios we had discussed and then I thought to write my thoughts on them. Task Parallel Library (TPL) The TPL is introduced in .NET Framework 4.0 under the System.Threading and System.Threading.Task namespaces. The TPL has public types and APIs that simplify the process of writing parallel and concurrency code and hence improve the application's productivity.   The TPL scales the degree of concurrency dynamically to most efficiently use all the processors that are available. The TPL handlers perform the following work: Partitioning the work Schedule threads on ThreadPool   Cancellation support State Management Improvise the performance of the ...

MAUI: Passing Data Across Pages

Image
.NET Multi-platform App UI (.NET MAUI) is a framework for building modern, multi-platform, natively compiled iOS, Android, macOS, and Windows apps using C# and XAML in a single codebase. This uses XAML for building an interactive User Interface.  In this article, we will build the application where we will see how to navigate across pages and share data across pages.  The .NET MAUI is for developers who are interested in writing C# and XAML-based cross-platform applications. This helps to share UI layout and design with the same shared codebase across platforms. Figure 1 shows  the MAUI apps' code-sharing Figure 1: The MAUI Apps Code Sharing Figure 1 shows that the MAUI allows us to build cross-platform apps for desktop and mobile. More information can be read from this link . In this article, we will see the implementation of navigation across pages and passing data across them. The MAUI provides several controls (aka UI elements) for creating application UI using XAML a...

Azure Functions: Creating REST APIs using Azure Function with Node.js

Image
In this article, we will implement Azure Functions using Node.js.  Azure Functions is a serverless solution where we have to write less code and maintenance less infrastructure which saves cost. In this article, we will be using Node.js to design and develop Azure Function using Visual Studio and Azure Extension for Visual Studio Code.    Why Azure Functions? The advantage of using the Azure Functions is the code is executed when an event is fired. Consider that when an HTTP request is received then only you want the code to be executed which will connect to the database server performing DB Operations. In this case, instead of having a dedicated server for running such an application, we can create an Azure Function that will execute the code based on the HTTP request, certainly, this will be more cost effective because instead of paying for the whole server we just pay for processing cost.       Please note that to try the code for this article, the ...