ODE
  1. ODE
  2. ODE-840

XPath20ExpressionCompilerImpl can't parse functions with embedded functions

    Details

    • Type: Bug Bug
    • Status: Resolved
    • Priority: Major Major
    • Resolution: Fixed
    • Affects Version/s: 1.3.4
    • Fix Version/s: 1.3.4
    • Labels:
      None
    • Environment:
      ODE 1.3.4 ReleaseCandidate

      Description

      org.apache.ode.bpel.elang.xpath20.compiler.XPath20ExpressionCompilerImpl.doJaxpCompile(OXPath20ExpressionBPEL20 out, Expression source):Line 169-170
      for (String functionExpr : extractFunctionExprs(xpathStr)) {
      expr = xpe.compile(functionExpr); //Line: 170 here an exception is thrown
      try

      { expr.evaluate(node); }

      catch (XPathExpressionException xpee)

      { // swallow errors caused by uninitialized variable }

      }

      xpathStr equals:
      bpel:doXslTransform("1.0.1/some.xsl", $Variable.body, "someParameter", $OtherVariable.body, "someParameter2", $SwsHeaderRQ, "someParameter3", true(), "someXpathParameter", $XPath)

      The result of extractFunctionExprs(xpathStr) is a list with one element:

      bpel:doXslTransform("1.0.1/some.xsl", $Variable.body, "someParameter", $OtherVariable.body, "someParameter2", $SwsHeaderRQ, "someParameter3", true()

      but it should be the same as xpathStr.

      So the results is that Line 170 throws an exception:

      Caused by: net.sf.saxon.trans.XPathException: XPath syntax error at char 149 in

      {...derRQ, "someParameter3", tru...}:
      expected ")", found "<eof>"

      What is more the application doesn't show a stractrace:

      2010-06-04 11:06:10,254 [Timer-1] DEBUG org.apache.ode.bpel.elang.xpath20.compiler.XPath20ExpressionCompilerBPEL20 - javax.xml.xpath.XPathExpressionException

      because the exception is logged this way:
      __log.debug(e);

      but it should be
      __log.debug("some message", e);


      The exception:

      javax.xml.xpath.XPathExpressionException
      at net.sf.saxon.xpath.XPathEvaluator.compile(XPathEvaluator.java:403)
      at org.apache.ode.bpel.elang.xpath20.compiler.XPath20ExpressionCompilerImpl.doJaxpCompile(XPath20ExpressionCompilerImpl.java:170)
      at org.apache.ode.bpel.elang.xpath20.compiler.XPath20ExpressionCompilerImpl._compile(XPath20ExpressionCompilerImpl.java:124)
      at org.apache.ode.bpel.elang.xpath20.compiler.XPath20ExpressionCompilerImpl.compile(XPath20ExpressionCompilerImpl.java:106)
      at org.apache.ode.bpel.compiler.BpelCompiler.compileExpr(BpelCompiler.java:574)
      at org.apache.ode.bpel.compiler.BpelCompiler.compileExpr(BpelCompiler.java:554)
      at org.apache.ode.bpel.compiler.AssignGenerator.compileFrom(AssignGenerator.java:194)
      at org.apache.ode.bpel.compiler.AssignGenerator.compile(AssignGenerator.java:82)
      at org.apache.ode.bpel.compiler.BpelCompiler$7.run(BpelCompiler.java:961)
      at org.apache.ode.bpel.compiler.BpelCompiler.compile(BpelCompiler.java:1127)
      at org.apache.ode.bpel.compiler.BpelCompiler.compileActivity(BpelCompiler.java:957)
      at org.apache.ode.bpel.compiler.BpelCompiler.compile(BpelCompiler.java:906)
      at org.apache.ode.bpel.compiler.SequenceGenerator.compileChildren(SequenceGenerator.java:54)
      at org.apache.ode.bpel.compiler.SequenceGenerator.compile(SequenceGenerator.java:45)
      at org.apache.ode.bpel.compiler.BpelCompiler$7.run(BpelCompiler.java:961)
      at org.apache.ode.bpel.compiler.BpelCompiler.compile(BpelCompiler.java:1127)
      at org.apache.ode.bpel.compiler.BpelCompiler.compileActivity(BpelCompiler.java:957)
      at org.apache.ode.bpel.compiler.BpelCompiler.compile(BpelCompiler.java:906)
      at org.apache.ode.bpel.compiler.IfGenerator.compile(IfGenerator.java:52)
      at org.apache.ode.bpel.compiler.BpelCompiler$7.run(BpelCompiler.java:961)
      at org.apache.ode.bpel.compiler.BpelCompiler.compile(BpelCompiler.java:1127)
      at org.apache.ode.bpel.compiler.BpelCompiler.compileActivity(BpelCompiler.java:957)
      at org.apache.ode.bpel.compiler.BpelCompiler.compile(BpelCompiler.java:906)
      at org.apache.ode.bpel.compiler.SequenceGenerator.compileChildren(SequenceGenerator.java:54)
      at org.apache.ode.bpel.compiler.SequenceGenerator.compile(SequenceGenerator.java:45)
      at org.apache.ode.bpel.compiler.BpelCompiler$7.run(BpelCompiler.java:961)
      at org.apache.ode.bpel.compiler.BpelCompiler.compile(BpelCompiler.java:1127)
      at org.apache.ode.bpel.compiler.BpelCompiler.compileActivity(BpelCompiler.java:957)
      at org.apache.ode.bpel.compiler.BpelCompiler.compile(BpelCompiler.java:906)
      at org.apache.ode.bpel.compiler.BpelCompiler$6.run(BpelCompiler.java:941)
      at org.apache.ode.bpel.compiler.BpelCompiler$8.run(BpelCompiler.java:1217)
      at org.apache.ode.bpel.compiler.BpelCompiler.compile(BpelCompiler.java:1127)
      at org.apache.ode.bpel.compiler.BpelCompiler.compileScope(BpelCompiler.java:1167)
      at org.apache.ode.bpel.compiler.BpelCompiler.compileSLC(BpelCompiler.java:930)
      at org.apache.ode.bpel.compiler.BpelCompiler.compile(BpelCompiler.java:906)
      at org.apache.ode.bpel.compiler.SequenceGenerator.compileChildren(SequenceGenerator.java:54)
      at org.apache.ode.bpel.compiler.SequenceGenerator.compile(SequenceGenerator.java:45)
      at org.apache.ode.bpel.compiler.BpelCompiler$7.run(BpelCompiler.java:961)
      at org.apache.ode.bpel.compiler.BpelCompiler.compile(BpelCompiler.java:1127)
      at org.apache.ode.bpel.compiler.BpelCompiler.compileActivity(BpelCompiler.java:957)
      at org.apache.ode.bpel.compiler.BpelCompiler.compile(BpelCompiler.java:906)
      at org.apache.ode.bpel.compiler.BpelCompiler$5.run(BpelCompiler.java:760)
      at org.apache.ode.bpel.compiler.BpelCompiler$8.run(BpelCompiler.java:1217)
      at org.apache.ode.bpel.compiler.BpelCompiler.compile(BpelCompiler.java:1127)
      at org.apache.ode.bpel.compiler.BpelCompiler.compileScope(BpelCompiler.java:1167)
      at org.apache.ode.bpel.compiler.BpelCompiler.compile(BpelCompiler.java:740)
      at org.apache.ode.bpel.compiler.BpelC.compile(BpelC.java:263)
      at org.apache.ode.bpel.compiler.BpelC.compile(BpelC.java:333)
      at org.apache.ode.store.DeploymentUnitDir$5.run(DeploymentUnitDir.java:213)
      at org.apache.ode.utils.InternPool.runBlock(InternPool.java:57)
      at org.apache.ode.store.DeploymentUnitDir.compile(DeploymentUnitDir.java:210)
      at org.apache.ode.store.DeploymentUnitDir.compile(DeploymentUnitDir.java:171)
      at org.apache.ode.store.ProcessStoreImpl.deploy(ProcessStoreImpl.java:200)
      at org.apache.ode.store.ProcessStoreImpl.deploy(ProcessStoreImpl.java:164)
      at org.apache.ode.jbi.OdeServiceUnit.deploy(OdeServiceUnit.java:74)
      at org.apache.ode.jbi.OdeSUManager.deploy(OdeSUManager.java:59)
      at org.apache.servicemix.jbi.framework.DeploymentService.deployServiceAssembly(DeploymentService.java:520)
      at org.apache.servicemix.jbi.framework.AutoDeploymentService.updateServiceAssembly(AutoDeploymentService.java:349)
      at org.apache.servicemix.jbi.framework.AutoDeploymentService.updateArchive(AutoDeploymentService.java:255)
      at org.apache.servicemix.jbi.framework.AutoDeploymentService.monitorDirectory(AutoDeploymentService.java:658)
      at org.apache.servicemix.jbi.framework.AutoDeploymentService.access$800(AutoDeploymentService.java:63)
      at org.apache.servicemix.jbi.framework.AutoDeploymentService$1.run(AutoDeploymentService.java:622)
      at java.util.TimerThread.mainLoop(Timer.java:512)
      at java.util.TimerThread.run(Timer.java:462)
      Caused by: net.sf.saxon.trans.XPathException: XPath syntax error at char 149 in {...derRQ, "someParameter3", tru...}

      :
      expected ")", found "<eof>"
      at net.sf.saxon.expr.ExpressionParser.grumble(ExpressionParser.java:149)
      at net.sf.saxon.expr.ExpressionParser.grumble(ExpressionParser.java:125)
      at net.sf.saxon.expr.ExpressionParser.expect(ExpressionParser.java:113)
      at net.sf.saxon.expr.ExpressionParser.parseFunctionCall(ExpressionParser.java:1787)
      at net.sf.saxon.expr.ExpressionParser.parseBasicStep(ExpressionParser.java:1307)
      at net.sf.saxon.expr.ExpressionParser.parseStepExpression(ExpressionParser.java:1213)
      at net.sf.saxon.expr.ExpressionParser.parseRelativePath(ExpressionParser.java:1151)
      at net.sf.saxon.expr.ExpressionParser.parsePathExpression(ExpressionParser.java:1137)
      at net.sf.saxon.expr.ExpressionParser.parseUnaryExpression(ExpressionParser.java:1026)
      at net.sf.saxon.expr.ExpressionParser.parseCastExpression(ExpressionParser.java:691)
      at net.sf.saxon.expr.ExpressionParser.parseCastableExpression(ExpressionParser.java:646)
      at net.sf.saxon.expr.ExpressionParser.parseTreatExpression(ExpressionParser.java:627)
      at net.sf.saxon.expr.ExpressionParser.parseInstanceOfExpression(ExpressionParser.java:609)
      at net.sf.saxon.expr.ExpressionParser.parseIntersectExpression(ExpressionParser.java:1059)
      at net.sf.saxon.expr.ExpressionParser.parseUnionExpression(ExpressionParser.java:1041)
      at net.sf.saxon.expr.ExpressionParser.parseMultiplicativeExpression(ExpressionParser.java:978)
      at net.sf.saxon.expr.ExpressionParser.parseAdditiveExpression(ExpressionParser.java:958)
      at net.sf.saxon.expr.ExpressionParser.parseRangeExpression(ExpressionParser.java:876)
      at net.sf.saxon.expr.ExpressionParser.parseComparisonExpression(ExpressionParser.java:826)
      at net.sf.saxon.expr.ExpressionParser.parseAndExpression(ExpressionParser.java:423)
      at net.sf.saxon.expr.ExpressionParser.parseOrExpression(ExpressionParser.java:405)
      at net.sf.saxon.expr.ExpressionParser.parseExprSingle(ExpressionParser.java:354)
      at net.sf.saxon.expr.ExpressionParser.parseExpression(ExpressionParser.java:306)
      at net.sf.saxon.expr.ExpressionParser.parse(ExpressionParser.java:228)
      at net.sf.saxon.expr.ExpressionTool.make(ExpressionTool.java:73)
      at net.sf.saxon.xpath.XPathEvaluator.createExpressionInternal(XPathEvaluator.java:222)
      at net.sf.saxon.xpath.XPathEvaluator.compile(XPathEvaluator.java:401)
      ... 63 more

      The whole log:

      2010-06-04 11:06:10,051 [Timer-1] DEBUG org.apache.ode.bpel.elang.xpath20.compiler.XPath20ExpressionCompilerBPEL20 - Compiling expression bpel:doXslTransform("1.0.1/some.xsl", $Variable.body, "someParameter", $OtherVariable.body, "someParameter2", $SwsHeaderRQ, "someParameter3", true(), "someXpathParameter", $XPath)
      2010-06-04 11:06:10,067 [Timer-1] DEBUG org.apache.ode.bpel.compiler.DefaultResourceFinder - openResource: uri=1.0.1/some.xsl relativeDir=C:\pathToFuse-3.4.0.5\data\smx\service-assemblies\some-process-sa\version_1\sus\OdeBpelEngine\some-process-ode-su absoluteDir=C:\pathToFuse-3.4.0.5\data\smx\service-assemblies\some-process-sa\version_1\sus\OdeBpelEngine\some-process-ode-su
      2010-06-04 11:06:10,114 [Timer-1] DEBUG org.apache.ode.bpel.compiler.DefaultResourceFinder - openResource: uri=SwsHeaderPopuler.xsl relativeDir=C:\pathToFuse-3.4.0.5\data\smx\service-assemblies\some-process-sa\version_1\sus\OdeBpelEngine\some-process-ode-su absoluteDir=C:\pathToFuse-3.4.0.5\data\smx\service-assemblies\some-process-sa\version_1\sus\OdeBpelEngine\some-process-ode-su
      2010-06-04 11:06:10,254 [Timer-1] DEBUG org.apache.ode.bpel.elang.xpath20.compiler.XPath20ExpressionCompilerBPEL20 - javax.xml.xpath.XPathExpressionException
      2010-06-04 11:06:10,254 [Timer-1] INFO org.apache.ode.bpel.elang.xpath20.compiler.XPath20ExpressionCompilerBPEL20 - Couldn't validate properly expression bpel:doXslTransform("1.0.1/some.xsl", $Variable.body, "someParameter", $OtherVariable.body, "someParameter2", $SwsHeaderRQ, "someParameter3", true(), "someXpathParameter", $XPath)
      2010-06-04 11:06:10,254 [Timer-1] DEBUG org.apache.ode.bpel.compiler.AssignGenerator - verifying copy: {OCopy {VarRef {Variable __PROCESS_SCOPE:ProcessNameProcess1.0.1.ProcessNameResponse:OMessageVarType#10(

      {https://someNamespace.com/some}

      ProcessNameOutput)}.body}={OXPath10Expression bpel:doXslTransform("1.0.1/some.xsl", $Variable.body, "someParameter", $OtherVariable.body, "someParameter2", $SwsHeaderRQ, "someParameter3", true(), "someXpathParameter", $XPath)}}
      2010-06-04 11:06:10,254 [Timer-1] DEBUG org.apache.ode.bpel.compiler.AssignGenerator - Copy verified OK: {OCopy {VarRef {Variable __PROCESS_SCOPE:ProcessNameProcess1.0.1.ProcessNameResponse:OMessageVarType#10(

      {https://someNamespace.com/some}

      ProcessNameOutput)}.body}=

      {OXPath10Expression bpel:doXslTransform("1.0.1/some.xsl", $Variable.body, "someParameter", $OtherVariable.body, "someParameter2", $SwsHeaderRQ, "someParameter3", true(), "someXpathParameter", $XPath)}
      1. ode-840-v1.txt
        4 kB
        David Carver
      2. ode-bpel-compiler-1.3.x-SNAPSHOT.jar
        298 kB
        David Carver
      3. ODE-840.patch
        4 kB
        Jayant Vaish

        Activity

        Jayant Vaish made changes -
        Attachment ODE-840.patch [ 12522781 ]
        Jayant Vaish made changes -
        Attachment ODE-840.patch [ 12522781 ]
        Jayant Vaish made changes -
        Attachment ODE-840.patch [ 12522780 ]
        Mateusz Nowakowski made changes -
        Status Open [ 1 ] Resolved [ 5 ]
        Resolution Fixed [ 1 ]
        David Carver made changes -
        Attachment ode-bpel-compiler-1.3.x-SNAPSHOT.jar [ 12446354 ]
        David Carver made changes -
        Attachment ode-840-v1.txt [ 12446353 ]
        Mateusz Nowakowski made changes -
        Field Original Value New Value
        Description org.apache.ode.bpel.elang.xpath20.compiler.XPath20ExpressionCompilerImpl.doJaxpCompile(OXPath20ExpressionBPEL20 out, Expression source):Line 169-170
                    for (String functionExpr : extractFunctionExprs(xpathStr)) {
                        expr = xpe.compile(functionExpr); //Line: 170 here an exception is thrown
                     try {
                     expr.evaluate(node);
                     } catch (XPathExpressionException xpee) {
                         // swallow errors caused by uninitialized variable
                     }
                    }

        xpathStr equals:
        bpel:doXslTransform("1.0.1/some.xsl", $Variable.body, "someParameter", $OtherVariable.body, "someParameter2", $SwsHeaderRQ, "someParameter3", true(), "someXpathParameter", $XPath)

        The result of extractFunctionExprs(xpathStr) is a list with one element:

        bpel:doXslTransform("1.0.1/some.xsl", $Variable.body, "someParameter", $OtherVariable.body, "someParameter2", $SwsHeaderRQ, "someParameter3", true()

        but it should be the same as xpathStr.


        So the results is that Line 170 throws an exception:

        Caused by: net.sf.saxon.trans.XPathException: XPath syntax error at char 149 in {...derRQ, "someParameter3", tru...}:
            expected ")", found "<eof>"



        javax.xml.xpath.XPathExpressionException
                at net.sf.saxon.xpath.XPathEvaluator.compile(XPathEvaluator.java:403)
                at org.apache.ode.bpel.elang.xpath20.compiler.XPath20ExpressionCompilerImpl.doJaxpCompile(XPath20ExpressionCompilerImpl.java:170)
                at org.apache.ode.bpel.elang.xpath20.compiler.XPath20ExpressionCompilerImpl._compile(XPath20ExpressionCompilerImpl.java:124)
                at org.apache.ode.bpel.elang.xpath20.compiler.XPath20ExpressionCompilerImpl.compile(XPath20ExpressionCompilerImpl.java:106)
                at org.apache.ode.bpel.compiler.BpelCompiler.compileExpr(BpelCompiler.java:574)
                at org.apache.ode.bpel.compiler.BpelCompiler.compileExpr(BpelCompiler.java:554)
                at org.apache.ode.bpel.compiler.AssignGenerator.compileFrom(AssignGenerator.java:194)
                at org.apache.ode.bpel.compiler.AssignGenerator.compile(AssignGenerator.java:82)
                at org.apache.ode.bpel.compiler.BpelCompiler$7.run(BpelCompiler.java:961)
                at org.apache.ode.bpel.compiler.BpelCompiler.compile(BpelCompiler.java:1127)
                at org.apache.ode.bpel.compiler.BpelCompiler.compileActivity(BpelCompiler.java:957)
                at org.apache.ode.bpel.compiler.BpelCompiler.compile(BpelCompiler.java:906)
                at org.apache.ode.bpel.compiler.SequenceGenerator.compileChildren(SequenceGenerator.java:54)
                at org.apache.ode.bpel.compiler.SequenceGenerator.compile(SequenceGenerator.java:45)
                at org.apache.ode.bpel.compiler.BpelCompiler$7.run(BpelCompiler.java:961)
                at org.apache.ode.bpel.compiler.BpelCompiler.compile(BpelCompiler.java:1127)
                at org.apache.ode.bpel.compiler.BpelCompiler.compileActivity(BpelCompiler.java:957)
                at org.apache.ode.bpel.compiler.BpelCompiler.compile(BpelCompiler.java:906)
                at org.apache.ode.bpel.compiler.IfGenerator.compile(IfGenerator.java:52)
                at org.apache.ode.bpel.compiler.BpelCompiler$7.run(BpelCompiler.java:961)
                at org.apache.ode.bpel.compiler.BpelCompiler.compile(BpelCompiler.java:1127)
                at org.apache.ode.bpel.compiler.BpelCompiler.compileActivity(BpelCompiler.java:957)
                at org.apache.ode.bpel.compiler.BpelCompiler.compile(BpelCompiler.java:906)
                at org.apache.ode.bpel.compiler.SequenceGenerator.compileChildren(SequenceGenerator.java:54)
                at org.apache.ode.bpel.compiler.SequenceGenerator.compile(SequenceGenerator.java:45)
                at org.apache.ode.bpel.compiler.BpelCompiler$7.run(BpelCompiler.java:961)
                at org.apache.ode.bpel.compiler.BpelCompiler.compile(BpelCompiler.java:1127)
                at org.apache.ode.bpel.compiler.BpelCompiler.compileActivity(BpelCompiler.java:957)
                at org.apache.ode.bpel.compiler.BpelCompiler.compile(BpelCompiler.java:906)
                at org.apache.ode.bpel.compiler.BpelCompiler$6.run(BpelCompiler.java:941)
                at org.apache.ode.bpel.compiler.BpelCompiler$8.run(BpelCompiler.java:1217)
                at org.apache.ode.bpel.compiler.BpelCompiler.compile(BpelCompiler.java:1127)
                at org.apache.ode.bpel.compiler.BpelCompiler.compileScope(BpelCompiler.java:1167)
                at org.apache.ode.bpel.compiler.BpelCompiler.compileSLC(BpelCompiler.java:930)
                at org.apache.ode.bpel.compiler.BpelCompiler.compile(BpelCompiler.java:906)
                at org.apache.ode.bpel.compiler.SequenceGenerator.compileChildren(SequenceGenerator.java:54)
                at org.apache.ode.bpel.compiler.SequenceGenerator.compile(SequenceGenerator.java:45)
                at org.apache.ode.bpel.compiler.BpelCompiler$7.run(BpelCompiler.java:961)
                at org.apache.ode.bpel.compiler.BpelCompiler.compile(BpelCompiler.java:1127)
                at org.apache.ode.bpel.compiler.BpelCompiler.compileActivity(BpelCompiler.java:957)
                at org.apache.ode.bpel.compiler.BpelCompiler.compile(BpelCompiler.java:906)
                at org.apache.ode.bpel.compiler.BpelCompiler$5.run(BpelCompiler.java:760)
                at org.apache.ode.bpel.compiler.BpelCompiler$8.run(BpelCompiler.java:1217)
                at org.apache.ode.bpel.compiler.BpelCompiler.compile(BpelCompiler.java:1127)
                at org.apache.ode.bpel.compiler.BpelCompiler.compileScope(BpelCompiler.java:1167)
                at org.apache.ode.bpel.compiler.BpelCompiler.compile(BpelCompiler.java:740)
                at org.apache.ode.bpel.compiler.BpelC.compile(BpelC.java:263)
                at org.apache.ode.bpel.compiler.BpelC.compile(BpelC.java:333)
                at org.apache.ode.store.DeploymentUnitDir$5.run(DeploymentUnitDir.java:213)
                at org.apache.ode.utils.InternPool.runBlock(InternPool.java:57)
                at org.apache.ode.store.DeploymentUnitDir.compile(DeploymentUnitDir.java:210)
                at org.apache.ode.store.DeploymentUnitDir.compile(DeploymentUnitDir.java:171)
                at org.apache.ode.store.ProcessStoreImpl.deploy(ProcessStoreImpl.java:200)
                at org.apache.ode.store.ProcessStoreImpl.deploy(ProcessStoreImpl.java:164)
                at org.apache.ode.jbi.OdeServiceUnit.deploy(OdeServiceUnit.java:74)
                at org.apache.ode.jbi.OdeSUManager.deploy(OdeSUManager.java:59)
                at org.apache.servicemix.jbi.framework.DeploymentService.deployServiceAssembly(DeploymentService.java:520)
                at org.apache.servicemix.jbi.framework.AutoDeploymentService.updateServiceAssembly(AutoDeploymentService.java:349)
                at org.apache.servicemix.jbi.framework.AutoDeploymentService.updateArchive(AutoDeploymentService.java:255)
                at org.apache.servicemix.jbi.framework.AutoDeploymentService.monitorDirectory(AutoDeploymentService.java:658)
                at org.apache.servicemix.jbi.framework.AutoDeploymentService.access$800(AutoDeploymentService.java:63)
                at org.apache.servicemix.jbi.framework.AutoDeploymentService$1.run(AutoDeploymentService.java:622)
                at java.util.TimerThread.mainLoop(Timer.java:512)
                at java.util.TimerThread.run(Timer.java:462)
        Caused by: net.sf.saxon.trans.XPathException: XPath syntax error at char 149 in {...derRQ, "someParameter3", tru...}:
            expected ")", found "<eof>"
                at net.sf.saxon.expr.ExpressionParser.grumble(ExpressionParser.java:149)
                at net.sf.saxon.expr.ExpressionParser.grumble(ExpressionParser.java:125)
                at net.sf.saxon.expr.ExpressionParser.expect(ExpressionParser.java:113)
                at net.sf.saxon.expr.ExpressionParser.parseFunctionCall(ExpressionParser.java:1787)
                at net.sf.saxon.expr.ExpressionParser.parseBasicStep(ExpressionParser.java:1307)
                at net.sf.saxon.expr.ExpressionParser.parseStepExpression(ExpressionParser.java:1213)
                at net.sf.saxon.expr.ExpressionParser.parseRelativePath(ExpressionParser.java:1151)
                at net.sf.saxon.expr.ExpressionParser.parsePathExpression(ExpressionParser.java:1137)
                at net.sf.saxon.expr.ExpressionParser.parseUnaryExpression(ExpressionParser.java:1026)
                at net.sf.saxon.expr.ExpressionParser.parseCastExpression(ExpressionParser.java:691)
                at net.sf.saxon.expr.ExpressionParser.parseCastableExpression(ExpressionParser.java:646)
                at net.sf.saxon.expr.ExpressionParser.parseTreatExpression(ExpressionParser.java:627)
                at net.sf.saxon.expr.ExpressionParser.parseInstanceOfExpression(ExpressionParser.java:609)
                at net.sf.saxon.expr.ExpressionParser.parseIntersectExpression(ExpressionParser.java:1059)
                at net.sf.saxon.expr.ExpressionParser.parseUnionExpression(ExpressionParser.java:1041)
                at net.sf.saxon.expr.ExpressionParser.parseMultiplicativeExpression(ExpressionParser.java:978)
                at net.sf.saxon.expr.ExpressionParser.parseAdditiveExpression(ExpressionParser.java:958)
                at net.sf.saxon.expr.ExpressionParser.parseRangeExpression(ExpressionParser.java:876)
                at net.sf.saxon.expr.ExpressionParser.parseComparisonExpression(ExpressionParser.java:826)
                at net.sf.saxon.expr.ExpressionParser.parseAndExpression(ExpressionParser.java:423)
                at net.sf.saxon.expr.ExpressionParser.parseOrExpression(ExpressionParser.java:405)
                at net.sf.saxon.expr.ExpressionParser.parseExprSingle(ExpressionParser.java:354)
                at net.sf.saxon.expr.ExpressionParser.parseExpression(ExpressionParser.java:306)
                at net.sf.saxon.expr.ExpressionParser.parse(ExpressionParser.java:228)
                at net.sf.saxon.expr.ExpressionTool.make(ExpressionTool.java:73)
                at net.sf.saxon.xpath.XPathEvaluator.createExpressionInternal(XPathEvaluator.java:222)
                at net.sf.saxon.xpath.XPathEvaluator.compile(XPathEvaluator.java:401)
                ... 63 more

        The whole log:

        2010-06-04 11:06:10,051 [Timer-1] DEBUG org.apache.ode.bpel.elang.xpath20.compiler.XPath20ExpressionCompilerBPEL20 - Compiling expression bpel:doXslTransform("1.0.1/some.xsl", $Variable.body, "someParameter", $OtherVariable.body, "someParameter2", $SwsHeaderRQ, "someParameter3", true(), "someXpathParameter", $XPath)
        2010-06-04 11:06:10,067 [Timer-1] DEBUG org.apache.ode.bpel.compiler.DefaultResourceFinder - openResource: uri=1.0.1/some.xsl relativeDir=C:\pathToFuse-3.4.0.5\data\smx\service-assemblies\some-process-sa\version_1\sus\OdeBpelEngine\some-process-ode-su absoluteDir=C:\pathToFuse-3.4.0.5\data\smx\service-assemblies\some-process-sa\version_1\sus\OdeBpelEngine\some-process-ode-su
        2010-06-04 11:06:10,114 [Timer-1] DEBUG org.apache.ode.bpel.compiler.DefaultResourceFinder - openResource: uri=SwsHeaderPopuler.xsl relativeDir=C:\pathToFuse-3.4.0.5\data\smx\service-assemblies\some-process-sa\version_1\sus\OdeBpelEngine\some-process-ode-su absoluteDir=C:\pathToFuse-3.4.0.5\data\smx\service-assemblies\some-process-sa\version_1\sus\OdeBpelEngine\some-process-ode-su
        2010-06-04 11:06:10,254 [Timer-1] DEBUG org.apache.ode.bpel.elang.xpath20.compiler.XPath20ExpressionCompilerBPEL20 - javax.xml.xpath.XPathExpressionException
        2010-06-04 11:06:10,254 [Timer-1] INFO org.apache.ode.bpel.elang.xpath20.compiler.XPath20ExpressionCompilerBPEL20 - Couldn't validate properly expression bpel:doXslTransform("1.0.1/some.xsl", $Variable.body, "someParameter", $OtherVariable.body, "someParameter2", $SwsHeaderRQ, "someParameter3", true(), "someXpathParameter", $XPath)
        2010-06-04 11:06:10,254 [Timer-1] DEBUG org.apache.ode.bpel.compiler.AssignGenerator - verifying copy: {OCopy {VarRef {Variable __PROCESS_SCOPE:ProcessNameProcess1.0.1.ProcessNameResponse:OMessageVarType#10({https://someNamespace.com/some}ProcessNameOutput)}.body}={OXPath10Expression bpel:doXslTransform("1.0.1/some.xsl", $Variable.body, "someParameter", $OtherVariable.body, "someParameter2", $SwsHeaderRQ, "someParameter3", true(), "someXpathParameter", $XPath)}}
        2010-06-04 11:06:10,254 [Timer-1] DEBUG org.apache.ode.bpel.compiler.AssignGenerator - Copy verified OK: {OCopy {VarRef {Variable __PROCESS_SCOPE:ProcessNameProcess1.0.1.ProcessNameResponse:OMessageVarType#10({https://someNamespace.com/some}ProcessNameOutput)}.body}={OXPath10Expression bpel:doXslTransform("1.0.1/some.xsl", $Variable.body, "someParameter", $OtherVariable.body, "someParameter2", $SwsHeaderRQ, "someParameter3", true(), "someXpathParameter", $XPath)}
        org.apache.ode.bpel.elang.xpath20.compiler.XPath20ExpressionCompilerImpl.doJaxpCompile(OXPath20ExpressionBPEL20 out, Expression source):Line 169-170
                    for (String functionExpr : extractFunctionExprs(xpathStr)) {
                        expr = xpe.compile(functionExpr); //Line: 170 here an exception is thrown
                     try {
                     expr.evaluate(node);
                     } catch (XPathExpressionException xpee) {
                         // swallow errors caused by uninitialized variable
                     }
                    }

        xpathStr equals:
        bpel:doXslTransform("1.0.1/some.xsl", $Variable.body, "someParameter", $OtherVariable.body, "someParameter2", $SwsHeaderRQ, "someParameter3", true(), "someXpathParameter", $XPath)

        The result of extractFunctionExprs(xpathStr) is a list with one element:

        bpel:doXslTransform("1.0.1/some.xsl", $Variable.body, "someParameter", $OtherVariable.body, "someParameter2", $SwsHeaderRQ, "someParameter3", true()

        but it should be the same as xpathStr.


        So the results is that Line 170 throws an exception:

        Caused by: net.sf.saxon.trans.XPathException: XPath syntax error at char 149 in {...derRQ, "someParameter3", tru...}:
            expected ")", found "<eof>"

        What is more the application doesn't show a stractrace:

        2010-06-04 11:06:10,254 [Timer-1] DEBUG org.apache.ode.bpel.elang.xpath20.compiler.XPath20ExpressionCompilerBPEL20 - javax.xml.xpath.XPathExpressionException

         because the exception is logged this way:
        __log.debug(e);

        but it should be
        __log.debug("some message", e);


        The exception:

        javax.xml.xpath.XPathExpressionException
                at net.sf.saxon.xpath.XPathEvaluator.compile(XPathEvaluator.java:403)
                at org.apache.ode.bpel.elang.xpath20.compiler.XPath20ExpressionCompilerImpl.doJaxpCompile(XPath20ExpressionCompilerImpl.java:170)
                at org.apache.ode.bpel.elang.xpath20.compiler.XPath20ExpressionCompilerImpl._compile(XPath20ExpressionCompilerImpl.java:124)
                at org.apache.ode.bpel.elang.xpath20.compiler.XPath20ExpressionCompilerImpl.compile(XPath20ExpressionCompilerImpl.java:106)
                at org.apache.ode.bpel.compiler.BpelCompiler.compileExpr(BpelCompiler.java:574)
                at org.apache.ode.bpel.compiler.BpelCompiler.compileExpr(BpelCompiler.java:554)
                at org.apache.ode.bpel.compiler.AssignGenerator.compileFrom(AssignGenerator.java:194)
                at org.apache.ode.bpel.compiler.AssignGenerator.compile(AssignGenerator.java:82)
                at org.apache.ode.bpel.compiler.BpelCompiler$7.run(BpelCompiler.java:961)
                at org.apache.ode.bpel.compiler.BpelCompiler.compile(BpelCompiler.java:1127)
                at org.apache.ode.bpel.compiler.BpelCompiler.compileActivity(BpelCompiler.java:957)
                at org.apache.ode.bpel.compiler.BpelCompiler.compile(BpelCompiler.java:906)
                at org.apache.ode.bpel.compiler.SequenceGenerator.compileChildren(SequenceGenerator.java:54)
                at org.apache.ode.bpel.compiler.SequenceGenerator.compile(SequenceGenerator.java:45)
                at org.apache.ode.bpel.compiler.BpelCompiler$7.run(BpelCompiler.java:961)
                at org.apache.ode.bpel.compiler.BpelCompiler.compile(BpelCompiler.java:1127)
                at org.apache.ode.bpel.compiler.BpelCompiler.compileActivity(BpelCompiler.java:957)
                at org.apache.ode.bpel.compiler.BpelCompiler.compile(BpelCompiler.java:906)
                at org.apache.ode.bpel.compiler.IfGenerator.compile(IfGenerator.java:52)
                at org.apache.ode.bpel.compiler.BpelCompiler$7.run(BpelCompiler.java:961)
                at org.apache.ode.bpel.compiler.BpelCompiler.compile(BpelCompiler.java:1127)
                at org.apache.ode.bpel.compiler.BpelCompiler.compileActivity(BpelCompiler.java:957)
                at org.apache.ode.bpel.compiler.BpelCompiler.compile(BpelCompiler.java:906)
                at org.apache.ode.bpel.compiler.SequenceGenerator.compileChildren(SequenceGenerator.java:54)
                at org.apache.ode.bpel.compiler.SequenceGenerator.compile(SequenceGenerator.java:45)
                at org.apache.ode.bpel.compiler.BpelCompiler$7.run(BpelCompiler.java:961)
                at org.apache.ode.bpel.compiler.BpelCompiler.compile(BpelCompiler.java:1127)
                at org.apache.ode.bpel.compiler.BpelCompiler.compileActivity(BpelCompiler.java:957)
                at org.apache.ode.bpel.compiler.BpelCompiler.compile(BpelCompiler.java:906)
                at org.apache.ode.bpel.compiler.BpelCompiler$6.run(BpelCompiler.java:941)
                at org.apache.ode.bpel.compiler.BpelCompiler$8.run(BpelCompiler.java:1217)
                at org.apache.ode.bpel.compiler.BpelCompiler.compile(BpelCompiler.java:1127)
                at org.apache.ode.bpel.compiler.BpelCompiler.compileScope(BpelCompiler.java:1167)
                at org.apache.ode.bpel.compiler.BpelCompiler.compileSLC(BpelCompiler.java:930)
                at org.apache.ode.bpel.compiler.BpelCompiler.compile(BpelCompiler.java:906)
                at org.apache.ode.bpel.compiler.SequenceGenerator.compileChildren(SequenceGenerator.java:54)
                at org.apache.ode.bpel.compiler.SequenceGenerator.compile(SequenceGenerator.java:45)
                at org.apache.ode.bpel.compiler.BpelCompiler$7.run(BpelCompiler.java:961)
                at org.apache.ode.bpel.compiler.BpelCompiler.compile(BpelCompiler.java:1127)
                at org.apache.ode.bpel.compiler.BpelCompiler.compileActivity(BpelCompiler.java:957)
                at org.apache.ode.bpel.compiler.BpelCompiler.compile(BpelCompiler.java:906)
                at org.apache.ode.bpel.compiler.BpelCompiler$5.run(BpelCompiler.java:760)
                at org.apache.ode.bpel.compiler.BpelCompiler$8.run(BpelCompiler.java:1217)
                at org.apache.ode.bpel.compiler.BpelCompiler.compile(BpelCompiler.java:1127)
                at org.apache.ode.bpel.compiler.BpelCompiler.compileScope(BpelCompiler.java:1167)
                at org.apache.ode.bpel.compiler.BpelCompiler.compile(BpelCompiler.java:740)
                at org.apache.ode.bpel.compiler.BpelC.compile(BpelC.java:263)
                at org.apache.ode.bpel.compiler.BpelC.compile(BpelC.java:333)
                at org.apache.ode.store.DeploymentUnitDir$5.run(DeploymentUnitDir.java:213)
                at org.apache.ode.utils.InternPool.runBlock(InternPool.java:57)
                at org.apache.ode.store.DeploymentUnitDir.compile(DeploymentUnitDir.java:210)
                at org.apache.ode.store.DeploymentUnitDir.compile(DeploymentUnitDir.java:171)
                at org.apache.ode.store.ProcessStoreImpl.deploy(ProcessStoreImpl.java:200)
                at org.apache.ode.store.ProcessStoreImpl.deploy(ProcessStoreImpl.java:164)
                at org.apache.ode.jbi.OdeServiceUnit.deploy(OdeServiceUnit.java:74)
                at org.apache.ode.jbi.OdeSUManager.deploy(OdeSUManager.java:59)
                at org.apache.servicemix.jbi.framework.DeploymentService.deployServiceAssembly(DeploymentService.java:520)
                at org.apache.servicemix.jbi.framework.AutoDeploymentService.updateServiceAssembly(AutoDeploymentService.java:349)
                at org.apache.servicemix.jbi.framework.AutoDeploymentService.updateArchive(AutoDeploymentService.java:255)
                at org.apache.servicemix.jbi.framework.AutoDeploymentService.monitorDirectory(AutoDeploymentService.java:658)
                at org.apache.servicemix.jbi.framework.AutoDeploymentService.access$800(AutoDeploymentService.java:63)
                at org.apache.servicemix.jbi.framework.AutoDeploymentService$1.run(AutoDeploymentService.java:622)
                at java.util.TimerThread.mainLoop(Timer.java:512)
                at java.util.TimerThread.run(Timer.java:462)
        Caused by: net.sf.saxon.trans.XPathException: XPath syntax error at char 149 in {...derRQ, "someParameter3", tru...}:
            expected ")", found "<eof>"
                at net.sf.saxon.expr.ExpressionParser.grumble(ExpressionParser.java:149)
                at net.sf.saxon.expr.ExpressionParser.grumble(ExpressionParser.java:125)
                at net.sf.saxon.expr.ExpressionParser.expect(ExpressionParser.java:113)
                at net.sf.saxon.expr.ExpressionParser.parseFunctionCall(ExpressionParser.java:1787)
                at net.sf.saxon.expr.ExpressionParser.parseBasicStep(ExpressionParser.java:1307)
                at net.sf.saxon.expr.ExpressionParser.parseStepExpression(ExpressionParser.java:1213)
                at net.sf.saxon.expr.ExpressionParser.parseRelativePath(ExpressionParser.java:1151)
                at net.sf.saxon.expr.ExpressionParser.parsePathExpression(ExpressionParser.java:1137)
                at net.sf.saxon.expr.ExpressionParser.parseUnaryExpression(ExpressionParser.java:1026)
                at net.sf.saxon.expr.ExpressionParser.parseCastExpression(ExpressionParser.java:691)
                at net.sf.saxon.expr.ExpressionParser.parseCastableExpression(ExpressionParser.java:646)
                at net.sf.saxon.expr.ExpressionParser.parseTreatExpression(ExpressionParser.java:627)
                at net.sf.saxon.expr.ExpressionParser.parseInstanceOfExpression(ExpressionParser.java:609)
                at net.sf.saxon.expr.ExpressionParser.parseIntersectExpression(ExpressionParser.java:1059)
                at net.sf.saxon.expr.ExpressionParser.parseUnionExpression(ExpressionParser.java:1041)
                at net.sf.saxon.expr.ExpressionParser.parseMultiplicativeExpression(ExpressionParser.java:978)
                at net.sf.saxon.expr.ExpressionParser.parseAdditiveExpression(ExpressionParser.java:958)
                at net.sf.saxon.expr.ExpressionParser.parseRangeExpression(ExpressionParser.java:876)
                at net.sf.saxon.expr.ExpressionParser.parseComparisonExpression(ExpressionParser.java:826)
                at net.sf.saxon.expr.ExpressionParser.parseAndExpression(ExpressionParser.java:423)
                at net.sf.saxon.expr.ExpressionParser.parseOrExpression(ExpressionParser.java:405)
                at net.sf.saxon.expr.ExpressionParser.parseExprSingle(ExpressionParser.java:354)
                at net.sf.saxon.expr.ExpressionParser.parseExpression(ExpressionParser.java:306)
                at net.sf.saxon.expr.ExpressionParser.parse(ExpressionParser.java:228)
                at net.sf.saxon.expr.ExpressionTool.make(ExpressionTool.java:73)
                at net.sf.saxon.xpath.XPathEvaluator.createExpressionInternal(XPathEvaluator.java:222)
                at net.sf.saxon.xpath.XPathEvaluator.compile(XPathEvaluator.java:401)
                ... 63 more

        The whole log:

        2010-06-04 11:06:10,051 [Timer-1] DEBUG org.apache.ode.bpel.elang.xpath20.compiler.XPath20ExpressionCompilerBPEL20 - Compiling expression bpel:doXslTransform("1.0.1/some.xsl", $Variable.body, "someParameter", $OtherVariable.body, "someParameter2", $SwsHeaderRQ, "someParameter3", true(), "someXpathParameter", $XPath)
        2010-06-04 11:06:10,067 [Timer-1] DEBUG org.apache.ode.bpel.compiler.DefaultResourceFinder - openResource: uri=1.0.1/some.xsl relativeDir=C:\pathToFuse-3.4.0.5\data\smx\service-assemblies\some-process-sa\version_1\sus\OdeBpelEngine\some-process-ode-su absoluteDir=C:\pathToFuse-3.4.0.5\data\smx\service-assemblies\some-process-sa\version_1\sus\OdeBpelEngine\some-process-ode-su
        2010-06-04 11:06:10,114 [Timer-1] DEBUG org.apache.ode.bpel.compiler.DefaultResourceFinder - openResource: uri=SwsHeaderPopuler.xsl relativeDir=C:\pathToFuse-3.4.0.5\data\smx\service-assemblies\some-process-sa\version_1\sus\OdeBpelEngine\some-process-ode-su absoluteDir=C:\pathToFuse-3.4.0.5\data\smx\service-assemblies\some-process-sa\version_1\sus\OdeBpelEngine\some-process-ode-su
        2010-06-04 11:06:10,254 [Timer-1] DEBUG org.apache.ode.bpel.elang.xpath20.compiler.XPath20ExpressionCompilerBPEL20 - javax.xml.xpath.XPathExpressionException
        2010-06-04 11:06:10,254 [Timer-1] INFO org.apache.ode.bpel.elang.xpath20.compiler.XPath20ExpressionCompilerBPEL20 - Couldn't validate properly expression bpel:doXslTransform("1.0.1/some.xsl", $Variable.body, "someParameter", $OtherVariable.body, "someParameter2", $SwsHeaderRQ, "someParameter3", true(), "someXpathParameter", $XPath)
        2010-06-04 11:06:10,254 [Timer-1] DEBUG org.apache.ode.bpel.compiler.AssignGenerator - verifying copy: {OCopy {VarRef {Variable __PROCESS_SCOPE:ProcessNameProcess1.0.1.ProcessNameResponse:OMessageVarType#10({https://someNamespace.com/some}ProcessNameOutput)}.body}={OXPath10Expression bpel:doXslTransform("1.0.1/some.xsl", $Variable.body, "someParameter", $OtherVariable.body, "someParameter2", $SwsHeaderRQ, "someParameter3", true(), "someXpathParameter", $XPath)}}
        2010-06-04 11:06:10,254 [Timer-1] DEBUG org.apache.ode.bpel.compiler.AssignGenerator - Copy verified OK: {OCopy {VarRef {Variable __PROCESS_SCOPE:ProcessNameProcess1.0.1.ProcessNameResponse:OMessageVarType#10({https://someNamespace.com/some}ProcessNameOutput)}.body}={OXPath10Expression bpel:doXslTransform("1.0.1/some.xsl", $Variable.body, "someParameter", $OtherVariable.body, "someParameter2", $SwsHeaderRQ, "someParameter3", true(), "someXpathParameter", $XPath)}
        Mateusz Nowakowski created issue -

          People

          • Assignee:
            Unassigned
            Reporter:
            Mateusz Nowakowski
          • Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved:

              Development