DuccId jobId = getJobId(processId);
IDuccWork duccWork = workMap.findDuccWork(jobId);
if(duccWork != null) {
if(duccWork instanceof IDuccWorkExecutable) {
IDuccWorkExecutable duccWorkExecutable = (IDuccWorkExecutable) duccWork;
IDuccWorkJob job = null;
if(duccWork instanceof IDuccWorkJob) {
job = (IDuccWorkJob)duccWork;
}
IDuccProcessMap processMap = duccWorkExecutable.getProcessMap();
IDuccProcess process = processMap.get(processId);
if(process == null) {
if(job != null) {
process = job.getDriver().getProcessMap().get(processId);
}
}
if(process != null) {
// PID
copyInventoryPID(job, inventoryProcess, process);
// Scheduler State
setResourceStateAndReason(job, inventoryProcess, process);
// Process State
copyInventoryProcessState(job, inventoryProcess, process);
// Process Reason
copyReasonForStoppingProcess(job, inventoryProcess, process);
// Process Exit code
copyProcessExitCode(job, inventoryProcess, process);
// Process Init & Run times
updateProcessTime(job, inventoryProcess, process);
// Process Initialization State
switch(inventoryProcess.getProcessState()) {
case Running:
process.setInitialized();
if(job != null) {
switch(job.getDuccType()) {
case Service:
switch(job.getJobState()) {
case Initializing:
stateJobAccounting.stateChange(job, JobState.Running);
break;
}
break;