aspose file tools*
The moose likes Tomcat and the fly likes Location of MySQL Connector jar Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Spring in Action this week in the Spring forum!
JavaRanch » Java Forums » Products » Tomcat
Bookmark "Location of MySQL Connector jar" Watch "Location of MySQL Connector jar" New topic
Author

Location of MySQL Connector jar

Elton Hughes
Ranch Hand

Joined: Jun 19, 2003
Posts: 72
Hello All,
I am learning about Java, servlets, JavaServer Pages, JDBC, and Tomcat. Whew. Lots of info, and very interesting stuff. As a part of the learning process I downloaded the latest stable version of the MySQL JDBC driver. I am using MacOS 10.2.8. I think I should place the jar in /Library/Java/Extensions . Is this correct?
The book I am using to learn from says to install the jar in the common/lib directory of Tomcat. Should this be a separate copy or a link to the jar in /Library/Java/Extensions?
Thanks,
Elton
[ October 15, 2003: Message edited by: Elton Hughes ]
Bear Bibeault
Author and ninkuma
Marshal

Joined: Jan 10, 2002
Posts: 61417
    
  67

I wouldn't put the jar in /Library/Java/Extensions at all. There's no need to.
bear


[Asking smart questions] [Bear's FrontMan] [About Bear] [Books by Bear]
Elton Hughes
Ranch Hand

Joined: Jun 19, 2003
Posts: 72
Hi Bear,
If not in /Library/Java/Extensions then where? And what is the role of the /Library/Java/Extensions directory?
Elton
Karen Gomes
Ranch Hand

Joined: Aug 25, 2003
Posts: 60
Hi Elton,
I have never used java on a mac ... but on a PC with windows environment we treat it exactly like the jar files of j2sdk. We specify it in the classpath..
May be you can look for where the jars or classes of jdk have been specified. Guess it should be treated alike.
Karen
Bear Bibeault
Author and ninkuma
Marshal

Joined: Jan 10, 2002
Posts: 61417
    
  67

If not in /Library/Java/Extensions then where? And what is the role of the /Library/Java/Extensions directory?

Tomcat ignores the system classpath. For use in Tomcat-served web applications, I'd put it in the shared/lib folder of your Tomcat installation.
bear
Elton Hughes
Ranch Hand

Joined: Jun 19, 2003
Posts: 72

Tomcat ignores the system classpath. For use in Tomcat-served web applications, I'd put it in the shared/lib folder of your Tomcat installation.

Makes sense. The book I am using suggests placing it in Tomcat's common/lib directory.
But what if I want to use the jar for Tomcat and regular old jdbc? Two jar's or a link?
Elton
Simon Brown
sharp shooter, and author
Ranch Hand

Joined: May 10, 2000
Posts: 1913
    
    6
Since this is turning out to be more of a Tomcat question (the difference between the various locations in which JAR files can be placed), I'm going to move it to the Tomcat forum.
Simon
Mike Curwen
Ranch Hand

Joined: Feb 20, 2001
Posts: 3695

Hi Elton,

Find a good description of the Tomcat classloaders here:

http://jakarta.apache.org/tomcat/tomcat-4.1-doc/class-loader-howto.html
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Location of MySQL Connector jar