You are viewing a plain text version of this content. The canonical link for it is here.
Posted to jira@kafka.apache.org by "cmccabe (via GitHub)" <gi...@apache.org> on 2023/03/02 22:02:06 UTC
[GitHub] [kafka] cmccabe opened a new pull request, #13331: MINOR: fix fault handling in ControllerServer and KafkaServer
cmccabe opened a new pull request, #13331:
URL: https://github.com/apache/kafka/pull/13331
This PR has two fixes for fault handling. One makes fault handling more strict on the controller; the other makes it a bit less strict on the (ZK-based) broker.
In ControllerServer, invoke a fatal fault handler in the catch block of the ControllerServer.startup() function. This will protect us from cases where unwinding startup would otherwise encounter a deadlock, or be too slow. This is the same reason why we made controller fault handlers call halt() instead of exit() in KAFKA-14693. In a sense, this JIRA is a continuation of that fix since it turns some cases that would previously have been handled by calling shutdown() into cases where we invoke a fault handler which will call halt() directly.
In KafkaServer, when we are in migration-from-zk mode and we create a RaftManager, it should have a fault handler which simply calls shutdown() on the broker rather than invoking
ProcessTerminatingFaultHandler. This fixes the bug where we could invoke the process terminating fault handler from junit tests.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: jira-unsubscribe@kafka.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [kafka] cmccabe commented on pull request #13331: MINOR: fix fault handling in ControllerServer and KafkaServer
Posted by "cmccabe (via GitHub)" <gi...@apache.org>.
cmccabe commented on PR #13331:
URL: https://github.com/apache/kafka/pull/13331#issuecomment-1454006628
Fix checkstyle
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: jira-unsubscribe@kafka.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [kafka] rondagostino commented on a diff in pull request #13331: MINOR: fix fault handling in ControllerServer and KafkaServer
Posted by "rondagostino (via GitHub)" <gi...@apache.org>.
rondagostino commented on code in PR #13331:
URL: https://github.com/apache/kafka/pull/13331#discussion_r1126859142
##########
core/src/main/scala/kafka/server/SharedServer.scala:
##########
@@ -170,6 +170,17 @@ class SharedServer(
snapshotsDiabledReason.compareAndSet(null, "metadata loading fault")
})
+ /**
+ * The fault handler to use when ControllerServer.startup throws an exception.
+ */
+ def controllerStartupFault: FaultHandler = faultHandlerFactory.build(
Review Comment:
nit: `controllerStartupFaultHandler` to match the style of the other ones.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: jira-unsubscribe@kafka.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [kafka] cmccabe merged pull request #13331: MINOR: fix fault handling in ControllerServer and KafkaServer
Posted by "cmccabe (via GitHub)" <gi...@apache.org>.
cmccabe merged PR #13331:
URL: https://github.com/apache/kafka/pull/13331
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: jira-unsubscribe@kafka.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org