Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
[jgit-dev] Java NIO Options

On Wednesday, 28 May 2014, Shawn Pearce <spearce@xxxxxxxxxxx> wrote:
> Right, we are (still!) targeting Java 5 and Java 6 platforms. So we
> can't go crazy and use Java 7 NIO features throughout the core part of
> the JGit library. But we can do it through some minimal sections that
> are important and easily isolated, like symbolic link support.
> There has been talk about dropping Java 5, but not 6 compatibility.
> Unfortunately there is no plan of action to actually do that.

For those curious (like me) about what might have a bearing on the decision to drop Java 5 compatibility, here's are the factors that I know of (being a bit of an outsider to the process):

EGit (which apparently aims to support at least the latest two Eclipse releases) still targets Java 1.5: 

...and Java 1.6 requirements are only just starting to percolate into Eclipse itself. Eclipse Luna (not yet released) has some Java 1.6 reqs, but core components (org.eclipse.core.filesystem, etc) still have a minimum execution environment of 1.5 - so not much pressure/invitation to upgrade there:

Platforms where Java 6 is not available: For example, on OpenVMS at one point, JGit was the only working Git client - there was no port of the C client available, and OpenVMS only had Java 5 available. Not sure if this is still the case, and I see some indication that Java 6 is available for at least some versions of OpenVMS.

Android: There's never been an exact correlation between Android's class library and a specific Java version, but the closest approximation is Java 6 (some Java 6 classes like java.util.Deque weren't added until Android API version 9). Personally, as the author of Agit, I'd now be happy to develop to Ice Cream Sandwich (Android API version 15) as a minimum. Unfortunately many Java 7 classes (like the whole of java.nio.file.*, including 'Path') aren't available even in the latest version of Android.

End-of-Life: Obviously, Java 5 was EOL'd by Sun/Oracle in 2009, Java 6 was EOL'd in March 2013.

Developer Effort: Continuing to support Java 5 definitely does extract some toll, see for instance this recent commit reverting an accidental use of Java 6's IOException(Throwable) constructor:

Would love to hear more reasons for and against, personally I love shiny things, me.


Back to the top