Create a variable called "counter". Than use "is element exist" to check if element exist and update "counter" variable whenever element is missing. Check counter variable in the loop, and fail thread if "counter" hit 3
If I am running a script and one thread fails, the data used for it will disappear from the source and I cannot see which one has to be reused.
There is no way to know which data was taken, 'cause the thread had deleted all things used before. But u could log data used before the thread will be crashed.