jeudi 29 juin 2017

Deploying JAR application with JNLP when JAR contains dependencies(Jars)

I have an in house Java application that we need to distribute through a web page. So I compressed the app in a .jar file and included all the dependencies (like miglayout15-swing.jar). I have about 15 dependencies.

Now I'm wondering if this is the right approach. Cause when I create my JNLP file and include the resources, it seems to be looking for the jar files outside my main jar file and not inside.

Should the right approach be to put the dependencies in a /lib folder next to where my main app jar is locates? And the users would be downloading my main jar and all the dependencies separately ? Here's my JNLP

    <resources>
    <java version="1.6+"/>
    <jar href="../jsps/Applet/ACFUtility.jar" main="true" />
    <jar href="org.eclipse.ui.workbench_3.105.1.v20130821-1411.jar"/>
    <jar href="swingx-1.6.1.jar"/>
    <jar href="org.eclipse.ui.forms_3.6.1.v20130822-1117.jar"/>
    <jar href="org.eclipse.text_3.5.300.v20130515-1451.jar"/>
    <jar href="org.eclipse.swt.win32.win32.x86_3.102.1.v20130827-2048.jar"/>
    <jar href="org.eclipse.osgi_3.9.1.v20130814-1242.jar"/>
    <jar href="org.eclipse.jface_3.9.1.v20130725-1141.jar"/>
    <jar href="org.eclipse.jface.text_3.8.101.v20130802-1147.jar"/>
    <jar href="org.eclipse.equinox.registry_3.5.301.v20130717-1549.jar"/>
    <jar href="org.eclipse.equinox.common_3.6.200.v20130402-1505.jar"/>
    <jar href="org.eclipse.core.runtime_3.9.0.v20130326-1255.jar"/>
    <jar href="org.eclipse.core.commands_3.6.100.v20130515-1857.jar"/>
    <jar href="forms-1.3.0.jar"/>
    <jar href="miglayout15-swing.jar"/>
    <jar href="com.ibm.icu_50.1.1.v201304230130.jar"/>

</resources>

App Jar Content




Aucun commentaire:

Enregistrer un commentaire