Hello Solprovider, First : I would like to create a wiki page on this debugging discussion so : Can you allow me to copy paste your answer in the http://wiki.apache.org/lenya/DebuggingTips page for introduce the article ?
On Sun, 12 Oct 2008 13:27:19 -0400, [EMAIL PROTECTED] wrote: > With Lenya/Cocoon XMAP, debugging a complex process with multiple > pipelines in multiple XMAPs can be a challenge. > > When first creating an XMAP, I serialize after each generator, > aggregator, and transformer and save the XML from the browser to a > file. Second : My problem is that I don't see how to see the result XML in the bowser (due to the construction of the site). Do you use a tips like that : On top of the publication-sitemap.xml: <map:match pattern="**"> <map:generate src="../../content/util/empty.xml"/> <map:mount uri-prefix="" src="{fallback:TheMapToTest.xmap}" check-reload="true" reload-method="synchron"/> <map:serialize type="html"/> </map:match> ==> I don't test that for now, I have this idea after read this mail : http://markmail.org/message/ljpvtd73fh6npmj2 third :thank you for this good explanation > Knowing the results of each process greatly helps with writing > the next stage. I often discover namespaces in element names that > need to be either dropped in the current process or handled by the > next process. The saved output provides reference for later > development. > > After an XMAP is completed, debugging is more difficult. The final > results are often combined from several XMAPs. Logging intermediate > results to a file is a very good solution. > > One difficult-to-notice mistake between processes can waste much time. > I often create a "test" XMAP to isolate portions of the problematic > XMAP -- copying pieces XMAPs, tweaking URLs, and controlling the input > by generating from XML files rather than depending on the full > process. Some tests work perfectly indicating the problem was earlier > in the pipeline -- difficult to determine without isolating each > process. > > HTH, > solprovider > > On 10/12/08, Florent André <[EMAIL PROTECTED]> wrote: >> On Thu, 09 Oct 2008 00:58:44 +0200, Thorsten Scherler > <[EMAIL PROTECTED]> >> wrote: >> >1 - the stream is "cut" when the map:serialize is throw >> > Yes that is the whole idea of debugging. >> > >> > Imaging a video of someone climbing a mountain and someone else >> > recording it with a cam. If the climber falls and later analyze why, > the >> > most repeated part of this video probably is the one just before the >> > fall. This is because the climber wants to learn why (s)he fall to > not >> > and fix this mistake in the future. >> >> Yes, I'm agree with you, very good metaphor. > --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]