Windows documentation suggestions taken from mtawa002 pull request. Note: The pull request is out of sync with master so only the changes that were easy to find were taken.
Project: http://git-wip-us.apache.org/repos/asf/vxquery/repo Commit: http://git-wip-us.apache.org/repos/asf/vxquery/commit/08919109 Tree: http://git-wip-us.apache.org/repos/asf/vxquery/tree/08919109 Diff: http://git-wip-us.apache.org/repos/asf/vxquery/diff/08919109 Branch: refs/heads/site Commit: 0891910923c2d5a426960b160b374c62f319d7cb Parents: 0ad460a Author: Preston Carman <[email protected]> Authored: Mon May 16 15:49:38 2016 -0700 Committer: Preston Carman <[email protected]> Committed: Mon May 16 17:22:43 2016 -0700 ---------------------------------------------------------------------- src/site/apt/development_eclipse_setup.apt | 53 +++++++++++++------------ src/site/apt/user_query.apt | 15 +++---- 2 files changed, 36 insertions(+), 32 deletions(-) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/vxquery/blob/08919109/src/site/apt/development_eclipse_setup.apt ---------------------------------------------------------------------- diff --git a/src/site/apt/development_eclipse_setup.apt b/src/site/apt/development_eclipse_setup.apt index 14b30bd..19b5776 100644 --- a/src/site/apt/development_eclipse_setup.apt +++ b/src/site/apt/development_eclipse_setup.apt @@ -15,44 +15,44 @@ Eclipse Setup - Eclipse is a nice IDE for developing in Java and below are the instructions to setting up + Eclipse is a nice IDE for developing in Java and below are the instructions to setting up Eclipse for Apache VXQuery\x99 development. * Installation * Install Java Development Kit (JDK) 1.7 or Later - + * Install Classic Eclipse - Follow the instruction for eclipse on from {{{http://www.eclipse.org}www.eclipse.org}} for + Follow the instruction for eclipse on from {{{http://www.eclipse.org}www.eclipse.org}} for the "Classic" eclipse version. * Install Apache Maven * Install Maven Integration (m2e) - + VXQuery uses {{{http://maven.apache.org/}Maven}} to define external libraries and build instructions. The Eclipse plugin for Maven integeration can be found at {{{http://eclipse.org/m2e/}m2e}}. * Code Formatter Setup - For VXQuery, the Hyracks project Eclipse formating template has been adopted as the standard. The - template file can be found at {{{http://hyracks.googlecode.com/files/HyracksCodeFormatProfile.xml}http://hyracks.googlecode.com/files/HyracksCodeFormatProfile.xml}} - + For VXQuery, the Hyracks project Eclipse formating template has been adopted as the standard. The + template file can be found at {{{http://hyracks.googlecode.com/files/HyracksCodeFormatProfile.xml}http://hyracks.googlecode.com/files/HyracksCodeFormatProfile.xml}} + Menu Options from Preferences: - + * Java - + * Code Style - + * Formatter - + * Code Import Setup - + [[1]] Import Hyracks Code Base Download and install the Hyracks Full Stack Staging branch to get the latest Hyracks support - for development. This is required since some new features being build are affecting Hyracks + for development. This is required since some new features being build are affecting Hyracks development. ---------------------------------------- @@ -62,6 +62,9 @@ $ mvn install $ cd .. ---------------------------------------- + Note: VXQuery has only been lightly testing on Windows based machines. If you run into issues please file an + {{{https://issues.apache.org/jira/browse/VXQUERY}issue}}. + The mvn "-DskipTests" option can be used to save about 20 minutes, but will skip the verification tests. Finally, from Eclipse's File menu "import" the Maven Hyracks project you have just downloaded through git. @@ -78,27 +81,27 @@ $ cd apache-vxquery $ mvn package $ cd .. ---------------------------------------- - - Finally, from Eclipse's File menu "import" the Maven VXQuery project you have just downloaded through git. - + + Finally, from Eclipse's File menu "import" the Maven VXQuery project you have just downloaded through git. + [[1]] Additional Project Configuration - - Some eclipse build errors will show up. To remove these display errors, add + + Some eclipse build errors will show up. To remove these display errors, add "target/generated-sources/javacc" as a source folder in VXQuery Core. * Debugging - Eclipse can be used to debug VXQuery. Using the following java option will allow eclipse to pause the + Eclipse can be used to debug VXQuery. Using the following java option will allow eclipse to pause the execution and allow eclipse to step through the code. - - "-Xdebug -Xrunjdwp:transport=dt_socket,address=127.0.0.1:8000,server=y,suspend=y" - - Realize you may need to update the address for your system. More details can be found at + + "-Xdebug -Xrunjdwp:transport=dt_socket,address=127.0.0.1:8000,server=y,suspend=y" + + Realize you may need to update the address for your system. More details can be found at {{{http://www.ibm.com/developerworks/opensource/library/os-eclipse-javadebug/index.html}IBM}} - + In eclipse create a debug configuration for VXQuery using Java remote application settings. The default - setting will most likely work out of the box. To show all the source code for debugging, add all the + setting will most likely work out of the box. To show all the source code for debugging, add all the source code for the eclipse workspace. To begin the debug process, execute the command below. In eclipse select the new debug configuration http://git-wip-us.apache.org/repos/asf/vxquery/blob/08919109/src/site/apt/user_query.apt ---------------------------------------------------------------------- diff --git a/src/site/apt/user_query.apt b/src/site/apt/user_query.apt index a022825..8ea6429 100644 --- a/src/site/apt/user_query.apt +++ b/src/site/apt/user_query.apt @@ -25,8 +25,9 @@ sh ./apache-vxquery-X.Y/vxquery-cli/target/appassembler/bin/vxq * Commands On Windows Based Systems ---------------------------------------- -cd apache-vxquery-X.Y/vxquery-cli/target/appassembler/bin -vxq.bat +set JAVA_OPTS=-Xmx1024m +set PATH=%PATH%;"path-to"\apache-vxquery-X.Y\vxquery-cli\target\appassembler\bin\ +vxq "path-to"\test.xq ---------------------------------------- * Command Line Options @@ -56,14 +57,14 @@ vxq.bat JAVA_OPTS="-Xmx1024m" ---------------------------------------- - + * Example - The following example query is from {{{http://www.w3schools.com/xquery/default.asp}W3Schools XQuery Tutorial}}. + The following example query is from {{{http://www.w3schools.com/xquery/default.asp}W3Schools XQuery Tutorial}}. If you are new to XQuery, the W3Schools tutorial is a great place to start. - + [[i]] Query file (test.xq) - + ---------------------------------------- for $x in doc("books.xml")/bookstore/book where $x/price>30 @@ -72,7 +73,7 @@ return $x/title ---------------------------------------- [[i]] Command line - + ---------------------------------------- JAVA_OPTS="-Xmx1024m" sh ./apache-vxquery-X.Y/vxquery-cli/target/appassembler/bin/vxq test.xq ----------------------------------------
