Adding timeouts on server connections