working on server socket structure