JavaFX: Future default JVM Language

June 11, 2009

With Larry Ellison’s recent public endorsement of JavaFX at JavaOne, it looks like JavaFX has a future once the Oracle takeover of Sun. In fact, he suggested that OpenOffice be rewritten in JavaFX (some considered it a bizarre comment, but it would be a bold strategic initiative). This is good news, because the efforts by Sun’s engineers are finally bearing fruit.

Joshua Marinacci has summarized the top 5 features of JavaFX 1.2, including Linux and Solaris betas:

http://weblogs.java.net/blog/joshy/archive/2009/06/top_5_most_impo.html

Osvaldo Pinali (of java.net) has some interesting observations on JavaFX 1.2:

http://weblogs.java.net/blog/opinali/archive/2009/06/first_look_at_j.html
http://weblogs.java.net/blog/opinali/archive/2009/06/first_look_at_j_2.html

However, his most important conclusion is that JavaFX Script may be a successor to the Java language:

http://weblogs.java.net/blog/opinali/archive/2009/06/javafx_script_a.html

With that and perhaps other few enhancements, JavaFX Script would become just as “complete” as other modern high-level OOPLs. JavaFX Script really could be a very viable candidate to the role of successor or companion to Java as a language for implementation of full Java applications.

Consider this: The Java language has come to a dead-end. The community, apparently, cannot stomach any evolution that would introduce even minimal backwards-compatibility breaking. The full compatibility constraint (both source and binary) makes very hard to introduce any major feature without some big compromise in either functionality, complexity, or interoperability with legacy APIs.

This conclusion was also reached by a poster (prime21) on a java.net poll a while ago:

http://java.net/cs/user/view/cs_msg/673284

The primary language on the JVM in the future will be JavaFX Script. New language features will go there. Java will not accept new features. That’s my prediction.

Sun’s plans seem to be to let legacy components of the Java framework unchanged for the sake of backwards compatibility (or legacy constructs) languish while it builds new components in parallel. This means that deprecated libraries will be maintained as separate modules and the Java language itself will no longer evolve (ex no addition of closures). This is the goal of Java 7’s module framework (Project Jigsaw) and the enabling of multiple languages in the JVM, respectively.

JavaFX Script seems to be less of a strict client-side Domain-Specific Language (DSL), and more of a prototype for the new default language of the JVM.

After all, it has support for closures, functional programming, data binding, no primitives (everything is an object) and more compact syntax.

Still, lots of work needs to be done, including, but not limited to:

1) Open source. JavaFX can become the RIA framework of choice for the open source community, and this would give it an unmistakable advantage over Flash and Silverlight. What’s more, it would allow for better debugging, since it would be possible to step into JavaFX classes (which I can’t do now).

2) Junit or unit testing functionality. Chalk this one to Fabrizio Giudici. This is absolutely essential for any serious programming.

3) Decoupling of GUI logic constructs from any server-side implementation. Otherwise, it would be weird to instantiate any of the GUI objects in the server VM.

4) Robust native support for multithreading. Right now, this is a bit of kludge:

http://forums.sun.com/thread.jspa?threadID=5382439&tstart=0

5) Profiling tools. Java has lots of these.

6) Some kind of native plugs into a more sophisticated database/ORM/JPA framework.\

After all, JavaFX will need to make up for around 15 years of evolution of Java tooling.

Apple: Get out of Java’s Way!

May 21, 2009

Following the revelation that Apple has failed to patch a flaw in its Java implementation:

http://landonf.bikemonkey.org/code/macosx/CVE-2008-5353.20090519.html

a flaw which was patched in Sun Java over 5 months ago, I’ve come to the conclusion that it’s time for Apple to surrender it’s control of the OS X Java implementation to Sun and the Java community.

