0

I'm new for SpringData Hadoop. I checkout some examples from www, such as [1]:https://github.com/pkainulainen/spring-data-apache-hadoop-examples/tree/master/mapreduce

All of them are configured to run at start-up:

 <hdp:job-runner id="wordCountJobRunner" job-ref="wordCountJob" run-at-startup="true"/>

But I want to run the job via a Servlet. How to?

Brian Clozel
  • 56,583
  • 15
  • 167
  • 176
noodles
  • 327
  • 1
  • 4
  • 15

1 Answers1

0

i think you have to try this:

http://quartz-scheduler.org/

examples of code you could see the official site, but here is some fragment:

// compute a time that is on the next round minute
Date runTime = evenMinuteDate(new Date());

// Trigger the job to run on the next round minute
Trigger trigger = newTrigger()
    .withIdentity("trigger1", "group1")
    .startAt(runTime)
    .build();
Dmitry Zagorulkin
  • 8,370
  • 4
  • 37
  • 60