在服务器上使用cron运行JAR文件?

时间:2012-10-25 14:04:54

标签: java cron hosting

我编写了一个java程序,它会进行一些计算,然后发送一封电子邮件。我把它打包成一个罐子。我需要每周星期四午夜运行这个程序。很可能我的计算机不会一直打开,所以我需要它从某个主机上运行。我的问题是 - 是否有一个支持cron和java的免费托管地点?

嗯,我看了一下应用程序引擎但是却试图安装eclipse的谷歌插件。单击安装后出现错误..

Cannot complete the install because one or more required items could not be found.
Software being installed: Google Web Toolkit SDK 2.4.0 2.4.0.v201208080120-rel-r37 (com.google.gwt.eclipse.sdkbundle.e37.feature.feature.group 2.4.0.v201208080120-rel-r37)
Missing requirement: Google App Engine Plugin 3.1.0.v201208080120-rel-r37 (com.google.appengine.eclipse.core 3.1.0.v201208080120-rel-r37) requires 'bundle org.eclipse.wst.sse.core 0.0.0' but it could not be found
Cannot satisfy dependency:
From: Google Plugin for Eclipse 3.7 3.1.0.v201208080120-rel-r37 (com.google.gdt.eclipse.suite.e37.feature.feature.group 3.1.0.v201208080120-rel-r37)
To: com.google.appengine.eclipse.core [3.1.0.v201208080120-rel-r37]
Cannot satisfy dependency:
From: Google Web Toolkit SDK 2.4.0 2.4.0.v201208080120-rel-r37 (com.google.gwt.eclipse.sdkbundle.e37.feature.feature.group 2.4.0.v201208080120-rel-r37)
To: com.google.gdt.eclipse.suite.e37.feature.feature.group 3.1.0

3 个答案:

答案 0 :(得分:0)

查看Google App Engine: https://developers.google.com/appengine/

它支持Java,并且在某些配额内是免费的。

请注意,它不支持运行桌面应用程序,但由于您使用Java编写代码,因此它很可能是可移植的,您还可以利用App Engine平台服务(如发送电子邮件)。它还有一个cron服务。

答案 1 :(得分:0)

启动Amazon Micro Instance Server。它们是免费的,可让您完全控制机器,包括设置cron作业。

AWS

答案 2 :(得分:0)

查看OpenShift(https://openshift.redhat.com/app/)。

为小型需求提供免费的一系列工具,并提供从那里扩展的能力。