use threading tcp server for testing