RFR:8194298 Add support for per Socket configuration of TCP keepalive
vyom tewari
vyom.tewari at oracle.com
Sat Apr 14 03:53:09 UTC 2018
On Saturday 14 April 2018 01:40 AM, Bernd Eckenfels wrote:
> Hello,
>
> Glad to see progress on this, much needed.
thanks
>
> I wonder if there is a better way for safe and dynamic string
> concatenation in the JDK, this errmsg[56] looks scary.
sure, i will fix it.
>
> Did you tried to support it on Windows, even if it does not support
> all 3 parameters it might be important to be available (I think Oracle
> Database supports it for DCD on Windows, too)
I already mentioned in mail, support for other platform can be added in
future if needed. Only "Windows 10 1709" support all three socket
options(TCP_KEEPIDLE, TCP_KEEPCNT, TCP_KEEPINTVL). These are socket
options, we want set/get both, I tried to implement keepalive times
using WSAloctl
(https://msdn.microsoft.com/en-us/library/windows/desktop/dd877220(v=vs.85).aspx)
but it is not possible to get the current *SIO_KEEPALIVE_VALS* for a
socket, MSDN says that WSAIoctl output buffer is not used.
Thanks,
Vyom
>
> Gruss
> Bernd
>
> Gruss
> Bernd
> --
> http://bernd.eckenfels.net
> ------------------------------------------------------------------------
> *From:* net-dev <net-dev-bounces at openjdk.java.net> on behalf of vyom
> tewari <vyom.tewari at oracle.com>
> *Sent:* Friday, April 13, 2018 11:50:39 AM
> *To:* OpenJDK Network Dev list
> *Subject:* RFR:8194298 Add support for per Socket configuration of TCP
> keepalive
> Hi All,
>
> Please review the below code.
>
> BugId : https://bugs.openjdk.java.net/browse/JDK-8194298
>
> webrev :
> http://cr.openjdk.java.net/~vtewari/8194298/webrev0.0/index.html
> <http://cr.openjdk.java.net/%7Evtewari/8194298/webrev0.0/index.html>
>
> Currently Java supports SO_KEEPALIVE, whose default value is 7200
> seconds which is too long for most of the applications. This code change
> will allow us to set the keepalive
> parameters(TCP_KEEPIDLE,TCP_KEEPCNT,TCP_KEEPINTVL) which will configure
> the idle time on per socket basis.
>
> I did code changes for Linux & Mac only, support for other platforms can
> be added in future if needed.
>
> Thanks,
>
> Vyom
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.openjdk.java.net/pipermail/net-dev/attachments/20180414/cdbf98c5/attachment-0001.html>
More information about the net-dev
mailing list