In computing, Java Web Start (also known as JavaWS, javaws or JAWS) is a deprecated framework developed by Sun Microsystems (now Oracle) that allows users to start application software for the Java Platform directly from the Internet using a web browser. The technology enables seamless version updating for globally distributed applications and greater control of memory allocation to the Java virtual machine.
Java Web Start was distributed as part of the Java Platform until being removed in Java SE 11, following its deprecation in Java SE 9. The code for Java Web Start was not released by Oracle as part of OpenJDK, and thus OpenJDK originally did not support it. IcedTea-Web provides an independent open source implementation of Java Web Start that is currently developed by the AdoptOpenJDK community, RedHat and Karakun AG, and which is bundled in some OpenJDK installers. [1] Next to this OpenWebStart provides an open source based implementation that is based on IcedTea-Web but offers more features and commercial support options.
Unlike Java applets, Web Start applications do not run inside the browser. By default they run in the same sandbox as applets, with several minor extensions like allowing to load and save the file that is explicitly selected by the user through the file selection dialog. Only signed applications can be configured to have additional permissions.
Web Start has an advantage over applets in that it overcomes many compatibility problems with browsers' Java plugins and different JVM versions. Web Start programs are no longer an integrated part of the web page, they are independent applications that run in a separate frame.
Web Start can also launch unmodified applets that are packaged inside .jar files, by writing the appropriate JNLP file. This file can also pass the applet parameters. Such applets also run in a separate frame. Applet launcher may not support some specific cases like loading class as resource.
Like applets, Java Web Start is cross-platform.
With JDK9, several deployment technologies including applets and Java Web Start were deprecated by Oracle. [2] [3]
In March 2018, Oracle announced it will not include Java Web Start in Java SE 11 (18.9 LTS) and later. Developers will need to transition to other deployment technologies. [4] A few stand-alone alternatives have since arisen.
The developer prepares a special XML file with JNLP extension. This file describes the application requirements, code location, parameters and additional permissions (if any). The browser downloads this file as any other and (following its MIME type, application/x-java-jnlp-file
) opens it with Web Start tool. Web Start tool downloads all necessary resources and launches the application.
Java Web Start provides a series of classes in the javax.jnlp package which provide various services to the application. Sun designed most of these services with the aim of allowing carefully controlled access to resources (such as files and the system clipboard) while restricting the application to authorized operations.
Sun introduced version 1.0 of Web Start in March 2001, [5] while 64-bit Windows support was added only in Java 6 [6] (later than 64-bit Java was first available). Since J2SE 1.4 Web Start comes as a default part of Java Runtime Environment (JRE) called javaws
, computer administrators no longer have to install it separately.
Programmers often speak of the Java Network Launching Protocol (JNLP) interchangeably with the term "Web Start". The JNLP protocol, defined with an XML schema, specifies how to launch Java Web Start applications. JNLP consists of a set of rules defining how exactly to implement the launching mechanism. JNLP files include information such as the location of the jar package file and the name of the main class for the application, in addition to any other parameters for the program. A properly configured browser passes JNLP files to a Java Runtime Environment (JRE) which in turn downloads the application onto the user's machine and starts executing it. The development of JNLP took place under the Java Community Process as JSR 56. It includes the original 1.0 release, the subsequent 1.5 maintenance release, and as of 2006 [update] , the pending 6.0 maintenance release.[ clarify ]
Important Web Start features include the ability to automatically download and install a JRE in the case where the user does not have Java installed, and for programmers to specify which JRE version a given program needs in order to execute. The user does not have to remain connected to the Internet to execute the downloaded programs, because they execute from a locally maintained cache. Updates of the software download from the Web and become available when the user has a connection to the Internet, thus easing the burden of deployment.
Any computer user can use JNLP simply by installing a JNLP client (most commonly Java Web Start). The installation can occur automatically such that the end-user sees the client launcher downloading and installing the Java application when first executed.
JNLP works in a similar fashion to how HTTP/HTML works for the web. For rendering an HTML webpage, after the user clicks on a weblink, the browser submits a URL to a webserver, which replies with an HTML file. The browser then requests the resources referred to by this file (images, css), and finally renders the page once it has received enough information. Page rendering usually starts before all resources have downloaded; some resources not critical to the layout of the page (such as images) can follow on afterwards.
JNLP mirrors this process; in the same way that a Web browser renders a webpage, a JNLP client "renders" a Java app. After the user clicks on a weblink, the browser submits a URL to a webserver, which replies with a JNLP file (instead of a HTML file) for the application. The JNLP client parses this file, requests the resources specified (jar files), waits for the retrieval of all required resources, and then launches the application. The JNLP file can list resources as "lazy", which informs the JNLP client that the application does not need those resources to start, but can retrieve them later on when/if the application requests them.
This section possibly contains original research .(September 2020) |
The example below gives a simple JNLP file to launch the applet, specifying code base, source, main class and window size. Such file contains all necessary references and is self-sufficient to launch the application. As no permissions are requested, the code will run in a sandbox. JNLP also states that this application can run offline (if already cached) and should be updated as a background process.
<?xml version="1.0" encoding="UTF-8"?><jnlpspec="1.0+"codebase="http://ultrastudio.org/upload"href=""><information><title>LaunchappletwithWebStart</title><vendor>FooBarInc.</vendor><offline-allowed/></information><resources><j2seversion="1.5+"href="http://java.sun.com/products/autodl/j2se"/><jarhref="Ray-2.3-4ca60e46-0956-3f22-983c-e3ed986dfd03.jar"main="true"/></resources><applet-descname="Ray diagram applet"main-class="raydiagramsapplet.Main"width="300"height="200"></applet-desc><updatecheck="background"/></jnlp>
To reduce the size of a Java Web Start application Sun Microsystems introduced a compression system called Pack200 in Java 1.5.0. It can compress a large jar file to one-ninth of its original size if it contains only Java classes. [7]
Java Web Start has supported Pack200 since it first appeared, but initially this feature required server-side cooperation and a certain amount of expertise to set up. When Sun introduced Java SE 6u10, Pack200 support became available without the need for special server support. Application designers can enable or disable this feature within JNLP files.
On slow connections Pack200 gives a performance boost in application startup time and download time.
By default, Java Web Start applications run "restricted", which means that they do not have access to some system resources such as local files. But publishers can remove these restrictions by signing their Web Start applications with the jarsigner
tool that comes with the JDK.
The open-source IcedTea project provides an alternative JNLP implementation in IcedTea-Web. As of version 1.7.2, it also works on newer versions without official JWS support. [8]
To run Java Web Start-based application after the release of Java 11, the company Karakun AG has released the open source tool OpenWebStart, based on IcedTea-Web. [9] The tool includes all the functionality of IcedTea-Web and adds extended features, such as native installers for Mac OS, Windows, and Linux. IcedTea-Web was created with support from RedHat and AdoptOpenJDK. [10]
Java applets are small applications written in the Java programming language, or another programming language that compiles to Java bytecode, and delivered to users in the form of Java bytecode.
Java is a high-level, class-based, object-oriented programming language that is designed to have as few implementation dependencies as possible. It is a general-purpose programming language intended to let programmers write once, run anywhere (WORA), meaning that compiled Java code can run on all platforms that support Java without the need to recompile. Java applications are typically compiled to bytecode that can run on any Java virtual machine (JVM) regardless of the underlying computer architecture. Although its syntax is similar to that of C and C++, the Java language has fewer low-level facilities than either of them. The Java runtime provides dynamic capabilities that are typically not available in traditional compiled languages.
A Java virtual machine (JVM) is a virtual machine that enables a computer to run Java programs as well as programs written in other languages that are also compiled to Java bytecode. The JVM is detailed by a specification that formally describes what is required in a JVM implementation. Having a specification ensures interoperability of Java programs across different implementations so that program authors using the Java Development Kit (JDK) need not worry about idiosyncrasies of the underlying hardware platform.
Java Platform, Standard Edition is a computing platform for development and deployment of portable code for desktop and server environments. Java SE was formerly known as Java 2 Platform, Standard Edition (J2SE).
A JAR file is a package file format typically used to aggregate many Java class files and associated metadata and resources into one file for distribution.
WebObjects is a discontinued Java web application server and a server-based web application framework originally developed by NeXT Software, Inc.
Apache Harmony is a retired open source, free Java implementation, developed by the Apache Software Foundation. It was announced in early May 2005 and on October 25, 2006, the board of directors voted to make Apache Harmony a top-level project. The Harmony project achieved 99% completeness for J2SE 5.0, and 97% for Java SE 6. The Android operating system has historically been a major user of Harmony, although since Android Nougat it increasingly relies on OpenJDK libraries.
The Java Media Framework (JMF) is a Java library that enables audio, video and other time-based media to be added to Java applications and applets. This optional package, which can capture, play, stream, and transcode multiple media formats, extends the Java Platform, Standard Edition and allows development of cross-platform multimedia applications.
Java is a set of computer software and specifications that provides a software platform for developing application software and deploying it in a cross-platform computing environment. Java is used in a wide variety of computing platforms from embedded devices and mobile phones to enterprise servers and supercomputers. Java applets, which are less common than standalone Java applications, were commonly run in secure, sandboxed environments to provide many features of native applications through being embedded in HTML pages.
Classpath is a parameter in the Java Virtual Machine or the Java compiler that specifies the location of user-defined classes and packages. The parameter may be set either on the command-line, or through an environment variable.
The Java language has undergone several changes since JDK 1.0 as well as numerous additions of classes and packages to the standard library. Since J2SE 1.4, the evolution of the Java language has been governed by the Java Community Process (JCP), which uses Java Specification Requests (JSRs) to propose and specify additions and changes to the Java platform. The language is specified by the Java Language Specification (JLS); changes to the JLS are managed under JSR 901. In September 2017, Mark Reinhold, chief Architect of the Java Platform, proposed to change the release train to "one feature release every six months" rather than the then-current two-year schedule. This proposal took effect for all following versions, and is still the current release schedule.
OpenJDK is a free and open-source implementation of the Java Platform, Standard Edition. It is the result of an effort Sun Microsystems began in 2006. The implementation is licensed under the GPL-2.0-only with a linking exception. Were it not for the GPL linking exception, components that linked to the Java Class Library would be subject to the terms of the GPL license. OpenJDK is the official reference implementation of Java SE since version 7.
Pack200, specified in JSR 200, deprecated in JEP 336 and removed in JEP 367, is a compacting archive format developed by Sun, capable of reducing JAR file sizes by up to a factor of 9, with a factor of 3 to 4 seen in practice. Pack200 is optimized for compressing JAR archive files, specifically the Java bytecode portion of the JAR files. Applications of this technology include faster Java application deployment over Java Web Start.
Oracle Secure Global Desktop (SGD) software provides secure access to both published applications and published desktops running on Microsoft Windows, Unix, mainframe and IBM i systems via a variety of clients ranging from fat PCs to thin clients such as Sun Rays.
Comparison of the Java and .NET platforms.
JavaFX is a software platform for creating and delivering desktop applications, as well as rich web applications that can run across a wide variety of devices. JavaFX has support for desktop computers and web browsers on Microsoft Windows, Linux, and macOS, as well as mobile devices running iOS and Android, through Gluon Mobile.
The Java Class Library (JCL) is a set of dynamically loadable libraries that Java Virtual Machine (JVM) languages can call at run time. Because the Java Platform is not dependent on a specific operating system, applications cannot rely on any of the platform-native libraries. Instead, the Java Platform provides a comprehensive set of standard class libraries, containing the functions common to modern operating systems.
IcedTea is a build and integration project for OpenJDK launched by Red Hat in June 2007. IcedTea also includes some addon libraries: IcedTea-Web is a free software implementation of Java Web Start and the Java web browser applet plugin. IcedTea-Sound is a collection of plugins for the Java sound subsystem, including the PulseAudio provider which used to be included with IcedTea. The Free Software Foundation recommends that all Java programmers use IcedTea as their development environment.
The Java Development Kit (JDK) is a distribution of Java technology by Oracle Corporation. It implements the Java Language Specification (JLS) and the Java Virtual Machine Specification (JVMS) and provides the Standard Edition (SE) of the Java Application Programming Interface (API). It is derivative of the community driven OpenJDK which Oracle stewards. It provides software for working with Java applications. Examples of included software are the Java virtual machine, a compiler, performance monitoring tools, a debugger, and other utilities that Oracle considers useful for Java programmers.
The Java Desktop Integration Components (JDIC) project provides components which give Java applications the same access to operating system services as native applications. For example, a Java application running on one user's desktop can open a web page using that user's default web browser, but the same Java application running on a different user's desktop would open the page in Opera . Initially the project supports features such as embedding the native HTML browser, programmatically opening the native mail client, using registered file-type viewers, and packaging JNLP applications as RPM, SVR4, and MSI installer packages. As a bonus, an SDK for developing platform-independent screensavers is included. Most of the features provided by JDIC were incorporated into the JDK starting with version 1.6. As a result, the development of the project has come to an end.
Oracle will not include Java Web Start in Java SE 11 (18.9 LTS) and later. Oracle will begin encouraging application developers and users to transition away from Java Web Start and encourage non-commercial consumers to remove any unused or non-supported Oracle JRE installations from their desktops.