Issue Details (XML | Word | Printable)

Key: BATCH-404
Type: Task Task
Status: Closed Closed
Resolution: Fixed
Priority: Major Major
Assignee: Dave Syer
Reporter: Dave Syer
Votes: 0
Watchers: 0
Operations

If you were logged in you would be able to see more operations.
Spring Batch

FactoryBeans for step configuration

Created: 01/Mar/08 05:09 PM   Updated: 07/Aug/08 10:06 AM
Component/s: Core
Affects Version/s: 1.0.0.m4
Fix Version/s: 1.0.0.m5

Time Tracking:
Not Specified

File Attachments: 1. Text File itemProcessor.patch (65 kB)
2. Zip Archive mylyn-context.zip (25 kB)



 Description  « Hide
Create FactoryBeans for common ItemOrientedStep use cases. Right now I have everything shoved into a single class (SimpleStepFactoryBean), but the plan is to spend some time tomorrow refactoring that into several special-purpose factories. That way we probably won't need so much logic in the ItemOrientedStep, and common configuration tasks will be easy.

 All   Comments   Work Log   Change History   FishEye   Builds      Sort Order: Ascending order - Click to sort in descending order
Dave Syer added a comment - 02/Mar/08 06:43 AM
Introduced Simple- and DefaultStepFactoryBean which cover all but one (retry) of the samples. Removed shouldFail() from ItemSkipPolicy because that is really an Exceptionhandler concern.

TODO: add feature for configuring skip limits and exception policies. Roughly speaking, user needs to be able to specify a list of exception classes with skip limits for input and output.

Dave Syer added a comment - 02/Mar/08 11:28 AM
Attached itemProcessor.patch - an interesting strategy for sbstracting some of the tricky logic from ItemOrientedStep. The KitchenSink* implementation would need to be refactored into two separate implementations, one for simple skips and one for stateful retries.

Dave Syer added a comment - 03/Mar/08 11:59 AM
Finished. ItemProcessor ended up as ItemHandler (it should be internal implementation detail anyway). The step factory beans are used in the samples.

Dave Syer added a comment - 07/Aug/08 10:06 AM
Assume closed as resolved and released