cocoon-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Ian Atkin <>
Subject RE: A very simple question (REALLY!!!! But please, answer!)
Date Thu, 23 Nov 2000 19:31:03 GMT
looks like your using cocoon to compile a java source file (i'm probably
wrong though) - which will never work!

1. compile the java source & put the .class file on the classpath (system or
web app)
2. write the functionality as an XSP page, which will be compiled by cocoon

read the FAQ it explains all about XSP.

seems you may have mis-understood the purpose of web-inf directory.
- this is never meant to be accessed by a user, just the servlet engine.
- in api v2.2 one servlet context = one web app, and each web app can have
it's own classpath (and loader)
- you have a choice to add classes to the system or the web app
- i've no idea about anything pre-v2.2 (i'm not sure if the webapp concept
pre-dates v2.2)

read the servlet API & your engine docs for more details

- have you setup cocoon as a servlet, ie with a name, classname, and it's
init properties? (you didn't say you did in your post)
- if not this is in the docs

if it's not one of these i'm as stumped as you...

Ian Atkin
Code Monkey & Text File Editor
Wide Learning

> -----Original Message-----
> From:	Luis Gois []
> Sent:	23 November, 2000 5:42 PM
> To:	cocoon-users
> Subject:	A very simple question (REALLY!!!! But please, answer!)
> Hello!
> Just deployed Cocoon 1.8 with Tomcat 3.2b6 and, though all XSP examples
> that came with Cocoon work fine, I can't seem to access my own
> classes!!! I've created de context /cocoon and copyed all Cocoon
> examples to the webapps/cocoon/servlets dir, so the Cocoon conf within
> Tomcat must be OK, right? I've put my own classes at
> webapps/cocoon/WEB-INF/classes dir, as I understand from Tomcat's
> documentation. Do I need to set classpath stuff in any config file
> somewhere? I really apreciate help on this, cause it seems something so
> simple and I just can't get there!:(
> 	I also tried to access some servlet 2.2b classes (servlet.jar in
> tomcat
> /lib dir, so it gets in TOMCAT classpath at startup sh) but it's methods
> aren't found! I keep geting the same message :
> java.lang.Exception: XSP Java Compiler: Compilation failed for
>      137: Method showDataAsTable(int, int) not found in class
> _usr._appl._mercado._unstable._local._src._XSP._index.
>                xspExpr(showDataAsTable(0,5), document)
>                                       ^
>      1 error
> 	(this is for may own classes at WEB-INF/classes/pt/grupes/java/dito/
> 	  with <xsp:include>*</xsp:include>	
> java.lang.Exception: XSP Java Compiler: Compilation failed for
>      137: Method getInitParameter() not found in class
> _usr._appl._mercado._unstable._local._src._XSP._index.
>                xspExpr(getInitParameter(), document)
>                                       ^
>      1 error
> (for servlet2.2	I get the same "Method (...) not found in class"
> error -
> method 			getInitParameter() for  example)
> I previously used JServ, so only servlet2.0 available.
> Thanks in advance.
> Luis Gois << File: esql-proc.xml >>  << File: ATT38751.txt >>

View raw message