Reputation: 86757
I have an existing spring-batch Step
and would like to refactor it with Async
processor + writer.
StepBuilderFactory steps;
steps.get("test").chunk(1000)
.reader(new FlatFileItemReader<String>())
.processor(new AsyncItemProcessor<String, String>())
.writer(new AsyncItemWriter<String>())
.build();
This does not work and complains for the processor:
The method processor(ItemProcessor<? super Object,? extends Object>) in the type SimpleStepBuilder<Object,Object> is not applicable for the arguments (AsyncItemProcessor<String,String>)
.
How is a step to be build using async?
Upvotes: 2
Views: 2334