Skip to Main Content

New to Java

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

Having trouble getting external HttpClient JAR to work with Eclipse

843785Dec 18 2008 — edited Dec 26 2008
Hi all,

I'm trying to include an external HttpClient JAR in a project I'm working on in Eclipse. I've already added it as an external JAR via Project > Properties > Java Build Path > Libraries and referenced it with import statements. However, it does not appear to work and I'm getting the following warnings:
Classpath entry C:/xampp/tomcat/webapps/commons-codec-1.3.jar will not be exported or published. Runtime ClassNotFoundExceptions may result.
Classpath entry C:/xampp/tomcat/webapps/commons-logging-1.1.1.jar will not be exported or published. Runtime ClassNotFoundExceptions may result.
Classpath entry C:/xampp/tomcat/webapps/httpclient/commons-httpclient-3.1.jar will not be exported or published. Runtime ClassNotFoundExceptions may result.
Classpath entry C:/xampp/tomcat/webapps/junit-dep-4.5.jar will not be exported or published. Runtime ClassNotFoundExceptions may result.
I also receive the following HTTP Status 500 exception report:
java.lang.NoClassDefFoundError: org/apache/commons/httpclient/HttpClient
	com.xxx.sdk.webservices.Directory.doGet(Directory.java:20)
	javax.servlet.http.HttpServlet.service(HttpServlet.java:690)
	javax.servlet.http.HttpServlet.service(HttpServlet.java:803)
Line 20 is the following:
HttpClient client = new HttpClient();
My environment is XAMPP on Windows XP Pro SP3, so Apache + Tomcat. Am I doing something incorrectly? Any help would really be appreciated.

Thanks,
- Matt

Edited by: Mateo1041 on Dec 18, 2008 12:48 PM
Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Jan 23 2009
Added on Dec 18 2008
5 comments
481 views