You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@vxquery.apache.org by pr...@apache.org on 2015/08/19 04:17:03 UTC

vxquery git commit: Shivani's changes for fixing an additional XMark query, adding XMark query documentation, and updating the XMark test suite.

Repository: vxquery
Updated Branches:
  refs/heads/master 7fc0d93b4 -> 44717b267


Shivani's changes for fixing an additional XMark query, adding XMark query documentation, and updating the XMark test suite.


Project: http://git-wip-us.apache.org/repos/asf/vxquery/repo
Commit: http://git-wip-us.apache.org/repos/asf/vxquery/commit/44717b26
Tree: http://git-wip-us.apache.org/repos/asf/vxquery/tree/44717b26
Diff: http://git-wip-us.apache.org/repos/asf/vxquery/diff/44717b26

Branch: refs/heads/master
Commit: 44717b2673aa4cf616a1639067535197aea543ea
Parents: 7fc0d93
Author: Preston Carman <pr...@apache.org>
Authored: Tue Aug 18 19:17:33 2015 -0700
Committer: Preston Carman <pr...@apache.org>
Committed: Tue Aug 18 19:17:33 2015 -0700

----------------------------------------------------------------------
 src/site/apt/development_xmark_status.apt       | 76 ++++++++++++++++++++
 src/site/site.xml                               | 27 +++----
 .../rules/PushChildIntoDataScanRule.java        | 49 +++++++------
 .../metadata/VXQueryMetadataProvider.java       | 14 +++-
 .../xmlquery/query/XMLQueryCompiler.java        |  3 +-
 .../ExpectedTestResults/Simple/fn_doc.txt       |  2 +-
 .../ExpectedTestResults/XMark/Modified/q13.txt  | 34 ++++-----
 .../ExpectedTestResults/XMark/Modified/q14.txt  |  5 +-
 .../ExpectedTestResults/XMark/Original/q13.txt  | 34 ++++-----
 .../ExpectedTestResults/XMark/Original/q14.txt  |  5 +-
 .../XMark/Original/simple_query1.txt            |  1 -
 .../XMark/Original/simple_query2.txt            |  4 --
 12 files changed, 156 insertions(+), 98 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/vxquery/blob/44717b26/src/site/apt/development_xmark_status.apt
