使用crontab调用webmethod? [英] using crontab to call a webmethod?

查看:193
本文介绍了使用crontab调用webmethod?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我是crontab的新人,我想知道如何使用crontab每周调用一个web方法。

I am new to crontab and I wanted to know how I could call a web method every week using crontab.

我有一个web方法在java中,我创建了一个wsdl这些webmethods,现在我能够通过SOAP UI测试这个Web方法。我实际上想是为这个webmethod创建一个.xml,然后使用crontab调用它。但我不知道它是否会工作。请详细说明,让我知道如何实现此功能。

I have a webmethod in java and I created a wsdl for these webmethods and now I am able to test this web method through the SOAP UI. What I actually thought was to create a .xml for this webmethod and then call it using crontab. But I am not sure whether it would work. Please elaborate and let me know how this functionality can be achieved.

推荐答案

cron可以运行任何可执行文件,其不需要连接到显示器。

cron can run any executable, or perhaps more correctly, executables that don't require a connection to a display.

要做你想要的,创建一个独立的程序,调用你想要的任何函数。确保您可以从命令行运行此程序,并且程序不会打开任何窗口。

To do what you want, create a standalone program that calls whatever functions you want. Make sure you can run this from the command line, and that the program doesn't open any windows.

您应该可以配置crontab来运行此程序无论你什么时候想要。

You should then be able to configure your crontab to run this program whenever you want.

您可能对此问题的答案感兴趣:如何运行Java程序在cron下并导入jar

You might be interested in the answers to this question: How to run a Java program under cron and import the jars

这篇关于使用crontab调用webmethod?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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