I\'m trying to implement async http in java. Here is the important part of the code:
for (String urlString : urls) { // TODO: try and get rid of the
My only guess is that it's due to a Future not completing before attempting to access its response. But that's a complete and utter guess!
Future
Maybe check each of the futureResponses .isDone() and .isCancelled() before accessing its .get().
futureResponses
.isDone()
.isCancelled()
.get()