public JobWithDetails getJob ( FolderJob folder , String jobName ) throws IOException { try { JobWithDetails job = client . get ( UrlUtils . toJobBaseUrl ( folder , jobName ) , JobWithDetails . class ) ; job . setClient ( client ) ; return job ; } catch ( HttpResponseException e ) { LOGGER . debug ( "getJob(folder={}, jobName={}) status={}" , folder , jobName , e . getStatusCode ( ) ) ; if ( e . getStatusCode ( ) == HttpStatus . SC_NOT_FOUND ) { // TODO: Think hard about this. return null ; } throw e ; } }
Get a single Job from the given folder .