// Don't use this async-Main() method signature since it does not allow placing a breakpoint after all program execution. The Main() method returns the task immediately, leaving running the task up to the .NET runtime. //static Task Main(string[] args) //{ // return Program.HostedServiceProgramExampleAsync(); //} //static void Main(string[] args) //{ // //Program.ServiceProviderExample(); // //Program.HostExample(); // //Program.WebHostExample(); // Program.HostedServiceProgramExample(); //} private static Task HostedServiceProgramExampleAsync() { //var emptyServiceProvider = ServiceProviderHelper.GetEmptyServiceProvider(); //await HostServiceBuilder.New() // .UseStartup<Startup>() // .UseHostedServiceProgram<Program04>() // .Build(emptyServiceProvider) // .RunAsync() // ; var task = HostedServiceProgram.RunAsync <Program04, Startup>(); return(task); }
static async Task Main(string[] args) { await HostedServiceProgram.RunAsync <Program, Startup>(); }
public static async Task SubMain() { await HostedServiceProgram.RunAsync <DeployBuiltBinaries, DeployBuiltBinariesStartup>(); }