Adds timeout to long running processes