Tabnine Logo
org.springframework.batch.core.job.flow
Code IndexAdd Tabnine to your IDE (free)

How to use org.springframework.batch.core.job.flow

Best Java code snippets using org.springframework.batch.core.job.flow (Showing top 20 results out of 315)

origin: spring-projects/spring-batch

@Override
public FlowExecutionStatus handle(FlowExecutor executor) throws Exception {
  /*
   * On starting a new step, possibly upgrade the last execution to make
   * sure it is abandoned on restart if it failed.
   */
  executor.abandonStepExecution();
  return new FlowExecutionStatus(executor.executeStep(step));
}
origin: spring-projects/spring-batch

@Override
public FlowExecutionStatus handle(FlowExecutor executor) throws Exception {
  return decider.decide(executor.getJobExecution(), executor.getStepExecution());
}
origin: spring-projects/spring-batch

@Override
public FlowExecutionStatus handle(FlowExecutor executor) throws Exception {
  return flow.start(executor).getStatus();
}
origin: spring-projects/spring-batch

@Override
public FlowExecutionStatus decide(JobExecution jobExecution, StepExecution stepExecution) {
  if (++count >= limit) {
    return new FlowExecutionStatus("COMPLETED");
  }
  else {
    return new FlowExecutionStatus("CONTINUE");
  }
}
origin: spring-projects/spring-batch

/**
 * @return true if this status represents the end of a flow
 */
public boolean isEnd() {
  return isStop() || isFail() || isComplete();
}
origin: spring-projects/spring-batch

/**
 * Create an ordering on {@link FlowExecution} instances by comparing their
 * statuses.
 *
 * @see Comparable#compareTo(Object)
 *
 * @param other the {@link FlowExecution} instance to compare with this instance.
 * @return negative, zero or positive as per the contract
 */
@Override
public int compareTo(FlowExecution other) {
  return this.status.compareTo(other.getStatus());
}
origin: spring-projects/spring-batch

/**
 * @param status The {@link FlowExecutionStatus} to end with
 * @param name The name of the state
 */
public EndState(FlowExecutionStatus status, String name) {
  this(status, status.getName(), name);
}
origin: spring-projects/spring-batch

  @Override
  public FlowExecution call() throws Exception {
    return flow.start(executor);
  }
});
origin: spring-projects/spring-batch

  @Override
  public FlowExecutionStatus handle(FlowExecutor executor) throws Exception {
    JobExecution jobExecution = executor.getJobExecution();
    jobExecution.createStepExecution(getName());
    if (fail) {
      return FlowExecutionStatus.FAILED;
    }
    else {
      return FlowExecutionStatus.COMPLETED;
    }
  }
};
origin: spring-projects/spring-batch

@Override
public FlowExecutionStatus handle(FlowExecutor executor) throws Exception {
  JobExecution jobExecution = executor.getJobExecution();
  if (jobExecution != null) {
    jobExecution.createStepExecution(getName());
  }
  return this.status;
}
origin: spring-projects/spring-batch

/**
 * Constructor for a {@link FlowStep} that sets the flow and of the step
 * explicitly.
 *
 * @param flow the {@link Flow} instance to be associated with this step.
 */
public FlowStep(Flow flow) {
  super(flow.getName());
}
origin: spring-projects/spring-batch

/**
 * Initialize the step names
 */
private void init() {
  findSteps(flow, stepMap);
}
origin: spring-projects/spring-batch

/**
 * Performs any logic to update the exit status for the current flow.
 *
 * @param executor {@link FlowExecutor} for the current flow
 * @param code The exit status to save
 */
protected void setExitStatus(FlowExecutor executor, String code) {
  executor.addExitStatus(code);
}
origin: spring-projects/spring-batch

@Override
public FlowExecutionStatus decide(JobExecution jobExecution, StepExecution stepExecution) {
  if (count++<2) {
    return new FlowExecutionStatus("OK");
  }
  return new FlowExecutionStatus("END");
}
origin: spring-projects/spring-batch

/**
 * @param status The {@link FlowExecutionStatus} to end with
 * @param name The name of the state
 */
public JsrEndState(FlowExecutionStatus status, String name) {
  super(status, status.getName(), name);
}
origin: spring-projects/spring-batch

  @Override
  public FlowExecutionStatus decide(JobExecution jobExecution,
      StepExecution stepExecution) {
    count++;
    if(count > 2) {
      return new FlowExecutionStatus("END");
    }
    else {
      return new FlowExecutionStatus("CONTINUE");
    }
  }
}
origin: spring-projects/spring-batch

@Override
public FlowExecutionStatus decide(JobExecution jobExecution, StepExecution stepExecution) {
  if (count++ < 2) {
    return new FlowExecutionStatus("OK");
  }
  return new FlowExecutionStatus("END");
}
origin: spring-projects/spring-batch

  @Override
  public FlowExecutionStatus decide(JobExecution jobExecution, StepExecution stepExecution) {
    return new FlowExecutionStatus("FOO");
  }
}
origin: spring-projects/spring-batch

  @Override
  public FlowExecutionStatus decide(JobExecution jobExecution, StepExecution stepExecution) {
    count++;
    return count<2 ? new FlowExecutionStatus("ONGOING") : FlowExecutionStatus.COMPLETED;
  }
};
origin: spring-projects/spring-batch

  @Override
  public FlowExecutionStatus decide(JobExecution jobExecution, StepExecution stepExecution) {
    return new FlowExecutionStatus("FOO");
  }
}
org.springframework.batch.core.job.flow

Most used classes

  • FlowExecutionStatus
    Represents the status of FlowExecution.
  • FlowJob
    Implementation of the Job interface that allows for complex flows of steps, rather than requiring se
  • Flow
  • FlowExecution
  • FlowExecutionException
  • FlowStep,
  • JobFlowExecutor,
  • State,
  • SimpleFlow,
  • StateTransition,
  • StepState,
  • FlowExecutionStatus$Status,
  • FlowHolder,
  • JobExecutionDecider,
  • AbstractState,
  • DecisionState,
  • EndState,
  • FlowExecutionAggregator,
  • FlowState
Tabnine Logo
  • Products

    Search for Java codeSearch for JavaScript code
  • IDE Plugins

    IntelliJ IDEAWebStormVisual StudioAndroid StudioEclipseVisual Studio CodePyCharmSublime TextPhpStormVimGoLandRubyMineEmacsJupyter NotebookJupyter LabRiderDataGripAppCode
  • Company

    About UsContact UsCareers
  • Resources

    FAQBlogTabnine AcademyTerms of usePrivacy policyJava Code IndexJavascript Code Index
Get Tabnine for your IDE now