It’s understandable that Apple’s Java will lag behind Sun Java, simply because the new code has to be adopted for OS X, which includes integration, testing, QA, developer previews, etc. However, there are many other ways that Apple has demonstrated its egregious incompetence, whether deliberate or accidental, in living up to its Java commitments and responsibilities:

  1. Contemptible slowness in issuing security updates, especially those based on existing patches from Sun. For a company that brags about how secure its OS is vis-a-vis Windows, this is totally unacceptable.
  2. Obsessive secrecy and total lack of transparency in dealing with Java developers. Instead of having a public bug database, it forces developers into signing unwieldy NDAs (non disclosure agreements) before allowing them to download developer previews for new versions of Java. This means any bugs are security issues are not disclosed publicly. Issues can only be disclosed to Apple directly. This is in sharp contrast with the totally open development model for Sun Java, which has already been open sourced and has a public community with public communication.
  3. Poor communication with said developers about its plans for future versions of Java. At WWDC 2007, Apple allowed only those Java developers who had paid to attend WWDC to know its Java plans for OS X Leopard when that OS would be released in October of that year. Those plans included omitting the year old Java 6 from Leopard and instead distributing only Java 5. The result was developer outrage over the omission because it was expected that Java 6 would have been included. Apple made the situation worse by deleting posts on its own forums confirming this fact, because they still had an obsessive need to keep it secret.

For these reasons, Apple is unfit as a steward of the Java platform on OS X. It has demonstrated contemptible irresponsibility in living up to its commitments:

We’re going to bring the Java platform back to the desktop in a really big way,” said Jobs to enthusiastic applause. “We are working really hard to make Mac the best delivery vehicle for the Java platform on the planet. We’re going to be there [with the Java platform] right out of the box, on your Mac.
— Steve Jobs, June 2000

Furthermore, Apple negotiated with Sun for the exclusive right to develop and distribute Java for OS X.

By failing to live up to their promises and commitments, Apple no longer deserves of being the sole provider of Java for OS X.

Fortunately, enterprising developers such as Landon Fuller are working to port OpenJDK, which is the open source version of the Java Development Kit, to OS X:

http://landonf.bikemonkey.org/code/java/OpenJDK6_MacPorts.20090516.html

I wish them the best of luck. This version of OpenJDK doesn’t come with graphical capabilities, although graphical applications can still be developed in X11 mode. Depending on whether or not Apple open sources its graphical Java code, the process of enabling this functionality could take years.

IT Predictions 2009

January 12, 2009

1) Microsoft starts scaling down and completely vacates at least one of its auxiliary business lines (MSN, Windows Mobile, XBox, search/portal).
2) Apple makes a serious push for enterprise customers, exemplified by features in Snow Leopard, which will sport of much more toned down GUI (ex no more red, yellow and green buttons on windows).
3) Sun Microsystems gets a stay of execution, as its gambles in storage, MySQL and virtualization pay dividends and return the company to marginal profitability.
4) The iPhone/iPod touch displace the Nintendo DS as the #1 mobile gaming device after hardware and software updates reinforce the device’s gaming functionality and attract more game development shops.
5) BluRay continues to stagnate as the recession hits the format hard. Digital movie downloads also become more attractive. Upscaling DVD players get improve marketing as cheap alternatives to BluRay.
6) Open source databases like MySQL and Postgresql benefit tremendously from the recession, as Oracle and other large database vendors finally lose traction.
7) At least one mobile operating system provider (WindowsMobile, OpenMoko, Android, Symbian) throws in the towel.
8) Apple scales back its iPod models and introduces at least one more lower-end iPhone line (ex “iPhone Nano”) in order to gain subscribers who can’t afford the full iPhone data plan and want to carry one device instead of two. The new phones will be available in CDMA and GSM, so Apple can do an end-run around AT&T for the non-smartphone business.
9) At least one major PC OEM, frustrated with Microsoft’s recent failures with Vista and the difficulty in extending Windows XP’s life, puts serious resources behind making Linux more user friendly in order to sell a line of Linux desktops and laptops. This could be a joint effort among Dell, HP, and several notebook vendors who realized there’s no way for them to install Mac OS X on their computers.
10) Cloud computing doesn’t take off, due mostly to the limits of internet connectivity and bandwidth and somewhat to consumers’ distrust of cloud computing vendors with their data.