org.springframework.batch.core.annotation.BeforeStep Java Examples

The following examples show how to use org.springframework.batch.core.annotation.BeforeStep. You can vote up the ones you like or vote down the ones you don't like, and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example #1
Source File: BaseProcessor.java    From seed with Apache License 2.0 5 votes vote down vote up
@BeforeStep
public void beforeStep(StepExecution stepExecution){
    if(null == this.stepExecution){
        this.stepExecution = stepExecution;
        LogUtil.getLogger().info("===>>>Step信息初始化完成");
    }
}
 
Example #2
Source File: SingleJVMJobProgressListener.java    From batchers with Apache License 2.0 5 votes vote down vote up
@Override
@BeforeStep
public void beforeStep(StepExecution stepExecution) {
    totalItemCount = employeeService.getEmployeeCount().intValue();
    jobStartParams = new JobStartParamsMapper().map(stepExecution.getJobParameters());
    stepName = stepExecution.getStepName();
    currentItemCount = new AtomicLong();
    lastPercentageComplete = new AtomicInteger();
    eventBus.post(new JobProgressEvent(jobStartParams, stepName, 0));
}
 
Example #3
Source File: MyStepExecutionListener.java    From SpringAll with MIT License 4 votes vote down vote up
@BeforeStep
public void breforeStep(StepExecution stepExecution) {
    System.out.println("before step execute: " + stepExecution.getStepName());
}
 
Example #4
Source File: BaseItemReader.java    From seed with Apache License 2.0 4 votes vote down vote up
@BeforeStep
public void saveStepExecution(StepExecution stepExecution) {
	this.stepExecution = stepExecution;
}
 
Example #5
Source File: BasePageItemReader.java    From seed with Apache License 2.0 4 votes vote down vote up
@BeforeStep
public void saveStepExecution(StepExecution stepExecution) {
	this.stepExecution = stepExecution;
}
 
Example #6
Source File: SettleJobListeners.java    From seed with Apache License 2.0 4 votes vote down vote up
@BeforeStep
public void initStepExecution(StepExecution stepExecution) {
    this.stepExecution = stepExecution;
}
 
Example #7
Source File: CustomItemReader.java    From POC with Apache License 2.0 4 votes vote down vote up
@BeforeStep
public void beforeStep(final StepExecution stepExecution) {
	JobParameters parameters = stepExecution.getJobExecution().getJobParameters();
	// use your parameters
	this.titleValue = parameters.getString("key");
}
 
Example #8
Source File: SlaveJobProgressListener.java    From batchers with Apache License 2.0 4 votes vote down vote up
@Override
@BeforeStep
public void beforeStep(StepExecution stepExecution) {
    jobStartParams = new JobStartParamsMapper().map(stepExecution.getJobParameters());
    stepName = stepExecution.getStepName();
}
 
Example #9
Source File: AlarmWriter.java    From pinpoint with Apache License 2.0 4 votes vote down vote up
@BeforeStep
public void beforeStep(StepExecution stepExecution) {
    this.stepExecution = stepExecution;
}
 
Example #10
Source File: NumberInfoClassifier.java    From tutorials with MIT License 4 votes vote down vote up
@BeforeStep
public void beforeStep(StepExecution stepExecution) {
    this.stepExecution = stepExecution;
    this.stepExecution.setExitStatus(new ExitStatus(QUIET));
}
 
Example #11
Source File: BaseWriter.java    From seed with Apache License 2.0 3 votes vote down vote up
@BeforeStep
public void saveStepExecution(StepExecution stepExecution) {
	this.stepExecution = stepExecution;
}