[
https://issues.apache.org/jira/browse/HTTPCORE-488?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16155385#comment-16155385
]
silver9886 commented on HTTPCORE-488:
-------------------------------------
I think we have to discuss about it. In the pr,
SingleCoreIOReactor.java
channel.setLastEventTime(System.currentTimeMillis());
is very useful.
In the truck code,lastEventTime change in handleIOEvent method ,that is the
time accept the SelectionKey.OP_CONNECT event.but it should be set right after
socketChannel.connect(sessionRequest.remoteAddress);then the checkTimeout(now)
in the InternalConnectChannel
will calculate the time duration between connect and OP_CONNECT event,and chck
if it is connect timeout.
> SingleCoreIOReactor.connect methods timeout parameter do not have effect.
> -------------------------------------------------------------------------
>
> Key: HTTPCORE-488
> URL: https://issues.apache.org/jira/browse/HTTPCORE-488
> Project: HttpComponents HttpCore
> Issue Type: Bug
> Components: HttpCore NIO
> Affects Versions: 5.0-alpha4
> Reporter: silver9886
> Priority: Minor
> Fix For: 5.0-beta1
>
>
> In my opinion , timeout parameter in connect method means connectTimeout.
> In InternalConnectChannel.onIOEvent ,if (readyOps & SelectionKey.OP_CONNECT)
> != 0 then the socketChannel will connect to the server.However , at this time,
> Perhaps It is connection time out already.
> So i suggest check connecttimeout at InternalConnectChannel.onIOEvent methods
> When there is SelectionKey.OP_CONNECT event happend
--
This message was sent by Atlassian JIRA
(v6.4.14#64029)
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]