This week's book giveaway is in the OCAJP 8 forum. We're giving away four copies of OCA Java SE 8 Programmer I Study Guide and have Edward Finegan & Robert Liguori on-line! See this thread for details.
I have a startup servlet which creates a new thread to read a file and create some instance with the values fetched from the file. The WAR file is deployed in weblogic clustered environment. I mean one weblogic server but having 2 cluster. So basically its only one machine and one server. but it is clustered. So the issue is that there are 2 clusters. And both the clusters are creating the thread and making new instance with same values from the file. So i am having duplicate instances.
Is there any way I can stop the 2nd cluster from creating the thread if first cluster has created the thread?
How about having one config parameter in web.xml say for example: createThread and set its value to false when one of the cluster creates the thread.