[prev in list] [next in list] [prev in thread] [next in thread] 

List:       fedora-devel-java-list
Subject:    Re: [fedora-java] Tomcat Help
From:       "Ryan Ollerenshaw" <ryanollerenshaw () gmail ! com>
Date:       2006-08-04 18:29:51
Message-ID: 20b31d4d0608041129i680e10efkc1f95b937d3c3de8 () mail ! gmail ! com
[Download RAW message or body]

On 8/4/06, Gary Benson <gbenson@redhat.com> wrote:
> Ryan Ollerenshaw wrote:
> > I am trying to set up Tomcat 5 on Fedora Core 5 and everything iw
> > working find but i do not know how to set my classpath when using
> > tomcat below is a few things that i have tried.
> >
> > I have found i can use the following code to print out the classpath
> > that my program is actaully using, the code is:
> >
> > Get the System Classloader
> >        ClassLoader sysClassLoader = ClassLoader.getSystemClassLoader();
> >
> >        //Get the URLs
> >        URL[] urls = ((URLClassLoader)sysClassLoader).getURLs();
> >
> >        for(int i=0; i< urls.length; i++)
> >        {
> >           out.println(urls[i].getFile());
> >           out.println("<br>");
> >        }
> >
> > and the classpath that is printed is:
> >
> > /usr/java/j2sdk1.4.2_12/lib/tools.jar
> > /etc/tomcat5/bin/dist/commons-daemon.jar
> > /etc/tomcat5/bin/bootstrap.jar
> >
> > But i am not sure where this is getting set, i do have the following
> > in my /tomcat5/bin/startup.sh
> >
> > export
> > CLASSPATH=./mapscript.jar:.:/etc/tomcat5/webapps/my_test/WEB-INF/classes
> >
> > so why is this not my classpath at run time??
>
> Tomcat does all kinds of weird things to the classpath.  Any jars your
> webapp needs need to be in its WEB-INF/lib directory.
>
> Cheers,
> Gary
>

Yes i have already done this, no help, could it be that the eclipse
tomcat plugin is setting its own classpath somewhere?  I have added
the jar to window -> preferances -> java -> classpath. but maybe i am
missing somthing else. It just seems that the ./startup.sh script in
the  tomcat directory does not have any effect when i make changes to
it.

--
fedora-devel-java-list mailing list
fedora-devel-java-list@redhat.com
https://www.redhat.com/mailman/listinfo/fedora-devel-java-list
[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic