I have a scenario, I have a common project where I have a synchronized function to validate whether a text file contains a string. Example, that text file contains say a list of food that needs to be excluded. I have a data coming through kafka and storm which contain list of food.
The function i created is a synchronized SET with all these food. When i get some kind of food in my data I look up to see if it needs to be excluded form getting inserted into the database. Everything worked in my local environment but when i deploy this code in a clustered environment, exclusion is a hit or miss. Now the data that gets loaded is not correct coz the food that is supposed to be excluded still exists. I am 100% sure it is because of the thread safe issue of that function. How do i achieve this functionality in the clustered environment. Please advice. Thanks. -- Kushan Maskey 817.403.7500 M. Miller & Associates <http://mmillerassociates.com/> [email protected]
