Current state: Adopted
Discussion thread: here
JIRA:
Please keep the discussion on the mailing list rather than commenting on the wiki (wiki discussions get unwieldy fast).
Over time, certain exceptions and methods within the Kafka Streams exception handling interfaces are unused in favor of newer, more comprehensive alternatives. Retaining these deprecated elements can lead to confusion, and complicates future development and maintenance. This KIP proposes the deprecation and removal of BrokerNotFoundException and improve code clarity.
The removal will affect the public exceptions of Kafka Streams. Users who are still using the BrokerNotFoundException class will encounter compilation errors.
This KIP proposes to remove BrokerNotFoundException which is unused since Kafka Streams 2.8.
This change goes in two steps
Step1: mark unused BrokerNotFoundException as deprecated in 4.2 release
Step2: remove the deprecated exception in the next major release which can be 5.0
Unused Exception for Deprecation and Removal:
org.apache.kafka.streams.errors.BrokerNotFoundExceptionBrokerNotFoundException class.BrokerNotFoundException was unused since Kafka Streams version 2.8. BrokerNotFoundException as it is no longer relevant.This is a code cleanup. Existing test suite should catch any failures. Will add or update new unit tests as needed.
Since BrokerNotFoundException is not used for a very long time, we can remove it directly. But, the protocol we follow is to deprecate them first and then remove them in the next major release.
We will have an unused class lying around for another release. Other than that, there is no damage if we follow the regular process. Hence, the two step process.