Websphere 7 clustered deployment

2019-05-07 16:24发布

We have a J2EE application as EAR file which is deployed in WAS 7, for making the application availability as high it needs to be deployed in 3 clusters. We have a Quartz Scheduler class whose job is to upload data from one database to another daily at 2:00 am.

Now, the problem is if the ear will be deployed in 3 different nodes for load balancing and high availability, all the 3 ear file will trigger the upload at the same time. How we can handle this. Is it possible to do some configuration in WAS 7 environment. Any help/suggestion would be appreciated.

Thanks

1条回答
叼着烟拽天下
2楼-- · 2019-05-07 17:28

You have two possibilities:

  1. The Quartz database backend where all your nodes would connect to the same database that Quartz uses for synchronizing the task running. This can be configured to prevent the task from running on several nodes simultaneously.
  2. EJB 3.x timer. See for instance this example. This however works for ensuring that only member from each of the clusters fire the timer.
查看更多
登录 后发表回答