DotNet Framework, Standard, Core and ASP Net Core

DotNet Framework Standard Core and ASP Net CoreLot of things have changed from the past few years in the DotNet ecosystem. In many occasions, I have seen people get confused with the differences between DotNet Core, DotNet Standard and DotNet Framework and how do they all relate to ASP Net Core.
I don’t blame them, so many new keywords that it is quite confusing to first look at.
Today, I would like to explain the differences in term of project templates. What is the difference between DotNet Standard library or DotNet Core library, what is the difference between DotNet Core application or DotNet Framework application, etc… This post will contain 5 points:1. DotNet Framework 2. DotNet Standard 3. DotNet Core 4. How to choose 5. ASP.Net Core 1. DotNet FrameworkEverything started from DotNet framework.
We would build libraries, console app and web application using ASP.Net MVC on top of DotNet Framework.
DotNet framework provides a set of API available for application to use in order to…

The Steps Toward Leadership

The Steps Toward LeadershipAs a Software Engineer, I have gone through many managements, different countries, different companies, different projects which all left me with a bitter taste.
After years of reflection, I realized that half of the feeling came from my inexperience while the other half was meant to be fulfilled by the management under which I was working. This management was meant to provide me, a Software Engineer, the direction, vision and ideology to carry on my work. Management composed of line managers, higher management, directors and company, I expected them to lead me to success.
It is incredibly hard to find the right way to get a Software Engineering team to work well. Most of the challenges aren’t well understood by those coming from different backgrounds. Not that it is harder or easier, it is just different. Tasks aren’t easily measured, it is hard to make KPI, goals aren’t easily defined and set, and many more issues. We have seen that giving management respo…

Setup environments for your AspNetCore backend and Angular frontend

Setup environments for your AspNetCore backend and Angular frontendLast week we saw how we could use angular cli and dotnet cli to pack and publish our application with simple commands. The application had no settings therefore there wasn’t a need to differentiate multiple deployments. But if we do need different settings, how should we handle it?
Today I will amswer this question by explaining how we can setup targets and environments for our application. This post will be composed by three parts:1. What is the difference between a target and an environment 2. Setup target and nvironment settings for AspNetCore app 3. Setup target and environment settings for Angular CLI 1. What is the difference between a target and an environmentA target refers to a target build. A target build is a set of configurations used to build the application. For development, the optimization is usually disabled as build time is more important than the optimization of code for example which would slow down…

Publish Angular application with Angular CLI and AspDotNet Core

Publish Angular application with Angular CLI and AspDotNet CoreA few months back I showed how to bootstrap an Angular application using Angular CLI. Apart from bootstrapping and serving, Angular CLI is also capable of packing the application and get it ready to be published in order for us to serve it on our own webserver. Today we will see how the process of publishing can be done in three steps1. Prepare the project for packing 2. Create a host 3. Publish the application 1. Prepare the project for packingIn order to ease the understanding, we start by separating our client Angular application and Host application.
The client will go into /client while the host into /host. Here a preview of how the structure will look like:- MyApplication | - /.git | - /client | - /e2e | - /node_modules | - /src | - ... | - /host (nothing here yet) | - /Host | - MyApplication.Host.sln In order to create this structure…

Save array of string EntityFramework Core

Save array of string EntityFramework CoreEntityFramework is a ORM where R stands for Relational (database). Relational databases operate with tables, rows and columns. If we have an object containing an array of objects, by default, it would translate to two tables and a JOIN between the two tables. This behaviour is great if our initial model has links to other objects but not so great when the array inside of model is only composed by primitive type values, like strings.
Today we will see how we can store array of values as property of our model and prevent having to create two tables with a JOIN.1. Install EntityFramework Core Sqlite 2. Save array of primitive type values All the code can be found on my GitHub.1. Install EntityFramework Core SqliteIn this example I will be using Sqlite.We start by creating two projects, a .NET Core/ASP.NET Core project and a .NET Standard library project. In the library we install Microsoft.EntityFrameworkCore and in the web project we install Micr…

Microsoft Orleans logs warnings and errors

Microsoft Orleans logs warnings and errorsMicrosoft Orleans is a framework which helps building distributed system by implementing the actor model together with the concept of virtual actors, taking care of availability and concurrency. If you are unfamiliar with Microsoft Orleans, you can look at my previous blog post explaining the benefits of Microsoft Orleans. Even though Orleans promises to abstract the distributed system problems, there are instances where errors arise without us being able to understand what is going on. Lucky us, the logs are well documented… but only for those who can decrypt them.
Today I will go through some of the errors and warnings which can be seen from silo and client so that you too can undestand what is going on. Enjoy!The code used to produce those errors can be found on my GitHub Client logsLogs on client appears with address {ip}:0.1.1. Can’t find implementation of interfaceAn unhandled excepti…

How to setup Continuous Integration/Deployment with GitLab for ASP NET Core application

How to setup Continuous Integration/Deployment with GitLab for ASP NET Core applicationIn any application, Continuous Integration and Continous Deployment environments are important to setup to remove respectively the risking of breaking your application while pushing code to master branch and having to manually deploy your application each time you need to either test it or deliver it. GitLab comes with a set of features to integrate quickly CI/CD to your application for free!
Today we will see how we can setup CI/CD by leveraging the free services from GitLab.
This post will be composed by 4 parts:1. Overview of the scenario 2. Setup a runner 3. Configure your job 4. Monitor your deployment on GitLab 1. Overview of the scenarioThe example that I will take is an ASP NET Core application which runs as a Windows service.My scenario is the most simplistic one may have:I want to setup CI, meaning build and running test and detect break in my code at each push to master branch,I want to s…