The future of Java and impacts on KoLmafia

fronobulax

Developer
Staff member
Interesting.

My take on things is that the reason mafia is not pinned to the latest and greatest JDK is because of Apple. A good portion of the dev team used Apple operating systems, hola, the original author strove for compatibility with what we would now call legacy Apple systems and Apple and Sun got into a snit and Apple stopped updating Java.

So what I imagine will happen is that one day KoLmafia will just declare that it is no longer available on a platform that does not support Java X where X is the oldest version supported by the current compiler. This will make some people sad and maybe even make it so a handful of people cannot run mafia but the impact will be minimal.

Alternatively, given that someone has stepped up and packaged mafia as a Windows executable, someone may step up and maintain a development environment that is capable of generating code for really old versions and the resulting jar file released or otherwise be made available. Philosophically I suspect the dev team would be willing to manage source code so that creating a legacy version is not too burdensome.
 

Ethelred

Member
Interesting.

My take on things is that the reason mafia is not pinned to the latest and greatest JDK is because of Apple. A good portion of the dev team used Apple operating systems, hola, the original author strove for compatibility with what we would now call legacy Apple systems and Apple and Sun got into a snit and Apple stopped updating Java.

... [snippage] ...

While that may have be the case in the past, Apple has passed resposibility for Java updates back to Oracle, and Java 7 (or 1.7, or whatever the proper label is) is available on "up-to-date" versions of Mac OSX. My understanding (which may well be incorrect) was that Hola had an old Mac system which would not support an "up-to-date" version of Mac OSX and was thus restricted to an older version of Java. Not really sure what difference any of this makes except that it's not likely Apple's fault, but rather the situation of some individuals. Anyone with "up-to-date" Mac HW and SW can run current versions of Java.
 

Catch-22

Active member
The problem is I think 10.5 and older (is that Tiger?) is not supported by Oracle and Apple stopped doing updates. There's instructions on how to get OpenJDK to compile for it, but it's a lot of messing about last I checked. Fortunately, at last count I think this affects like 2 users of KoLmafia, with one of them being Holatuwol (who should be able to follow instructions on OpenJDK compiling).
 

holatuwol

Developer
As far as legacy Mac operating systems go, OS X 10.3 is Panther (supports up to Java 4), OS X 10.4 is Tiger (supports up to Java 5), OS X 10.5 is Leopard (supports up to Java 5), OS X 10.6 is Snow Leopard (supports up to Java 6). The two vetoes to the update beyond Java 5 were jasonharper and I are on OS X 10.4.

With that being said, unless you are using language features or Java API that only become available in the later versions of Java, it doesn't matter. If all jasonharper and I have is a JDK 5 compiler, and as long as the source code doesn't contain anything that *requires* the newer version of Java, it will compile as long as we modify our build.xml to use a different source compatibility.
 

roippi

Developer
I've looked into it and I don't think there's ever been a particular time where I was aching for a feature that's only available in 6. 7 does have some nice stuff in it, notably switching on strings, but we're certainly not ready to require 7.

I'd like to be able to take down the Java 7 warning over in the bug reports forum and not hold people back from updating. I have a feeling that there's still some.. unaddressed issues lurking in the codebase with regards to 7, but we're going to have to bite the bullet eventually.
 
Top