modify readme

This commit is contained in:
MysticBoy
2019-10-30 22:04:52 +08:00
parent ff00436c7d
commit 9f86702bfe
2 changed files with 24 additions and 1 deletions

View File

@@ -28,4 +28,27 @@ Wrapper above [Quartz.NET] (https://github.com/quartznet/quartznet) for .NET Cor
.WithSimpleSchedule(x => x.WithIntervalInSeconds(2).RepeatForever()));
return result;
})
```
1. ConfigureQuartzHost Must be call after Host.CreateDefaultBuilder(args).ConfigureWebHostDefaults()
```
public class Program
{
public static void Main(string[] args)
{
CreateHostBuilder(args).Build().Run();
}
public static IHostBuilder CreateHostBuilder(string[] args) =>
Host.CreateDefaultBuilder(args)
.ConfigureWebHostDefaults(webBuilder =>
{
webBuilder.UseStartup<Startup>();
webBuilder.ConfigureKestrel(serverOptions =>
{
serverOptions.AllowSynchronousIO = true;
});
})
.ConfigureQuartzHost();
}
```

View File

@@ -4,7 +4,7 @@
<TargetFramework>netcoreapp3.0</TargetFramework>
<Authors>mukmyash</Authors>
<Company />
<Version>0.0.6</Version>
<Version>0.0.7</Version>
<GeneratePackageOnBuild>true</GeneratePackageOnBuild>
<RepositoryUrl>https://github.com/mukmyash/QuartzHostedService</RepositoryUrl>
<Description>Wrapper above [Quartz.NET] (https://github.com/quartznet/quartznet) for .NET Core.</Description>