java - Is there a way to limit the maximum number of processing records in a Job of Spring Batch? -
is there way limit maximum number of processing records in job of spring batch?
i need have configuration control maximum number of records can processed job.
the job reading database using stored procedure, limit maximum number of fetched rows in procedure itself, looking features provided in spring batch , not able find yet.
write custom itemreader
holds record count , return null
('stop reading') when limit reached.
store variable used count records step-execution context.
remember let custom itemreader
implements itemstream
: in manner sb save/restore record count into/from context automatically.
hope clear, english not native language.
Comments
Post a Comment