Java Tutorials
JavaAvoiding Java Engine in Your Application
Firefox is undoubtedly one of the most popular browsers in the world today – only next to IE. Most users who have been online for many years have recognized the capability of this browser because of its ability to integrate plug-ins which makes the browser a mini-platform for an almost unlimited number of functionalities.
Its simple interface has also made it a favorite for developers. Firefox even has the capability to read websites that have been configured to work with very old version of browsers. Although it is only second to IE, it is a lot better because of its endless possibility.
Apparently, the usefulness and backwards compatibility of Firefox goes way back to the early days of Java. The virtual machine or JavaVM used to be fired up with a very simple command or when the application requires the browser to execute Java functionality.
But the old command of JavaVM to be fired up is only as simple as calling a function with “sun” which refers to the name of the company that developed Java: Sun Microsystems Inc. Calling a function is very common in an Ajax or JavaScript based application. Although the word sun in a function might not happen if you do not have any files that named “sun” it is still a possibility.
When a function or even a window that has “sun” as part of its command, the JavaVM will be called which means it will download Java if the application is not yet installed. This will delay your online application a lot and it will download unnecessary files.
This will create a major inconvenience to your application. Although Java could easily work with JavaScript, downloading JavaVM is not one of the ideal interactions developers would need from these programming languages.
The function that comes with “sun” is not the only word that triggers JavaVM. Functions with Java, Packages, Netscape, Sun, JavaClass, JavaArray and JavaMember will immediately trigger the download of JavaVM.
This actually reminds us why Java has fallen short in competing with JavaScript as the programming language for Web 2.0. Although the functionality is offered by Java and its applets, the mere fact that developers still have to download or start-up Java before anything else will be executed has always pushed away further adoption of Java. Since JavaScript does not have any prior requirements before it could be used, it has become the choice of developers.
Unfortunately, there is no workaround for this concern. You need to review your application and remove those words if they are associated with functions. Although this would be an inconvenience, it is necessary to make those changes because JavaVM will definitely drag your application.
It is a small tradeoff since it will mean ease of use for your users. This form of “bug” has just been detected and might have been crippling your application for sometime now without your knowledge. JavaVM is good in itself but that does not mean that users can just download JavaVM anytime without being needed in the online application and without the knowledge of the developer.
Sponsored Links
