same thing with server
Add limit of waiting and something else