conduktor.io ↗

KIP-100 — Relax Type constraints in Kafka Streams API

Accepted Kafka 1.0 Streams

Relaxes generic type bounds in Kafka Streams API methods (e.g., `KStream.filter`, `KStream.map`, `KTable.join`) to use use-site variance (`? super K`, `? super V`, `? extends R`) so that functions typed on supertypes or subtypes are accepted without unchecked casting. The existing invariant bounds force callers to write explicit type casts or duplicate lambda logic when working with type hierarchies.

Details

AuthorXavier Léauté
StatusAccepted
Kafka Version1.0
JIRAKAFKA-4481
WikiView on Apache Wiki
Created2016-12-08
Last Modified2017-01-19
Explore how this KIP affects the Kafka protocol in the Protocol Explorer, or see the full KIP database.