Status
Current state: "Under Discussion"
Discussion thread: here [Change the link from the KIP proposal email archive to your own email thread]
JIRA: KAFKA-6345 – Application Reset Tool might delete incorrect internal topics
Please keep the discussion on the mailing list rather than commenting on the wiki (wiki discussions get unwieldy fast).
Motivation
The streams application reset tool deletes all topic that start with <application.id>-
. This may lead to undesired behaviour when we have two similarly named application.id-s
E.g. If people have two versions of the same application and name them "app" and "app-v2", then resetting "app" would also delete the internal topics of "app-v2".
Public Interfaces
Add an option to streams reset tool.
internalTopicsOption = optionParser.accepts("internal-topics", "Comma-separated list of internal topics. If specified, these are the only internal topics that the tool will attempt to delete.") |
Proposed Changes
Add an internal-topics option to streams reset tool that will specify the internal topics considered for deletion
Compatibility, Deprecation, and Migration Plan
- This is purely an addition of an option to kafka-streams-application-reset.sh. It will not cause any compatibility issues.
Rejected Alternatives
Disallow "dash" in the application.id
This will raise a lot of backward compatibility issues.
Have a "negative prefix" option
This may be more convenient than having to list out relevant internal topics which may be tedious. However, the internal-topics option is a lot more explicit and it's usage will be more familiar because of it's similarity to other options (e.g. input-topics and intermediate-topics). Usage of either "negative-prefix" or "internal-topic" options will involve doing a dry-run and then deciding whether to carry on or to limit the internal topics considered for deletion. Having displayed the internal-topics marked for deletion in the dry-run, it is more straightforward to simply specify the subset to be deleted.