refactor worker and commanduploader for concurrency