With the end of 2011 nearing, I thought it would be a good time look back on what has happened in the world of JavaFX this year…
As you may recall, it was October 2010, at JavaOne, where Oracle announced publicly that JavaFX was going to see a reboot. It was announced that JavaFX was to transition from the ‘JavaFX Script’ language to being built in Java. This decision was made inside Oracle only a month or two prior to the announcement, which led to a number of JavaOne sessions and BOFs being quickly cancelled and replaced to cover the new direction. At JavaOne 2010 the sessions were therefore discussing what was coming, rather than what was available in JavaFX 1.3.1 (which was the last release in the JavaFX 1.x line). I remember showing demonstrations of not much more than rectangles being drawn on screen, using what was then our Java APIs (but which permutated considerably during the course of development). This was the JavaFX 2.0 state of the art at the time, and we have come a long way since then!
Another vivid recollection I have from JavaOne 2010 is the various reactions that people had of this news. It varied from those in shock at losing their favourite language, to those who said it was long overdue and was the right way to proceed with JavaFX. I tried to ease people into this new approach by clarifying that, of course, now that JavaFX is in Java, many other JVM languages can come in to make developing JavaFX more enjoyable again, especially if developers were to write improved DSL extensions to these languages. Fortunately, exactly this has happened, with projects such as GroovyFX, ScalaFX, and of course, the JavaFX Script fork, Visage, coming in to simplify the development of rich JavaFX user interfaces.
Work continued apace in redeveloping JavaFX in Java through late 2010, and in early 2011 we begun to offer early access builds of JavaFX 2.0 to close partners. Despite the builds being made available to actual end-developers, API changes were happening at an incredibly rapid pace. I’m sure this led to great frustration (which is also why the builds were not more widely distributed). Internally, these major API changes were massively helped by our use of Lombok during the early prototype stages, as it allowed for us to create custom annotations to represent our properties, and simply update our Lombok code to recompile with a massively different API. As our API became more stable, we started to remove our dependency on Lombok, and today it is not used at all in our source code.
As development continued with JavaFX 2.0, we started to do something I was, and continue to be, very proud of – we started making pre-release builds available to the community. This let you, the consumers of the API, provide invaluable feedback to the developers. No one wins when ‘big bang’ releases are made without discussion, and frankly, the JavaFX community rock – whether it is in comments on blog posts, in the JavaFX forum, in the openjfx-dev mailing list, or in one-on-one emails sent to developers in the JavaFX team (it’s normally not hard to guess our @oracle.com email addresses!).
As JavaOne 2011 drew closer, JavaFX 2.0 was continuing to see refinement, with APIs being finalised, performance being improved, and bugs squashed. Unsurprisingly for most people, JavaFX 2.0 was released at JavaOne 2011. In addition to porting the JavaFX 1.3.1 source code to Java, JavaFX 2.0 also ships with a huge number of new features that were developed at the same time. I’m loathe to include a list, as I’m certain I’ll miss out plenty of cool stuff, but from my point of view as a controls team member, JavaFX 2.0 includes new API for properties, binding, collections, animation, new controls such as TreeView, TableView, ChoiceBox, Menus, SplitPane, TitledPane, HTMLEditor, and Accordion, improved layout APIs (including GridPane), the WebView component, and much more. In addition to the new API, JavaFX 2.0 ships as the first release to enable the brand new Prism graphics engine, as well as the new Glass framework for windowing and other native operating system integration. Of course, feel free to comment on your favourite new feature (especially if I missed it out)!
Perhaps the most controversial topic related to JavaFX was its lack of cross-platform support from the get-go – JavaFX 2.0 shipped as a Windows-only release. The uncertainty around what this meant led Richard (the newly crowned Java Client Architect) to blog about this in his ‘Is JavaFX 2.0 Cross Platform?‘ post. The general reasoning for this approach was that we could either make a tiered release plan (as we did), and get the Windows build out sooner, or hold back the release for a much longer time so that development of Windows, Mac OS, Linux, etc builds could all get up to the same level prior to release. We ended up doing the tiered release approach, as it meant we could get a solid Windows release out sooner, and focus on getting other platforms solid subsequently. I’m sure this upset people that wanted support for their preferred operating system from the start, but I’m also comfortable with the approach taken for the reason above.
Almost as soon as JavaFX 2.0 shipped, JavaFX 2.0.1 was released, as the JavaFX team jumped on the Java release train of alternating security and bug-fix releases. Because of this, JavaFX 2.0.1 shipped only a few weeks after JavaFX 2.0 did, with just a few security-related fixes. Very few engineers inside Oracle were involved in this release, with most focused on the forthcoming JavaFX 2.0.2 release instead.
JavaFX 2.0.2 was released to coincide with Java 7u2 (which JavaFX is co-bundled with) in early December. JavaFX 2.0.2 includes a huge number of bug fixes, optimisations, some new API, and an improved redistribution license. As mentioned, it was the first release following JavaFX 2.0 that features considerable development effort by all teams. For me it was an exciting release due to the huge number of bugs we were able to squash between JavaFX 2.0 going into code freeze (since about a month before JavaOne) and JavaFX 2.0.2 going into code freeze around early November.
Not content with this pace, JavaFX 2.1 early access builds were also announced in December. JavaFX 2.1 builds are available for Windows and Mac OS, allowing for the same JavaFX code to run on both operating systems without any changes necessary. The JavaFX 2.1 builds are intended to be weekly releases, and of course are not as production-ready as the JavaFX 2.0.2 release (but also not as exciting ). Already, people are exploring what is new in these builds, which as of JavaFX 2.1 build 06 includes a bunch of new collections API, a ComboBox control, new charts, and native DirectoryChooser support. There is also plenty more coming in JavaFX 2.1, but which has not hit a public release yet.
Aside from the amazing pace of releases containing bug fixes and new features, I can’t conclude this look back without mentioning the news that was announced at JavaOne 2011 that all of JavaFX will be open sourced. Already, the OpenJFX project exists, with the UI controls being available (and developed) in the open. Amazingly, the openjfx-dev mailing list, which opened up on December 1, has already had 442 posts in December, and there are 107 people already signed up to the list. The discussion is lively, and brings together community members and Oracle employees to discuss the future of the JavaFX API. Already there have been discussions on a range of topics, and your feedback is appreciated no end.
On a side note, FX Experience, the blog run by Richard, Jasper and I (Jonathan), also continues to grow at a nice pace. In 2009, FX Experience received 54,444 views, at an average of 259 views per day (for the seven months the site was running from June). In 2010, the average daily visitors was 326 people, which led us to have 118,926 visits in 2010. This year, with two days remaining, we grew the visitor numbers to average 530 views per day, resulting in 192,928 visits in the year. I’m very pleased at the growth this blog continues to see, and hope that it continues for the foreseeable future.
The top 12 posts this year were the following (ignoring the fact that this favours posts from earlier in the year):
- JavaFX 2.0
- Introducing FXML
- Is JavaFX 2.0 Cross Platform?
- Maps in JavaFX 2.0
- JavaFX 2.0 Charts
- Worker Threading in JavaFX 2.0
- JavaFX 2.0 Beta is Available!
- FXML: Why It Rocks, And The Next Phase
- JavaFX links of the week, February 13
- Simple 3D Cubes in JavaFX 2.0
- SplitPane in JavaFX 2.0
- FXML + Guice
Looking forward, the JavaFX roadmap was updated recently to detail our plans for JavaFX 2.1, 2.2 and 3.0. If you want to be more involved in these discussions, joining the openjfx-dev mailing list is the place to start. There are a number of exciting plans for next year, including full support for Mac OS and Linux, the JavaFX Scene Builder tool (for easily building user interfaces), as well as plenty of new features/API, and of course a huge number of bug fixes.
That’s all I can really recall for JavaFX this year. I’m sure I’ve forgotten more than I remember, but I hope that the insight into the year that has been has been interesting, and I hope you’re all enjoying using JavaFX. Next year stands to be another exciting year, so strap yourself in tight and hold on – it’s gonna be a fun ride!