Docker – Volumes

By | 24/11/2021

In this post we will see how to use a Volume in a Docker container.First of all, what is a Volume and when we need it?A Docker image is made of a set of read-only layers and when we start a new container, Docker takes the read-only image and adds a read-write layer on top.… Read More »

Mongo DB – Basic commands

By | 17/11/2021

In this post, we will see some MongoDB basic commands that will help us to manage our MongoDB instances.Here, we can find all Mongo DB’s commands. First of all, we connect to Mongo shell with the command mongo and then, we will start to run some commands: SHOW DBS – It shows all databases USE… Read More »

Mongo DB – Docker

By | 10/11/2021

In these previous posts:MongoDB – How to install it on macOS MongoDB – How to install on Windowswe have seen how to install Mongo DB.In reality, using DOCKER, we can install Mongo DB without install it on our system and in an easier way. IMPORTANT: For this post, I have used a Windows system but… Read More »

Web API – Resource Filter

By | 03/11/2021

In this post, we will see how to create Resource Filter in a .NET 5 Web API project.First of all, what is a Resource Filter?“A Resource filter is the first to handle a request after authorization. It can run code before the rest of the filter pipeline, and after the rest of the pipeline has… Read More »

Web API – Action Filter

By | 27/10/2021

In this post, we will see how to create an Action Filter in a .NET 5 Web API project.First of all, what is an Action Filter?“An Action filter runs the code immediately before and after the controller action method is called. It can be used to perform any action before or after execution of the… Read More »

Web API – OData with .NET 5

By | 20/10/2021

In this post, we will see how to implement OData with .NET 5.First of all, what is OData?From OData.org:“OData (Open Data Protocol) is an ISO/IEC approved, OASIS standard that defines a set of best practices for building and consuming RESTful APIs. OData helps you focus on your business logic while building RESTful APIs without having to worry about… Read More »

C# – How to return a value from a Thread

By | 13/10/2021

In this post, we will see how to return a value from a Thread. First of all, we create a new Console application project where we define three methods called Method1, Method2 and Method3: Then, we modify the Main method in order to run the first two methods in different Threads: If we run the… Read More »

Category: C#

Web API – Custom Data Annotation

By | 06/10/2021

In this post, we will see how to create a Data Annotation custom to use in a .NET 5 Web API project.First of all, what is a Data Annotation?From Microsoft web site:“The advantage of using the Data Annotation validators is that they enable you to perform validation simply by adding one or more attributes –… Read More »