File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
The moose likes Tomcat and the fly likes Where to put jar files? Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login

Win a copy of OCA Java SE 8 Programmer I Study Guide 1Z0-808 this week in the OCAJP forum!
JavaRanch » Java Forums » Products » Tomcat
Bookmark "Where to put jar files?" Watch "Where to put jar files?" New topic

Where to put jar files?

michael yue
Ranch Hand

Joined: Nov 20, 2003
Posts: 204
Where am I supposed to put all the jar files in tomcat? I can run similar code in standalone mode but when put in tomcat server it did not work.
Should I also restart the server?
Bear Bibeault
Author and ninkuma

Joined: Jan 10, 2002
Posts: 61985

Depends. App-specific jars should go in the app's WEB-INF/lib. Jars Shared between all apps should go in $CATALINA_HOME/shared/lib. Jars shared between all app and Tomcat itself should go in $CATALINA_HOME/common/lib.
And yes, when you change jars you must restart the app or server as appropriate (though Tomcat 5 is pretty good about doing it on its own when it detects the change and auto-reload is enabled).

[Asking smart questions] [Bear's FrontMan] [About Bear] [Books by Bear]
With a little knowledge, a cast iron skillet is non-stick and lasts a lifetime.
subject: Where to put jar files?