agave-jobs/jobs-core/src/main/java/org/iplantc/service/jobs/managers/launchers/AbstractJobLauncher.java
/**
     * Creates a {@link TransferTask} to copy the tempAppDir contents to the job work directory and associates
     * it with a {@link JobStatusType#STAGING_JOB} event, then saves the
     * {@link Job} history. Separated here for easier testing and to avoid mocking static DAO methods.
     *
     * @return transfer task for the overall {@link #getTempAppDir()} upload
     * @throws JobException if unable to persist the transfer task or job event.
     */
Creates a  TransferTask to copy the tempAppDir contents to the job work directory and associates
it with a  JobStatusType#STAGING_JOB event, then saves the
Job history. Separated here for easier testing and to avoid mocking static DAO methods.

@return transfer task for the overall  #getTempAppDir() upload
@throws JobException if unable to persist the transfer task or job event.
Creates a TransferTask to copy the tempAppDir contents to the job work directory and associates it with a JobStatusType#STAGING_JOB event then saves the Job history . Separated here for easier testing and to avoid mocking static DAO methods . @return transfer task for the overall #getTempAppDir () upload @throws JobException if unable to persist the transfer task or job event .
protected TransferTask createJobWorkDirectoryTransferTask() throws JobException {
        TransferTask transferTask;
        try {
            transferTask = new TransferTask(
                    "https://workers.prod.agaveplatform.org/" + getTempAppDir().getPath(),
                    "agave://" + getJob().getSystem() + "/" + getJob().getWorkPath(),
                    getJob().getOwner(), null, null);
            updateTransferTask(transferTask);
            JobDao.refresh(getJob());
            getJob().addEvent(new JobEvent(JobStatusType.STAGING_JOB,
                    "Staging runtime assets to " + transferTask.getDest(),
                    transferTask,
                    getJob().getOwner()));
            JobDao.persist(getJob());
            return transferTask;
        } catch (TransferException e) {
            throw new JobException("Unable to save transfer task to track deploying of job app assets to execution system.", e);
        } catch (JobException e) {
            throw new JobException("Unable to add STAGING_JOB event to job history.", e);
        }
    }
protected TransferTask createJobWorkDirectoryTransferTask ( ) throws JobException { TransferTask transferTask ; try { transferTask = new TransferTask ( "https://workers.prod.agaveplatform.org/" + getTempAppDir ( ) . getPath ( ) , "agave://" + getJob ( ) . getSystem ( ) + "/" + getJob ( ) . getWorkPath ( ) , getJob ( ) . getOwner ( ) , null , null ) ; updateTransferTask ( transferTask ) ; JobDao . refresh ( getJob ( ) ) ; getJob ( ) . addEvent ( new JobEvent ( JobStatusType . STAGING_JOB , "Staging runtime assets to " + transferTask . getDest ( ) , transferTask , getJob ( ) . getOwner ( ) ) ) ; JobDao . persist ( getJob ( ) ) ; return transferTask ; } catch ( TransferException e ) { throw new JobException ( "Unable to save transfer task to track deploying of job app assets to execution system." , e ) ; } catch ( JobException e ) { throw new JobException ( "Unable to add STAGING_JOB event to job history." , e ) ; } }
Creates a {@link TransferTask} to copy the tempAppDir contents to the job work directory and associates
 it with a {@link JobStatusType#STAGING_JOB} event, then saves the
 {@link Job} history.
Creates a { @link TransferTask } to copy the tempAppDir contents to the job work directory and associates it with a { @link JobStatusType#STAGING_JOB } event then saves the { @link Job } history .