private long startInternal(String jobXMLName, Properties jobParameters) throws JobStartException, JobSecurityException {

        if (logger.isLoggable(Level.FINE)) {
            logger.fine("Starting job: jobXMLName = " + jobXMLName + "\n" + traceJobParameters(jobParameters));
        }

        if (authService != null) {
            authService.authorizedJobSubmission();
        }

        WSJobInstance jobInstance = getBatchKernelService().createJobInstanceIntraApplication(jobXMLName, batchSecurityHelper.getRunAsUser());
        WSJobExecution jobExecution = getPersistenceManagerService().createJobExecution(jobInstance.getInstanceId(), jobParameters, new Date());

        IJobXMLSource jobXML = null;
        long executionId = 0;

        try {

            jobXML = getJobXMLLoaderService().loadJSL(jobXMLName);

            executionId = getBatchKernelService().startJob(jobInstance, jobXML, jobParameters, jobExecution.getExecutionId()).getKey();

        } catch (BatchSubmitInvalidParametersException bsipe) {
            markInstanceExecutionFailed(jobInstance, jobExecution, this.getCorrelationId(jobParameters));
            throw bsipe;
        } catch (RuntimeException e) {
            markInstanceExecutionFailed(jobInstance, jobExecution, this.getCorrelationId(jobParameters));
            throw e;
        }

        if (logger.isLoggable(Level.FINE)) {
            logger.fine("Started job execution with executionId: " + executionId);
        }

        return executionId;
    }
private long startInternal ( String jobXMLName , Properties jobParameters ) throws JobStartException , JobSecurityException { if ( logger . isLoggable ( Level . FINE ) ) { logger . fine ( "Starting job: jobXMLName = " + jobXMLName + "\n" + traceJobParameters ( jobParameters ) ) ; } if ( authService != null ) { authService . authorizedJobSubmission ( ) ; } WSJobInstance jobInstance = getBatchKernelService ( ) . createJobInstanceIntraApplication ( jobXMLName , batchSecurityHelper . getRunAsUser ( ) ) ; WSJobExecution jobExecution = getPersistenceManagerService ( ) . createJobExecution ( jobInstance . getInstanceId ( ) , jobParameters , new Date ( ) ) ; IJobXMLSource jobXML = null ; long executionId = 0 ; try { jobXML = getJobXMLLoaderService ( ) . loadJSL ( jobXMLName ) ; executionId = getBatchKernelService ( ) . startJob ( jobInstance , jobXML , jobParameters , jobExecution . getExecutionId ( ) ) . getKey ( ) ; } catch ( BatchSubmitInvalidParametersException bsipe ) { markInstanceExecutionFailed ( jobInstance , jobExecution , this . getCorrelationId ( jobParameters ) ) ; throw bsipe ; } catch ( RuntimeException e ) { markInstanceExecutionFailed ( jobInstance , jobExecution , this . getCorrelationId ( jobParameters ) ) ; throw e ; } if ( logger . isLoggable ( Level . FINE ) ) { logger . fine ( "Started job execution with executionId: " + executionId ) ; } return executionId ; }
@return job execution id