KafkaFuture.Function is currently an empty public abstract class.
This means you cannot implement them as a java lambda. And you end up with constructs as:
I propose to define them as interfaces.
So this code can become in java 8:
I know this change is backwards incompatible (extends becomes implements).
But as KafkaFuture is marked as @InterfaceStability.Evolving.
And KafkaFuture states in its javadoc:
This will eventually become a thin shim on top of Java 8's CompletableFuture.
I think this change might be worth considering.