In below inner class of java.net.InetAddress
, there is a native method - isIPv6Supported()
. Suppose, I am using Springs as application framework and deploying my application in Weblogic server, question is that whether this native method will be implemented by Weblogic, Springs or both.
My guess is that it should be implemented by both, but when I try to search Spring source code then this method is not found anywhere but ideally it should be there otherwise how a HTTP connection will happen, this is called before lookupAllHostAddr()
and lookup for the DNS has to happen before a HTTP connection is established.
class InetAddressImplFactory {
static InetAddressImpl create() {
Object o;
if (isIPv6Supported()) {
o = InetAddress.loadImpl("Inet6AddressImpl");
} else {
o = InetAddress.loadImpl("Inet4AddressImpl");
}
return (InetAddressImpl)o;
}
static native boolean isIPv6Supported();
}