added the threaded option