adding rsockets support into JDK

Lu, Yingqi yingqi.lu at intel.com
Mon Feb 4 22:42:22 UTC 2019


Hi Brian,

You are right! Rdma socket and server socket do not support all the available Standard Socket Options. Here is the list:

RdmaSocket{Channel} supports following socket options:
StandardSocketOptions.SO_SNDBUF
StandardSocketOptions.SO_RCVBUF
StandardSocketOptions.SO_REUSEADDR
StandardSocketOptions.TCP_NODELAY
RDMASocketOptions. RDMA_SQSIZE
RDMASocketOptions. RDMA_RQSIZE
RDMASocketOptions. RDMA_INLINE

RdmaServerSocket{Channel} supports following socket options:
StandardSocketOptions.SO_RCVBUF
StandardSocketOptions.SO_REUSEADDR
RDMASocketOptions. RDMA_SQSIZE
RDMASocketOptions. RDMA_RQSIZE
RDMASocketOptions. RDMA_INLINE

Please help update them!

Thanks,
Lucy


From: Brian Burkhalter [mailto:brian.burkhalter at oracle.com]
Sent: Monday, February 4, 2019 1:58 PM
To: Lu, Yingqi <yingqi.lu at intel.com>
Cc: nio-dev at openjdk.java.net; Viswanathan, Sandhya <sandhya.viswanathan at intel.com>; Aundhe, Shirish <shirish.aundhe at intel.com>; Kaczmarek, Eric <eric.kaczmarek at intel.com>
Subject: Re: adding rsockets support into JDK

Hi Lucy,

I found and fixed some small errors in the RdmaSockets doc:

http://hg.openjdk.java.net/jdk/sandbox/rev/78d016915473

I also have some doubts about the accuracy of the documentation in this class regarding socket options. Firstly, the options supported  by the objects returned by openSocket() and openSocketChannel() look as if they do not include *all* the options supported by java.net.Socket and java.net.ServerSocket, respectively, contrary to the documentation, e.g.,

"An RDMA socket supports the same socket options that java.net.Socket<file:///\\Users\bpb\Work\CoreLibs\jdk\sandbox\build\macosx-x86_64-server-release\images\docs\api\java.base\java\net\Socket.html> defines. In addition, it supports the socket options specified by RdmaSocketOptions<file:///\\Users\bpb\Work\CoreLibs\jdk\sandbox\build\macosx-x86_64-server-release\images\docs\api\jdk.net\jdk\net\RdmaSocketOptions.html>.”.

In addition to the RDMA socket options, the RDMA socket and socket channel appear to support SO_SNDBUF, SO_RCVBUF, SO_REUSEADDR, and TCP_NODELAY which are only a proper subset of the options supported by Socket{Channel} and what one would expect based on [1].

Secondly, openServerSocketChannel() does not include the sentence

"In addition, it supports the socket options specified by RdmaSocketOptions<file:///\\Users\bpb\Work\CoreLibs\jdk\sandbox\build\macosx-x86_64-server-release\images\docs\api\jdk.net\jdk\net\RdmaSocketOptions.html>.”

but looks like it should.

Thirdly, the documentation of openServerSocketChannel() does not mention options at all which appears to be an omission.

I am happy to update this documentation as needed once there is corroboration or rejection of my foregoing comments.

Thanks,

Brian

[1] https://linux.die.net/man/7/rsocket


On Feb 4, 2019, at 11:51 AM, Lu, Yingqi <yingqi.lu at intel.com<mailto:yingqi.lu at intel.com>> wrote:

I think we already addressed all the feedbacks. However, Alan/Chris, please let us know if there is anything else we need to change in terms of JavaDoc wording.

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://mail.openjdk.java.net/pipermail/nio-dev/attachments/20190204/ea799c61/attachment-0001.html>


More information about the nio-dev mailing list