cocoon-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Christopher Oliver <res1c...@verizon.net>
Subject Re: Pipleline Execution Stack Trace (was Cocoon Stack Traces)
Date Mon, 19 Jan 2004 17:31:52 GMT
Vadim Gritsenko wrote:

> Christopher Oliver wrote:
>
>> So I would propose something like the following:
>>
>> 1) Have the TreeProcessor pass the sitemap source location in 
>> setGenerator(), addTransformer(), and setSerializer() to the 
>> ProcessingPipeline.
>> 2) In "Debug" mode instrument the PipelineProcessor to write the 
>> output of each stage to a temporary file and regenerate SAX events 
>> from the temporary file (with location information). The 
>> PipelineProcessor would catch any exception thrown by a pipeline 
>> component and generate a "Cocoon" stack trace that includes the 
>> source location of the temp file. The Cocoon error reporter could 
>> even display the source code (maybe in tab-panes or whatever) of the 
>> pipeline intermediate results together with the stack trace. 
>> Hypothetically the label or tooltip on the tab-pane would be 
>> something like:
>>
>> C:\TEMP\Pipeline_1060734815693.xml (output of 
>> C:\cocoon\build\webapp\samples\sitemap.xmap::66:16)
>>
>> where the sitemap location refers to a <map:generate> or 
>> <map:transform> instruction.
>>
>> WDYT?
>
>
>
> IIRC, profiler pipeline already does some of this, like it saves 
> output of every stage. Me thinks this "debug" mode should be part of 
> profiling pipeline.

I am aware of that from: 
http://marc.theaimsgroup.com/?t=106776583200001&r=1&w=2

But profiling seems like a separate concern.

>
> PS I don't like writing to a temp file part
>
> Vadim
>
>
Why not (curious as to exact reason)?

The idea is that this is analagous to running a C compiler (which is 
also a pipeline, BTW) with "cc -i -s" to save the preprocessor and 
assembler output.

Chris


Mime
View raw message