[ 
https://issues.apache.org/jira/browse/HADOOP-16677?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Xudong Cao updated HADOOP-16677:
--------------------------------
    Description: 
In SocketIOWithTimeout, when a thread was interrupted and exit from select(), 
it proceed to throw an InterruptedIOException, in exception message the 
remaining timeout mills should be calcuated correctly rather than simply give a 
total timeout millis ,  which could be very misleading.

 

An example after this jira:

2019-10-24 09:22:58,212 INFO org.apache.hadoop.hdfs.server.datanode.DataNode: 
Exception for 
BP-753871533-10.215.131.216-1511957392115:blk_10646544613_9573675038

java.io.InterruptedIOException: Interrupted while waiting for IO on channel 
java.nio.channels.SocketChannel[connected local=/10.196.146.114:9003 
remote=/10.215.153.105:38559]. 60000 millis timeout left.

at 
org.apache.hadoop.net.SocketIOWithTimeout$SelectorPool.select(SocketIOWithTimeout.java:342)

...

  was:In SocketIOWithTimeout, when a thread was interrupted and exit from 
select(), it proceed to throw an InterruptedIOException, in exception message 
the remaining timeout mills should be calcuated correctly rather than simply 
give a total timeout millis ,  which could be very misleading.


> Recalculate the remaining timeout millis correctly while throwing an 
> InterupptedException in SocketIOWithTimeout.
> -----------------------------------------------------------------------------------------------------------------
>
>                 Key: HADOOP-16677
>                 URL: https://issues.apache.org/jira/browse/HADOOP-16677
>             Project: Hadoop Common
>          Issue Type: Bug
>          Components: common
>    Affects Versions: 3.1.3
>            Reporter: Xudong Cao
>            Assignee: Xudong Cao
>            Priority: Minor
>              Labels: pull-request-available
>         Attachments: HADOOP-16677.001.patch
>
>
> In SocketIOWithTimeout, when a thread was interrupted and exit from select(), 
> it proceed to throw an InterruptedIOException, in exception message the 
> remaining timeout mills should be calcuated correctly rather than simply give 
> a total timeout millis ,  which could be very misleading.
>  
> An example after this jira:
> 2019-10-24 09:22:58,212 INFO org.apache.hadoop.hdfs.server.datanode.DataNode: 
> Exception for 
> BP-753871533-10.215.131.216-1511957392115:blk_10646544613_9573675038
> java.io.InterruptedIOException: Interrupted while waiting for IO on channel 
> java.nio.channels.SocketChannel[connected local=/10.196.146.114:9003 
> remote=/10.215.153.105:38559]. 60000 millis timeout left.
> at 
> org.apache.hadoop.net.SocketIOWithTimeout$SelectorPool.select(SocketIOWithTimeout.java:342)
> ...



--
This message was sent by Atlassian Jira
(v8.3.4#803005)

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to