You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@servicemix.apache.org by "Grant McDonald (JIRA)" <ji...@apache.org> on 2006/08/11 04:15:23 UTC

[jira] Closed: (SM-530) Update of New Validation Component Error Handler to add in a namespace prefix

     [ https://issues.apache.org/activemq/browse/SM-530?page=all ]

Grant McDonald closed SM-530.
-----------------------------

    Resolution: Won't Fix

Thanks for the feedback :)  after looking into it some more I find that I agree with you.  The inclusion of prefix definitions on nodes can create other issues with XSL transformation and the XPath issue is more elegantly solved using a PrefixResolver.

> Update of New Validation Component Error Handler to add in a namespace prefix
> -----------------------------------------------------------------------------
>
>                 Key: SM-530
>                 URL: https://issues.apache.org/activemq/browse/SM-530
>             Project: ServiceMix
>          Issue Type: Improvement
>          Components: servicemix-components
>         Environment: Ubuntu Linux 5.10, Windows XP SP2, ServiceMix HEAD
>            Reporter: Grant McDonald
>         Attachments: servicemix-components.zip
>
>   Original Estimate: 5 minutes
>  Remaining Estimate: 5 minutes
>
> I realised that without a namespace prefix the XML generated by the MessageAwareErrorHandler will not be accessible via xpath.  An example of this:
> <Fault xmlns="http://www.servicemix.org/demo">
>     <messages>
>           ....
>    </messages>
> </Fault>
> To retrieve the child elements of the messages node we would need to specify "//messages/*" but with the namespace declared at the top this will return nothing.  Instead the XML should be:
> <Fault xmlns="http://www.servicemix.org/demo" xmlns:smdemo="http://www.servicemix.org/demo">
>     <messages>
>           ....
>    </messages>
> </Fault>
> and the xpath "//smdemo:messages/*
> The provided patch adds this functionality and updates the example.xml test resource.

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: https://issues.apache.org/activemq/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira