How to schedule my Apache Spark application to run everyday at 00.30 AM(night) in IBM Bluemix?

白昼怎懂夜的黑 提交于 2019-12-12 01:58:14

问题


Hi All & IBM Bluemix team, I am using IBM Analytics for Apache Spark service in IBM Bluemix. I have developed a Apache Spark application and I want to run everyday at 00.30 AM in the night. How to schedule my Apache Spark application to run everyday at 00.30 AM(night) in IBM Bluemix?


回答1:


You can use any scheduling tool like (Crontab on linux) that will allow you to run spark-submit.sh script from your machine at a specific time.(in your case 00:30am)

A typical crontab entry would look like this

30 0 * * * /<your-directory-where-spraksubmit.sh>/spark-submit.sh --vcap vcap.json --deploy-mode cluster --class org.apache.spark.examples.SparkPi --master https://169.54.219.20 spark-examples-1.6.0-hadoop2.6.0.jar 

Refrence to IBM spark-submit.sh https://console.ng.bluemix.net/docs/services/AnalyticsforApacheSpark/index-gentopic3.html

Crontab:-

http://kvz.io/blog/2007/07/29/schedule-tasks-on-linux-using-crontab/

Again you can use any tools of your desire.

Thanks, Charles.



来源:https://stackoverflow.com/questions/38402153/how-to-schedule-my-apache-spark-application-to-run-everyday-at-00-30-amnight-i

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!