Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

JNLP should use a specific Java version but error results

I'm facing a problem here. I want to use a special version to run our java webstart application but just for one jnlp. ("It was tested, ... blabla we can't use a new version... blabla" by random windbag)

So I tried to configure our JNLP like this:

<resources>
    <j2se version="1.6.0_29" href="http://java.oracle.com/products/autodl/j2se"/>
    ...
</resources>

When I start this jnlp now I get following Error even if the right Java is installed:

Error: The application has requested a version of the JRE (version 1.6.0_29) that currently is not locally installed. Java Web Start is unable to automatically download and install the requested version. This JRE must be installed manually.

Update

In the JNLP File Syntax it's allowed to use a specific Java version like 1.6.0_29. I even tried it with 1.6.0_29-b11 - still the same error.

Exact product versions (implementation versions) may also be specified. by including the href attribute. For example, 1.3.1_07, 1.4.2, or 1.5.0-beta2 by Sun Microsystems, Inc. For example,

<j2se version="1.4.2" href="http://java.sun.com/products/autodl/j2se"/>

or

<j2se version="1.4.2_04" href="http://java.sun.com/products/autodl/j2se"/>

Edit

The given answer is not helping and not the right answer.

like image 634
alexvetter Avatar asked Apr 16 '12 13:04

alexvetter


People also ask

How do I set Java to default to JNLP?

Select the 'Default apps' category, then select the 'Choose default apps by file type' link. 4. Scroll down to the '. jnlp' file type and select 'Java Web Start Launcher' as the default app.

How do I open a JNLP file in Java 17?

Right-click a JNLP file and click “Open With.” Select the “Java Web Start Launcher” application in the list or click “Browse,” browse to the “C:\Program Files (x86)\Java\jre[version]\bin” folder on your computer and double-click the “Javaws.exe” program file.

Is JNLP deprecated?

Java Applet and WebStart functionality, including the Applet API, The Java plug-in, the Java Applet Viewer, JNLP and Java Web Start including the javaws tool are all deprecated in JDK 9 and will be removed in a future release.

What can I use instead of Java Web Start?

Setlog just released its first open-source project. It is a combined installer, updater and launcher named trivrost, which, among other things, can act a Java Web Start alternative.


3 Answers

This is quite common. Make sure that each client machine has enabled 1.6.0_29 for JNLP/Webstart.

Installing 1.6.0_29 is not necessarily enough to tell webstart that it's available. See this post for more information

Webstart settings

like image 186
Sergei Vasalin Avatar answered Sep 27 '22 23:09

Sergei Vasalin


I had installed Java 1.6.0_21 and it was enabled at the Java Control Panel. However I got the same error message that it's stated in the question: "The application has requested a version of the JRE (version 1.6.0_29) that currently is not locally installed"

I got this message even if I tried with different lines in the JNLP, such as:

<j2se version="1.6.0_29"/>

or

<j2se version="1.6.0_29-b06"/>

I solved this by editing the JNLP file with the following line:

<j2se version="1.6"/>

So the documentation line "Exact product versions (implementation versions) may also be specified" seems to be false.

like image 37
Alzhaid Avatar answered Sep 27 '22 23:09

Alzhaid


Do you use :

jnlp spec="1.0+"

If so you should try with :

jnlp spec="6.0+"

I found this link, maybe there is something wrong in the configuration of your browser/JRE, or are you under a proxy?

like image 30
alain.janinm Avatar answered Sep 27 '22 23:09

alain.janinm