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

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


    String methodName = "isCancelJobDriverProcessFailed";
    logger.trace(methodName, null, messages.fetch("enter"));
    boolean ckpt = false;
    if(!job.isFinished()) {
      DuccWorkPopDriver driver = job.getDriver();
      IDuccProcessMap processMap = driver.getProcessMap();
      if(processMap != null) {
        Collection<IDuccProcess> processCollection = processMap.values();
        Iterator<IDuccProcess> iterator = processCollection.iterator();
        while(iterator.hasNext()) {
          IDuccProcess process = iterator.next();
          if(process.isComplete()) {
            IRationale rationale = new Rationale("health monitor detected job driver failed unexpectedly");
View Full Code Here


    String methodName = "isDriverCompleted";
    logger.trace(methodName, null, messages.fetch("enter"));
    boolean ckpt = false;
    if(job.isFinished()) {
      DuccWorkPopDriver driver = job.getDriver();
      IDuccProcessMap processMap = driver.getProcessMap();
      if(processMap != null) {
        Collection<IDuccProcess> processCollection = processMap.values();
        Iterator<IDuccProcess> iterator = processCollection.iterator();
        while(iterator.hasNext()) {
          IDuccProcess process = iterator.next();
          if(!process.isDeallocated()) {
            process.setResourceState(ResourceState.Deallocated);
View Full Code Here

  }
 
  private void interrupter() {
    String location = "interrupter";
    CasDispatchMap casDispatchMap = getCasDispatchMap();
    IDuccProcessMap processMap = (IDuccProcessMap) getJob().getProcessMap().deepCopy();
    Iterator<DuccId> iterator = processMap.keySet().iterator();
    while(iterator.hasNext()) {
      DuccId duccId = iterator.next();
      IDuccProcess duccProcess = processMap.get(duccId);
      boolean statusComplete = duccProcess.isComplete();
      boolean statusDeallocated = duccProcess.isDeallocated();
      boolean statusProcessFailed = duccProcess.isFailed();
      if(statusComplete || statusDeallocated || statusProcessFailed) {
        duccOut.debug(location, jobid, duccProcess.getDuccId(), "isComplete:"+statusComplete+" "+"isDeallocated:"+statusDeallocated+" "+"isProcessFailed:"+statusProcessFailed);
View Full Code Here

          int pMemSize = toInt(job.getSchedulingInfo().getShareMemorySize(),1*shareSize);
          long pShareSize = pMemSize/shareSize;
          if(pShareSize <= 0) {
            pShareSize = 1;
          }
          IDuccProcessMap processMap = job.getProcessMap();
          Iterator<DuccId> iteratorP = processMap.keySet().iterator();
          while(iteratorP.hasNext()) {
            DuccId jpid = iteratorP.next();
            IDuccProcess jp = processMap.get(jpid);
            ProcessState processState = jp.getProcessState();
            switch(processState) {
            case Starting:
            case Initializing:
            case Running:
View Full Code Here

          int pMemSize = toInt(service.getSchedulingInfo().getShareMemorySize(),1*shareSize);
          long pShareSize = pMemSize/shareSize;
          if(pShareSize <= 0) {
            pShareSize = 1;
          }
          IDuccProcessMap processMap = service.getProcessMap();
          Iterator<DuccId> iteratorP = processMap.keySet().iterator();
          while(iteratorP.hasNext()) {
            DuccId jpid = iteratorP.next();
            IDuccProcess jp = processMap.get(jpid);
            ProcessState processState = jp.getProcessState();
            switch(processState) {
            case Starting:
            case Initializing:
            case Running:
View Full Code Here

      ConcurrentSkipListMap<JobInfo, JobInfo> jobs = duccData.getSortedJobs();
      for(JobInfo jobInfo : jobs.descendingKeySet()) {
        DuccWorkJob job = jobInfo.getJob();
        if(job.isOperational()) {
          DuccId jobid = job.getDuccId();
          IDuccProcessMap map = job.getProcessMap();
          Iterator<DuccId> procids = map.keySet().iterator();
          while(procids.hasNext()) {
            DuccId procid = procids.next();
            IDuccProcess proc = map.get(procid);
            if(!proc.isComplete()) {
              NodeIdentity nodeIdentity = proc.getNodeIdentity();
              String procNodeName = nodeIdentity.getName();
              if(procNodeName != null) {
                if(nodeName.equals(procNodeName)) {
View Full Code Here

 
  private boolean jobDriverTerminated(DuccWorkJob duccWorkJob) {
    String methodName = "jobDriverTerminated";
    boolean status = true;
    logger.trace(methodName, null, messages.fetch("enter"));
    IDuccProcessMap processMap = duccWorkJob.getDriver().getProcessMap();
    Iterator<DuccId> processMapIterator = processMap.keySet().iterator();
    while(processMapIterator.hasNext()) {
      DuccId duccId = processMapIterator.next();
      IDuccProcess process = processMap.get(duccId);
      if(process.isActive()) {
        logger.debug(methodName, duccId,  messages.fetch("processes active"));
        status = false;
      }
    }
View Full Code Here

 
  private boolean jobProcessesTerminated(DuccWorkJob duccWorkJob) {
    String methodName = "jobProcessesTerminated";
    boolean status = true;
    logger.trace(methodName, null, messages.fetch("enter"));
    IDuccProcessMap processMap = duccWorkJob.getProcessMap();
    Iterator<DuccId> processMapIterator = processMap.keySet().iterator();
    while(processMapIterator.hasNext()) {
      DuccId duccId = processMapIterator.next();
      IDuccProcess process = processMap.get(duccId);
      if(process.isActive()) {
        logger.debug(methodName, duccId,  messages.fetch("processes active"));
        status = false;
      }
    }
View Full Code Here

          if(duccWorkJob.isCompleted() && allProcessesTerminated(duccWorkJob) && isSaved(duccWorkJob) && isAgedOut(duccWorkJob)) {
            workMap.removeDuccWork(duccId);
            driverStatusReportMap.remove(duccId);
            logger.info(methodName, duccId, messages.fetch("removed job"));
            changes ++;
            IDuccProcessMap processMap = duccWorkJob.getProcessMap();
            Iterator<DuccId> processMapIterator = processMap.keySet().iterator();
            while(processMapIterator.hasNext()) {
              DuccId processDuccId = processMapIterator.next();
              orchestratorCommonArea.getProcessAccounting().removeProcess(processDuccId);
              logger.info(methodName, duccId, messages.fetch("removed process")+" "+processDuccId.toString());
              changes ++;
View Full Code Here

  }
 
  private void setJdJmxUrl(DuccWorkJob job, String jdJmxUrl) {
    if(jdJmxUrl != null) {
      DuccWorkPopDriver driver = job.getDriver();
      IDuccProcessMap processMap = driver.getProcessMap();
      if(processMap != null) {
        Collection<IDuccProcess> processCollection = processMap.values();
        Iterator<IDuccProcess> iterator = processCollection.iterator();
        while(iterator.hasNext()) {
          IDuccProcess process = iterator.next();
          process.setProcessJmxUrl(jdJmxUrl);
         
View Full Code Here

TOP

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

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.