tcp part refactor having finished