Spring Batch : Job start/restart from any of the multiple steps included -
i using spring batch 3.0.3. have job named jbabc, inlcudes 3 steps. possible, can run user defined steps while invoking jbabc. roles might need start/restart job abc1, whereas other roles need start/restart abc2 , other group might need start/restart abc3. looking run job based on custom/user defined step parameter.
<job id="jbabc" xmlns="http://www.springframework.org/schema/batch"> <step id="abc1" next="abc2" > <tasklet ref="abc1tasklet"></tasklet> </step> <step id="abc2" next ="abc3"> <tasklet ref="abc2tasklet"></tasklet> </step> <step id="abc3"> <tasklet ref="abc3tasklet"></tasklet> </step> </job>
have @ http://docs.spring.io/spring-batch/trunk/reference/html/configurestep.html chapter 5.3.2.
you can implement first step, whicht returns specific state depending on parameter. ""-tag, able define step should executed next.
depending on how many options have, define different jobs , use specific launcher start 1 have to.
Comments
Post a Comment