As Lord Kelvin once famously said, If you cannot measure it, you cannot improve it. With that in mind, we need to measure our application to see where its problems are. There are some applications, known as profilers, that can give us the means to do this. Let's have a look at some of the choices that we have.
MiniProfiler
One open source profiler is MiniProfiler, available from http://miniprofiler.com/dotnet/AspDotNetCore and from NuGet as MiniProfiler.AspNetCore.Mvc. There are also other packages, such as Microsoft.EntityFrameworkCore.SqlServer, for the Entity Framework Core SQL Server provider, andMicrosoft.EntityFrameworkCore.Sqlite for SQLite, which you should add as well.
The following screenshot shows the console, with details regarding the request and the database calls:
This screen shows some metrics after a page was loaded, including the response time, the time it took the DOM to load,...