Preparing to add thread wrapper to keep state information.