Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Invoke(Begin = "2017-7-22 10:00", Interval = 1000 * 3600 * 24, SkipWhileExecuting = false) #15

Open
keke93 opened this issue Jul 24, 2017 · 8 comments

Comments

@keke93
Copy link

keke93 commented Jul 24, 2017

22日没执行,23日执行,24日没执行,是SkipWhileExecuting=false的问题么?用的1.1.0-rtm-10026版

@liguobao
Copy link
Contributor

现在呢?能看到日志吗?SkipWhileExecuting表示是否需要等待上一次执行完成之后再执行。

@MeetOct
Copy link

MeetOct commented Aug 31, 2017

@keke93
如果是站点部署在iis下面的话 ,iis回收的时候,timer也会停止
是不是因为这个原因。。。

@yukozh
Copy link
Member

yukozh commented Aug 31, 2017

应该和IIS无关,IIS只能回收托管资源,.net core app在IIS上并不是托管资源

@MeetOct
Copy link

MeetOct commented Aug 31, 2017

@kagamine
这个我实际测试过,iis回收后job确实停止了。。

@wanbolantian
Copy link

@MeetOct 应该是iis的原因,包括在用asp.net core 自带的IHostedService接口来实现后台任务时,如果是部署在iis中的,在iis回收资源时,任务是会停止的。参看下面的链接https://docs.microsoft.com/en-us/dotnet/standard/microservices-architecture/multi-container-microservice-net-applications/background-tasks-with-ihostedservice

@MeetOct
Copy link

MeetOct commented Nov 9, 2018

@wanbolantian
哈,很早之前踩的坑

@tongfei-github
Copy link

@MeetOct 我也遇到这个问题,怎么解决的啊?跪求。。。

@HungerKiller
Copy link

@tongfei-github 保证你的app别被杀死就行了。可以试试,应用程序池-->高级设置-->空闲超时操作,默认是Terminate,改成Suspend。(老一点的IIS没有这个配置)。

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

7 participants