[ 
https://issues.apache.org/jira/browse/ODE-968?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13290097#comment-13290097
 ] 

Jayant Vaish commented on ODE-968:
----------------------------------

In 
org.apache.ode.bpel.elang.xpath20.runtime.XPath20ExpressionRuntime.evaluate(OExpression
 cexp, EvaluationContext ctx) throws FaultException, EvaluationException{
.....
try { someRes = evaluate(cexp, ctx, XPathConstants.NODESET); } catch (Exception 
e) { someRes = evaluate(cexp, ctx, XPathConstants.STRING); }
....

}

evaluate(cexp, ctx, XPathConstants.NODESET); is responsible to call the ode 
extension xpath function, but that function return type is not NodeList (For 
example it's return type is String).
So, it throws exception as String value is not converted in NodeList.
Then in the catch block it again execute that function.

                
> Ode Extension XPath functions executes twice.
> ---------------------------------------------
>
>                 Key: ODE-968
>                 URL: https://issues.apache.org/jira/browse/ODE-968
>             Project: ODE
>          Issue Type: Bug
>          Components: BPEL Runtime
>            Reporter: Jayant Vaish
>            Priority: Critical
>         Attachments: DomToString.zip
>
>
> When the XPath query call the ode extension xpathFunction for the first time 
> it expects return type of NODESET, If in case it returns something else then 
> the exception is thrown and in the catch block it executes that function 
> again.
> To reproduce this issue, unzip the attached project in your server's 
> var/deploy/
> Set logging level debug for 
> "org.apache.ode.bpel.elang.xpath20.runtime.JaxpFunctionResolver.DomToString"
> Now, while running this process 
> "org.apache.ode.bpel.elang.xpath20.runtime.JaxpFunctionResolver.DomToString.evaluate(List
>  args) throws XPathFunctionException" will be executed twice.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: 
https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

Reply via email to