Announcement Announcement Module
Collapse
No announcement yet.
How to create a Poller with Spring Batch Page Title Module
Move Remove Collapse
X
Conversation Detail Module
Collapse
  • Filter
  • Time
  • Show
Clear All
new posts

  • How to create a Poller with Spring Batch

    hi

    we want to poll every 1 minute a directory and read (process) all files that are in there with spring batch.

    solution 1:
    we call our spring-batch job with a spring-quartz every minute.
    problem: if a job would take longer than 1 minute, a second job would start also, how can we prevent this.

    solution 2:
    we use spring integration poller.
    it would be nice solution, but we like to know if it is possible with spring-batch also ;-)

    thanks for you help!

  • #2
    You can use Quartz. You can set it up so that it will not start the new batch until the previous one has finished.

    Comment

    Working...
    X