i think this is generally an antipattern. its never a good idea to put jars
like wicket,spring into server's shared lib dirs because anything static
then becomes shared across all webapps. it can have some strange sideffects.

for example take wicket's springbean injection stuff. it keeps the injector
in a static field, and the injector is tied to the application. so if you do
this then webapp A can get an injector that works with webapp B because they
now shared the static field that is shared across the webapps.

-igor


On 3/4/07, Dan Brough <[EMAIL PROTECTED]> wrote:

Chris Colman wrote:
> I found the problem: had to put the wicket jars in my web app's 'lib'
> directory and not in 'common/lib'.
>
I noticed this "problem" with jetty.
wicket.protocol.http.WicketFilter sets the context class loader to the
filters class loader
which can't see your web application classes.
I worked around this by extending the WicketFilter with the override:

        protected ClassLoader getClassLoader() {
                return Thread.currentThread().getContextClassLoader();
        }

so that my new WicketFilter would keep the default context class loader.
Mow I can stick all my wicket jars in the servers lib directory instead
of having to put them in the webapps lib directory.

Anyone know what problems this might cause me ? .. or perhaps the logic
behind wicket changing
the context class loader for the request threads ?

cheers,
Dan Brough.




-------------------------------------------------------------------------
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share
your
opinions on IT & business topics through brief surveys-and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV
_______________________________________________
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user

-------------------------------------------------------------------------
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your
opinions on IT & business topics through brief surveys-and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV
_______________________________________________
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user

Reply via email to