3 ms·
That is not what I wrote. You need something smarter to deal with the fact I want the first server returned that replied with a successful response, which is, i
by jerf 9y ago
That is not what I wrote. You need something smarter to deal with the fact I want the first server returned that replied with a successful response, which is, in general, not expected to be the first server that replied. If you want parity you'll also need to cancel the remaining requests once the successful one has returned.
You still won't have to add very much more stuff, but you're not going to be that much shorter than my Go in the end, either.