hadoop-common-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Steve Loughran (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (HADOOP-15379) Make IrqHandler.bind() public
Date Fri, 13 Apr 2018 10:02:00 GMT

    [ https://issues.apache.org/jira/browse/HADOOP-15379?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16437107#comment-16437107
] 

Steve Loughran commented on HADOOP-15379:
-----------------------------------------

thanks everyone. FWIW I found this as I was trying to write a special handler to intercept
control-c interrupts in the spark-shell; I keep on accidentally existing it. My current workaround:
place a class into the package. Which is a shame as it would otherwise be a few lines in the
spark-shell itself:
{code}
import org.apache.hadoop.service.launcher.IrqHandler

object irq extends IrqHandler.Interrupted {
  @Override def interrupted(interruptData: IrqHandler.InterruptData): Unit = {}
}

new IrqHandler("INT", irq).bind()

{code}

> Make IrqHandler.bind() public
> -----------------------------
>
>                 Key: HADOOP-15379
>                 URL: https://issues.apache.org/jira/browse/HADOOP-15379
>             Project: Hadoop Common
>          Issue Type: Bug
>          Components: util
>    Affects Versions: 3.1.0
>            Reporter: Steve Loughran
>            Assignee: Ajay Kumar
>            Priority: Minor
>             Fix For: 3.2.0, 3.1.1
>
>         Attachments: HADOOP-15379.00.patch
>
>
> {{org.apache.hadoop.service.launcher.IrqHandler.bind()}} is package private
> this means you can create an {{Interrupted}} handler in a different package, but you
can't bind it to a signal.



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

---------------------------------------------------------------------
To unsubscribe, e-mail: common-issues-unsubscribe@hadoop.apache.org
For additional commands, e-mail: common-issues-help@hadoop.apache.org


Mime
View raw message