Installing and using dotnet-counters
In this section, we will install and use dotnet-counters
. These counters are very useful data-gathering tools that help us to monitor the health of our programs.
Open Developer Command Prompt for Visual Studio 2022. Then, type in the following command and press Enter:
dotnet tool install --global dotnet-counters --version 3.1.141901
This will download and install dotnet-tools. A successful installation will be presented, as shown in Figure 5.20:
The purpose of using dotnet-counters
is to perform health monitoring and a first-level performance investigation of your applications. If when using this program, potential performance problems are identified, then you can perform a more serious performance investigation using tools such as PerfView or dotnet-trace:
- To periodically collect selected counter...