----------------------------------------------------------------------
diff --git a/src/site/apt/development_xmark_status.apt b/src/site/apt/development_xmark_status.apt
new file mode 100644
index 0000000..a7a6f6c
--- /dev/null
+++ b/src/site/apt/development_xmark_status.apt
@@ -0,0 +1,76 @@
+~~ Licensed to the Apache Software Foundation (ASF) under one or more
+~~ contributor license agreements.  See the NOTICE file distributed with
+~~ this work for additional information regarding copyright ownership.
+~~ The ASF licenses this file to You under the Apache License, Version 2.0
+~~ (the "License"); you may not use this file except in compliance with
+~~ the License.  You may obtain a copy of the License at
+~~
+~~     http://www.apache.org/licenses/LICENSE-2.0
+~~
+~~ Unless required by applicable law or agreed to in writing, software
+~~ distributed under the License is distributed on an "AS IS" BASIS,
+~~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+~~ See the License for the specific language governing permissions and
+~~ limitations under the License.
+
+
+XMark Benchmark Documentation
+    
+    In the following table, XMark queries are listed to show the current status of 
+    each query in VXQuery. The <Query Number> column represents the XMark query 
+    number. <Original Query> column represents the original XMark query from the XMark Benchmark site. Original query 
+    works if it has a <Working> status in the column. If the original query does not work, then 
+    the column displays the error type. <Optimized Query> column represents 
+    the parallel optimized version for the original XMark query. The optimized version of the query 
+    has been written to increase performance. Optimized query 
+    works if it has a <Working> status in the column. If the optimized query does not work, then 
+    the column displays the error or displays <Same Error as Original Query>. 
+    <Frame Size> column represents the frame size that VXQuery needs to run the query. 
+    The <Issues> column represents the JIRA issues for the query or are related to the query.
+    All queries that do not work with the default frame size
+    are related to {{{https://issues.apache.org/jira/browse/VXQUERY-167} VXQuery Issue 167 }}.
+    
+
+*------------------+--------------------+---------------------+-----------------+-----------+
+| <<Query Number>> | <<Original Query>> | <<Optimized Query>> | <<Frame Size>>  | <<Issues>> |
+*------------------+--------------------+---------------------+-----------------+-----------:
+| 1 | Working | Working | Working with default size  | None |
+*------------------+--------------------+---------------------+-----------------+-----------:
+| 2 | Working | Working | Working with default size | None |  
+*------------------+--------------------+---------------------+-----------------+-----------:
+| 3 | Working  | Working | Working with default size | None |  
+*------------------+--------------------+---------------------+-----------------+-----------:
+| 4 | Working | Working| Working with default size | None |
+*------------------+--------------------+---------------------+-----------------+-----------:
+| 5  | Working | Working | Working with default size | None |
+*------------------+--------------------+---------------------+-----------------+-----------:
+|  6 | Error in the Query Plan  | Same Error as Original Query  | Cannot be determined | {{{https://issues.apache.org/jira/browse/VXQUERY-170} VXQuery Issue 170 }} |
+*------------------+--------------------+---------------------+-----------------+-----------:
+|  7 | Error in the Query Plan  | Same Error as Original Query | Cannot be determined | {{{https://issues.apache.org/jira/browse/VXQUERY-170} VXQuery Issue 170 }} |
+*------------------+--------------------+---------------------+-----------------+-----------:
+|  8 | Working | Working | Working with default size | {{{https://issues.apache.org/jira/browse/VXQUERY-171} VXQuery Issue 171 }} |
+*------------------+--------------------+---------------------+-----------------+-----------:
+| 9 | Array Out Of bounds Exception | Same Error as Original Query | Cannot be determined | {{{https://issues.apache.org/jira/browse/VXQUERY-173} VXQuery Issue 173 }} |
+*------------------+--------------------+---------------------+-----------------+-----------:
+| 10 | Times out while execution | Same Error as Original Query | Cannot be determined | {{{https://issues.apache.org/jira/browse/VXQUERY-176} VXQuery Issue 176 }} |
+*------------------+--------------------+---------------------+-----------------+-----------:
+| 11 | Working | Working | Working with default size | {{{https://issues.apache.org/jira/browse/VXQUERY-171} VXQuery Issue 171 }} |
+*------------------+--------------------+---------------------+-----------------+-----------:
+| 12 | Working | Working |Working with default size | {{{https://issues.apache.org/jira/browse/VXQUERY-172} VXQuery Issue 172 }} |
+*------------------+--------------------+---------------------+-----------------+-----------:
+| 13 | Working | Working |Working with default size | None |
+*------------------+--------------------+---------------------+-----------------+-----------:
+| 14 | Working | Working |Working with max size | None |
+*------------------+--------------------+---------------------+-----------------+-----------:
+| 15 | Working | Working | Working with max size | {{{https://issues.apache.org/jira/browse/VXQUERY-174} VXQuery Issue 174 }} |
+*------------------+--------------------+---------------------+-----------------+-----------:
+| 16 | Working | Working |Working with max size | None |
+*------------------+--------------------+---------------------+-----------------+-----------:
+| 17 | Working | Working | Working with default size | {{{https://issues.apache.org/jira/browse/VXQUERY-171} VXQuery Issue 171 }} |
+*------------------+--------------------+---------------------+-----------------+-----------:
+| 18 | Use defined functions | Same Error as Original Query | Cannot be determined | {{{https://issues.apache.org/jira/browse/VXQUERY-154} VXQuery Issue 154 }} |
+*------------------+--------------------+---------------------+-----------------+-----------:
+| 19 | Working | Working | Working with default size | {{{https://issues.apache.org/jira/browse/VXQUERY-172} VXQuery Issue 172 }} |
+*------------------+--------------------+---------------------+-----------------+-----------:
+| 20 | Empty results | Same Error as Original Query | Working with frame size | {{{https://issues.apache.org/jira/browse/VXQUERY-175} VXQuery Issue 175 }} |
+*------------------+--------------------+---------------------+-----------------+-----------:
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/vxquery/blob/44717b26/src/site/site.xml
----------------------------------------------------------------------
diff --git a/src/site/site.xml b/src/site/site.xml
index 08e4522..b9612c1 100644
--- a/src/site/site.xml
+++ b/src/site/site.xml
@@ -20,19 +20,16 @@ limitations under the License.
         <src>images/VXQuery.png</src>
         <href>http://vxquery.apache.org/</href>
     </bannerLeft>
-
     <bannerRight>
         <name>Apache Software Foundation</name>
         <src>images/asf_logo_wide.png</src>
         <href>http://www.apache.org/</href>
     </bannerRight>
-
     <skin>
         <groupId>org.apache.maven.skins</groupId>
         <artifactId>maven-fluido-skin</artifactId>
         <version>1.3.1</version>
     </skin>
-
     <body>
         <menu name="Apache Software Foundation">
             <item
@@ -48,13 +45,11 @@ limitations under the License.
                 name="Security"
                 href="http://www.apache.org/security/" />
         </menu>
-
         <menu name="Get VXQuery">
             <item
                 name="Download"
                 href="http://www.apache.org/dyn/closer.cgi/vxquery/" />
         </menu>
-
         <menu name="For Users">
             <item
                 name="Get Started"
@@ -72,7 +67,6 @@ limitations under the License.
                 name="Running the Test Suite"
                 href="user_running_tests.html" />
         </menu>
-
         <menu name="For Developers">
             <item
                 name="Get Started"
@@ -96,28 +90,23 @@ limitations under the License.
                 name="Update Local Git XQTS Results"
                 href="development_update_xqts_results.html" />
             <item
+                name="XMark Benchmark Status"
+                href="development_xmark_status.html" />
+            <item
                 name="XML Data and Node Types"
                 href="development_xml_node_details.html" />
             <item
                 name="XML Data Model Example"
                 href="development_xml_document.html" />
-            <!-- <item
-                name="XQuery Benchmarks"
-                href="development_benchmarks.html" /> -->
         </menu>
-
         <menu ref="reports" />
         <menu ref="modules" />
-
         <footer>
-            <div class="row-fluid">Apache VXQuery, VXQuery, Apache, the Apache
-                feather logo, and the Apache VXQuery project logo are either
-                registered trademarks or trademarks of The Apache Software
-                Foundation in the United States and other countries.
-                All other marks mentioned may be trademarks or registered
-                trademarks of their respective owners.
+            <div class="row-fluid">Apache VXQuery, VXQuery, Apache, the Apache feather logo, and the Apache VXQuery project logo
+                are either registered trademarks or trademarks of The Apache Software Foundation in the United States
+                and other countries. All other marks mentioned may be trademarks or registered trademarks of their
+                respective owners.
             </div>
         </footer>
     </body>
-</project>
-
+</project>
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/vxquery/blob/44717b26/vxquery-core/src/main/java/org/apache/vxquery/compiler/rewriter/rules/PushChildIntoDataScanRule.java
----------------------------------------------------------------------
diff --git a/vxquery-core/src/main/java/org/apache/vxquery/compiler/rewriter/rules/PushChildIntoDataScanRule.java b/vxquery-core/src/main/java/org/apache/vxquery/compiler/rewriter/rules/PushChildIntoDataScanRule.java
index 3c23731..6b052bc 100644
--- a/vxquery-core/src/main/java/org/apache/vxquery/compiler/rewriter/rules/PushChildIntoDataScanRule.java
+++ b/vxquery-core/src/main/java/org/apache/vxquery/compiler/rewriter/rules/PushChildIntoDataScanRule.java
@@ -18,67 +18,64 @@ package org.apache.vxquery.compiler.rewriter.rules;
 
 import java.util.ArrayList;
 import java.util.List;
-import java.util.ListIterator;
 
 import org.apache.commons.lang3.mutable.Mutable;
-import org.apache.commons.lang3.mutable.MutableObject;
+import org.apache.vxquery.compiler.rewriter.VXQueryOptimizationContext;
 import org.apache.vxquery.compiler.rewriter.rules.util.ExpressionToolbox;
-import org.apache.vxquery.context.RootStaticContextImpl;
-import org.apache.vxquery.context.StaticContextImpl;
-import org.apache.vxquery.datamodel.accessors.TaggedValuePointable;
-import org.apache.vxquery.functions.BuiltinFunctions;
+import org.apache.vxquery.context.StaticContext;
 import org.apache.vxquery.functions.BuiltinOperators;
-import org.apache.vxquery.functions.Function;
 import org.apache.vxquery.metadata.VXQueryCollectionDataSource;
-import org.apache.vxquery.types.SequenceType;
+import org.apache.vxquery.metadata.VXQueryMetadataProvider;
+import org.apache.vxquery.types.ElementType;
 
 import edu.uci.ics.hyracks.algebricks.common.exceptions.AlgebricksException;
 import edu.uci.ics.hyracks.algebricks.core.algebra.base.ILogicalExpression;
 import edu.uci.ics.hyracks.algebricks.core.algebra.base.ILogicalOperator;
 import edu.uci.ics.hyracks.algebricks.core.algebra.base.IOptimizationContext;
-import edu.uci.ics.hyracks.algebricks.core.algebra.base.LogicalExpressionTag;
 import edu.uci.ics.hyracks.algebricks.core.algebra.base.LogicalOperatorTag;
-import edu.uci.ics.hyracks.algebricks.core.algebra.expressions.AbstractFunctionCallExpression;
-import edu.uci.ics.hyracks.algebricks.core.algebra.expressions.ConstantExpression;
+import edu.uci.ics.hyracks.algebricks.core.algebra.metadata.IMetadataProvider;
 import edu.uci.ics.hyracks.algebricks.core.algebra.operators.logical.AbstractLogicalOperator;
 import edu.uci.ics.hyracks.algebricks.core.algebra.operators.logical.AssignOperator;
 import edu.uci.ics.hyracks.algebricks.core.algebra.operators.logical.DataSourceScanOperator;
 import edu.uci.ics.hyracks.algebricks.core.algebra.operators.logical.UnnestOperator;
-import edu.uci.ics.hyracks.data.std.primitive.IntegerPointable;
 
 /**
  * The rule searches for an unnest operator immediately following a data scan
  * operator.
- * 
+ *
  * <pre>
- * Before 
- * 
+ * Before
+ *
  *   plan__parent
  *   UNNEST( $v2 : child( $v1 ) )
  *   DATASCAN( $source : $v1 )
  *   plan__child
- *   
+ *
  *   Where $v1 is not used in plan__parent.
- *   
+ *
  * After
- * 
+ *
  *   plan__parent
  *   DATASCAN( $source : $v1 )
  *   plan__child
- *   
+ *
  *   $source is encoded with the child parameters.
  * </pre>
- * 
+ *
  * @author prestonc
  */
 public class PushChildIntoDataScanRule extends AbstractUsedVariablesProcessingRule {
-    final StaticContextImpl dCtx = new StaticContextImpl(RootStaticContextImpl.INSTANCE);
+    StaticContext dCtx = null;
     final int ARG_DATA = 0;
     final int ARG_TYPE = 1;
 
     protected boolean processOperator(Mutable<ILogicalOperator> opRef, IOptimizationContext context)
             throws AlgebricksException {
-        AbstractLogicalOperator op1 = (AbstractLogicalOperator) opRef.getValue();;
+        if (dCtx == null) {
+            IMetadataProvider metadataProvider = ((VXQueryOptimizationContext) context).getMetadataProvider();
+            dCtx = ((VXQueryMetadataProvider) metadataProvider).getStaticContext();
+        }
+        AbstractLogicalOperator op1 = (AbstractLogicalOperator) opRef.getValue();
         if (op1.getOperatorTag() != LogicalOperatorTag.UNNEST) {
             return false;
         }
@@ -110,7 +107,7 @@ public class PushChildIntoDataScanRule extends AbstractUsedVariablesProcessingRu
 
     /**
      * In reverse add them to the data source.
-     * 
+     *
      * @param ds
      * @param expression
      */
@@ -121,8 +118,10 @@ public class PushChildIntoDataScanRule extends AbstractUsedVariablesProcessingRu
         for (int i = finds.size(); i > 0; --i) {
             int typeId = ExpressionToolbox.getTypeExpressionTypeArgument(finds.get(i - 1));
             if (typeId > 0) {
-                ds.addChildSeq(typeId);
-                added = true;
+                if (dCtx.lookupSequenceType(typeId).getItemType().equals(ElementType.ANYELEMENT) && typeId > 0) {
+                    ds.addChildSeq(typeId);
+                    added = true;
+                }
             }
         }
         return added;

http://git-wip-us.apache.org/repos/asf/vxquery/blob/44717b26/vxquery-core/src/main/java/org/apache/vxquery/metadata/VXQueryMetadataProvider.java
----------------------------------------------------------------------
diff --git a/vxquery-core/src/main/java/org/apache/vxquery/metadata/VXQueryMetadataProvider.java b/vxquery-core/src/main/java/org/apache/vxquery/metadata/VXQueryMetadataProvider.java
index b2ab17c..ea4bdb1 100644
--- a/vxquery-core/src/main/java/org/apache/vxquery/metadata/VXQueryMetadataProvider.java
+++ b/vxquery-core/src/main/java/org/apache/vxquery/metadata/VXQueryMetadataProvider.java
@@ -22,6 +22,8 @@ import java.util.ArrayList;
 import java.util.List;
 import java.util.Map;
 
+import org.apache.vxquery.context.StaticContext;
+
 import edu.uci.ics.hyracks.algebricks.common.constraints.AlgebricksAbsolutePartitionConstraint;
 import edu.uci.ics.hyracks.algebricks.common.constraints.AlgebricksPartitionConstraint;
 import edu.uci.ics.hyracks.algebricks.common.exceptions.AlgebricksException;
@@ -52,12 +54,14 @@ import edu.uci.ics.hyracks.api.job.JobSpecification;
 import edu.uci.ics.hyracks.dataflow.std.result.ResultWriterOperatorDescriptor;
 
 public class VXQueryMetadataProvider implements IMetadataProvider<String, String> {
-    String[] nodeList;
-    Map<String, File> sourceFileMap;
+    private final String[] nodeList;
+    private final Map<String, File> sourceFileMap;
+    private final StaticContext staticCtx;
 
-    public VXQueryMetadataProvider(String[] nodeList, Map<String, File> sourceFileMap) {
+    public VXQueryMetadataProvider(String[] nodeList, Map<String, File> sourceFileMap, StaticContext staticCtx) {
         this.nodeList = nodeList;
         this.sourceFileMap = sourceFileMap;
+        this.staticCtx = staticCtx;
     }
 
     @Override
@@ -69,6 +73,10 @@ public class VXQueryMetadataProvider implements IMetadataProvider<String, String
         return sourceFileMap;
     }
 
+    public StaticContext getStaticContext() {
+        return staticCtx;
+    }
+
     @Override
     public Pair<IOperatorDescriptor, AlgebricksPartitionConstraint> getScannerRuntime(IDataSource<String> dataSource,
             List<LogicalVariable> scanVariables, List<LogicalVariable> projectVariables, boolean projectPushed,

http://git-wip-us.apache.org/repos/asf/vxquery/blob/44717b26/vxquery-core/src/main/java/org/apache/vxquery/xmlquery/query/XMLQueryCompiler.java
----------------------------------------------------------------------
diff --git a/vxquery-core/src/main/java/org/apache/vxquery/xmlquery/query/XMLQueryCompiler.java b/vxquery-core/src/main/java/org/apache/vxquery/xmlquery/query/XMLQueryCompiler.java
index d9c5d01..aea6ef7 100644
--- a/vxquery-core/src/main/java/org/apache/vxquery/xmlquery/query/XMLQueryCompiler.java
+++ b/vxquery-core/src/main/java/org/apache/vxquery/xmlquery/query/XMLQueryCompiler.java
@@ -199,7 +199,8 @@ public class XMLQueryCompiler {
         module = new XMLQueryTranslator(ccb).translateModule(moduleNode);
         pprinter = new LogicalOperatorPrettyPrintVisitor(new VXQueryLogicalExpressionPrettyPrintVisitor(
                 module.getModuleContext()));
-        VXQueryMetadataProvider mdProvider = new VXQueryMetadataProvider(nodeList, ccb.getSourceFileMap());
+        VXQueryMetadataProvider mdProvider = new VXQueryMetadataProvider(nodeList, ccb.getSourceFileMap(),
+                module.getModuleContext());
         compiler = cFactory.createCompiler(module.getBody(), mdProvider, 0);
         listener.notifyTranslationResult(module);
         XMLQueryTypeChecker.typeCheckModule(module);

http://git-wip-us.apache.org/repos/asf/vxquery/blob/44717b26/vxquery-xtest/src/test/resources/ExpectedTestResults/Simple/fn_doc.txt
----------------------------------------------------------------------
diff --git a/vxquery-xtest/src/test/resources/ExpectedTestResults/Simple/fn_doc.txt b/vxquery-xtest/src/test/resources/ExpectedTestResults/Simple/fn_doc.txt
index 169a175..3b9d17a 100644
--- a/vxquery-xtest/src/test/resources/ExpectedTestResults/Simple/fn_doc.txt
+++ b/vxquery-xtest/src/test/resources/ExpectedTestResults/Simple/fn_doc.txt
@@ -1 +1 @@
-<stationCollection pageSize="100"pageCount="1"totalCount="1"><station><id>GHCND:US000000001</id><displayName>Station 1</displayName><latitude>10.000</latitude><longitude>-10.000</longitude><elevation>1000.0</elevation><locationLabels><type>ST</type><id>FIPS:1</id><displayName>State 1</displayName></locationLabels><locationLabels><type>CNTY</type><id>FIPS:-9999</id><displayName>County 1</displayName></locationLabels><locationLabels><type>CNTRY</type><id>FIPS:US</id><displayName>UNITED STATES</displayName></locationLabels></station></stationCollection>
\ No newline at end of file
+<stationCollection pageSize="100" pageCount="1" totalCount="1"><station><id>GHCND:US000000001</id><displayName>Station 1</displayName><latitude>10.000</latitude><longitude>-10.000</longitude><elevation>1000.0</elevation><locationLabels><type>ST</type><id>FIPS:1</id><displayName>State 1</displayName></locationLabels><locationLabels><type>CNTY</type><id>FIPS:-9999</id><displayName>County 1</displayName></locationLabels><locationLabels><type>CNTRY</type><id>FIPS:US</id><displayName>UNITED STATES</displayName></locationLabels></station></stationCollection>
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/vxquery/blob/44717b26/vxquery-xtest/src/test/resources/ExpectedTestResults/XMark/Modified/q13.txt
----------------------------------------------------------------------
diff --git a/vxquery-xtest/src/test/resources/ExpectedTestResults/XMark/Modified/q13.txt b/vxquery-xtest/src/test/resources/ExpectedTestResults/XMark/Modified/q13.txt
index 6b7bf95..cce306b 100644
--- a/vxquery-xtest/src/test/resources/ExpectedTestResults/XMark/Modified/q13.txt
+++ b/vxquery-xtest/src/test/resources/ExpectedTestResults/XMark/Modified/q13.txt
@@ -1,14 +1,11 @@
-<item name="cockatrice approves money">
-  <description>
-    <text>clothes edmund doubtful fool torments ropes contrive lecher ardea
+<item name="cockatrice approves money"><description>
+          <text>clothes edmund doubtful fool torments ropes contrive lecher ardea
             happiness fertile treads constable defences<keyword>lion
             neighbour ourself</keyword>marshal disordered moderate venus
             afeard article rot hazards craft crowns<emph>plainness patient</emph>lying knowledge diseases meritorious medicine</text>
-  </description>
-</item>
-<item name="answer misdoubt">
-  <description>
-    <text>delay brutish rage alexandria trumpet god wet resolve pursue colour
+        </description></item>
+<item name="answer misdoubt"><description>
+          <text>delay brutish rage alexandria trumpet god wet resolve pursue colour
             body walk month writing beside profane left declining coach through
             protectorship congruent confusion favours following populous
             exercise timon shoots function fourscore mangled favorably slain
@@ -27,17 +24,13 @@
             holly walk inform moods deck bulk begin action school nobles
             antique people unkennel stomach into petitions jack assail yongrey
             ages betimes golden sink droop kernel hoppedance perfection weight<emph>whining safe english rod other featur</emph>
-    </text>
-  </description>
-</item>
-<item name="prosperity dine yon debate">
-  <description>
-    <text>visitation strangely mab spirit forgot bargain holds</text>
-  </description>
-</item>
-<item name="congeal pawned alack">
-  <description>
-    <text>white obey<bold>calling neighbour office afternoon drum embowell
+          </text>
+        </description></item>
+<item name="prosperity dine yon debate"><description>
+          <text>visitation strangely mab spirit forgot bargain holds</text>
+        </description></item>
+<item name="congeal pawned alack"><description>
+          <text>white obey<bold>calling neighbour office afternoon drum embowell
             touch sue lifeless leapt shun called</bold>weary congregation
             yield check falling wives challenge mental fatal hard ancient
             stands cor dishes therein gramercy discipline farewell dire tricks
@@ -51,5 +44,4 @@
             verona</keyword>waters triumphing officer hastily<emph>resign
             subject figure hay thwart written signs gout bred distance period
             glove players change folly</emph>going wat lost</text>
-  </description>
-</item>
\ No newline at end of file
+        </description></item>
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/vxquery/blob/44717b26/vxquery-xtest/src/test/resources/ExpectedTestResults/XMark/Modified/q14.txt
----------------------------------------------------------------------
diff --git a/vxquery-xtest/src/test/resources/ExpectedTestResults/XMark/Modified/q14.txt b/vxquery-xtest/src/test/resources/ExpectedTestResults/XMark/Modified/q14.txt
index d201f0a..8a313a5 100644
--- a/vxquery-xtest/src/test/resources/ExpectedTestResults/XMark/Modified/q14.txt
+++ b/vxquery-xtest/src/test/resources/ExpectedTestResults/XMark/Modified/q14.txt
@@ -1 +1,4 @@
-condemnanswer misdoubtnearest sighswronged revels swell coz
\ No newline at end of file
+condemn
+answer misdoubt
+nearest sighs
+wronged revels swell coz
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/vxquery/blob/44717b26/vxquery-xtest/src/test/resources/ExpectedTestResults/XMark/Original/q13.txt
----------------------------------------------------------------------
diff --git a/vxquery-xtest/src/test/resources/ExpectedTestResults/XMark/Original/q13.txt b/vxquery-xtest/src/test/resources/ExpectedTestResults/XMark/Original/q13.txt
index 6b7bf95..cce306b 100644
--- a/vxquery-xtest/src/test/resources/ExpectedTestResults/XMark/Original/q13.txt
+++ b/vxquery-xtest/src/test/resources/ExpectedTestResults/XMark/Original/q13.txt
@@ -1,14 +1,11 @@
-<item name="cockatrice approves money">
-  <description>
-    <text>clothes edmund doubtful fool torments ropes contrive lecher ardea
+<item name="cockatrice approves money"><description>
+          <text>clothes edmund doubtful fool torments ropes contrive lecher ardea
             happiness fertile treads constable defences<keyword>lion
             neighbour ourself</keyword>marshal disordered moderate venus
             afeard article rot hazards craft crowns<emph>plainness patient</emph>lying knowledge diseases meritorious medicine</text>
-  </description>
-</item>
-<item name="answer misdoubt">
-  <description>
-    <text>delay brutish rage alexandria trumpet god wet resolve pursue colour
+        </description></item>
+<item name="answer misdoubt"><description>
+          <text>delay brutish rage alexandria trumpet god wet resolve pursue colour
             body walk month writing beside profane left declining coach through
             protectorship congruent confusion favours following populous
             exercise timon shoots function fourscore mangled favorably slain
@@ -27,17 +24,13 @@
             holly walk inform moods deck bulk begin action school nobles
             antique people unkennel stomach into petitions jack assail yongrey
             ages betimes golden sink droop kernel hoppedance perfection weight<emph>whining safe english rod other featur</emph>
-    </text>
-  </description>
-</item>
-<item name="prosperity dine yon debate">
-  <description>
-    <text>visitation strangely mab spirit forgot bargain holds</text>
-  </description>
-</item>
-<item name="congeal pawned alack">
-  <description>
-    <text>white obey<bold>calling neighbour office afternoon drum embowell
+          </text>
+        </description></item>
+<item name="prosperity dine yon debate"><description>
+          <text>visitation strangely mab spirit forgot bargain holds</text>
+        </description></item>
+<item name="congeal pawned alack"><description>
+          <text>white obey<bold>calling neighbour office afternoon drum embowell
             touch sue lifeless leapt shun called</bold>weary congregation
             yield check falling wives challenge mental fatal hard ancient
             stands cor dishes therein gramercy discipline farewell dire tricks
@@ -51,5 +44,4 @@
             verona</keyword>waters triumphing officer hastily<emph>resign
             subject figure hay thwart written signs gout bred distance period
             glove players change folly</emph>going wat lost</text>
-  </description>
-</item>
\ No newline at end of file
+        </description></item>
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/vxquery/blob/44717b26/vxquery-xtest/src/test/resources/ExpectedTestResults/XMark/Original/q14.txt
----------------------------------------------------------------------
diff --git a/vxquery-xtest/src/test/resources/ExpectedTestResults/XMark/Original/q14.txt b/vxquery-xtest/src/test/resources/ExpectedTestResults/XMark/Original/q14.txt
index d201f0a..8a313a5 100644
--- a/vxquery-xtest/src/test/resources/ExpectedTestResults/XMark/Original/q14.txt
+++ b/vxquery-xtest/src/test/resources/ExpectedTestResults/XMark/Original/q14.txt
@@ -1 +1,4 @@
-condemnanswer misdoubtnearest sighswronged revels swell coz
\ No newline at end of file
+condemn
+answer misdoubt
+nearest sighs
+wronged revels swell coz
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/vxquery/blob/44717b26/vxquery-xtest/src/test/resources/ExpectedTestResults/XMark/Original/simple_query1.txt
----------------------------------------------------------------------
diff --git a/vxquery-xtest/src/test/resources/ExpectedTestResults/XMark/Original/simple_query1.txt b/vxquery-xtest/src/test/resources/ExpectedTestResults/XMark/Original/simple_query1.txt
deleted file mode 100644
index 9043899..0000000
--- a/vxquery-xtest/src/test/resources/ExpectedTestResults/XMark/Original/simple_query1.txt
+++ /dev/null
@@ -1 +0,0 @@
-TestSources/XMark/SingleFile/auction.xml

http://git-wip-us.apache.org/repos/asf/vxquery/blob/44717b26/vxquery-xtest/src/test/resources/ExpectedTestResults/XMark/Original/simple_query2.txt
----------------------------------------------------------------------
diff --git a/vxquery-xtest/src/test/resources/ExpectedTestResults/XMark/Original/simple_query2.txt b/vxquery-xtest/src/test/resources/ExpectedTestResults/XMark/Original/simple_query2.txt
deleted file mode 100644
index d8f9c8a..0000000
--- a/vxquery-xtest/src/test/resources/ExpectedTestResults/XMark/Original/simple_query2.txt
+++ /dev/null
@@ -1,4 +0,0 @@
-<catgraph>
-    <edge from="category0" to="category0"/>
-    <edge from="category0" to="category0"/>
-</catgraph>