Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.lang.java.programmer > #34653

Re: classpath issue

Path csiph.com!eternal-september.org!feeder.eternal-september.org!mx02.eternal-september.org!.POSTED!not-for-mail
From Martin Gregorie <martin@address-in-sig.invalid>
Newsgroups comp.lang.java.programmer
Subject Re: classpath issue
Date Wed, 15 Jun 2016 17:20:12 -0000 (UTC)
Organization A noiseless patient Spider
Lines 49
Message-ID <njs2oc$3rg$1@dont-email.me> (permalink)
References <1168fc92-420f-4125-8107-07098ab84ca7@googlegroups.com> <4742mbtfru95bsm21eur57jf0kt6gf8ls7@4ax.com> <b04c0b84-cd0a-41ea-990d-f985ba840b78@googlegroups.com>
Mime-Version 1.0
Content-Type text/plain; charset=UTF-8
Content-Transfer-Encoding 8bit
Injection-Date Wed, 15 Jun 2016 17:20:12 -0000 (UTC)
Injection-Info mx02.eternal-september.org; posting-host="e5160e2be48f1ea550cf61512446f525"; logging-data="3952"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX1/McZDrXIqregATTccLyFOY6ZwL4SIG1og="
User-Agent Pan/0.140 (Chocolate Salty Balls; GIT 3663720 git://git.gnome.org/pan2)
Cancel-Lock sha1:JiageuekJF9s/vw42bO/cppt8Jg=
Xref csiph.com comp.lang.java.programmer:34653

Show key headers only | View raw


On Wed, 15 Jun 2016 08:06:11 -0700, Eric Douglas wrote:

> 
> No I meant Public, the name of the folder under the folder the web
> service is pointing to, the same folder all the other jars are in which
> it does find as it does some processing before it gets this error.  The
> codebase= points to the local domain web server, setup on IIS.
> 
> You can see that class is in the jar.  This is a publicly available jar.
> http://mvnrepository.com/artifact/org.apache.httpcomponents/
httpclient/4.5.1
> 
> It's a Java Console error, not a JNLP dialog error.
> The message is:
> Exception in thread "AWT-EventQueue-2" java.lang.NoClassDefFoundError:
> org/apache/http/client/methods/HttpUriRequest
> 	at ... (my custom class from another jar in the same path)
> Caused by: java.lang.ClassNotFoundException:
> org.apache.http.client.methods.HttpUriRequest
> 	at java.net.URLClassLoader.findClass(Unknown Source)
> 	at com.sun.jnlp.JNLPClassLoader.findClass(Unknown Source) at
> 	java.lang.ClassLoader.loadClass(Unknown Source)
> 	at com.sun.jnlp.JNLPClassLoader.loadClass(Unknown Source) at
> 	java.lang.ClassLoader.loadClass(Unknown Source)
> 	... 25 more
> 
> All jars referenced by the JNLP are signed, by the same cert.
> 
> I can run this Java program from a command line using a -cp classpath
> referencing exactly the same list of jars in the JNLP resources section
> without error.

On the assumption that org.apache.http.client.methods.HttpUriRequest is 
not in the same jarfile as your class that calls it, check that:

- the jarfile that contains it will be loaded by your JNLP setup 
  if it isn't present on the target system.

- the jarfile that contains it is listed in your jarfile's manifest

- JNLP is configured to put the org.apache jarfile where the manifest 
  expects to find it - usually in the same directory as the calling
  jarfile or an 'includes' subdirectory.


-- 
martin@   | Martin Gregorie
gregorie. | Essex, UK
org       |

Back to comp.lang.java.programmer | Previous | Next — Previous in thread | Find similar | Unroll thread


Thread

classpath issue Eric Douglas <e.d.programmer@gmail.com> - 2016-06-14 13:29 -0700
  Re: classpath issue Lew <lewbloch@gmail.com> - 2016-06-14 13:35 -0700
    Re: classpath issue Eric Douglas <e.d.programmer@gmail.com> - 2016-06-14 13:51 -0700
      Re: classpath issue Lew <lewbloch@gmail.com> - 2016-06-15 12:25 -0700
  Re: classpath issue Arne Vajhøj <arne@vajhoej.dk> - 2016-06-14 18:53 -0400
  Re: classpath issue Andreas Leitgeb <avl@logic.at> - 2016-06-14 23:21 +0000
  Re: classpath issue Stanimir Stamenkov <s7an10@netscape.net> - 2016-06-15 02:26 +0300
  Re: classpath issue Roedy Green <inquiry@mindprod.com> - 2016-06-15 01:30 -0700
    Re: classpath issue Eric Douglas <e.d.programmer@gmail.com> - 2016-06-15 08:06 -0700
      Re: classpath issue Martin Gregorie <martin@address-in-sig.invalid> - 2016-06-15 17:20 +0000

csiph-web