Created write-loop thread