RE: Timeout parameters

From: "Nagaura, Ryohei" <nagaura(dot)ryohei(at)jp(dot)fujitsu(dot)com>
To: "Jamison, Kirk" <k(dot)jamison(at)jp(dot)fujitsu(dot)com>, "Tsunakawa, Takayuki" <tsunakawa(dot)takay(at)jp(dot)fujitsu(dot)com>
Cc: 'Kyotaro HORIGUCHI' <horiguchi(dot)kyotaro(at)lab(dot)ntt(dot)co(dot)jp>, "coelho(at)cri(dot)ensmp(dot)fr" <coelho(at)cri(dot)ensmp(dot)fr>, "robertmhaas(at)gmail(dot)com" <robertmhaas(at)gmail(dot)com>, "MikalaiKeida(at)ibagroup(dot)eu" <MikalaiKeida(at)ibagroup(dot)eu>, "AYahorau(at)ibagroup(dot)eu" <AYahorau(at)ibagroup(dot)eu>, "michael(at)paquier(dot)xyz" <michael(at)paquier(dot)xyz>, "pgsql-hackers(at)postgresql(dot)org" <pgsql-hackers(at)postgresql(dot)org>
Subject: RE: Timeout parameters
Date: 2019-03-29 04:39:37
Message-ID: EDA4195584F5064680D8130B1CA91C4540F6B2@G01JPEXMBYT04
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Hi, Tsunakawa-san, Kirk-san.

Thank you for your review.

Tsunakawa-san,
> From: Tsunakawa, Takayuki [mailto:tsunakawa(dot)takay(at)jp(dot)fujitsu(dot)com]
> The client-side tcp_user_timeout patch looks good.
Thanks, but I minorly changed that patch.
It is the declaration place of sebuf[], moving to just before where it'll become needed.

> The server-side tcp_user_timeout patch needs fixing the following:
> (1)
> + GUC_UNIT_MS | GUC_NOT_IN_SAMPLE
> + 12000, 0, INT_MAX,
>
> GUC_NOT_IN_SAMPLE should be removed because the parameter appears in
> postgresql.conf.sample.
> The default value should be 0, not 12000.
Oops, fixed!

> (2)
> Now that you've changed show_tcp_usertimeout() to use
> pq_gettcpusertimeout(), you need to modify pq_settcpusertimeout(); just immitate pq_setkeepalivesidle().
> Otherwise, SHOW would display a wrong value.
Indeed, pq_settcpusertimeout() should be modified as well.

> The socket_timeout patch needs the following fixes. Now that others
> have already tested these patches successfully, they appear committable to me.
Thank you so much for reviewing even socket_timeout patch.

> The reason why oom_error label is present is that it is used at
> multiple places to avoid repeating the same error processing code.
Understood.

> (2)
> + conn->sock = -1;
>
> Use PGINVALID_SOCKET instead of -1.
Oh, I see.

Kirk-san,
> I referred to the doc in libpq.sgml, corrected misspellings, and rephrased the
> doc a little bit as below:
Changed "stop-gap" and "mean" -> "stopgap" and "measure" respectively.
But I can't find the difference between mine and yours.
Would you please tell me if there is a difference like this depending on your rephrasing?

Best regards,
---------------------
Ryohei Nagaura

Attachment Content-Type Size
socket_timeout_v10.patch application/octet-stream 5.0 KB
TCP_backend_v17.patch application/octet-stream 7.6 KB
TCP_interface_v17.patch application/octet-stream 3.7 KB

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Nagaura, Ryohei 2019-03-29 05:13:46 RE: Timeout parameters
Previous Message Jamison, Kirk 2019-03-29 04:22:16 RE: Timeout parameters