You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@cocoon.apache.org by Barzilai Spinak <ba...@internet.com.uy> on 2003/09/24 11:01:17 UTC

Right procedure for rebuilding a block??

A couple of weeks ago I posted a question about adding a "selectBoolean" 
tag to JXForms and
the response I got was basically "you do it".
So, I went and did a few modifications to relevant source files under 
blocks/jxforms and I'm not sure
how to compile just that.   So I rebuilt all Cocoon and then I 
substituted the newly generated  "cocoon-jxforms-block.jar"
file in place of the old one (yes, I did a backup copy :-)
Now, after I restart Tomcat, Cocoon doesn't work. Any request into the 
/cocoon  webapp just returns empty.
Not even the Cocoon home page works.
The modifications I made were very minor, just a shy first attempt. No 
syntax errors, everything compiled right, and it was
in a couple of files belonging to blocks/jxforms like I said above.
So... evidently I don't have a clue about what I'm doing and whoever 
wrote JXForms could add this feature in 20 minutes
but nobody has identified himself as such.
The logs in Tomcat show these exceptions: 
java.lang.NoClassDefFoundError: 
org/apache/cocoon/generation/ServiceableGenerator
but I'm not sure whether they are related.

Is there anything I'm missing?  Is there an easy way to compile just the 
modified block?

BarZ



ADSL para estar en internet las 24 horas a máxima velocidad 
	          y sin ocupar el teléfono.
-----------------------------------------------------------
http://www.internet.com.uy                   Tel. 707.42.52


Re: Right procedure for rebuilding a block??

Posted by Barzilai Spinak <ba...@internet.com.uy>.
Ugo Cei wrote:

> Barzilai Spinak wrote:
>
>> The logs in Tomcat show these exceptions: 
>> java.lang.NoClassDefFoundError: 
>> org/apache/cocoon/generation/ServiceableGenerator
>
>
> The missing class has been added on Sep. 3rd. Apparently your 
> cocoon.jar was compiled from sources prior to that date:
>
> $Id: ServiceableGenerator.java,v 1.1 2003/09/03 15:00:56 cziegeler Exp $
>
> If you still have problems, open an issue in bugzilla and post your 
> diffs there, I'll try to test them ASAP. 

The Cocoon version I have currently running, and the one I used to 
rebuild are exactly the same tar.gz I downloaded (2.1.1) a couple of days
after it was released.  It includes the source 
src/java/org/apache/cocoon/generation/ServiceableGenerator.java
and it should be in the running Cocoon since it is...well... *running*
It has nothing to do with blocks/jxforms  as far as I know.  And that is 
the only .jar (the jxforms one) that I substituted into the *running* 
version
of Cocoon (previously, stopping tomcat, and then restarting it)

I'll try to test it with jetty as suggested.

BarZ




ADSL para estar en internet las 24 horas a máxima velocidad 
	          y sin ocupar el teléfono.
-----------------------------------------------------------
http://www.internet.com.uy                   Tel. 707.42.52


Re: Right procedure for rebuilding a block??

Posted by Ugo Cei <u....@cbim.it>.
Barzilai Spinak wrote:
> The logs in Tomcat show these exceptions: 
> java.lang.NoClassDefFoundError: 
> org/apache/cocoon/generation/ServiceableGenerator

The missing class has been added on Sep. 3rd. Apparently your cocoon.jar 
was compiled from sources prior to that date:

$Id: ServiceableGenerator.java,v 1.1 2003/09/03 15:00:56 cziegeler Exp $

If you still have problems, open an issue in bugzilla and post your 
diffs there, I'll try to test them ASAP.

	Ugo

-- 
Ugo Cei - Consorzio di Bioingegneria e Informatica Medica
P.le Volontari del Sangue, 2 - 27100 Pavia - Italy
Phone: +39.0382.525100 - E-mail: u.cei@cbim.it


Re: Right procedure for rebuilding a block??

Posted by Bertrand Delacretaz <bd...@codeconsult.ch>.
Le Mercredi, 24 sep 2003, à 11:20 Europe/Zurich, Barzilai Spinak a 
écrit :
>
> ...This might help in developing... I'll try it when I'm more awake. 
> However I think I'll need to provide my own sitemap and setup my test 
> application and all that....

If you implement new features, it would be good to expose them in the 
samples anyway, so you might want to add new samples or update existing 
ones to show what's new.

> ...The sources I was working with were the same ones I used to build 
> my currently running Cocoon. It was just a couple of lines that I 
> modified inside a block
> and used the generated jar into my currently working and deployed 
> Cocoon. That's what makes it strange (at least to me)...

sounds strange to me too, but testing with the cocoon.sh script will 
certainly show the problem.

-Bertrand

Re: Right procedure for rebuilding a block??

Posted by Barzilai Spinak <ba...@internet.com.uy>.
Bertrand Delacretaz wrote:

>> ...So, I went and did a few modifications to relevant source files 
>> under blocks/jxforms and I'm not sure
>> how to compile just that.   So I rebuilt all Cocoon and then I 
>> substituted the newly generated  "cocoon-jxforms-block.jar"
>
>
> It might be easier to test your changes by starting Cocoon with the 
> "cocoon.sh servlet" command (or cocoon.bat) after the build. This uses 
> the built-in (light) version of Jetty and is much more independent 
> from your environment and from previous builds.

This might help in developing... I'll try it when I'm more awake. 
However I think I'll need to provide my own sitemap and setup my test 
application and all that.


> Maybe do a "build clean" at some point as well.
>
>> ...The logs in Tomcat show these exceptions: 
>> java.lang.NoClassDefFoundError: 
>> org/apache/cocoon/generation/ServiceableGenerator...
>
>
> Most probably, the CVS version that you're using for the build has 
> changed since you built your jars, and your tomcat installation is out 
> of sync.
> Testing the whole thing as described above should help. 

The sources I was working with were the same ones I used to build my 
currently running Cocoon. It was just a couple of lines that I modified 
inside a block
and used the generated jar into my currently working and deployed 
Cocoon. That's what makes it strange (at least to me)
What about the Manifest file and all those numbers next to each jar 
file?  Maybe that is the problem?   Maybe the numbers in the manifest 
don't much
whatever they must match in my new jar??  

thanks

BarZ





ADSL para estar en internet las 24 horas a máxima velocidad 
	          y sin ocupar el teléfono.
-----------------------------------------------------------
http://www.internet.com.uy                   Tel. 707.42.52


Re: Right procedure for rebuilding a block??

Posted by Bertrand Delacretaz <bd...@codeconsult.ch>.
> ...So, I went and did a few modifications to relevant source files 
> under blocks/jxforms and I'm not sure
> how to compile just that.   So I rebuilt all Cocoon and then I 
> substituted the newly generated  "cocoon-jxforms-block.jar"

It might be easier to test your changes by starting Cocoon with the 
"cocoon.sh servlet" command (or cocoon.bat) after the build. This uses 
the built-in (light) version of Jetty and is much more independent from 
your environment and from previous builds.

Maybe do a "build clean" at some point as well.

> ...The logs in Tomcat show these exceptions: 
> java.lang.NoClassDefFoundError: 
> org/apache/cocoon/generation/ServiceableGenerator...

Most probably, the CVS version that you're using for the build has 
changed since you built your jars, and your tomcat installation is out 
of sync.
Testing the whole thing as described above should help.

-Bertrand