-
Jan 16th, 2012, 05:03 AM
#1
Run @Scheduled task only on one WebLogic cluster node?
We are running a Spring 3.0.x web application (.war) with a nightly @Scheduled job in a clustered WebLogic 10.3.4 environment. However, as the application is deployed to each node (using the deployment wizard in the AdminServer's web console), the job is started on each node every night thus running multiple times concurrently.
How can we prevent this from happening?
I know that libraries like Quartz allow coordinating jobs inside clustered environment by means of a database lock table or I could even implement something like this myself. But since this seems to be a fairly common scenario I wonder if Spring does not already come with an option how to easily circumvent this problem without having to add new libraries to my project or putting in manual workarounds.
Please let me know if there are any open questions. Thanks a lot for your help.
Axel
-
May 13th, 2013, 02:49 AM
#2
Did you find a solution to this one?
-
May 15th, 2013, 12:46 PM
#3
Hi nightwolf88,
I also posted this question on StackOverflow, but did not get a direct answer with a solution, so we started building the synchronization by using a shared DB table ourselves. Here's the thread, in case you are interested:
http://stackoverflow.com/questions/8...c-cluster-node
I hope this helps.
Cheers,
Axel
Tags for this Thread
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules