full path for cluster.properties

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

Branch: refs/heads/steven/hdfs
Commit: 89c4ac7ee4073b407258d7944b3a7f6b3d5acdd0
Parents: ce741a0
Author: efikalti <[email protected]>
Authored: Tue Aug 18 19:09:41 2015 +0300
Committer: efikalti <[email protected]>
Committed: Tue Aug 18 19:09:41 2015 +0300

----------------------------------------------------------------------
 .../org/apache/vxquery/compiler/rewriter/RewriteRuleset.java | 2 +-
 .../main/java/org/apache/vxquery/hdfs2/HDFSFunctions.java    | 8 +++++---
 vxquery-server/src/main/resources/conf/cluster.properties    | 2 +-
 3 files changed, 7 insertions(+), 5 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/vxquery/blob/89c4ac7e/vxquery-core/src/main/java/org/apache/vxquery/compiler/rewriter/RewriteRuleset.java
----------------------------------------------------------------------
diff --git 
a/vxquery-core/src/main/java/org/apache/vxquery/compiler/rewriter/RewriteRuleset.java
 
b/vxquery-core/src/main/java/org/apache/vxquery/compiler/rewriter/RewriteRuleset.java
index 1afdead..1940651 100644
--- 
a/vxquery-core/src/main/java/org/apache/vxquery/compiler/rewriter/RewriteRuleset.java
+++ 
b/vxquery-core/src/main/java/org/apache/vxquery/compiler/rewriter/RewriteRuleset.java
@@ -21,13 +21,13 @@ import java.util.List;
 
 import org.apache.vxquery.compiler.rewriter.rules.CollectionWithTagRule;
 import 
org.apache.vxquery.compiler.rewriter.rules.ConsolidateAssignAggregateRule;
+import org.apache.vxquery.compiler.rewriter.rules.ConsolidateDescandantChild;
 import org.apache.vxquery.compiler.rewriter.rules.ConvertAssignToUnnestRule;
 import 
org.apache.vxquery.compiler.rewriter.rules.ConvertFromAlgebricksExpressionsRule;
 import 
org.apache.vxquery.compiler.rewriter.rules.ConvertToAlgebricksExpressionsRule;
 import 
org.apache.vxquery.compiler.rewriter.rules.EliminateSubplanForSingleItemsRule;
 import 
org.apache.vxquery.compiler.rewriter.rules.EliminateUnnestAggregateSequencesRule;
 import 
org.apache.vxquery.compiler.rewriter.rules.EliminateUnnestAggregateSubplanRule;
-import org.apache.vxquery.compiler.rewriter.rules.InlineNestedVariablesRule;
 import org.apache.vxquery.compiler.rewriter.rules.IntroduceCollectionRule;
 import 
org.apache.vxquery.compiler.rewriter.rules.IntroduceTwoStepAggregateRule;
 import org.apache.vxquery.compiler.rewriter.rules.PushChildIntoDataScanRule;

http://git-wip-us.apache.org/repos/asf/vxquery/blob/89c4ac7e/vxquery-core/src/main/java/org/apache/vxquery/hdfs2/HDFSFunctions.java
----------------------------------------------------------------------
diff --git 
a/vxquery-core/src/main/java/org/apache/vxquery/hdfs2/HDFSFunctions.java 
b/vxquery-core/src/main/java/org/apache/vxquery/hdfs2/HDFSFunctions.java
index 8e21577..60682d7 100644
--- a/vxquery-core/src/main/java/org/apache/vxquery/hdfs2/HDFSFunctions.java
+++ b/vxquery-core/src/main/java/org/apache/vxquery/hdfs2/HDFSFunctions.java
@@ -159,9 +159,7 @@ public class HDFSFunctions {
      * @return true if is successfully finds the Hadoop/HDFS home directory
      */
     private boolean locateConf() {
-        this.conf_path = System.getenv("HADOOP_CONF_DIR");
         if (this.conf_path == null) {
-            
             // load properties file
             Properties prop = new Properties();
             String propFilePath = 
"../vxquery-server/src/main/resources/conf/cluster.properties";
@@ -178,9 +176,13 @@ public class HDFSFunctions {
                 System.err.println(e);
                 return false;
             }
-
             // get the property value for HDFS_CONF
             this.conf_path = prop.getProperty("HDFS_CONF");
+            if (this.conf_path == null)
+            {
+                this.conf_path = System.getenv("HADOOP_CONF_DIR");
+                return this.conf_path != null;
+            }
             return this.conf_path != null;
         }
         return this.conf_path != null;

http://git-wip-us.apache.org/repos/asf/vxquery/blob/89c4ac7e/vxquery-server/src/main/resources/conf/cluster.properties
----------------------------------------------------------------------
diff --git a/vxquery-server/src/main/resources/conf/cluster.properties 
b/vxquery-server/src/main/resources/conf/cluster.properties
index 8f6fa1c..0a7bc81 100644
--- a/vxquery-server/src/main/resources/conf/cluster.properties
+++ b/vxquery-server/src/main/resources/conf/cluster.properties
@@ -54,4 +54,4 @@ NCJAVA_OPTS="-server -Xmx7G 
-Djava.util.logging.config.file=./vxquery-benchmark/
 # Yourkit mac option: 
-agentpath:/Applications/YourKit_Java_Profiler.app/bin/mac/libyjpagent.jnilib=sampling
 
 #HDFS configuration directory
-HDFS_CONF=vxquery-xtest/src/test/resources/hadoop/conf
+HDFS_CONF=/home/efi/Projects/vxquery/vxquery-xtest/src/test/resources/hadoop/conf

Reply via email to