In my application, I am executing a bunch of SQL queries like a job and the details of the execution, which are inserted into a table. As soon as any record is inserted,the listener should pick it up and start monitoring the execution status and update the status in the same table.
My front-end is ready and till now I am able to execute the job(multiple queries) and insert the details in table. Now I want to capture the status of execution and also I should be able to end ,pause ,restart the execution.
While I am going through multithreading part, I came across ExecutorService.
My question is should I do this using ExecutorService? or is there any other way?
Please share any tutorial links.
In your case i think you can use ExecutorService and create jobs in Callable objects that will help you to get the status of your running job it the form of Future objects.
For tutorial i would prefer this , it has basic information about concurrent package.