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

MINOR: Generalize server startup to make way for KIP-500 #9883

Merged
merged 7 commits into from
Jan 16, 2021

Conversation

hachikuji
Copy link
Contributor

This patch attempts to generalize server initialization for KIP-500. It adds a Server trait which KafkaServer extends for the legacy Zookeeper server, and a new KafkaRaftServer for the new server. I have also added stubs for KafkaRaftBroker and KafkaRaftController to give a clearer idea how this will be used.

This patch attempts to be non-intrusive, but it's worth pointing out that it does away with KafkaServerStartable. I believe this was intended to support custom startup logic, but it is not an official API and we do not plan to support it after KIP-500.

Committer Checklist (excluded from commit message)

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

Copy link
Contributor

@ijuma ijuma 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 PR. Initial comments/questions below.

@cmccabe cmccabe added the kraft label Jan 14, 2021
@hachikuji hachikuji marked this pull request as ready for review January 14, 2021 18:47
val roles = getList(KafkaConfig.ProcessRolesProp).asScala.map {
case "broker" => BrokerRole
case "controller" => ControllerRole
case role => throw new ConfigException(s"Unknown process role $role")
Copy link
Contributor

Choose a reason for hiding this comment

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

can you list the valid roles in this exception?

@cmccabe
Copy link
Contributor

cmccabe commented Jan 15, 2021

LGTM. I had one small comment.

Thanks, @hachikuji

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