kafka-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "东方甲乙" <254479...@qq.com>
Subject RE: [DISCUSS] KIP-148: Add a connect timeout for client
Date Sun, 14 May 2017 09:37:24 GMT
Hi Guozhang,


Sorry for the delay, thanks for the question.  It seems two different parameters to me:
connect.timeout.ms: only work for the connecting phrase, after connected phrase this parameter
is not used.
connections.max.idle.ms: currently not work in the connecting phrase (only select return readyKeys
>0) will add to the expired manager, after connected will check if the connection is still
alive in some time.


Even if we change the connections.max.idle.ms to work including the connecting phrase, we
can not set this parameter to a small value, such as 5 seconds. Because the client is maybe
busy sending message to other node, it will be disconnected in 5 seconds, so the default value
of connections.max.idle.ms is setting to a larger time. We should have two parameters to control
the connecting phrase behavior and the connected phrase behavior, do you think so?


Thanks,


David




------------------ 原始邮件 ------------------
发件人: "Guozhang Wang";<wangguoz@gmail.com>;
发送时间: 2017年5月6日(星期六) 上午7:52
收件人: "dev@kafka.apache.org"<dev@kafka.apache.org>; 

主题: Re: [DISCUSS] KIP-148: Add a connect timeout for client



Hello David,

Thanks for the KIP. For the described issue, I'm wondering if it can be
resolved by tuning the CONNECTIONS_MAX_IDLE_MS_CONFIG (
connections.max.idle.ms) on the client side? Default is 9 minutes.


Guozhang

On Tue, May 2, 2017 at 8:22 AM, 东方甲乙 <254479818@qq.com> wrote:

> Hi all,
>
> Currently in our test environment, we found that after one of the broker
> node crash (reboot or os crash), the client may still be connecting to the
> crash node to send metadata request or other request, and it needs several
> minutes to be aware that the connection is timeout then try another node to
> connect to send the request. Then the client may still not be aware of the
> metadata change after several minutes.
>
>
> So I want to add a connect timeout on the  client,  please take a look at:
>
> https://cwiki.apache.org/confluence/display/KAFKA/KIP-
> 148%3A+Add+a+connect+timeout+for+client
>
> Regards,
>
> David




-- 
-- Guozhang
Mime
  • Unnamed multipart/alternative (inline, 8-Bit, 0 bytes)
View raw message