Hi Pete

I have now downloaded the Turbine snapshot of 12Sept. I am still having problems with 
classes not being found. I get the ff exception on my browser: (not the whole 
exception, just the top part):

***********************************
There has been an error! Please review the exception below for more information.
Get/Post Data:
screen = WebMacroSiteScreen 
template = Error 

The exception is:
java.lang.NoClassDefFoundError: 
org/apache/turbine/services/cache/ObjectExpiredException
        at org.wits.services.ObjectManager.getAllFaculties(ObjectManager.java:88)
        at org.wits.servlets.screens.EnterFaculty.doBuildTemplate(EnterFaculty.java, 
Compiled Code)
        at 
org.apache.turbine.modules.screens.WebMacroSiteScreen.doBuildTemplate(WebMacroSiteScreen.java:121)
        at 
org.apache.turbine.modules.screens.TemplateScreen.doBuild(TemplateScreen.java:123)
        at 
org.apache.turbine.modules.screens.WebMacroSiteScreen.doBuild(WebMacroSiteScreen.java:134)
        at org.apache.turbine.modules.Screen.build(Screen.java:100)
        at org.apache.turbine.modules.ScreenLoader.eval(ScreenLoader.java:126)
        at 
org.apache.turbine.modules.layouts.WebMacroSiteLayout.doBuild(WebMacroSiteLayout.java:106)
        at org.apache.turbine.modules.Layout.build(Layout.java:93)
*****************************

My setup is as follows:

1. I am running tomcat
2. Turbine is in my context /lib directory, with all the other libs (WM, ECS, etc) 
that turbine requires.
3. There are no other Turbine classes anywhere in my context path, tomcat classpath.
4. My application has classes in Web-Inf/classes and ONE OTHER DIRECTORY as well. This 
other directory has been specified in Tomcat's classpath, and some of these classes 
are actually being executed.

I now have no idea what is wrong, and this problem is driving me around the bend.

Any recommendations as to what I should try?

One other question: What is the order of the classpath which Tomcat searches - is it 
webinf/classes, webinf/lib, and then the specified Tomcat classpath?


Regards

Chris


>>> [EMAIL PROTECTED] 09/12/00 11:50AM >>>
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. 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

>  
> > This is prolly because your classes are in WEB-INF/lib and
> > the turbine classes are in WEB-INF/classes or vice versa. It
> > always leaves me pulling out hair when that sort of thing
> > happens. Easieest solution is to unjar everything into
> > WEB-INF/classes - thou you may want to package it up
> > propperly when you release it as putting heaps in
> > WEB-INF/classes can cause odd behaviour.
> 
> I do have my classes (including custom services) in webapp/WEB-INF/classes and all
> the jars form the distribution including turbine-2.0.jar in webapp/WEB-INF/lib and
> everything is working just fine. I don't know how uncompressing jar influences 
> debugging (haven't done that yet) but I thaught that as far as the debuger can find
> the *source* files, it doesn't matter where the classes are loaded from.

But it can matter to the run time :P. CL issues always
irritate me and it usually takes me ages to track them down
- one of the reasons I use WEB-INF/lib for more of my stuff
if I can help it.

Cheers,

Pete

*--------------------------------------------------*
| Latrobe University,     | Does the name 'Pavlov' |
| Bundoora, Australia     |    ring a bell ?       |
*--------------------------------------------------*



------------------------------------------------------------
To subscribe:        [EMAIL PROTECTED] 
To unsubscribe:      [EMAIL PROTECTED] 
Search: <http://www.mail-archive.com/turbine%40list.working-dogs.com/>
Problems?:           [EMAIL PROTECTED] 



------------------------------------------------------------
To subscribe:        [EMAIL PROTECTED]
To unsubscribe:      [EMAIL PROTECTED]
Search: <http://www.mail-archive.com/turbine%40list.working-dogs.com/>
Problems?:           [EMAIL PROTECTED]

Reply via email to