agave-jobs/jobs-core/src/main/java/org/iplantc/service/jobs/managers/launchers/AbstractJobLauncher.java
/**
     * Creates a {@link TransferTask} 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 Software#getDeploymentPath()} download
     * @throws JobException if unable to persist the transfer task or job event.
     */
Creates a  TransferTask 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  Software#getDeploymentPath() download
@throws JobException if unable to persist the transfer task or job event.
Creates a TransferTask 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 Software#getDeploymentPath () download @throws JobException if unable to persist the transfer task or job event .
protected TransferTask createJobSoftwareDeploymentDirectoryTransferTask() throws JobException{
        TransferTask transferTask;
        try {
            transferTask = new TransferTask(
                    "agave://" + getSoftware().getStorageSystem().getSystemId() + "/" + getSoftware().getDeploymentPath(),
                    "https://workers.prod.agaveplatform.org/" + getTempAppDir().getPath(),
                    getJob().getOwner(), null, null);
            TransferTaskDao.persist(transferTask);
            JobDao.refresh(getJob());
            getJob().addEvent(new JobEvent(JobStatusType.STAGING_JOB,
                    "Fetching app assets from " + transferTask.getSource(),
                    null,
                    getJob().getOwner()));
            JobDao.persist(getJob());
            return transferTask;
        } catch (TransferException e) {
            throw new JobException("Unable to save transfer task to track staging of job app assets from software deployment system.", e);
        } catch (JobException e) {
            throw new JobException("Unable to add STAGING_JOB event to job history.", e);
        }
    }
protected TransferTask createJobSoftwareDeploymentDirectoryTransferTask ( ) throws JobException { TransferTask transferTask ; try { transferTask = new TransferTask ( "agave://" + getSoftware ( ) . getStorageSystem ( ) . getSystemId ( ) + "/" + getSoftware ( ) . getDeploymentPath ( ) , "https://workers.prod.agaveplatform.org/" + getTempAppDir ( ) . getPath ( ) , getJob ( ) . getOwner ( ) , null , null ) ; TransferTaskDao . persist ( transferTask ) ; JobDao . refresh ( getJob ( ) ) ; getJob ( ) . addEvent ( new JobEvent ( JobStatusType . STAGING_JOB , "Fetching app assets from " + transferTask . getSource ( ) , null , getJob ( ) . getOwner ( ) ) ) ; JobDao . persist ( getJob ( ) ) ; return transferTask ; } catch ( TransferException e ) { throw new JobException ( "Unable to save transfer task to track staging of job app assets from software deployment system." , e ) ; } catch ( JobException e ) { throw new JobException ( "Unable to add STAGING_JOB event to job history." , e ) ; } }
Creates a {@link TransferTask} and associates it with a {@link JobStatusType#STAGING_JOB} event, then saves the
 {@link Job} history.
Creates a { @link TransferTask } and associates it with a { @link JobStatusType#STAGING_JOB } event then saves the { @link Job } history .
// create the parent transfer task to copy the deployment directory on the software storage system.