Skip to main content



      Home
Home » Newcomers » Newcomers » Project Libraries(Spring Framework)
Project Libraries [message #1328910] Fri, 02 May 2014 19:19 Go to next message
Eclipse UserFriend
I followed some Spring MVC tutorials and imported the Spring libraries using the import external jars in the build path but I got exceptions from tomcat. Then I put the same libraries in my web-inf/lib folder and all was well. What is the difference between having libraries in the libraries place vs in web-inf/lib?
Re: Project Libraries [message #1329460 is a reply to message #1328910] Sat, 03 May 2014 01:47 Go to previous messageGo to next message
Eclipse UserFriend
Moe,

I think you have to put them where the server will know to where find
them not just anywhere that makes the JDT compiler find them and use
them at development time.

On 03/05/2014 1:19 AM, Moe B wrote:
> I followed some Spring MVC tutorials and imported the Spring libraries
> using the import external jars in the build path but I got exceptions
> from tomcat. Then I put the same libraries in my web-inf/lib folder
> and all was well. What is the difference between having libraries in
> the libraries place vs in web-inf/lib?
Re: Project Libraries [message #1330021 is a reply to message #1329460] Sat, 03 May 2014 08:23 Go to previous messageGo to next message
Eclipse UserFriend
So we put them in web-inf/lib for the server to find them and in the libraries folders for the compiler to find them? Is that what the difference is between those two locations?
Re: Project Libraries [message #1330241 is a reply to message #1330021] Sat, 03 May 2014 10:58 Go to previous message
Eclipse UserFriend
On 05/03/2014 06:23 AM, Moe B wrote:
> So we put them in web-inf/lib for the server to find them and in the
> libraries folders for the compiler to find them? Is that what the
> difference is between those two locations?

Moe,

When not using Maven (and I don't like to and don't usually do except at
work), I put all my libraries underneath project/lib. Then, I use Build
Path -> Libraries to bring them into my project and Deployment Assembly
to tell Eclipse to deploy them (and it will deploy them to WEB-INF/lib
for you when you build the WAR or run Tomcat from Eclipse.

Note that when you run your application (presumably to debug it) in
Eclipse with Tomcat, your deployment mimics a real Tomcat deployment
artificially on this path:

workspace/.metadata/.plugins/org.eclipse.wst.server.core/tmp0/wtpwebapps

....underneath which you'll find project/WEB-INF/lib and all your libraries.

But, yeah, you do have to tell Eclipse one way or another where to find
the libraries. What I've described is how it works in a Dynamic Web Project.
Previous Topic:Cursorposition in Files when using Tasks
Next Topic:Changing project path in Kepler64 (new OS)
Goto Forum:
  


Current Time: Thu Jun 19 19:01:29 EDT 2025

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

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

Back to the top