nikhilbansal
asked on
Multi threaded mailing application
Dear All
I am supposed to develop a Multi Threaded mailing application in java. It has function as mentioned below:
There will be a thread which will scan the table in a database for the records having the status as Pending. Suppose the query returns 100 records. Each record contains an email id.Then first 15 records will be fetched in a Vector. Now 3 threads will be spawned. Each thread will work on 5 records. The 1st thread will send mail to the email id of those 5 records. 2nd thread will send mail to the email id of next 5 records and so on. Once the mail has been sent to 15 mail ids corresponding to 15 records, the status of those 15 records will be updated to Success in database.
This process will continue till all the records have been processed.
Can somebody help me in this application. I am not good at using threads.
Warm Regards
U can reach out to me at nikhil.bansal@tcs.com
Nikhil
I am supposed to develop a Multi Threaded mailing application in java. It has function as mentioned below:
There will be a thread which will scan the table in a database for the records having the status as Pending. Suppose the query returns 100 records. Each record contains an email id.Then first 15 records will be fetched in a Vector. Now 3 threads will be spawned. Each thread will work on 5 records. The 1st thread will send mail to the email id of those 5 records. 2nd thread will send mail to the email id of next 5 records and so on. Once the mail has been sent to 15 mail ids corresponding to 15 records, the status of those 15 records will be updated to Success in database.
This process will continue till all the records have been processed.
Can somebody help me in this application. I am not good at using threads.
Warm Regards
U can reach out to me at nikhil.bansal@tcs.com
Nikhil
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
For a tutorial have a look here: http://www.didimusic.gr/
SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.