Added control over upload and download threads