
Originally Posted by
crowest
Greetings,
I've a Spring Batch job that's rather established and like always a new requirement has come over the horizon and upset the applecart!
Presently my Job consists of four steps that run one after the other. Step 1 is a simple tasklet to search for a file on the local file-system that matches a generated naming criteria and waits for a semaphore file to appear before proceeding. Step 2 is a reader/writer/processor that generates a file. Step 3 is optional and re-formats the file from Step 2. Step 4 uses FTP to transfer the file (formatted or not) to another system.
My new requirement needs me to read one or more input files, and generate intermediary files. A new step will take those intermediary files and create one output file ready for formatting (optional) and FTPing as currently takes place.
The main problem is the number of input files can only be determined at runtime and therefore as I see it a normal Split (configured by Spring XML) is not possible. Is the PartionStep my salvation here? Will it allow me to establish a bunch of reader/writer/processors to read separate and entirely individual input files with their own output file? I notice there isn't a factory bean to create such a Step as there is for TaskletStep. Is it advisable to create one of my own? Will the
Any advice would be most appreciated...
Best wishes,
Steve C.