camel-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Charles Moulliard (JIRA)" <j...@apache.org>
Subject [jira] Created: (CAMEL-702) net.sf.saxon.trans.StaticError: XQuery syntax error in ##: generated when several threads are created for a route
Date Fri, 11 Jul 2008 15:40:00 GMT
net.sf.saxon.trans.StaticError: XQuery syntax error in ##: generated when several threads are
created for a route
-----------------------------------------------------------------------------------------------------------------

                 Key: CAMEL-702
                 URL: https://issues.apache.org/activemq/browse/CAMEL-702
             Project: Apache Camel
          Issue Type: Bug
          Components: camel-saxon
    Affects Versions: 1.4.0
         Environment: Win2K / Camel Apache 1.4-SNAPSHOT (11/07/2208)
            Reporter: Charles Moulliard


Hi,

When I configure the following routes to process 10 xml files in a directory , everything
works correctly

A) 

		from("file:///c:/temp/test/?delete=false&lock=true&consumer.delay=500&consumer.initialDelay=10").thread(10)
		.to("bean:authenticate")
				.choice().when(header("authenticated").isEqualTo(true))
					//.to("display")
				    .to("direct:extractDocument")
		.otherwise().to("activemq:queue:rejectedmessages.queue");
		
B) 

			from("direct:extractDocument").thread(1)
			.setHeader("responder").xpath("//XyZ:Response/text()", String.class, ns)
			.setHeader("channel", "File-Channel")
			
			.to("bean:saveContent")
			.to("xquery:com/myapplication/transformation/in/extract.xquery")
			.to("activemq:queue:A.in.queue");
	}
	
C) 		from("activemq:queue:A.in.queue").thread(10)
		.filter(body().isInstanceOf(String.class))
		.unmarshal(jaxb)
		.to("bean:convert")
		.to("bean:save")
		.to("activemq:queue:A.in.queue");

Here is the log trace

4336937 [Thread Processor] INFO  Authenticate  - Company authenticated
4336937 [Thread Processor] INFO  Authenticate  - Company authenticated
4336937 [Thread Processor] INFO  Authenticate  - Company authenticated
4336937 [Thread Processor] INFO  Authenticate  - Company authenticated
4336937 [Thread Processor] INFO  Authenticate  - Company authenticated
4336937 [Thread Processor] INFO  Authenticate  - Company authenticated
4336937 [Thread Processor] INFO  Authenticate  - Company authenticated
4336937 [Thread Processor] INFO  Authenticate  - Company authenticated
4336937 [Thread Processor] INFO  Authenticate  - Company authenticated
4336937 [Thread Processor] INFO  Authenticate  - Company authenticated
4337359 [Thread Processor] INFO  SaveContent  - Message saved
4338562 [Thread Processor] INFO  SaveContent  - Message saved
4338828 [Thread Processor] INFO  SaveContent  - Message saved
4339062 [Thread Processor] INFO  SaveContent  - Message saved
4339328 [Thread Processor] INFO  SaveContent  - Message saved
4339890 [Thread Processor] INFO  SaveContent  - Message saved
4340312 [Thread Processor] INFO  SaveContent  - Message saved
4340515 [Thread Processor] INFO  SaveContent  - Message saved
4340687 [Thread Processor] INFO  SaveContent  - Message saved
4340750 [Thread Processor] INFO  Convert  - Message send
4340906 [Thread Processor] INFO  SaveContent  - Message saved
4341218 [Thread Processor] INFO  Save  - Order saved
4341328 [Thread Processor] INFO  Convert  - Message send
4341890 [Thread Processor] INFO  Save  - Order saved
4341922 [Thread Processor] INFO  Convert  - Message send
4342672 [Thread Processor] INFO  Save  - Order saved
4342734 [Thread Processor] INFO  Convert  - Message send
4343672 [Thread Processor] INFO  Save  - Order saved
4343718 [Thread Processor] INFO  Convert  - Message send
4344703 [Thread Processor] INFO  Save  - Order saved
4344734 [Thread Processor] INFO  Convert  - Message send
4345937 [Thread Processor] INFO  Save  - Order saved
4345984 [Thread Processor] INFO  Convert  - Message send
4347359 [Thread Processor] INFO  Save  - Order saved
4347375 [Thread Processor] INFO  Convert  - Message send
4349078 [Thread Processor] INFO  Save  - Order saved
4349109 [Thread Processor] INFO  Convert  - Message send
4350859 [Thread Processor] INFO  Save  - Order saved
4350906 [Thread Processor] INFO  Convert  - Message send
4352593 [Thread Processor] INFO  Save  - Order saved

but when I would like to increase the number of threads to execute more than one XQUERY at
a time

B)			from("direct:extractDocument").thread(10)
			.setHeader("responder").xpath("//XyZ:Response/text()", String.class, ns)
			.setHeader("channel", "File-Channel")
			
			.to("bean:saveContent")
			.to("xquery:com/myapplication/transformation/in/extract.xquery")
			.to("activemq:queue:A.in.queue");

 the following error is generated

4315906 [Thread Processor] INFO  com.bravura.babel.server.common.Authenticate  - Company authenticated
4315906 [Thread Processor] INFO  com.bravura.babel.server.common.Authenticate  - Company authenticated
4315906 [Thread Processor] INFO  com.bravura.babel.server.common.Authenticate  - Company authenticated
4315906 [Thread Processor] INFO  com.bravura.babel.server.common.Authenticate  - Company authenticated
4315906 [Thread Processor] INFO  com.bravura.babel.server.common.Authenticate  - Company authenticated
4315906 [Thread Processor] INFO  com.bravura.babel.server.common.Authenticate  - Company authenticated
4315906 [Thread Processor] INFO  com.bravura.babel.server.common.Authenticate  - Company authenticated
4315906 [Thread Processor] INFO  com.bravura.babel.server.common.Authenticate  - Company authenticated
4315906 [Thread Processor] INFO  com.bravura.babel.server.common.Authenticate  - Company authenticated
4315906 [Thread Processor] INFO  com.bravura.babel.server.common.Authenticate  - Company authenticated
4316750 [Thread Processor] INFO  com.bravura.babel.server.common.SaveContent  - Message saved
4316781 [Thread Processor] INFO  com.bravura.babel.server.common.SaveContent  - Message saved
4316781 [Thread Processor] INFO  com.bravura.babel.server.common.SaveContent  - Message saved
4317094 [Thread Processor] INFO  com.bravura.babel.server.common.SaveContent  - Message saved
4317125 [Thread Processor] INFO  com.bravura.babel.server.common.SaveContent  - Message saved
4317172 [Thread Processor] INFO  com.bravura.babel.server.common.SaveContent  - Message saved
4317203 [Thread Processor] INFO  com.bravura.babel.server.common.SaveContent  - Message saved
4317250 [Thread Processor] INFO  com.bravura.babel.server.common.SaveContent  - Message saved
4317281 [Thread Processor] INFO  com.bravura.babel.server.common.SaveContent  - Message saved
4317328 [Thread Processor] INFO  com.bravura.babel.server.common.SaveContent  - Message saved

43Error on line 1 column 0 
  XPST0003: XQuery syntax error in ##:
    Unexpected token "<eof>" in path expression
Error on line 1 column 0 
  XPST0003: XQuery syntax error in ##:
    Unexpected token "<eof>" in path expression
Error on line 1 column 0 
  XPST0003: XQuery syntax error in ##:
    Unexpected token "<eof>" in path expression
Error on line 1 column 0 
  XPST0003: XQuery syntax error in ##:
    Unexpected token "<eof>" in path expression
Error on line 1 column 0 
  XPST0003: XQuery syntax error in ##:
    Unexpected token "<eof>" in path expression
Error on line 1 column 0 
  XPST0003: XQuery syntax error in ##:
    Unexpected token "<eof>" in path expression
Error on line 1 column 0 
  XPST0003: XQuery syntax error in ##:
    Unexpected token "<eof>" in path expression
Error on line 1 column 0 
  XPST0003: XQuery syntax error in ##:
    Unexpected token "<eof>" in path expression
Error on line 1 column 0 
  XPST0003: XQuery syntax error in ##:
    Unexpected token "<eof>" in path expression
18219 [Thread Processor] ERROR org.apache.camel.processor.DeadLetterChannel  - Failed delivery
for exchangeId: ID-dell-charles/4777-1215789902562/0-1. On delivery attempt: 0 caught: org.apache.camel.RuntimeExpressionException:
net.sf.saxon.trans.StaticError: XQuery syntax error in ##:
    Unexpected token "<eof>" in path expression
