Question

I am using JSF-2, Spring 4, hibernate 4 in my application. I have Spring type service layer, Dao Layers , Models and other thing. I want to schedule some of the services which should be automatically executed or called at specified time, usually these services or business logic would perform some kind of data-mapping from excel-file to database. I want to perform these task without user-intervention and scheduler should take care all these data-mapping.

Note : I am calling these services from my view as well as these services also should be used in scheduler to perform data-mapping.

I am newbie at utmost level, never used any kind of scheduler or anything. So my question :

1)what should I have to use to schedule these task?

2)I am confused regarding Spring Batch and Spring-sheduler? are they both perform scheduling ,if no then what is actual use of sping-batch?

3)Can spring-scheduler itself sufficient enough to perform these scheduling Any help would be highly considerable.

Was it helpful?

Solution

1)what should I have to schedule these task? Basically you need the classes that support the operations that you want to do (excel creation from database queries), spring in both cases.

2)I am confused regarding Spring Batch and Spring-sheduler? are they both perform scheduling ,if know then what is actual use of sping-batch?

Spring Batch provides reusable functions that are essential in processing large volumes of records, including logging/tracing, transaction management, job processing statistics, job restart, skip, and resource management. It also provides more advanced technical services and features that will enable extremely high-volume and high performance batch jobs though optimization and partitioning techniques

Spring scheduler just run any method at certain time, it is not so robust, and only execute the logic involve on a process, not statistic, not job restart, just start a process during predefined period of time (calling a method of a class)

3)Can spring-scheduler itself sufficient enough to perform these scheduling? Yes it is, if you are not very related with spring-batch this will take more time that just call the methods you already have.

Scheduler A scheduler is a software product that allows an enterprise to schedule and track computer batch tasks

Scheduler just ran the process.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top