Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Newcomers » Newcomers » Classpath dependancy validator warning(Classpath dependancy validator message & other warnings)
Classpath dependancy validator warning [message #538095] Fri, 04 June 2010 22:26 Go to next message
Phil Freihofner is currently offline Phil FreihofnerFriend
Messages: 47
Registered: May 2010
Member
I am curious what, if anything, to do with the following warning (from the "Markers" tab):

Classpath entry org.eclipse.datatools.connectivity.jdt.DRIVERLIBRARY/Postgre SQL JDBC Driver will not be exported or published. Runtime ClassNotFoundExceptions may result.

Indeed, in the project in question, I get a ClassNotFound exception. Where can I learn about this? I don't see anything in the Connectivity properties that says anything about exporting or not.

In scrutinizing the various warning messages, I also have a warning during the startup of the Apache server:

INFO: The APR based Apache Tomcat Native library which allows optimal performance in production environments was not found on the java.library.path: [long path list here]

And:

WARNING: [SetPropertiesRule]{Server/Service/Engine/Host/Context} Setting property 'source' to 'org.eclipse.jst.jee.server:Nearby' did not find a matching property.

What is the significance of these?

In part, this is a continuation of exploring a question I have in earlier. Hopefully the different emphasis of the question will prevent this from being perceived as a double post, and I promise to follow up in each context as appropriate.

Thanks!
Re: Classpath dependancy validator warning [message #538106 is a reply to message #538095] Sat, 05 June 2010 04:13 Go to previous messageGo to next message
Russell Bateman is currently offline Russell BatemanFriend
Messages: 3798
Registered: July 2009
Location: Provo, Utah, USA
Senior Member

On 6/4/2010 4:26 PM, Phil Freihofner wrote:
> I am curious what, if anything, to do with the following warning (from
> the "Markers" tab):
>
> Classpath entry
> org.eclipse.datatools.connectivity.jdt.DRIVERLIBRARY/Postgre SQL JDBC
> Driver will not be exported or published. Runtime
> ClassNotFoundExceptions may result.
>
> Indeed, in the project in question, I get a ClassNotFound exception.
> Where can I learn about this? I don't see anything in the Connectivity
> properties that says anything about exporting or not.
>
> In scrutinizing the various warning messages, I also have a warning
> during the startup of the Apache server:
> INFO: The APR based Apache Tomcat Native library which allows optimal
> performance in production environments was not found on the
> java.library.path: [long path list here]
>
> And:
>
> WARNING: [SetPropertiesRule]{Server/Service/Engine/Host/Context} Setting
> property 'source' to 'org.eclipse.jst.jee.server:Nearby' did not find a
> matching property.
>
> What is the significance of these?
>
> In part, this is a continuation of exploring a question I have in
> earlier. Hopefully the different emphasis of the question will prevent
> this from being perceived as a double post, and I promise to follow up
> in each context as appropriate.
>
> Thanks!



I believe what you're seeing is this.

In Java Build Path -> Libraries you have libraries, other than the JRE
System Library, that contribute to your project. If you plan on
deploying the application to a container like Tomcat, you need to decide
whether and which of the libraries to copy to the WAR for that purpose.
This is done by selecting them in Properties -> Java EE Module
Dependencies. Once you do this, I think your warnings will disappear.

Your container may already offer some of the libraries you otherwise
must add to your project. So, you might decline to fix this. However, if
you can't run when you deploy, then this is an indication that you
should include the JARs containing the missing symbols.

Hope this is a) accurate and b) that it helps.

