My opinion about JavaFX 2.0

It’s been a few weeks since Oracle announced the plans with JavaFX.The JavaFX 2010-2011 roadmap is described at the JavaFX website. AsI expected, there were many discussions and opinions in the blogosphereafter the announcement. I took some time to read opinions, and to makemy own impact estimations.

Java

In general, I always applaud the move towards more Java.I am a Java developer, so the more Java the better for me.There are many reasons why I like JavaFX to be an integral part of theJava runtime. Every developer probably has his own list, here is mine:

  • Access the latest and greatest JDK features
  • Generics and Annotations can be used in JavaFX
  • Less confusion in concepts (should I make this a Java or JavaFX class?)
  • Less confusion in grammar (Foo foo = new Foo() or Foo {})
  • Existing tools for Java work for JavaFX (i.e. format, auto-complete,…)
  • No separate download for end-users

Apart from the move to Java, one of the major things is Prism. We heard a lotabout Prism already, and my personal summary is that Prism is “THE graphicalengine for applications in 2010+”, where AWT was the graphical engine inJava in the late nineties.

Timeline

For the projects I am working on, the new roadmap is a positive thing.The major drawback of the roadmap is the timeline. Developing in JavaFX 1.3.1is still encouraged, and Oracle will probably provide some script orguidelines to migrate JavaFX 1.3.1 code to JavaFX 2.0.
But if Oracle wants to be a winner in the RIA market, things should happenfaster. I understand quality matters, and I fully agree. One of thecritics I heard about “good old Sun” is that Sun often over-promised andcouldn’t deliver. I partly agree with that. A number of in-house, closed doorprojects were not as good as promised. But, and here I go again with mycomparison, look at the Glassfish project.

Lessons learned from the Glassfish project

From the very beginning, the Glassfish team created and communicated a roadmap.The goals were clear from day 1, but also the architectural documents,discussions and code was made available.
Having the goals clear creates high expectations fromusers and customers. Having the code and discussions open, allows developersto help, and it generates early feedback. When Glassfish x.y is released,there won’t be negative surprises, since it is something that was alreadyavailable in the community during development. Developers clearly knowwhat is going on. If they need things faster, they are free to help andcontribute. Of course, the quality assurance is still in internal hands.Not everyone is allowed to commit patches to the core functionality. Butthat is not needed. The developer community is allowed to help, and it isup to Oracle to decide what do with the code.

I strongly encourage the same concept for JavaFX development. The JavaFXteam at Oracle is great, lots of clever people. I was glad I could talkwith some of the core JavaFX developers (e.g. Richard Bair, JasperPotts, Jonathan Giles and Amy Fowler) during JavaOne. Those are excellentpeople doing a great job. Add the power of the development community tothis team, and JavaFX 2.0 will be a success.

JavaFX script and Visage

The JavaFX community has mixed feelings on the fact that Oracle won’tcontinue the investment in JavaFX script. That means that Oracle won’tcontinue to develop the JavaFX Script Compiler. Some people like thisdecision, others are extremely disappointed.
That sounds very reasonable. JavaFX script is a DSL with somespecific characteristics. I don’t believe there is a single languagethat is “best” for all developers. The way developers think, the waythey see (or don’t see) concepts and structures makes one oranother language the most suitable to them. Some people see feature Xof Scala as an advantage, others see it as a disadvantage. There is no”best” answer.

At JavaOne, Stephen Chin announced Visage, a “new” DSL that is actually the continuation ofJavaFX script with modifications. The great thing about this is thatit is a DSL that is developed in the Open Source, with input from thecommunity.
I am convinced that Visage is a great language for at least a number ofdevelopers. One of the good things about JavaFX 2.0 (and Java in general)is the increasing support for DSL’s that can leverage the Java platform.Developers use the language of their own choose (Java, Visage, Scala,…)and their code runs on the Java platform. That is an incredible strongpoint of the Java Platform.

Overall, I am happy with the JavaFX 2.0 plans. But I am convinced thedeveloper community should be involved, in order to increase thechances on success.