--- Jos Vos <[EMAIL PROTECTED]> wrote:
> I see a strange behaviour in a p:choose clause in a subpipeline:
> it looks like serializers in p:when/p:otherwise clauses are not
> executed after the processor the produces the final output of the
> subpipeline (ref=...) is ready. Can this be true and is it a
> bug or a feature?
Jos,
Thank you for sending me your pipeline in a private email. Consider this
example:
<p:choose href="#instance">
<p:when test="true()">
<p:processor name="oxf:null-serializer">
<p:input name="data" href="#instance" debug="x"/>
</p:processor>
<p:processor name="oxf:identity">
<p:input name="data" href="#instance"/>
<p:output name="data" id="x"/>
</p:processor>
</p:when>
</p:choose>
In the branch of the <p:choose>, we have a null-serializer (from the pipeline
engine perspective,, this is a processor with no output, similar to the
file-serializer in your pipeline) and an identity processor that declares an id
"x". For the pipeline engine the whole <p:choose> is like a processor that
declares a output "x". Just like with regular processors, if a processor
declares one of more outputs and none of the output is used, the processor is
not executed. So in this case, if "x" is not referenced in the rest of the
pipeline, the whole <p:choose> is not executed.
Now if you remove the identity processor for the branch, the <p:choose> will be
considered as if it was a processor with no output. So it will be always
executed.
Does this explain what you are experimenting? To avoid this kind of unexpected
behavior, we could consider the pipeline invalid if and output is declared but
never used.
Alex
-------------------------------------------------------
The SF.Net email is sponsored by: Beat the post-holiday blues
Get a FREE limited edition SourceForge.net t-shirt from ThinkGeek.
It's fun and FREE -- well, almost....http://www.thinkgeek.com/sfshirt
_______________________________________________
orbeon-user mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/orbeon-user