Java Download Service Listener

One of the previous post [Applet Startup Time] provided a way to measure start-up time of JavaFX Applets. Many responded with requested information (Thanks a lot!). One of the main concern raised was high start-up time for “Without JavaFX Runtime”. This is high because it includes time taken to download and install JavaFX Runtime.

Unfortunately there was no way to notify the user about exact progress of this. Hence user will not be able to differentiate between download and install of “JavaFX Runtime” and “JavaFX Application”.

Recent JavaFX Update 1.2.3 reduced the download size and start-up time. You can notice this change by trying out the start-up time measurement applet again.. But still it doesn’t provide a way to exactly notify the start-up progress. We can only specify a custom splash-screen as specified here.

Now we can implement custom progress listener with actual values. We can use the same approach for JavaFX applications as well. There is minor issue in using this feature with JavaFX Applet deployed using dtfx.js. This script is not updated to utilize this feature. So for now we need to explicitly hide the default splash screen by invoking JavaScript method hideOverlay as shown in ProgressListenerFX.html

@Carl Great! May be I must collect these new data and compare with the previous startup data.. 🙂
Latest JRE installers downloads and saves JavaFX Runtime in “system” cache.. You can remove
both user and system cache entry using below commands..

Nice post.
Do you think it’s possible to create a JavaFX stage instead of a Swing panel? I made a quick try running com.sun.javafx.runtime.main.Main in the constructor of my progress listener implementation, but it does not work. The javaws process just “vanish” with no message and no crash log…any idea if this should be possible to get this working?

I don’t think its supported.. The interface is suitable for AWT/Swing implementation.. Also I think it will be better to have a very lightweight splash-screen (Downloading (if required) and start-up of JavaFX runtime adds to start-up time). Are you using any specific feature in JavaFX for splash-screen?