自动运行web服务 [英] Automatically run web serivce

查看:81
本文介绍了自动运行web服务的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我有一个asmx Web服务,它从数据库中获取值。我需要的是每5分钟自动运行Web服务而无需打开应用程序?任何人都可以为它推荐一些东西吗?是否有可能通过IIS运行Web服务?

解决方案

错误。这不是服务的工作方式。您不会由客户端运行Web服务。服务在服务器端永久执行;客户端不会激活它。所有Web服务都会接收来自客户端的HTTP请求,并根据每个HTTP请求将一些HTTP响应发送回客户端。这样的请求可以是调用某些Web方法并将结果发送回客户端的请求。



所有您需要知道的是使用Web服务。这取决于服务的种类和规格。从一些基础知识开始,请参阅: http://msdn.microsoft.com/en-us/library /aa561062.aspx [ ^ ]。



再次,定期查询某些服务的整个想法看起来有问题。



-SA

I have a asmx web service which fetches values from database. What I need is to run the web service automatically every 5 mins of time without opening the application? can anyone please suggest something for it? Whether any possibility of running the web service through IIS?

解决方案

Wrong. This is not how services works. You don't "run" a Web service by a client. A service is executed permanently on the server side; clients don't activate it. All a Web Service does is receiving HTTP requests from clients and sending back some HTTP response back to the clients, per each HTTP request. And such request can be a request to call some Web method and send the results back to a client.

All you need to know is hot to consume Web Services. It depends on the kind of the service and its spec. To start with some basics, please see: http://msdn.microsoft.com/en-us/library/aa561062.aspx[^].

Again, the whole idea to poll some service periodically looks questionable.

—SA


这篇关于自动运行web服务的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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