7191556: (fs) UnixNativeDispatcher.getextmntent should be moved into platform specific code
Alan Bateman
Alan.Bateman at oracle.com
Thu Aug 16 00:54:50 PDT 2012
On 15/08/2012 19:29, Andrew Hughes wrote:
> :
> It's ok by me. I'm not sure how common it is either (fairly rare I would
> have thought). I would guess it's much more common on *BSD (it's certainly
> in FreeBSD's ports, as is GNOME), but that platform doesn't seem to be supported
> anyway. FileSystemProvider's create method will throw an AssertionError rather
> than returning the provider, which seems to be there just as a base for the MacOS X
> one.
I think most of the BSD port came into the jdk8 and jdk7u forests as
part of the Mac port but there is a lot of inconsistencies. To my
knowledge, BSD isn't supported in the main forests and that there are
still patches and changes in the down-stream bsd porting project. In
this specific case I think the right thing to do is to add
src/bsd/classes/sun/nio/fs/DefaultFileSystemprovider.java to create the
BSD provider. At least the assertion error "Platform not recognized"
will serve as a reminder to porters. Of course this also brings up the
topic of having code for several platforms in src/solaris. We've been
kicking that can down the road for several years but that's a bigger topic.
> Sure. It's not so much of an issue with NIO, but GIO/Glib will also need to be used
> to replace GConf in sun.net.spi.DefaultProxySelector, so perhaps it's worth seeing
> the two could be unified in some way, rather than having a search for GIO at two
> different places in the codebase.
>
I agree we shouldn't have to duplicate code to search for GIO but we
also have to be careful with dependencies between given parts of the JDK
code. I would suggest coming up with a proposal and we can discuss it in
more detail. On net-dev there are periodic issues with the default proxy
selector code and I completely agree this needs attention too.
-Alan.
More information about the nio-dev
mailing list