in src/main/java/com/amazonaws/services/sqs/executors/CompletedFutureSerializer.java [29:43]
public String apply(Future<T> future) {
if (!future.isDone()) {
throw new IllegalArgumentException();
}
try {
return NORMAL_VALUE_PREFIX + resultSerializer.apply(future.get());
} catch (InterruptedException e) {
// Should never happen
throw new IllegalStateException();
} catch (ExecutionException e) {
return EXCEPTION_PREFIX + exceptionSerializer.apply(e.getCause());
} catch (CancellationException e) {
return Character.toString(CANCELLED_PREFIX);
}
}