cocoon-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Litrik De Roy" <cocoon-...@litrik.com>
Subject Re: Redirect following a transformer does not execute the transformer
Date Wed, 15 Oct 2003 19:46:23 GMT
----- Original Message ----- 
From: "Tony Collen" <colle006@umn.edu>

> Litrik De Roy wrote:
> > Imagine the following pipeline:
> >
> >   <map:match pattern="delete">
> >     <map:generate src="delete.xml"/>
> >     <map:transform type="write-source"/>
> >     <map:redirect-to uri="list"/>
> >   </map:match>
> >
> > I have noticed that the Source Writing transformer does not get executed
?
> > It looks like the sitemap is "optimizing" the pipeline and assuming
"hey,
> > I'll need to redirect, why bother doing the generate and transform".
> >
> > Does this work as designed, or am I missing something?
>
> Hmm, I'm not 100% on the inner functionality of Cocoon's pipelines, but it
could be the way they are
> assembled before any data is sent through.

Neither do I know the internals of the pipeline. And I can't seem to find
the source of the code doing the sitemap stuff. I can locate and understand
the source of a simple generator, but the sitemap itself...

>
> > PS: The use case for the above pipeline is displaying a list where the
user
> > can delete some entry. This calls the "delete" url (typically with some
> > parameters) but I want to prevent that the browser shows the delete url
in
> > the address bar. So I redirect to the list URL which refreshes the list
and
> > displays a very nice URL (but unfortunately no longer executes the
> > transform).
>
>
> If you're trying to delete a file, perhaps an action would be more
appropriate?
>

Well I'm doing a lot of different things: aggregate some data, send it
through a custom transformer, do some extra xsl, send it through the session
transformer to update some xml stored in my session context, next send it
through the source writing transformer to update a snippet of xml on disk.

The pipeline works beautifully without the redirect. But to get rid of the
ugly URL in the browser I was hoping to use a redirect.

> Regards,

Thanks for your feedback.

>
> Tony
>

Litrik De Roy
www.litrik.com



Mime
View raw message