Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

KAFKA-18229: Move configs out of "kraft" directory #18389

Open
wants to merge 1 commit into
base: trunk
Choose a base branch
from

Conversation

frankvicky
Copy link
Contributor

JIRA: KAFKA-18229

We should move configs out of the kraft directory since AK no longer relies on ZK.

Committer Checklist (excluded from commit message)

  • Verify design and implementation
  • Verify test coverage and CI build status
  • Verify documentation (including upgrade notes)

@github-actions github-actions bot added triage PRs from the community tools docker Official Docker image small Small PRs labels Jan 5, 2025
@frankvicky frankvicky force-pushed the KAFKA-18229 branch 2 times, most recently from dc04d08 to 78efb6d Compare January 5, 2025 06:48
Copy link

A label of 'needs-attention' was automatically added to this PR in order to raise the
attention of the committers. Once this issue has been triaged, the triage label
should be removed to prevent this automation from happening again.

for i in $(seq 1 $#); do
if [ "${!i}" = "-c" ] || [ "${!i}" = "--config" ]; then
next_i=$((i + 1))
[[ "${!next_i}" == *"config/kraft"* ]] && echo "Warning: If using default properties file, config/kraft path has been deprecated"
Copy link
Member

@ijuma ijuma Jan 13, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Deprecated would imply we still support it, but plan to remove it in the future. It looks like we are doing a move here. Perhaps you want to say that they were moved to a new location and state that new location?

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why is this needed to address the intent of the Jira? It is odd for a script to be checking the path of a file. The CLI should only be concern with the content of the file.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes, we should remind users that config/kraft is not used anymore after 4.0.0

Copy link
Member

@jsancio jsancio left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for the changes @frankvicky

I also filed this issue https://issues.apache.org/jira/browse/KAFKA-18497. Do you want to address that issue in this PR too? It basically asks to move config/reconfig-server.properties to override config/server.properties. What do you think?

for i in $(seq 1 $#); do
if [ "${!i}" = "-c" ] || [ "${!i}" = "--config" ]; then
next_i=$((i + 1))
[[ "${!next_i}" == *"config/kraft"* ]] && echo "Warning: If using default properties file, config/kraft path has been deprecated"
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why is this needed to address the intent of the Jira? It is odd for a script to be checking the path of a file. The CLI should only be concern with the content of the file.

Comment on lines 23 to 28
for arg in "$@"; do
if [[ "$arg" == *.properties ]]; then
[[ "$arg" == *"config/kraft"* ]] && echo "Warning: If using default properties file, config/kraft path has been deprecated"
break
fi
done
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why is this needed to address the intent of the Jira? It is odd for a script to be checking the path of a file. The CLI should only be concern with the content of the file.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We are making a breaking change without a deprecation cycle, so this is trying to provide a warning related to that. I haven't checked if the warning is effective though - good to think through that.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The breaking change being that process.roles must be provided? In 3.x process.roles was optional but in 4.x that property must be specified since ZK is not supported and KRaft is the only valid configuration.

If so, let KafkaConfig's schema validation catch invalid configurations and warn the user.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

No, the config files are moving to a different path.

@jsancio jsancio self-assigned this Jan 13, 2025
@jsancio jsancio added the kraft label Jan 13, 2025
@frankvicky
Copy link
Contributor Author

Hi @jsancio,

I have read the ticket description and agree it would be good to address KAFKA-18497 in this PR.
I will update the patch in the next commit. 🐱

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants