December 2019
Intermediate to advanced
510 pages
11h 33m
English
The .NET Core worker template is nothing more than a common .NET Core app. Furthermore, we can run the worker template as a common console application. Besides, the worker template also provides the hosting APIs to run the worker as an always-running process. In the case of Windows, it is possible to run the worker using Windows services technology. In the case of Linux, the worker runs using systemd.
Furthermore, .NET Core provides two different NuGet packages to specify the host behavior of the worker: the Microsoft.Extensions.Hosting.WindowsServices package and the Microsoft.Extensions.Hosting.Systemd package, both available on NuGet.
The Microsoft.Extensions.Hosting.WindowsServices package provides an extension method called ...