com.github.ltsopensource.spring.tasktracker
Class JobDispatcher

java.lang.Object
  extended by com.github.ltsopensource.spring.tasktracker.JobDispatcher
All Implemented Interfaces:
JobRunner

public class JobDispatcher
extends Object
implements JobRunner

Author:
Robert HG (254963746@qq.com) on 10/20/15.

Constructor Summary
JobDispatcher()
           
 
Method Summary
 Result run(JobContext jobContext)
          执行任务 抛出异常则消费失败, 返回null则认为是消费成功
 void setShardField(String shardField)
           
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

JobDispatcher

public JobDispatcher()
Method Detail

run

public Result run(JobContext jobContext)
           throws Throwable
Description copied from interface: JobRunner
执行任务 抛出异常则消费失败, 返回null则认为是消费成功

Specified by:
run in interface JobRunner
Throws:
Throwable

setShardField

public void setShardField(String shardField)


Copyright © 2017. All rights reserved.