You only need one thread for this.