private T result() throws ExecutionException {
        if (cancelled) {
            throw new CancellationException();
        }
        if (exception != null) {
            throw new ExecutionException(exception);
        }
        return result;
    }
An abstract implementation of {@link Callback} that also implements the {@link Future} interface. This allows for
operations like waiting until the callback is completed via {@link #onCompletion(Throwable, Object)}. The result
from the callback can be converted by concrete implementations of this class before being retrieved via
{@link Future#get}.
@param <U> the callback result type
@param <T> the future result type obtained after converting the callback result
connect/runtime/src/main/java/org/apache/kafka/connect/util/ConvertingFutureCallback.java