Example usage for org.springframework.batch.core.job.flow FlowExecutionStatus STOPPED

List of usage examples for org.springframework.batch.core.job.flow FlowExecutionStatus STOPPED

Introduction

In this page you can find the example usage for org.springframework.batch.core.job.flow FlowExecutionStatus STOPPED.

Prototype

FlowExecutionStatus STOPPED

To view the source code for org.springframework.batch.core.job.flow FlowExecutionStatus STOPPED.

Click Source Link

Document

Special well-known status value.

Usage

From source file:org.springframework.batch.core.job.flow.support.SimpleFlow.java

protected boolean isFlowContinued(State state, FlowExecutionStatus status, StepExecution stepExecution) {
    boolean continued = true;

    continued = state != null && status != FlowExecutionStatus.STOPPED;

    if (stepExecution != null) {
        Boolean reRun = (Boolean) stepExecution.getExecutionContext().get("batch.restart");
        Boolean executed = (Boolean) stepExecution.getExecutionContext().get("batch.executed");

        if ((executed == null || !executed) && reRun != null && reRun && status == FlowExecutionStatus.STOPPED
                && !state.getName().endsWith(stepExecution.getStepName())) {
            continued = true;//from  w  w  w. ja  v a  2s .  c o m
        }
    }

    return continued;
}