ShortShip

25 January 2009

When JavaFX + Web Start might be a better choice than Flex + AIR

Over the next several months I will be working on an application currently written in Flex and deployed with AIR. I’m fairly impressed with what the application is able to do now but some of the planned features are currently impossible to implement in Flex given the limitations of the AIR 1.5 runtime. One thing we’ll need specifically is the ability to launch a native application from our AIR application. The amount of extra work we’ll have to do to make this possible is immense. Because we don’t want users to require any additional runtimes (ie Java), we’re forced to write a “proxy” application in C/C++ that the AIR application can communicate with to perform these unsupported operations. So, instead of having to maintain one application, we’ll have to maintain at least two (the proxy application will vary with each OS we support). In addition, we’ll need to provide the ability to update this proxy application as well as allow users to remove it. 

All of this had me wondering if JavaFX would have been a better choice. Combined with Web Start it has all of the same functionalities we currently have with Flex and AIR but there wouldn’t be any need for a proxy application since a signed Java application has full access to the system. In addition, JavaFX does have several free tools (Netbeans, plug-ins for Photoshop and Illustrator, ect). 

Of course, there are issues with using JavaFX. For one, not many developers know Java FX Script but many developers have at least some experience with Flex. Secondly, Flex and AIR are more mature than JavaFX. Flash is also much more prominent than Java and the process of installing AIR from a website is pretty seamless. On the other hand, JavaFX on Windows requires Java 6 and the process of updating to Java 6 is less than ideal.

No related posts.

5 Comments currently posted.

Carsten Schlipf says:

That Java FX requires Java 6 is an urban myth. The only difference is that you cannot take advantage of the new plugin and that you have to download the FX platform JARs. Also some special features, like dragging an applet to the desktop require Java 6. However for web start you can also use Java 5

Coffeejolts says:

JavaFX will be a better choice at some point in the future. The JavaFX Script language is easy to learn. A decent dev can figure it out in a day. The runtime needs some improvements (layout managers, more UI widgets, better performance), which is why I say it will be ready in the future.

But, why JavaFX and not Java? If you needed the media support, you could have just taken if from the JavaFX runtime.

Rob Christensen says:

Hi ShortShip,

I just wanted to drop you a note and say thank you for sharing your thoughts on AIR. Though I do not have anything to share at the moment, I want to let you know that we are indeed thinking about this problem and you’re not the first person to mention this as a challenge. It is possible to request a redistribution agreement from Adobe for the AIR runtime and write a bundled, command proxy type of application to launch an application (quite a few developers are doing this today).

Thank you again,
-Rob
Product Manager, Adobe AIR

P.S. Feel free to email me if you have any other questions related to AIR.

pavan kumar says:

AIR can never be used to make complex desktop applications(atleast as of now) , since Flash is inherently single threaded. JavaFx allows for async operations ..but…currently lacks any widgets to be of any practcial use…. but it would be just a matter of time before a good component library is created.

commenter says:

Sun is putting the cart before the horse. It’s all about deployment, deployment, DEPLOYMENT!

Even if the technology is in the beta stages at the very least make the deployment as seamless or transparent to the user as possible. This is something that both Adobe and Microsoft have figured out early and quickly. But for some reason Sun seems to have it’s head so far up it’s butt it doesn’t seem to realize it will not succeed on the desktop market if it’s deployment is anything but straightforward. Security prompt dialogs? 5-10 minute downloads for a 800kb webstart demo? 5 years ago this would have been acceptable but come on Sun you keep hyping up these technologies yet you consistently fail to deliver.

Is it incompetence? Arrogance? Lack of Vision? Or maybe it’s just lack of good leadership where sun has now inevitably slid into the abyss? It’s 2009 now and Sun has been bought out by Oracle. I would of prefered IBM but something tells me that at the very least Oracle won’t hype but actually implement technologies they are committed too whatever they may be.

Post a comment on this entry: