Add timeout for keep-alive connections