redesign for worker threads