the multi thread version of server has been finished preliminary, more needed to be check and modified.