Package com.taobao.zeus.jobs

Examples of com.taobao.zeus.jobs.Job.cancel()


  public void cancelDebugJob(String debugId) {
    Job job = context.getDebugRunnings().get(debugId);
    if (job == null) {
      throw new RuntimeException("任务已经不存在");
    }
    job.cancel();
    context.getDebugRunnings().remove(debugId);

    DebugHistory his = job.getJobContext().getDebugHistory();
    his.setEndTime(new Date());
    his.setStatus(com.taobao.zeus.model.JobStatus.Status.FAILED);
View Full Code Here


  }

  public void cancelManualJob(String historyId) {
    Job job = context.getManualRunnings().get(historyId);
    context.getManualRunnings().remove(historyId);
    job.cancel();

    JobHistory his = job.getJobContext().getJobHistory();
    his.setEndTime(new Date());
    his.setStatus(com.taobao.zeus.model.JobStatus.Status.FAILED);
    context.getJobHistoryManager().updateJobHistory(his);
View Full Code Here

  }

  public void cancelScheduleJob(String jobId) {
    Job job = context.getRunnings().get(jobId);
    context.getRunnings().remove(jobId);
    job.cancel();

    JobHistory his = job.getJobContext().getJobHistory();
    his.setEndTime(new Date());
    his.setStatus(com.taobao.zeus.model.JobStatus.Status.FAILED);
    context.getJobHistoryManager().updateJobHistory(his);
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.