Github user tgravescs commented on a diff in the pull request:
https://github.com/apache/spark/pull/11690#discussion_r56041637
--- Diff:
yarn/src/main/scala/org/apache/spark/deploy/yarn/ApplicationMaster.scala ---
@@ -117,6 +119,25 @@ private[spark] class ApplicationMaster(
private var delegationTokenRenewerOption:
Option[AMDelegationTokenRenewer] = None
+ if (SystemUtils.IS_OS_UNIX) {
+ // Register signal handler for signal "TERM", "INT" and "HUP". For the
cases where AM receive a
+ // signal and stop, from RM's aspect this application needs to be
reattempted, rather than mark
+ // as success.
+ // Replace this signal handler with SignalLogger in AM side.
+ val signalHandler = new SignalHandler() {
+ override def handle(sig: Signal): Unit = {
+
+ logInfo(s"RECEIVED SIGNAL ${sig.getNumber}: SIG${sig.getName}")
--- End diff --
so do we really need to disable the signallogger? I haven't done much with
java signal handlers but it seems like the handle() call returns the old signal
handler and then this signal handler would propogate it to any other ones
installed.
See SignalLogger.scala where it has prevHandler. We should test that
though to verify that works.
---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at [email protected] or file a JIRA ticket
with INFRA.
---
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]