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.  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.

Reply via email to