add server and client finished with thread