Jnlp problem java1.6
843802Feb 22 2008 — edited Nov 3 2008Hi all,
We are using jnlp to launch our application in the client side. Since we are using websphere as our server we need to IBM Jre in the client side also. So there is some thing called application client in websphere. This will install IBM Jre in the client side using Java web start. Using three jnlp files we are doing this. Application is working fine in jre 1.4 and 1.5 in the client side. But with 1.6 (tried with update 2 and 4) it is failing to install IBM Jre and getting exception in the client side.
I am placing the exception and jnlp files we are using launch.jsp is the main file. We are getting two exceptions. After pressing ok with the first it is poping up with the second exception.
Thanks,
Bhaskar.
Error1:
-----------
java.lang.Exception: cache failed forhttp://kida82.ims.att.com:2383/base/Runtime/jnlp.jsp
at com.sun.javaws.Launcher.updateFinalLaunchDesc(Unknown Source)
at com.sun.javaws.Launcher.prepareToLaunch(Unknown Source)
at com.sun.javaws.Launcher.launch(Unknown Source)
at com.sun.javaws.Main.launchApp(Unknown Source)
at com.sun.javaws.Main.continueInSecureThread(Unknown Source)
at com.sun.javaws.Main$1.run(Unknown Source)
at java.lang.Thread.run(Unknown Source)
Error2:
----------
JNLPException[category: Launch File Error : Exception: null : LaunchDesc:
<jnlp spec="1.0+" codebase="http://kida82.ims.att.com:2383/base/Runtime/" href="http://kida82.ims.att.com:2383/base/Runtime/jnlp.jsp">
<information>
<title>WebSphere Client 6.0 Runtime JRE</title>
<vendor>IBM</vendor>
<homepage href="null"/>
<description>WebSphere Client 6.0 Runtime JRE</description>
<description kind="short">WebSphere Client 6.0 Runtime JRE</description>
<description kind="tooltip">WebSphere Client 6.0 Runtime JRE</description>
<icon href="http://kida82.ims.att.com:2383/base/Runtime/icon.gif" kind="default"/>
<offline-allowed/>
</information>
<security>
<all-permissions/>
</security>
<update check="timeout" policy="always"/>
<resources>
<java version="1.4+"/>
<jar href="http://kida82.ims.att.com:2383/base/Runtime/WebSphereClientRuntimeInstaller.jar" download="eager" main="true"/>
<property name="com.ibm.websphere.client.jre.version" value="WASclient6.0"/>
<jar href="http://kida82.ims.att.com:2383/base/Runtime/windows/WASClient6.0_windows.jar" download="eager" main="false"/>
<property name="com.ibm.websphere.client.jre.launch.java" value="java\jre\bin\javaw.exe -Dcom.ibm.CORBA.FragmentSize=0 -Dcom.ibm.CORBA.Debug=true -Dcom.ibm.CORBA.CommTrace=true -Dcom.ibm.CORBA.Debug.Output=c:\client_trace.log"/>
</resources>
<installer-desc main-class="com.ibm.websphere.client.installer.ClientRuntimeInstaller"/>
</jnlp> ]
at com.sun.javaws.Launcher.executeInstallers(Unknown Source)
at com.sun.javaws.Launcher.prepareLaunchFile(Unknown Source)
at com.sun.javaws.Launcher.prepareToLaunch(Unknown Source)
at com.sun.javaws.Launcher.launch(Unknown Source)
at com.sun.javaws.Main.launchApp(Unknown Source)
at com.sun.javaws.Main.continueInSecureThread(Unknown Source)
at com.sun.javaws.Main$1.run(Unknown Source)
at java.lang.Thread.run(Unknown Source)
luanch.jsp(Main file)
-----------------------------
<!--
"This sample program is provided AS IS and may be used, executed, copied and modified without royalty payment by customer (a) for its own instruction and study, (b) in order to develop applications designed to run with an IBM WebSphere product, either for customer's own internal use or for redistribution by customer, as part of such an application, in customer's own products."
Product 5630-A36, (C) COPYRIGHT International Business Machines Corp., 2004
All Rights Reserved * Licensed Materials - Property of IBM
-->
<%--
This is a generic jnlp for a client app. It will specify the WAS JRE
as a dependency as well as the client launcher
--%>
<%! private final String description="ERP Application";
private final String earName="J2eeJWS.ear";
%>
<% // locally declared variables
String urlSt = request.getRequestURL().toString();
System.out.println("urlSt :"+urlSt);
String jnlpCodeBase=urlSt.substring(0,urlSt.lastIndexOf('/'));
String argument=jnlpCodeBase.substring(0,jnlpCodeBase.lastIndexOf('/'));
System.out.println("argument ::"+argument);
String jnlpRefURL=urlSt.substring(urlSt.lastIndexOf('/')+1,urlSt.length());
%>
<% // to set the Last_Modified header so that the JNLP client will know whether to download
// the JNLP file again and update the cached copy.
String jspPath = application.getRealPath(request.getServletPath());
System.out.println("jspPath : "+jspPath);
java.io.File jspFile = new java.io.File(jspPath);
long lastModified = jspFile.lastModified();
%>
<%--
Need to set a JNLP mime type - if WebStart is installed on the client,
this header will induce the browser to drive the WebStart Client
--%><%
response.setContentType("application/x-java-jnlp-file");
response.setHeader("Cache-Control", null);
response.setHeader("Set-Cookie", null);
response.setHeader("Vary", null);
response.setDateHeader("Last-Modified", lastModified);
System.out.println("jnlpCodeBase : "+jnlpCodeBase+" jnlpRefURL : "+jnlpRefURL);
%>
<?xml version="1.0" encoding="utf-8"?>
<jnlp spec="1.0+" codebase="<%=jnlpCodeBase%>"
href="<%=jnlpRefURL%>">
<information>
<title><%=description %></title>
<vendor>AT and T</vendor>
<description><%=description %></description>
<description kind="short"><%=description %></description>
<description kind="tooltip"><%=description %></description>
<offline-allowed/>
</information>
<security>
<all-permissions/>
</security>
<resources>
<j2se version="WASclient6.0" href="/base/Runtime/RTjnlp.jsp"/>
<jar href="WebSphereClientLauncher.jar" main="true"/>
<extension name="WAS Thin EJB Client Library"
href="/base/Runtime/WebSphereJars/WSjnlp.jsp"/>
<jar href="CCCommon.jar" />
<jar href="perltools.jar" />
<jar href="gjt1_1.jar" />
<jar href="QueryControllerClient.jar" />
<jar href="SECServerclient.jar" />
<jar href="ICSSessionClient.jar"/>
<jar href="poi.jar"/>
<jar href="jh.jar"/>
<property name="com.ibm.websphere.client.launcher.main"
value="com.att.suite.client.SuiteAppManager"/>
<property name="java.naming.factory.initial"
value="com.ibm.websphere.naming.WsnInitialContextFactory" />
<property name="java.naming.provider.url"
value="corbaloc:iiop:aipa204.ims.att.com:2809"/>
</resources>
<application-desc>
<argument><%=argument%></argument>
</application-desc>
</jnlp>
RTjnlp.jsp
---------------
<!--
"This sample program is provided AS IS and may be used, executed, copied and modified without royalty payment by customer (a) for its own instruction and study, (b) in order to develop applications designed to run with an IBM WebSphere product, either for customer's own internal use or for redistribution by customer, as part of such an application, in customer's own products."
Product 5630-A36, (C) COPYRIGHT International Business Machines Corp., 2004
All Rights Reserved * Licensed Materials - Property of IBM
-->
<%--
This is an Installer JNLP
It will download two .jars:
WebSphereClientRuntimeInstaller.jar - includes the installer utility
WASClient6.0_<platform>.jar - the client runtime JRE image
The installer will unzip the client runtime jar on the client machine, and register
it with Java Web Start
--%>
<%! private final String description="WebSphere Client 6.0 Runtime JRE";
// The version here is (WAS based) JRE version
private final String JREversion="WASclient6.0";
%>
<% // to set the Last_Modified header so that the JNLP client will know whether to download
// the JNLP file again and update the cached copy.
String jspPath = application.getRealPath(request.getServletPath());
java.io.File jspFile = new java.io.File(jspPath);
long lastModified = jspFile.lastModified();
%><%
// locally declared variables
String url=request.getRequestURL().toString();
String jnlpCodeBase=url.substring(0,url.lastIndexOf('/'));
String jnlpRefURL=url.substring(url.lastIndexOf('/')+1,url.length());
// Need to set a JNLP mime type - if WebStart is installed on the client,
// this header will induce the browser to drive the WebStart Client
response.setContentType("application/x-java-jnlp-file");
response.setHeader("Cache-Control", null);
response.setHeader("Set-Cookie", null);
response.setHeader("Vary", null);
response.setDateHeader("Last-Modified", lastModified);
// An installer must reply with the version number for a given install
if (response.containsHeader("x-java-jnlp-version-id"))
response.setHeader("x-java-jnlp-version-id", JREversion);
else
response.addHeader("x-java-jnlp-version-id", JREversion);
%>
<?xml version="1.0" encoding="utf-8"?>
<jnlp
spec="1.0+"
codebase="<%=jnlpCodeBase%>"
href="<%=jnlpRefURL%>">
<information>
<title><%=description%></title>
<vendor>IBM</vendor>
<icon href="icon.gif"/>
<description><%=description %></description>
<description kind="short"><%=description %></description>
<description kind="tooltip"><%=description %></description>
<offline-allowed/>
</information>
<security>
<all-permissions/>
</security>
<resources>
<j2se version="1.4+"/>
<jar href="WebSphereClientRuntimeInstaller.jar" main="true"/>
<%-- JRE version registration with WebStart --%>
<property name="com.ibm.websphere.client.jre.version" value="<%=JREversion%>"/>
</resources>
<resources os="Windows">
<jar href="windows/WASClient6.0_windows.jar"/>
<%-- relative path of the jre executable --%>
<property name="com.ibm.websphere.client.jre.launch.java" value="java\jre\bin\javaw.exe"/>
</resources>
<resources os="Linux">
<jar href="linux/WASClient6.0_linux.jar"/>
<property name="com.ibm.websphere.client.jre.launch.java" value="java/jre/bin/java"/>
</resources>
<resources os="AIX">
<jar href="aix/WASClient6.0_AIX.jar"/>
<property name="com.ibm.websphere.client.jre.launch.java" value="java/jre/bin/java"/>
</resources>
<resources os="SunOS">
<jar href="sun/WASClient6.0_SUN.jar"/>
<property name="com.ibm.websphere.client.jre.launch.java" value="java/jre/bin/java"/>
</resources>
<resources os="HP-UX">
<jar href="hp-ux/WASClient6.0_HP-UX.jar"/>
<property name="com.ibm.websphere.client.jre.launch.java" value="java/jre/bin/java"/>
</resources>
<installer-desc main-class="com.ibm.websphere.client.installer.ClientRuntimeInstaller"/>
</jnlp>
WSjnlp.jsp
---------------
<!--
"This sample program is provided AS IS and may be used, executed, copied and modified without royalty payment by customer (a) for its own instruction and study, (b) in order to develop applications designed to run with an IBM WebSphere product, either for customer's own internal use or for redistribution by customer, as part of such an application, in customer's own products."
Product 5630-A36, (C) COPYRIGHT International Business Machines Corp., 2004
All Rights Reserved * Licensed Materials - Property of IBM
-->
<%! private final String description="WebSphere Jars";
%>
<% // locally declared variables
String urlSt = request.getRequestURL().toString();
String jnlpCodeBase=urlSt.substring(0,urlSt.lastIndexOf('/'));
String jnlpRefURL=urlSt.substring(urlSt.lastIndexOf('/')+1,urlSt.length());
%>
<% // to set the Last_Modified header so that the JNLP client will know whether to download
// the JNLP file again and update the cached copy.
String jspPath = application.getRealPath(request.getServletPath());
java.io.File jspFile = new java.io.File(jspPath);
long lastModified = jspFile.lastModified();
%>
<%--
Need to set a JNLP mime type - if WebStart is installed on the client,
this header will induce the browser to drive the WebStart Client
--%><%
response.setContentType("application/x-java-jnlp-file");
response.setHeader("Cache-Control", null);
response.setHeader("Set-Cookie", null);
response.setHeader("Vary", null);
response.setDateHeader("Last-Modified", lastModified);
%>
<?xml version="1.0" encoding="utf-8"?>
<jnlp
spec="1.0+"
codebase="<%=jnlpCodeBase%>"
href="<%=jnlpRefURL%>">
<information>
<title><%=description %></title>
<vendor>IBM</vendor>
<description><%=description %></description>
<description kind="short"><%=description %></description>
<description kind="tooltip"><%=description %></description>
<offline-allowed/>
</information>
<security>
<all-permissions/>
</security>
<resources>
<jar href="activation-impl.jar"/>
<jar href="activity.jar"/>
<jar href="activityImpl.jar"/>
<jar href="activitySession.jar"/>
<jar href="activitySessionPrivate.jar"/>
<jar href="acwa.jar"/>
<jar href="admin.jar"/>
<jar href="appprofile-impl.jar"/>
<jar href="appprofile.jar"/>
<jar href="b2bjaxp.jar"/>
<jar href="b2bxml.jar"/>
<jar href="b2bxmlSamples.jar"/>
<jar href="bootstrap.jar"/>
<jar href="channel.http.jar"/>
<jar href="channel.httptunnel.jar"/>
<jar href="channel.mqfap.jar"/>
<jar href="channel.jfap.jar"/>
<jar href="channel.ssl.jar"/>
<jar href="channel.tcp.jar"/>
<jar href="channelfw.jar"/>
<jar href="classloader.jar"/>
<jar href="client.jar"/>
<jar href="cluster.jar"/>
<jar href="clusteradapter.jar"/>
<jar href="clusterprop.jar"/>
<jar href="clusterrouter.jar"/>
<jar href="clustertopo.jar"/>
<jar href="commons-discovery.jar"/>
<jar href="commons-logging-api.jar"/>
<jar href="db2Interfaces.jar"/>
<jar href="deployutils.jar"/>
<jar href="distexcep.jar"/>
<jar href="dwlmclient.jar"/>
<jar href="ecutils.jar"/>
<jar href="ejbportable.jar"/>
<jar href="emf.jar"/>
<jar href="ffdc.jar"/>
<jar href="handlerfw.jar"/>
<jar href="handlerfwimpl.jar"/>
<jar href="handlerfwservice.jar"/>
<jar href="i18nctx.jar"/>
<jar href="idl.jar"/>
<jar href="ivjejb35.jar"/>
<jar href="iwsorb.jar"/>
<jar href="j2cClient.jar"/>
<jar href="j2ee.jar"/>
<jar href="jaxruddi.jar"/>
<jar href="jdom.jar"/>
<jar href="lmproxy.jar"/>
<jar href="logutil.jar"/>
<jar href="ltext.jar"/>
<jar href="mail-impl.jar"/>
<jar href="management.jar"/>
<jar href="marshall.jar"/>
<jar href="messagingClient.jar"/>
<jar href="naming.jar"/>
<jar href="namingclient.jar"/>
<jar href="nls.jar"/>
<jar href="objectpool.jar"/>
<jar href="objectpoolimpl.jar"/>
<jar href="physicalrep.jar"/>
<jar href="pmi.jar"/>
<jar href="pmiclient.jar"/>
<jar href="pmirm-sib.jar"/>
<jar href="processintf.jar"/>
<jar href="processmgmt.jar"/>
<jar href="qryclient.jar"/>
<jar href="ras.jar"/>
<jar href="rsadapterClient.jar"/>
<jar href="runtime.jar"/>
<jar href="runtimefw.jar"/>
<jar href="runtimeimpl.jar"/>
<jar href="sas.jar"/>
<jar href="scheduler-client.jar"/>
<jar href="scheduler-clientImpl.jar"/>
<jar href="sdrt.jar"/>
<jar href="sib.common.jar"/>
<jar href="soap-sec.jar"/>
<jar href="soap.jar"/>
<jar href="tmx4jc.jar"/>
<jar href="tmx4jt.jar"/>
<jar href="txClient.jar"/>
<jar href="txClientPrivate.jar"/>
<jar href="txMsgs.jar"/>
<jar href="uddi4jv2.jar"/>
<jar href="uddiv3client.jar"/>
<jar href="urlprotocols.jar"/>
<jar href="utils.jar"/>
<jar href="vaprt.jar"/>
<jar href="was-wssecurity.jar"/>
<jar href="wasjmx.jar"/>
<jar href="wasproduct.jar"/>
<jar href="wasupgrade.jar"/>
<jar href="wccm_base.jar"/>
<jar href="wccm_services_pme.jar"/>
<jar href="webservices-security.jar"/>
<jar href="webservices.jar"/>
<jar href="wjmxapp.jar"/>
<jar href="wlm.jar"/>
<jar href="wlmclient.jar"/>
<jar href="workspace.jar"/>
<jar href="ws-commons-logging.jar"/>
<jar href="wsatlib.jar"/>
<jar href="wsbytebufferservice.jar"/>
<jar href="wsdeployenv.jar"/>
<jar href="wsdl4j.jar"/>
<jar href="wsexception.jar"/>
<jar href="wsif-j2c.jar"/>
<jar href="wsif.jar"/>
<jar href="wssec.jar"/>
<jar href="xmlsecurity.jar"/>
</resources>
<component-desc/>
</jnlp>