[EMAIL PROTECTED] wrote:
>
> On Tue, 12 Sep 2000, Rafal Krzewski wrote:
> > > I believe the problem is in BaseInitableBroker.java:223 wher
> > > it goes
> > >
> > > try
> > > {
> > > initable = (Initable)Class.forName(className).newInstance();
> > > }
> > >
> > > The Class.forName is failing as it checks context
> > > classloader and is not finding appropriate classes.
> >
> > So? What's wrong with context loader? it has classes/ and all jars in lib/ in
> > it's classpath...
>
> nope they are seperate classloaders. Or at least they
> *should* be according to spec :P.
All right, shame on me for not reading the spec ;-)
>They have to be seperate
> because WEB-INF/classes is reloadable (and thus has to be
> disposable) while WEB-INF/lib is meant to be static. So the
> disposable CL has a parent CL that is responsible for
> WEB_INF/lib
OK, this means that the WEB-INF/lib ClassLoader cannot access
the classes managed by the WEB-INF/classes classloader. Now,
I don't have enough knowledge of Java internals to state what
happens when I call 'Class.forName("myclass")' - what ClassLoader
will be used... Does it depend on what CL loaded the class containg
the code, or on the thread that is executing the code?
I can only say that Class.forName() works for me... I have the modules
(screens etc), and my model classes, including Services in classes/
and Turbine in lib/ and I haven't had any problems like that.
Mayble it's JDK version dependent (I use 1.3/linux) or I am just lucky :-)
Rafal.
------------------------------------------------------------
To subscribe: [EMAIL PROTECTED]
To unsubscribe: [EMAIL PROTECTED]
Search: <http://www.mail-archive.com/turbine%40list.working-dogs.com/>
Problems?: [EMAIL PROTECTED]