adding rsockets support into JDK

Lu, Yingqi yingqi.lu at intel.com
Tue Sep 25 03:57:40 UTC 2018


Hi Brian,

Thank you for the quick review. As Alan suggested, I am following the example of SCTP support to add dlopen/dlsym into JDK internal implementations. Hopefully, I will be able to submit another version of the patch tomorrow or Wednesday.

Do you prefer that I submit a diff vs. webrev.09 or a complete patch to current jdk trunk as webrev.11?

Thanks,
Lucy

From: Brian Burkhalter [mailto:brian.burkhalter at oracle.com]
Sent: Monday, September 24, 2018 5:52 PM
To: Lu, Yingqi <yingqi.lu at intel.com>
Cc: Alan Bateman <Alan.Bateman at oracle.com>; 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,

On Sep 23, 2018, at 8:07 PM, Lu, Yingqi <yingqi.lu at intel.com<mailto:yingqi.lu at intel.com>> wrote:


Here is the version 10 of the patch http://cr.openjdk.java.net/~ylu/8195160.10.

To simplify the review I created a diff webrev versus version 9:

http://cr.openjdk.java.net/~bpb/8195160/webrev.10vs09/


This patch includes all the changes Brian added based on version 09. In addition, I added following things:

1.     Fixed JNI function names from various C files. This is due to the package name changing from rdma.ch<http://rdma.ch/> to jdk.internal.net.rdma

Sorry I overlooked this.

In other C code I encountered an error while building:

openjdk/src/jdk.net/linux/native/libextnet/LinuxRdmaSocketDispatcherImpl.c:146:1:<http://jdk.net/linux/native/libextnet/LinuxRdmaSocketDispatcherImpl.c:146:1:> error: 'handle' defined but not used [-Werror=unused-function]
 handle(JNIEnv *env, jlong rv, char *msg)
 ^~~~~~

If the function is simply removed then it builds.


2.     Found a small issue with supportedOptions() from both java.net.Socket and java.net.ServerSocket. When a RDMA socket created after a regular TCP socket or verse visa, the private variable "options" can possibly return the wrong set of supported socket options. I create another variable named rdmaOptions and use that to track socket options for all the RDMA sockets.
3.     Removed some of the test cases from RDMA test set that are targeted only for old TCP socket issues. Currently, all the test cases passed on my CentOS 7 machine (with librdmacm and librdmacm-devel installed)
4.     Created one more test for non-Linux platform to test if UOE is thrown on RDMA sockets and channels.
5.     For test cases, I removed "include <rdma/rsocket.h>" from C file and -lrdmacm inside JTreg make file. Instead, I use dlopen and dlsym to load the library dynamically.

All tests pass in my local Linux build.

Aside from the dlopen/dlsym issue that you are working this is looking pretty good.

Thanks,

Brian

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


More information about the nio-dev mailing list