1.) Set up an eclipse java-project named "cocoon" 2.) Import all cocoon-2.0.4 sources into the cocoon-project (i did this during project creation). 3.) Setup project environment to compile cocoon from within eclipse. You need to add all necessary libs by hand. I also had to discard some classes due to unavailable jars (i remeber about 5 classes only to be deleted from the cocon distrib). Otherwise the project would not compile ;-( 4.) create a launch config as already described on default port 8000 (in fact you can use anything else too) 5.) place breakpoints into any point of the cocoon sources I had no problems as you describe... 6.) Set the JAVA_OPTS as already described. 7.) Start tomcat with startup.sh 8.) Launch the launch config from 4.) 9.) Sit back and watch your appserver beeing fully under your control...
no other tricks here ...
One question: Why would you prefer to set the JAVA_OPTS by hand? And how are you starting the tomcat server, if you set the JAVA_OPTS by hand ??? I think it is much easier to simply cretae the JAVA_OPTS environment var possibly on a startup script and never think about this again... Ok, remember about this, when you go to production ;-)
regards, hussayn
ePost wrote:
Hi Hussayn,
I´m just coming back to the debug problem in eclipse (learning a lot of new stuff at the moment). I´ve set the startup option for tomcat as you adviced (but via command line not via JAVA_OPTS). In eclipse I start the remote debug session which successfully connects to port 8000. But I can´t set any breakpoints in the Cocoon Java Source. Do I have to adjust the source lookup path in eclipse? I´ve already tried some settings but nothing worked.
Thanks for your answer.
Helmut
On Thu, 20 Mar 2003 09:34:06 +0100, SAXESS - Hussayn Dabbous <[EMAIL PROTECTED]> wrote:
Hi,
I can't tell you why you get this error, but i can tell you
how we are debugging cocoon enabled web applications in a
similar environment as yours:
We are running eclipse, cocoon-2.0.4, tomcat-4.1.18 on solaris
and linux. We run eclipse on a PC-frontend and we always start
the tomcat server with the startup scripts. When debuging
whichever webapp (including cocoon) we set the JAVA_OPTS
as follows:
-server -Xdebug -Xnoagent -Djava.compiler=NONE - Xrunjdwp:transport=dt_socket,server=y,suspend=n,address=8000
Then we (re)start the tomcat server as usual with "startup.sh" or
"startup.bat". Please note, that we set the JAVA_OPTS, not the
CATALINA_OPTS for this, although the docs at the tomcat site
state something else (that does not work for us)
On eclipse we set up a remote debugging session on port 8000.
This works perfectly! It should also work, when the tomcat server
is running locally.
regards, hussayn
Helmut Tammen wrote:
Hi,
I try to use the combination of Eclipse, Tomcat and the Sysdeo Plugin to debug the cocoon source in Eclipse. This doesn´t work (error message when trying to access any Cocoon resource at the end). When I start Tomcat via the startup.bat everything works fine.
My environment:
Windows 2000
Eclipse 2.1 (Beta)
JDK 1.4.1_02
Tomcat 4.0.6
Sysdeo plugin for Eclipse 2.1 (Beta)
Cocoon 2.1-dev
I´ve also tried JDK 1.4.0, Tomcat 4.1.18 and Cocoon 2.0.4 in various combinations with no success.
All the Xerces and Xalan libs are replaced with the ones from Cocoon in the directories [JAVA_HOME]/jre/lib/
endorsed, [CATALINA_HOME]/common/endorsed and in [ECLIPSE_HOME]/plugins/org.apache.xerces_4.0.7 (probably not necessary because not in the classpath of my webapp)
Does anyone have an idea what´s going wrong here?
Thanks in advance
Helmut
ERROR (2003-03-20) 08:33.54:103 [access] (Unknown-URI) Unknown- thread/CocoonServlet: Cocoon got an Exception while trying to close stream.
java.io.IOException: The stream has been closed
at org.apache.catalina.connector.ResponseStream.flush(ResponseStream.java:237)
at org.apache.cocoon.servlet.CocoonServlet.service(CocoonServlet.java:1145)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
--------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]