Package org.apache.uima.ducc.transport.event.common

Examples of org.apache.uima.ducc.transport.event.common.Rationale


 
  private void completeService(DuccWorkJob service, IRationale rationale) {
    String location = "completeService";
    DuccId jobid = service.getDuccId();
    if(service.getProcessFailureCount() > 0) {
      service.setCompletion(JobCompletionType.Warning, new Rationale("process failure(s) occurred"));
      logger.debug(location, jobid, service.getCompletionRationale().getText()+", "+"ProcessFailureCount="+service.getProcessFailureCount());
    }
    else if(service.getProcessInitFailureCount() > 0) {
      service.setCompletion(JobCompletionType.Warning, new Rationale("process initialization failure(s) occurred"));
      logger.debug(location, jobid, service.getCompletionRationale().getText()+", "+"ProcessInitFailureCount="+service.getProcessInitFailureCount());
    }
    else {
      setCompletionIfNotAlreadySet(service, JobCompletionType.EndOfJob, rationale);
      logger.debug(location, jobid, service.getCompletionRationale().getText()+", "+"no failures");
View Full Code Here


      job.setCompletion(JobCompletionType.Undefined, rationale);
      job.getStandardInfo().setDateOfCompletion(TimeStamp.getCurrentMillis());
      break;
    case EndOfJob:
      if(job.getProcessFailureCount() > 0) {
        job.setCompletion(JobCompletionType.Warning, new Rationale("all work items completed, but job process failure(s) occurred"));
      }
      else if(job.getProcessInitFailureCount() > 0) {
        job.setCompletion(JobCompletionType.Warning, new Rationale("all work items completed, but job process initialization failure(s) occurred"));
      }
      else {
        try {
          if(Integer.parseInt(job.getSchedulingInfo().getWorkItemsError()) > 0) {
            job.setCompletion(JobCompletionType.Error, rationale);
View Full Code Here

    case Completing:
      if(isTerminateDriver()) {
        setDriverState(DriverState.Completed);
        if(getWorkItemsProcessingError() == 0) {
          if(getWorkItemsLost() == 0) {
            setJobCompletion(JobCompletionType.EndOfJob, new Rationale("job driver status reported as normal completion"));
          }
        }
      }
      break;
    case Completed:
View Full Code Here

TOP

Related Classes of org.apache.uima.ducc.transport.event.common.Rationale

Copyright © 2018 www.massapicom. 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.