cocoon-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Simon Collins" <scoll...@fastmail.fm>
Subject Re: Linkrewriter dynamic configuration overloading syntax pitfall (Javadoc out of sync, Cocoon 2.1M1)
Date Mon, 12 May 2003 15:49:07 GMT
Hi Olivier,

Is Cocoon 2.1M1 the version that comes with Forrest 0.4? I couldn't
figure that out. I'm using the binaries from 0.4 and had a similar
problem. Any changes I make to the link map don't take affect until I
reload the servlet context. I tried your suggested config changes but
they didnt seem to fix it.

I noticed that Forrest has an open bug logged to do with this caching
issue:
http://issues.cocoondev.org/jira//ViewIssue.jspa?key=FOR-27

which refers to a caching bug in Cocoon that is now fixed:
http://issues.cocoondev.org/jira//ViewIssue.jspa?key=FOR-27

I thought that this was what was causing my problems, but if you dont
have any problems after changing your config then maybe it's something
else I'm doing wrong. Did you also get this working with Forrest 0.4
binaries or just separately with Cocoon 2.1M1 ?

Cheers,
Simon

On Sun, 11 May 2003 06:10:27 +0200, "Olivier Lange"
<olange@petit-atelier.ch> said:
> Dear all
> 
> I had a hard time figuring out how to dynamically overload the
> configuration
> of the input modules used for the LinkRewriter configuration. I believe
> there is a syntax pitfall in the Javadoc of Cocoon 2.1M1, the Javadoc
> being
> out of sync on this topic.
> 
> I discovered the Linkrewriter in Forrest 0.4, studied its configuration,
> then followed the Javadoc and overlooked the sitemap configuration of the
> bookdemo and sitedemo samples of Cocoon 2.1M1. Here is a summary.
> 
> The Javadoc notes that the "dynamic config syntax [is] different to the
> static config syntax (attributes used instead of elements)"
> (LinkRewriterTransformer.java, lines 114-116). So one is suggested to
> write:
> 
> <map:sitemap>
>   <map:components>
>     <map:transformers>
>       <map:transformer name="linkrewriter"
>         src="org.apache.cocoon.transformation.LinkRewriterTransformer">
>         ...
>         <input-module name="linkmap" src="{src}" ... />
>         ...                          ^^^ attribute: does not work
>       </map:transformer>
> 
> I tried, but this didn't work. The linkwriter would not use the sitemap's
> substitued value of the 'src' attribute to get the "Linkmap", it rather
> used
> the value of the static configuration defined in the cocoon.xconf file:
> 
>   <component-instance name="linkmap" ...>
>     ...
>     <file src="cocoon://linkmap"/>
>     ...
>   </component-instance>
> 
> To dynamically overload the cocoon.xconf's static configuration, one has
> to
> write:
> 
>   <map:transformer name="linkrewriter" src="..."
>     ...
>     <input-module name="linkmap" ... >
>       <file src="{src}"/>
>     </input-module>
>     ...
>   </map:transformer>
> 
> There is actually no difference to the static configuration syntax. The
> samples use this later syntax and work fine.
> 
> Olivier
> 
> 
> 
> 
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: cocoon-users-unsubscribe@xml.apache.org
> For additional commands, e-mail: cocoon-users-help@xml.apache.org
> 
> 

---------------------------------------------------------------------
To unsubscribe, e-mail: cocoon-users-unsubscribe@xml.apache.org
For additional commands, e-mail: cocoon-users-help@xml.apache.org


Mime
View raw message