On Thu, Aug 22, 2013 at 11:48 AM, Konstantin Kolinko <knst.koli...@gmail.com
> wrote:

> 2013/8/22 Daniel Mikusa <dmik...@gopivotal.com>:
> > On Aug 21, 2013, at 4:09 PM, David kerber <dcker...@verizon.net> wrote:
> >
> >> Basically you're trying to defeat the way the system is designed to
> work.  Don't do that…
> >
> > +1 Don't do what you've described unless you have a very good reason.
>  It will cause you many headaches.
> >
> > Keep all of your JAR files in "WEB-INF/lib", with the exception of JDBC
> drivers.  Put those in "$CATALINA_BASE/lib".
> >
> > Dan
> >
>
> 1.
> +1.
>
> Adding webapp libraries to the common classloader (by placing them
> into ${catalina.base}/lib or by modifying the definition of
> common.loader) is a bad idea.
> (as documented and as discussed many times on this mailing list)
>
> IF you want to decouple libraries from your war,  add them to your
> webapp's classpath, by configuring a VirtualWebappLoader ,
>
> http://tomcat.apache.org/tomcat-7.0-doc/config/loader.html#VirtualWebappLoader_Implementation


​Interesting.  I just tried this out, but I'm not having luck.
We load the context of the app from
$catalina_home/conf/Catalina/localhost/myApp.xml

I tried adding the Loader to my context so it looks like this.  Am I doing
something wrong.



<?xml version='1.0' encoding='utf-8'?>
<Context>

    <Loader className="org.apache.catalina.loader.VirtualWebappLoader"
              virtualClasspath="/web/lib;/web/lib/*.jar"/>

<Resource
   factory="org.apache.tomcat.jdbc.pool.DataSourceFactory"
...
​



>
>
>
> 2. Top-posting is bad,
> per rules of this mailing list,
> http://tomcat.apache.org/lists.html#tomcat-users
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
> For additional commands, e-mail: users-h...@tomcat.apache.org
>
>

Reply via email to