Hi Alexander, Well, it looks to me as though support is the next stop-- I've run the query, but as expected on a trivial dataset it has no issues (and no results), and I see no difference between 8.0-1 and current builds. I don't think the inference size will help, since you're not using inferrence here -- and that would show up as a different error anyhow.
For some reason this query is using all available memory-- we'll need to understand more about the dataset to help diagnose. Charles ________________________________ From: general-boun...@developer.marklogic.com [general-boun...@developer.marklogic.com] on behalf of Takacs [tak...@gmail.com] Sent: Thursday, April 23, 2015 12:53 AM To: MarkLogic Developer Discussion Subject: Re: [MarkLogic Dev General] SPARQL queries causing XDMP-MEMCANCELED Hi Charles, Thank you very much for your reply! 1. Our system is running the query through XCC in the following manner: xquery version \"1.0-ml\"; import module namespace sem="http://marklogic.com/semantics" at "/MarkLogic/semantics.xqy" declare variable $SPARQL as xs:string external sem:query-results-serialize(sem:sparql($SPARQL, (), 'optimize=2')) Though we have experienced the same issue running it in the console. The error in the log looks like this: 2015-04-22 11:18:26.679 Notice: t5-xdbc: XDMP-MEMCANCELED: { SELECT DISTINCT ?_app_id ?_reason ?_comment { ?ERR <http://ihelab.com/T5/model#hasERR.7> ?ERR_7 . ?MSA_2 <http://ihelab.com/T5/model#mSA.2Value> ?_msg_id . ?ACK <http://ihelab.com/T5/model#hasMSH> ?MSH . ?MSH <http://ihelab.com/T5/model#hasMSH.5> ?MSH_5 . ?HD_1 <http://ihelab.com/T5/model#hD.1Value> ?_app_id . FILTER (?_app_id = "SENDING_APP_3252") ?MSH_5 <http://ihelab.com/T5/model#hasHD.1> ?HD_1 . ?ACK <http://ihelab.com/T5/model#hasMSA> ?MSA . ?MSA <http://ihelab.com/T5/model#hasMSA.2> ?MSA_2 . ?PCD_01_Message <http://ihelab.com/T5/model#id> ?_msg_id . ?PCD_01_Message <http://ihelab.com/T5/model#timeStamp> ?_ts . ?ACK <http://ihelab.com/T5/model#hasERR> ?ERR . BIND (3 AS ?_severity) BIND ("Generated by HL7 v2 Conformance Profile of IHE PCD-01 message" AS ?_comment) ?ERR_7 <http://ihelab.com/T5/model#eRR.7Value> ?_err . ?PCD_01_Message <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://ihelab.com/T5/model#PCD_01_Message> . FILTER (Q{http://www.w3.org/2001/XMLSchema}dateTime($_ts) ge xs:dateTime("2015-04-22T11:18:11.547")) FILTER (Q{http://www.w3.org/2001/XMLSchema}dateTime($_ts) le xs:dateTime("2015-04-22T11:18:11.547")) BIND ($_err AS ?_reason) } } -- Canceled because of memory usage 2015-04-22 11:18:26.679 Notice: t5-xdbc: at 18:1, 2015-04-22 11:18:26.679 Notice: t5-xdbc: in sem:sparql(" 	 	 	 	 # Template: List o...", (), "optimize=2") [1.0-ml] 2015-04-22 11:18:26.679 Notice: t5-xdbc: at 4:28 [1.0-ml] The query plan for that particular execution: 2015-04-22 11:18:21.102 Info: plan=SPARQLModule[ 2015-04-22 11:18:21.102 Info: Prolog[] 2015-04-22 11:18:21.102 Info: SPARQLSelect[SPARQLDistinct[SPARQLProject[order() 2015-04-22 11:18:21.102 Info: GraphNode[Var _app_id 0] 2015-04-22 11:18:21.102 Info: GraphNode[Var _reason 1] 2015-04-22 11:18:21.102 Info: GraphNode[Var _comment 2] 2015-04-22 11:18:21.102 Info: SPARQLBind[ 2015-04-22 11:18:21.102 Info: GraphNode[Var _reason 1] 2015-04-22 11:18:21.102 Info: Variable[QName[(Unknown) _err] 15] 2015-04-22 11:18:21.102 Info: SPARQLFilter[ 2015-04-22 11:18:21.102 Info: FILTER ValueCompExpr[ 2015-04-22 11:18:21.102 Info: CastExpr[ 2015-04-22 11:18:21.102 Info: Variable[QName[(Unknown) _ts] 12] 2015-04-22 11:18:21.102 Info: SequenceType[AtomicType[QName[(Unknown) Q{http://www.w3.org/2001/XMLSchema}dateTime]]*]] 2015-04-22 11:18:21.102 Info: ge 2015-04-22 11:18:21.102 Info: Literal[xs:dateTime("2015-04-22T11:18:11.547")]] 2015-04-22 11:18:21.102 Info: FILTER ValueCompExpr[ 2015-04-22 11:18:21.102 Info: CastExpr[ 2015-04-22 11:18:21.102 Info: Variable[QName[(Unknown) _ts] 12] 2015-04-22 11:18:21.102 Info: SequenceType[AtomicType[QName[(Unknown) Q{http://www.w3.org/2001/XMLSchema}dateTime]]*]] 2015-04-22 11:18:21.102 Info: le 2015-04-22 11:18:21.102 Info: Literal[xs:dateTime("2015-04-22T11:18:11.547")]] 2015-04-22 11:18:21.102 Info: SPARQLScatterJoin[order(11) hash(4==4,11==11,13==13,14==14) scatter(4 = 4, 11 = 11, 13 = 13, 14 = 14) 2015-04-22 11:18:21.102 Info: SPARQLParallelCrossProduct[order(10,11) hash() scatter() 2015-04-22 11:18:21.102 Info: TriplePattern[order(13,14) PSO 2015-04-22 11:18:21.102 Info: GraphNode[Var ERR 13] 2015-04-22 11:18:21.102 Info: GraphNode[IRI <http://ihelab.com/T5/model#hasERR.7>] 2015-04-22 11:18:21.102 Info: GraphNode[Var ERR_7 14]] 2015-04-22 11:18:21.102 Info: SPARQLScatterJoin[order(10,11) hash(10==10) scatter(10 = 10) 2015-04-22 11:18:21.102 Info: SPARQLParallelHashJoin[order(8,9) hash(9==9) scatter() 2015-04-22 11:18:21.102 Info: TriplePattern[order(9,10) PSO 2015-04-22 11:18:21.102 Info: GraphNode[Var MSA_2 9] 2015-04-22 11:18:21.102 Info: GraphNode[IRI <http://ihelab.com/T5/model#mSA.2Value>] 2015-04-22 11:18:21.102 Info: GraphNode[Var _msg_id 10]] 2015-04-22 11:18:21.102 Info: SPARQLScatterJoin[order(8,9) hash(8==8) scatter(8 = 8) 2015-04-22 11:18:21.102 Info: SPARQLScatterJoin[order(4,8) hash(4==4) scatter(4 = 4) 2015-04-22 11:18:21.102 Info: SPARQLParallelHashJoin[order() hash(5==5) scatter() 2015-04-22 11:18:21.102 Info: TriplePattern[order(4,5) PSO 2015-04-22 11:18:21.102 Info: GraphNode[Var ACK 4] 2015-04-22 11:18:21.102 Info: GraphNode[IRI <http://ihelab.com/T5/model#hasMSH>] 2015-04-22 11:18:21.102 Info: GraphNode[Var MSH 5]] 2015-04-22 11:18:21.102 Info: SPARQLParallelHashJoin[order() hash(6==6) scatter() 2015-04-22 11:18:21.102 Info: TriplePattern[order(5,6) PSO 2015-04-22 11:18:21.102 Info: GraphNode[Var MSH 5] 2015-04-22 11:18:21.102 Info: GraphNode[IRI <http://ihelab.com/T5/model#hasMSH.5>] 2015-04-22 11:18:21.102 Info: GraphNode[Var MSH_5 6]] 2015-04-22 11:18:21.102 Info: SPARQLNestedLoopJoin[order() hash(7==7) scatter(7 = 7) 2015-04-22 11:18:21.102 Info: TriplePattern[order(7) OPS 2015-04-22 11:18:21.102 Info: GraphNode[Var HD_1 7] 2015-04-22 11:18:21.102 Info: GraphNode[IRI <http://ihelab.com/T5/model#hD.1Value>] 2015-04-22 11:18:21.102 Info: GraphNode[Var _app_id 0] 2015-04-22 11:18:21.102 Info: FILTER 0 = Literal["SENDING_APP_3252"]] 2015-04-22 11:18:21.102 Info: TriplePattern[order(7,6) OPS 2015-04-22 11:18:21.102 Info: GraphNode[Var MSH_5 6] 2015-04-22 11:18:21.102 Info: GraphNode[IRI <http://ihelab.com/T5/model#hasHD.1>] 2015-04-22 11:18:21.102 Info: GraphNode[Var HD_1 7]]]]] 2015-04-22 11:18:21.102 Info: TriplePattern[order(4,8) PSO 2015-04-22 11:18:21.102 Info: GraphNode[Var ACK 4] 2015-04-22 11:18:21.102 Info: GraphNode[IRI <http://ihelab.com/T5/model#hasMSA>] 2015-04-22 11:18:21.102 Info: GraphNode[Var MSA 8]]] 2015-04-22 11:18:21.102 Info: TriplePattern[order(8,9) PSO 2015-04-22 11:18:21.102 Info: GraphNode[Var MSA 8] 2015-04-22 11:18:21.102 Info: GraphNode[IRI <http://ihelab.com/T5/model#hasMSA.2>] 2015-04-22 11:18:21.102 Info: GraphNode[Var MSA_2 9]]]] 2015-04-22 11:18:21.102 Info: TriplePattern[order(10,11) OPS 2015-04-22 11:18:21.102 Info: GraphNode[Var PCD_01_Message 11] 2015-04-22 11:18:21.102 Info: GraphNode[IRI <http://ihelab.com/T5/model#id>] 2015-04-22 11:18:21.102 Info: GraphNode[Var _msg_id 10]]]] 2015-04-22 11:18:21.102 Info: SPARQLHashJoin[order(11) hash(11==11) scatter() 2015-04-22 11:18:21.102 Info: SPARQLCrossProduct[order(14,15) hash() scatter() 2015-04-22 11:18:21.102 Info: TriplePattern[order(11,12) SOP 2015-04-22 11:18:21.102 Info: GraphNode[Var PCD_01_Message 11] 2015-04-22 11:18:21.102 Info: GraphNode[IRI <http://ihelab.com/T5/model#timeStamp>] 2015-04-22 11:18:21.102 Info: GraphNode[Var _ts 12]] 2015-04-22 11:18:21.102 Info: SPARQLCrossProduct[order(14,15) hash() scatter() 2015-04-22 11:18:21.102 Info: SPARQLCrossProduct[order() hash() scatter() 2015-04-22 11:18:21.102 Info: TriplePattern[order(4,13) SOP 2015-04-22 11:18:21.102 Info: GraphNode[Var ACK 4] 2015-04-22 11:18:21.102 Info: GraphNode[IRI <http://ihelab.com/T5/model#hasERR>] 2015-04-22 11:18:21.102 Info: GraphNode[Var ERR 13]] 2015-04-22 11:18:21.102 Info: SPARQLBind[ 2015-04-22 11:18:21.102 Info: GraphNode[Var _comment 2] 2015-04-22 11:18:21.102 Info: Literal["Generated by HL7 v2 Conformance Profile of IHE PCD-01 message"] 2015-04-22 11:18:21.102 Info: SPARQLBind[ 2015-04-22 11:18:21.102 Info: GraphNode[Var _severity 3] 2015-04-22 11:18:21.102 Info: Literal[3] 2015-04-22 11:18:21.102 Info: SPARQLJoin[order()]]]] 2015-04-22 11:18:21.102 Info: TriplePattern[order(14,15) PSO 2015-04-22 11:18:21.102 Info: GraphNode[Var ERR_7 14] 2015-04-22 11:18:21.102 Info: GraphNode[IRI <http://ihelab.com/T5/model#eRR.7Value>] 2015-04-22 11:18:21.102 Info: GraphNode[Var _err 15]]]] 2015-04-22 11:18:21.102 Info: TriplePattern[order(11) SOP 2015-04-22 11:18:21.102 Info: GraphNode[Var PCD_01_Message 11] 2015-04-22 11:18:21.102 Info: GraphNode[IRI <http://www.w3.org/1999/02/22-rdf-syntax-ns#type>] 2015-04-22 11:18:21.102 Info: GraphNode[IRI <http://ihelab.com/T5/model#PCD_01_Message>]]]]]]]]]] 2. We currently have a default inference size of 100 megabytes and a max of 1000 megabytes for the XDBC app server we are using, we have experimented a bit with increasing it but it didn't give any obvious results. Yours truly, Alexander
_______________________________________________ General mailing list General@developer.marklogic.com Manage your subscription at: http://developer.marklogic.com/mailman/listinfo/general