Russ Bateman
Re: Classpath dependancy validator warning [message #538112 is a reply to message #538106] Sat, 05 June 2010 06:20 Go to previous messageGo to next message
Phil Freihofner is currently offline Phil FreihofnerFriend
Messages: 47
Registered: May 2010
Member
Thank you so much!

I was a bit thrown by the use of the term WAR, as the project was not built from a WAR, and I don't understand where this is located. But I was able to find a reference to the PostgreSQL Driver in "Properties -> Java EE Module
Dependencies" as you described, and it was unchecked.

Upon checking it, the Marker warning disappeared, and the program did find and connect to the database when I ran it.

This has been one of the hardest things I have ever tried to figure out, and I am very, very grateful to you for taking the time to answer my question.
Re: Classpath dependancy validator warning [message #538137 is a reply to message #538112] Sat, 05 June 2010 15:10 Go to previous messageGo to next message
Russell Bateman is currently offline Russell BatemanFriend
Messages: 3798
Registered: July 2009
Location: Provo, Utah, USA
Senior Member

On 6/5/2010 12:20 AM, Phil Freihofner wrote:
> Thank you so much!
>
> I was a bit thrown by the use of the term WAR, as the project was not
> built from a WAR, and I don't understand where this is located. But I
> was able to find a reference to the PostgreSQL Driver in "Properties ->
> Java EE Module Dependencies" as you described, and it was unchecked.
> Upon checking it, the Marker warning disappeared, and the program did
> find and connect to the database when I ran it.
>
> This has been one of the hardest things I have ever tried to figure out,
> and I am very, very grateful to you for taking the time to answer my
> question.

You're certainly welcome Phil. Check out
http://www.javahotchocolate.com/ for stuff like this.

I write to prove to myself that I grok. And why not drop bread crumbs
for the next Hansel and Gretl that come along?

Russ
Re: Classpath dependancy validator warning [message #634491 is a reply to message #538137] Thu, 21 October 2010 23:27 Go to previous messageGo to next message
Phil Freihofner is currently offline Phil FreihofnerFriend
Messages: 47
Registered: May 2010
Member
Hi - I am now using a different setup and am getting this same error. Unfortunatly, the solution does not seem to be possible in this new context.

Error warning:
Classpath Dependency Validator Message
Classpath entry org.eclipse.datatools.connectivity.jdt.DRIVERLIBRARY/MySQL JDBC Driver will not be exported or published. Runtime ClassNotFoundExceptions may result.

I am now using:
Eclipse Java EE IDE for Web Developers.
Version: Helios Release
Build id: 20100617-1415

I am using Tomcat 7.0.2.

The JDBC driver was added to the Build Path via AddLibrary>Connectivity Driver Definition. The same method of adding this driver code works for a different project that does NOT use Apache.

Previously, I was able to select the project's "Properties>Java EE Module Dependencies". With this new version of Eclipse, the "Java EE Module Dependencies" does not exist, and I am having trouble trying to determine what the equivalent might be.

Many thanks!

Phil Freihofner
Re: Classpath dependancy validator warning [message #634493 is a reply to message #634491] Thu, 21 October 2010 23:43 Go to previous messageGo to next message
Russell Bateman is currently offline Russell BatemanFriend
Messages: 3798
Registered: July 2009
Location: Provo, Utah, USA
Senior Member

On 2010.10.21 17:27, Phil Freihofner wrote:
> Hi - I am now using a different setup and am getting this same error.
> Unfortunatly, the solution does not seem to be possible in this new
> context.
>
> Error warning:
> Classpath Dependency Validator Message
> Classpath entry
> org.eclipse.datatools.connectivity.jdt.DRIVERLIBRARY/MySQL JDBC Driver
> will not be exported or published. Runtime ClassNotFoundExceptions may
> result.
>
> I am now using:
> Eclipse Java EE IDE for Web Developers.
> Version: Helios Release
> Build id: 20100617-1415
>
> I am using Tomcat 7.0.2.
>
> The JDBC driver was added to the Build Path via AddLibrary>Connectivity
> Driver Definition. The same method of adding this driver code works for
> a different project that does NOT use Apache.
>
> Previously, I was able to select the project's "Properties>Java EE
> Module Dependencies". With this new version of Eclipse, the "Java EE
> Module Dependencies" does not exist, and I am having trouble trying to
> determine what the equivalent might be.
>
> Many thanks!
>
> Phil Freihofner

You must ask this in the eclipse webtools forum if you want an answer.

This is exactly why I don't use Helios for web-application development.
I think they broke this aspect of WTP for Helios and only the super
gurus are able to work around it or explain how it's done instead of
using the old Java EE Module Dependencies configuration. I still don't
get how to do it, but Galileo works perfectly, so I haven't stressed
over it. For WTP stuff (and Android for now), I just stay with Galileo.
Otherwise, Helios works well.
Re: Classpath dependancy validator warning [message #634504 is a reply to message #634493] Fri, 22 October 2010 01:34 Go to previous messageGo to next message
Phil Freihofner is currently offline Phil FreihofnerFriend
Messages: 47
Registered: May 2010
Member
Hi -

Thanks Russell! I found a solution to the problem in this message: #550535, on the WebTools forum as you suggested.

Galileo's "Properties->EE Dependencies" has been replaced by Helios' "Properties->Deployment Assembly". On that form I did the following:

Add->Classpath Container->Connectivity Driver Definition, and selected my JDBC driver.

After doing this, the Web Application's JSP allowed me to connect to the database and gave me the results of a simple query.

For some reason, though, the Classpath Dependency Validator Warning is persisting. I've left a thread open on WebTools to see if anyone knows what to do about that, though it is of lesser concern than just getting the db connection to work.

Now, onto the next steps: (1) working at home outside of Eclipse (via WAR dropped in Tomcats "webfiles" dir), (2) on the remote site using the remote Tomcat and remote MySQL db.
Re: Classpath dependancy validator warning [message #870859 is a reply to message #634504] Thu, 10 May 2012 03:08 Go to previous messageGo to next message
Eclipse UserFriend
I've been searching for a solution to this "warning" for a while now and thanks to this thread, I got the answer! Thanks and can you believe that I'm using RAD 8 with all the latest fixes and it still has the problem that Phil points out...that the warning and error doesn't go away but when I deploy it, it works fine!

Thanks to Phil for mentioning that. Otherwise, I'd be banging my head for nothing.

Re: Classpath dependancy validator warning [message #1651556 is a reply to message #634491] Thu, 05 March 2015 11:19 Go to previous messageGo to next message
Dhaval Simaria is currently offline Dhaval SimariaFriend
Messages: 1
Registered: March 2015
Junior Member
I am not getting classpath Container when I click on Add in Web Deployment Assembly.
This are the things that I do get;
Add->Archive via Path Variable
Archives from File System
Archives from Workspace
Folder
Java Build Path Entries
Project
I am trying to run my jsp-servlet to register a user and make an entry in mySQL database.
Will be grateful for any kind help.
Re: Classpath dependancy validator warning [message #1725219 is a reply to message #1651556] Tue, 01 March 2016 20:24 Go to previous messageGo to next message
Nekha Sara is currently offline Nekha SaraFriend
Messages: 1
Registered: March 2016
Junior Member
were you able to figure it out? I too have the same options when selected the Add option under Properties -> Deployment Assembly
Re: Classpath dependancy validator warning [message #1725230 is a reply to message #1725219] Tue, 01 March 2016 21:42 Go to previous messageGo to next message
Phil Freihofner is currently offline Phil FreihofnerFriend
Messages: 47
Registered: May 2010
Member
Quote:
were you able to figure it out? I too have the same options when selected the Add option under Properties -> Deployment Assembly

I'm sorry but I haven't touched this issue in years, and don't know the answer to your question.
Re: Classpath dependancy validator warning [message #1844287 is a reply to message #538112] Wed, 08 September 2021 07:01 Go to previous messageGo to next message
Om Prakash is currently offline Om PrakashFriend
Messages: 1
Registered: September 2021
Junior Member
Hey There,
I am also getting same problem with my code.
and unable to find Java EE dependencies option in my eclipse 06 2021 eclipse under properties.
Kindly suggest I'm unable to figure out my code.
Here is my error :-
Description Resource Path Location Type
Classpath entry C:/DB_Home/product/18.0.0/dbhomeXE/jdbc/lib/ojdbc8.jar will not be exported or published. Runtime ClassNotFoundExceptions may result. LoginAppDemo P/LoginAppDemo Classpath Dependency Validator Message
Re: Classpath dependancy validator warning [message #1844338 is a reply to message #1844287] Thu, 09 September 2021 19:16 Go to previous message
Nitin Dahyabhai is currently offline Nitin DahyabhaiFriend
Messages: 4425
Registered: July 2009
Senior Member

Fundamentally the message is telling you that you've added a library to the Java Build Path that won't
be published with the web app, and that usually leads to runtime errors. You can mark it for deployment
using the Deployment Assembly property page. The message may stick around until you Build or Validate
the project.


_
Nitin Dahyabhai
Eclipse Web Tools Platform
Previous Topic:Dark theme has white current line for XML editor
Next Topic:Remove trailing whitespace on saving files
Goto Forum:
  


Current Time: Tue Mar 19 07:13:04 GMT 2024

Powered by FUDForum. Page generated in 0.04132 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top