Windows服务如何以标准间隔启动应用程序? [英] How does a windows service set off an application at a standard interval?

查看:142
本文介绍了Windows服务如何以标准间隔启动应用程序?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

顾问设置Windows服务以运行应用程序.该应用程序应该每15分钟运行一次.该应用程序根本没有运行,并且该服务似乎运行正常.

A consultant setup a windows service to run a application. The application is supposed to run every 15 minutes. The application is not running at all and the service appears to be running fine.

我不熟悉应用程序作为服务运行时如何以标准间隔运行.

I am not familiar with how an application will run at a standard interval when running as a service.

该服务使用SRVANY.EXE工具.

The service uses the SRVANY.EXE tool.

推荐答案

设置服务以使用SRVANY.EXE运行的任何顾问"都应被触发. SRVANY是不幸的骇客,应该在十年前就已淘汰; 永远不要在生产环境中使用.

Any 'consultant' that sets up a service to run using SRVANY.EXE should be fired. SRVANY is an unfortunate hack that should have been retired a decade ago; it should never be used in a production environment.

如果该服务的唯一目的是按计划运行该应用程序,则该应用程序根本不应该存在.将应用程序作为计划任务运行.如果它具有其他功能,则将其重写为真实服务.如果写得合理,应该可以轻松转换.

If the only purpose for the service is to run the app on a schedule then it shouldn't exist at all. Run the app as a Scheduled Task. If it has other functionality then rewrite it as a real service. If it is reasonably well written it should be a fairly easy conversion.

这篇关于Windows服务如何以标准间隔启动应用程序?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