In the Spring Batch step-scope documentation, there are three unexplained spring-batch context maps: jobParameters
, jobExecutionContext
, and stepExecutionContext
.
Springsource sample code, combined:
<bean id="flatFileItemReader" scope="step"
class="org.springframework.batch.item.file.FlatFileItemReader">
<property name="var1" value="#{jobParameters['input.file.name']}" />
<property name="var2" value="#{jobExecutionContext['input.file.name']}" />
<property name="var3" value="#{stepExecutionContext['input.file.name']}" />
</bean>
What are the default parameters available within jobParameters
, jobExecutionContext
, and stepExecutionContext
?
There are also likely differences between what's available in Spring Batch version 1.x vs. 2.x vs. 3.x--the documentation is pretty scarce in this area.