Reputation: 70
Can different client versions of kafka hit a single version of Kafka broker. I know that we can enable the 'inter.broker.protocol.version' to make newer versions of Kafka accept older version clients.
for example is there a way we make both 0.8 and 0.9 versions of Kafka clients work on 0.9 Kafka broker?.
Upvotes: 1
Views: 4632
Reputation: 1162
Update:
Starting with version 0.10.2, Java clients (producer and consumer) have acquired the ability to communicate with older brokers. Version 0.11.0 clients can talk to version 0.10.0 or newer brokers. However, if your brokers are older than 0.10.0, you must upgrade all the brokers in the Kafka cluster before upgrading your clients. Version 0.11.0 brokers support 0.8.x and newer clients.
https://kafka.apache.org/documentation/#upgrade_11_0_0
Upvotes: 2
Reputation: 23881
Actually inter.broker.protocol.version
does not have any relation to this, its sole purpose is to support rolling upgrade for cluster to prevent situations where new brokers start "talking" newer protocol version that older brokers can not understand, so that's why you set inter.broker.protocol.version
to your current cluster version.
Regarding clients there should be no problems at all as long as one simple rule is satisfied: clients should use a protocol version supported by broker, e.g. a 0.9 broker will happily handle all requests from older clients, but will fail on request versions that appeared in 0.10. Basically the rule is upgrade brokers first, then clients
to ensure all necessary logic is implemented on brokers to successfully handle client requests.
The client sends the request version on each request, so the broker can distinguish older clients from newer and handle their requests properly.
Upvotes: 3