This is an attempt to execute the function in a seperate thread.