Scheduled console app vs Windows service? When is it appropriate to use each

前端 未结 7 2072
误落风尘
误落风尘 2020-12-24 12:55

I just read this: What is the benefit of developing the application as a windows service? but I\'m still unsure of when to use a windows service.

I have a couple tas

7条回答
  •  不知归路
    2020-12-24 13:11

    I have a number of windows scheduled tasks that run hourly on a production web server. They are not reliable at all. They are running in Windows 2003 Server under a specific machine account. Most of the time they work perfectly, but occasionally they fail to run and sometimes they terminate before they are finished.

    Some of this may be due to the fact that they are vbscripts and the way they are written, but I've seen scheduled tasks with WS FTP Pro (commercial FTP software) that behave the same way.

    I've converted many of these to windows services and have never had to worry about them again.

    I would definitely lean towards windows services. Like some of the other comments, I have been burned by windows scheduled tasks too many times. I don't trust them for enterprise level solutions.

提交回复
热议问题