Announcement Announcement Module
Collapse
No announcement yet.
New possible bug with Spring Batch 2.0.2 Page Title Module
Move Remove Collapse
X
Conversation Detail Module
Collapse
  • Filter
  • Time
  • Show
Clear All
new posts

  • New possible bug with Spring Batch 2.0.2

    I have a Spring Batch job that has three steps, which initializes with Spring Batch 2.0.1 but no longer loads with 2.0.2. I now get the following error when I load the job from the application context:

    Code:
    Configuration problem: The element [updateTrackingCompleted] is unreachable
    Offending resource: class path resource [my-config.xml]
    Here is the XML for the config of this job:

    Code:
    <batch:job id="myJob" job-repository="jobRepository">
      <batch:step id="updateTrackingInProcess">
        <batch:tasklet transaction-manager="transactionManager"
          ref="updateTrackingInProcessTasklet" />
      </batch:step>
      <batch:step id="myStep">
        <batch:tasklet transaction-manager="transactionManager">
          <batch:chunk reader="myReader" processor="myProcessor" 
            writer="myWriter" commit-interval="100"/>
        </batch:tasklet>
      </batch:step>
      <batch:step id="updateTrackingCompleted">
        <batch:tasklet transaction-manager="transactionManager"
          ref="updateTrackingCompletedTasklet" />
      </batch:step>
    </batch:job>
    This may be a bug, or the newest version may want me to handle the XML syntax differently. If so, it would be good to know that.

    Brian

  • #2
    That is expected (and new in 2.0.2): you need explicit next= or <next/> in the first two steps. I think in 2.0.1 it would have loaded but only one of the three steps would be executed.

    Comment


    • #3
      You are so right, Dave

      Dave,

      Thanks for getting back to me so quickly. I discovered my error after 2.0.1 only ran the first step. Once I had the (required) next logic in there, I reverted to 2.0.2 and it worked fine.

      Brian

      Comment

      Working...
      X