agave-common/common-api/src/main/java/org/iplantc/service/common/quartz/util/QuartzUtility.java
/**
     * if authorized, pauses job identified by {@code jobName}.
     *
     * @param jobName job name.
     * @return json message stating all jobs resumed
     */
if authorized, pauses job identified by  jobName.
@param jobName job name.
@return json message stating all jobs resumed
if authorized pauses job identified by jobName . @param jobName job name . @return json message stating all jobs resumed
public synchronized String pauseJob(String jobName) {
        if (isAuthorized()) {
            JobDetail jobDetail = quartzFindJob(jobName);
            try {
                scheduler().pauseJob(jobDetail.getKey());
                pausedJobs.add(jobDetail.getKey().getName());
            } catch (SchedulerException e) {
                log.error("unable to pause " + jobName + ". failed with :" + e.getMessage(), e);
                toJSON(new QuartzConfigResetResponse(
                        e.getMessage(),
                        QuartzConfigResetResponse.Type.ERROR
                ));
            }
            return toJSON(
                    new QuartzConfigResetResponse(jobName + " job paused.", QuartzConfigResetResponse.Type.SUCCESS)
            );
        }
        throw new AuthorizationException();
    }
public synchronized String pauseJob ( String jobName ) { if ( isAuthorized ( ) ) { JobDetail jobDetail = quartzFindJob ( jobName ) ; try { scheduler ( ) . pauseJob ( jobDetail . getKey ( ) ) ; pausedJobs . add ( jobDetail . getKey ( ) . getName ( ) ) ; } catch ( SchedulerException e ) { log . error ( "unable to pause " + jobName + ". failed with :" + e . getMessage ( ) , e ) ; toJSON ( new QuartzConfigResetResponse ( e . getMessage ( ) , QuartzConfigResetResponse . Type . ERROR ) ) ; } return toJSON ( new QuartzConfigResetResponse ( jobName + " job paused." , QuartzConfigResetResponse . Type . SUCCESS ) ) ; } throw new AuthorizationException ( ) ; }
if authorized, pauses job identified by {@code jobName}.
if authorized pauses job identified by { @code jobName } .