43org.apache.camel.RuntimeExpressionException: net.sf.saxon.trans.StaticError: XQuery syntax
error in ##:
    Unexpected token "<eof>" in path expression
	at org.apache.camel.component.xquery.XQueryBuilder.evaluate(XQueryBuilder.java:125)
	at org.apache.camel.component.xquery.XQueryBuilder.process(XQueryBuilder.java:89)
	at org.apache.camel.impl.ProcessorEndpoint.onExchange(ProcessorEndpoint.java:92)
	at org.apache.camel.impl.ProcessorEndpoint$1.process(ProcessorEndpoint.java:66)
	at org.apache.camel.impl.converter.AsyncProcessorTypeConverter$ProcessorToAsyncProcessorBridge.process(AsyncProcessorTypeConverter.java:43)
	at org.apache.camel.processor.SendProcessor.process(SendProcessor.java:75)
	at org.apache.camel.processor.Pipeline.process(Pipeline.java:101)
	at org.apache.camel.processor.Pipeline.process(Pipeline.java:85)
	at org.apache.camel.processor.Pipeline.process(Pipeline.java:101)
	at org.apache.camel.processor.Pipeline.access$100(Pipeline.java:40)
	at org.apache.camel.processor.Pipeline$1.done(Pipeline.java:124)
	at org.apache.camel.processor.ThreadProcessor$ProcessCall.run(ThreadProcessor.java:66)
	at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:650)
	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:675)
	at java.lang.Thread.run(Thread.java:595)
Caused by: net.sf.saxon.trans.StaticError: XQuery syntax error in ##:
    Unexpected token "<eof>" in path expression
	at net.sf.saxon.query.QueryParser.grumble(QueryParser.java:323)
	at net.sf.saxon.expr.ExpressionParser.grumble(ExpressionParser.java:136)
	at net.sf.saxon.expr.ExpressionParser.parseBasicStep(ExpressionParser.java:1403)
	at net.sf.saxon.expr.ExpressionParser.parseStepExpression(ExpressionParser.java:1220)
	at net.sf.saxon.expr.ExpressionParser.parseRelativePath(ExpressionParser.java:1160)
	at net.sf.saxon.expr.ExpressionParser.parsePathExpression(ExpressionParser.java:1146)
	at net.sf.saxon.expr.ExpressionParser.parseUnaryExpression(ExpressionParser.java:1025)
	at net.sf.saxon.expr.ExpressionParser.parseCastExpression(ExpressionParser.java:684)
	at net.sf.saxon.expr.ExpressionParser.parseCastableExpression(ExpressionParser.java:639)
	at net.sf.saxon.expr.ExpressionParser.parseTreatExpression(ExpressionParser.java:620)
	at net.sf.saxon.expr.ExpressionParser.parseInstanceOfExpression(ExpressionParser.java:602)
	at net.sf.saxon.expr.ExpressionParser.parseIntersectExpression(ExpressionParser.java:1058)
	at net.sf.saxon.expr.ExpressionParser.parseUnionExpression(ExpressionParser.java:1040)
	at net.sf.saxon.expr.ExpressionParser.parseMultiplicativeExpression(ExpressionParser.java:977)
	at net.sf.saxon.expr.ExpressionParser.parseAdditiveExpression(ExpressionParser.java:957)
	at net.sf.saxon.expr.ExpressionParser.parseRangeExpression(ExpressionParser.java:873)
	at net.sf.saxon.expr.ExpressionParser.parseComparisonExpression(ExpressionParser.java:823)
	at net.sf.saxon.expr.ExpressionParser.parseAndExpression(ExpressionParser.java:414)
	at net.sf.saxon.expr.ExpressionParser.parseOrExpression(ExpressionParser.java:396)
	at net.sf.saxon.expr.ExpressionParser.parseExprSingle(ExpressionParser.java:350)
	at net.sf.saxon.expr.ExpressionParser.parseExpression(ExpressionParser.java:314)
	at net.sf.saxon.query.QueryParser.parseQuery(QueryParser.java:256)
	at net.sf.saxon.query.QueryParser.makeXQueryExpression(QueryParser.java:97)
	at net.sf.saxon.query.StaticQueryContext.compileQuery(StaticQueryContext.java:450)
	at net.sf.saxon.query.StaticQueryContext.compileQuery(StaticQueryContext.java:513)
	at org.apache.camel.component.xquery.XQueryBuilder$3.createQueryExpression(XQueryBuilder.java:216)
	at org.apache.camel.component.xquery.XQueryBuilder.getExpression(XQueryBuilder.java:294)
	at org.apache.camel.component.xquery.XQueryBuilder.evaluateAsDOM(XQueryBuilder.java:153)
	at org.apache.camel.component.xquery.XQueryBuilder.evaluate(XQueryBuilder.java:115)
	... 14 more




-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


Mime
View raw message