You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@trafodion.apache.org by su...@apache.org on 2015/10/14 22:28:29 UTC

[1/3] incubator-trafodion git commit: Fixed version issue in DCS Added a new target to Makefile(toplevel and core) to install traf components( eg: make trafinstall) Updated the format of DCS log files fixed minor issues

Repository: incubator-trafodion
Updated Branches:
  refs/heads/master 64c5f79af -> 7bb805d48


Fixed version issue in DCS
Added a new target to Makefile(toplevel and core) to install
traf components( eg: make trafinstall)
Updated the format of DCS log files
fixed minor issues


Project: http://git-wip-us.apache.org/repos/asf/incubator-trafodion/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-trafodion/commit/5a2eceb6
Tree: http://git-wip-us.apache.org/repos/asf/incubator-trafodion/tree/5a2eceb6
Diff: http://git-wip-us.apache.org/repos/asf/incubator-trafodion/diff/5a2eceb6

Branch: refs/heads/master
Commit: 5a2eceb6c0f8d36010b48f57e94a020c86a71f1d
Parents: df76bab
Author: Anuradha Hegde <he...@dev02.trafodion.org>
Authored: Wed Oct 14 05:02:16 2015 +0000
Committer: Anuradha Hegde <he...@dev02.trafodion.org>
Committed: Wed Oct 14 05:02:16 2015 +0000

----------------------------------------------------------------------
 Makefile                                        |  4 +
 core/Makefile                                   |  4 +
 .../org/trafodion/rest/VersionAnnotation.java   |  4 +-
 .../org/trafodion/rest/version/util/VerGen.java |  2 +-
 core/sqf/sql/scripts/install_local_hadoop       | 50 +------------
 core/sqf/sql/scripts/install_traf_components    | 79 ++++++++++++++++++--
 dcs/bin/stop-dcs.sh                             |  3 +
 dcs/conf/log4j.properties                       |  2 +-
 .../org/trafodion/dcs/VersionAnnotation.java    |  4 +-
 .../org/trafodion/dcs/version/util/VerGen.java  |  2 +-
 .../resources/dcs-webapps/master/servers.jsp    |  4 +-
 dcs/src/saveVersion.sh                          |  2 +-
 wms/bin/scripts/hp_default_service.py           | 66 ----------------
 wms/bin/scripts/traf_default_service.py         | 66 ++++++++++++++++
 14 files changed, 161 insertions(+), 131 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-trafodion/blob/5a2eceb6/Makefile
----------------------------------------------------------------------
diff --git a/Makefile b/Makefile
index e02f71b..9e80e30 100644
--- a/Makefile
+++ b/Makefile
@@ -52,3 +52,7 @@ clean:
 cleanall:
 	@echo "Removing all Trafodion objects"
 	cd core && $(MAKE) cleanall 
+
+trafinstall:
+	@echo "Installing Trafodion components"
+	cd core && $(MAKE) trafinstall

http://git-wip-us.apache.org/repos/asf/incubator-trafodion/blob/5a2eceb6/core/Makefile
----------------------------------------------------------------------
diff --git a/core/Makefile b/core/Makefile
index 28df509..3bd0bb9 100644
--- a/core/Makefile
+++ b/core/Makefile
@@ -100,6 +100,7 @@ odb: ndcs
 cleantests:
 	cd ../dcs/src/test/pytests && $(RM) -r odbc* tox.ini config.ini .tox .testrep* env.sh test_p2.pyc 
 	cd ../dcs/src/test/jdbc_test && $(RM) -r jdbcprop pom.xml  target
+	cd ../tests/phx && $(RM) -r jdbcprop *.log pom.xml target
 	
 clean: sqroot
 	cd $(MPI_TARGET) &&		$(MAKE) clean-local
@@ -198,3 +199,6 @@ eclipseclean:
 	$(RM) sql/.classpath sql/.project
 	$(RM) sqf/src/seatrans/hbase-trx/.classpath sqf/src/seatrans/hbase-trx/.project
 	$(RM) .cproject .project
+
+trafinstall:
+	cd $(MY_SQROOT)/sql/scripts && install_traf_components

http://git-wip-us.apache.org/repos/asf/incubator-trafodion/blob/5a2eceb6/core/rest/src/main/java/org/trafodion/rest/VersionAnnotation.java
----------------------------------------------------------------------
diff --git a/core/rest/src/main/java/org/trafodion/rest/VersionAnnotation.java b/core/rest/src/main/java/org/trafodion/rest/VersionAnnotation.java
index ffa8b5e..9c44f32 100644
--- a/core/rest/src/main/java/org/trafodion/rest/VersionAnnotation.java
+++ b/core/rest/src/main/java/org/trafodion/rest/VersionAnnotation.java
@@ -47,12 +47,12 @@ public @interface VersionAnnotation {
   String date();
 
   /**
-   * Get the url for the subversion repository.
+   * Get the url for the repository.
    */
   String url();
 
   /**
-   * Get the subversion revision.
+   * Get the revision.
    * @return the revision number as a string (eg. "451451")
    */
   String revision();

http://git-wip-us.apache.org/repos/asf/incubator-trafodion/blob/5a2eceb6/core/rest/src/main/java/org/trafodion/rest/version/util/VerGen.java
----------------------------------------------------------------------
diff --git a/core/rest/src/main/java/org/trafodion/rest/version/util/VerGen.java b/core/rest/src/main/java/org/trafodion/rest/version/util/VerGen.java
index 6e64d01..1229399 100644
--- a/core/rest/src/main/java/org/trafodion/rest/version/util/VerGen.java
+++ b/core/rest/src/main/java/org/trafodion/rest/version/util/VerGen.java
@@ -151,7 +151,7 @@ public class VerGen {
      *            <li>min - minor version number
      *            <li>micro - minor minor version number
      *            <li>qualifier - optional qualifier (dash followed by qualifier text)
-     *            <li>rev - current SVN revision number
+     *            <li>rev - current revision number
      *            <li>buildDate - date the build
      *            </ul>
      */

http://git-wip-us.apache.org/repos/asf/incubator-trafodion/blob/5a2eceb6/core/sqf/sql/scripts/install_local_hadoop
----------------------------------------------------------------------
diff --git a/core/sqf/sql/scripts/install_local_hadoop b/core/sqf/sql/scripts/install_local_hadoop
index 7dbe2f2..755a307 100755
--- a/core/sqf/sql/scripts/install_local_hadoop
+++ b/core/sqf/sql/scripts/install_local_hadoop
@@ -1541,57 +1541,9 @@ if [ ! -r $YARN_HOME/lib/native/libhdfs.so ]; then
   echo "------------------------------------------------------------"
 fi
 
-echo "Setting up configuration script for dcs, rest and trafci..."
-
-# For DCS
-cat >$HOME/.dcs-site.xml-$USER <<EOF
-    <property>
-     <name>dcs.master.port</name> <value>$MY_DCS_MASTER_PORT</value>
-    </property>
-    <property>
-     <name>dcs.master.info.port</name> <value>$MY_DCS_MASTER_INFO_PORT</value>
-    </property>
-    <property>
-     <name>dcs.server.info.port</name> <value>$MY_DCS_SERVER_INFO_PORT</value>
-    </property>
-    <property>
-     <name>dcs.zookeeper.peerport</name> <value>$MY_HBASE_ZOOKEEPER_PEERPORT_NUM</value>
-    </property>
-    <property>
-     <name>dcs.zookeeper.leaderport</name> <value>$MY_HBASE_ZOOKEEPER_LEADERPORT_NUM</value>
-    </property>
-    <property>
-     <name>dcs.zookeeper.property.clientPort</name> <value>$MY_HBASE_ZOOKEEPER_PROPERTY_CLIENTPORT_NUM</value>
-    </property>
-EOF
-
-# For rest
-
-cat >$HOME/.rest-site.xml-$USER <<EOF
-    <property>
-     <name>rest.port</name> <value>$MY_REST_SERVER_PORT</value>
-    </property>
-    <property>
-     <name>rest.https.port</name> <value>$MY_REST_SERVER_SECURE_PORT</value>
-    </property>
-    <property>
-     <name>rest.zookeeper.peerport</name> <value>$MY_HBASE_ZOOKEEPER_PEERPORT_NUM</value>
-    </property>
-    <property>
-     <name>rest.zookeeper.leaderport</name> <value>$MY_HBASE_ZOOKEEPER_LEADERPORT_NUM</value>
-    </property>
-    <property>
-     <name>rest.zookeeper.property.clientPort</name> <value>$MY_HBASE_ZOOKEEPER_PROPERTY_CLIENTPORT_NUM</value>
-    </property>
-EOF
-
 #For clients
 cat >$HOME/.traf-clports-$USER <<EOF
-DCS_MASTER=$MY_DCS_MASTER_PORT
-REST_SERVER=$MY_REST_SERVER_PORT
-REST_SECURE_SERVER=$MY_REST_SERVER_SECURE_PORT
-DB_MGR=$MY_DB_MGR_PORT
-DB_SECURE_MGR=$MY_DB_MGR_SECURE_PORT
+HADOOP_START_PORT=$MY_START_PORT
 EOF
 
 echo

http://git-wip-us.apache.org/repos/asf/incubator-trafodion/blob/5a2eceb6/core/sqf/sql/scripts/install_traf_components
----------------------------------------------------------------------
diff --git a/core/sqf/sql/scripts/install_traf_components b/core/sqf/sql/scripts/install_traf_components
index a4ea09f..26a54c4 100755
--- a/core/sqf/sql/scripts/install_traf_components
+++ b/core/sqf/sql/scripts/install_traf_components
@@ -24,6 +24,19 @@
 MY_SW_ROOT=$MY_SQROOT/sql/local_hadoop
 MY_LOG_FILE=$MY_SW_ROOT/log/install_traf_components_$(date +%F_%T).log
 
+# Define ports for Trafodion components
+MY_START_PORT=`cat $HOME/.traf-clports-$USER |grep HADOOP_START_PORT |cut -d "=" -f2`
+MY_HBASE_ZOOKEEPER_PEERPORT_NUM=`expr $MY_START_PORT + 167`
+MY_HBASE_ZOOKEEPER_LEADERPORT_NUM=`expr $MY_START_PORT + 168`
+MY_HBASE_ZOOKEEPER_PROPERTY_CLIENTPORT_NUM=`expr $MY_START_PORT + 170`
+MY_DCS_MASTER_PORT=`expr $MY_START_PORT + 172`
+MY_DCS_MASTER_INFO_PORT=`expr $MY_START_PORT + 181`
+MY_DCS_SERVER_INFO_PORT=`expr $MY_START_PORT + 182`
+MY_REST_SERVER_PORT=`expr $MY_START_PORT + 193`
+MY_REST_SERVER_SECURE_PORT=`expr $MY_START_PORT + 194`
+MY_DB_MGR_PORT=`expr $MY_START_PORT + 195`
+MY_DB_MGR_SECURE_PORT=`expr $MY_START_PORT + 196`
+
 # Default location of Trafodion, DCS, REST and Phoenix src folders
 TRAF_SRC=$MY_SQROOT/../../
 DCS_SRC=$MY_SQROOT/../../dcs
@@ -31,8 +44,6 @@ REST_SRC=$MY_SQROOT/../rest
 PHX_SRC=$MY_SQROOT/../../tests/phx
 TRAF_TARS=$MY_SQROOT/../../distribution
 
-MY_DCS_MASTER_PORT=`cat $HOME/.traf-clports-$USER |grep DCS_MASTER |cut -d "=" -f2`
-
 if [ -z "$DCS_TAR" ]; then
   DCS_TAR=$(ls $TRAF_TARS/dcs*tar.gz 2>/dev/null)
 fi
@@ -143,8 +154,27 @@ else
   sed -e "s@#[ ]*export DCS_MANAGES_ZK=true@export DCS_MANAGES_ZK=false@" dcs-env.sh.orig >> dcs-env.sh
   mv -f dcs-site.xml dcs-site.xml.orig
   sed -e "s@</configuration>@@" dcs-site.xml.orig > dcs-site.xml
-  cat $HOME/.dcs-site.xml-$USER >> $DCS_HOME/conf/dcs-site.xml
-  echo "</configuration>" >> $DCS_HOME/conf/dcs-site.xml
+  cat >>dcs-site.xml <<EOF
+    <property>
+     <name>dcs.master.port</name> <value>$MY_DCS_MASTER_PORT</value>
+    </property>
+    <property>
+     <name>dcs.master.info.port</name> <value>$MY_DCS_MASTER_INFO_PORT</value>
+    </property>
+    <property>
+     <name>dcs.server.info.port</name> <value>$MY_DCS_SERVER_INFO_PORT</value>
+    </property>
+    <property>
+     <name>dcs.zookeeper.peerport</name> <value>$MY_HBASE_ZOOKEEPER_PEERPORT_NUM</value>
+    </property>
+    <property>
+     <name>dcs.zookeeper.leaderport</name> <value>$MY_HBASE_ZOOKEEPER_LEADERPORT_NUM</value>
+    </property>
+    <property>
+     <name>dcs.zookeeper.property.clientPort</name> <value>$MY_HBASE_ZOOKEEPER_PROPERTY_CLIENTPORT_NUM</value>
+    </property>
+  </configuration>
+EOF
 
   echo "Configured $DCS_HOME/conf/dcs-site.xml" | tee -a ${MY_LOG_FILE}
 
@@ -207,10 +237,47 @@ else
   sed -e "s@#[ ]*export REST_MANAGES_ZK=true@export REST_MANAGES_ZK=false@" rest-env.sh.orig >> rest-env.sh
   mv -f rest-site.xml rest-site.xml.orig
   sed -e "s@</configuration>@@" rest-site.xml.orig > rest-site.xml
-  cat $HOME/.rest-site.xml-$USER >> $REST_HOME/conf/rest-site.xml
-  echo "</configuration>" >> $REST_HOME/conf/rest-site.xml
+  cat >>rest-site.xml <<EOF
+    <property>
+     <name>rest.port</name> <value>$MY_REST_SERVER_PORT</value>
+    </property>
+    <property>
+     <name>rest.https.port</name> <value>$MY_REST_SERVER_SECURE_PORT</value>
+    </property>
+    <property>
+     <name>rest.zookeeper.peerport</name> <value>$MY_HBASE_ZOOKEEPER_PEERPORT_NUM</value>
+    </property>
+    <property>
+     <name>rest.zookeeper.leaderport</name> <value>$MY_HBASE_ZOOKEEPER_LEADERPORT_NUM</value>
+    </property>
+    <property>
+     <name>rest.zookeeper.property.clientPort</name> <value>$MY_HBASE_ZOOKEEPER_PROPERTY_CLIENTPORT_NUM</value>
+    </property>
+  </configuration>
+EOF
 
   echo "Configured $REST_HOME/conf/rest-site.xml" | tee -a ${MY_LOG_FILE}
+  echo "Adding swrest script..." | tee -a ${MY_LOG_FILE}
+  cat <<EOF >$MY_SQROOT/sql/scripts/swrest
+#!/bin/sh
+# command to run rest tests
+#Displays the status of configured servers
+curl -X GET -H "Accept: application/json" http://localhost:$MY_REST_SERVER_PORT/v1/servers| python -m json.tool
+
+#Displays the status of dtm
+curl -X GET -H "Accept: application/json" http://localhost:$MY_REST_SERVER_PORT/v1/servers/dtm| python -m json.tool
+
+#Displays the status of rms
+curl -X GET -H "Accept: application/json" http://localhost:$MY_REST_SERVER_PORT/v1/servers/rms| python -m json.tool
+
+#Displays the status of configured dcs servers
+curl -X GET -H "Accept: application/json" http://localhost:$MY_REST_SERVER_PORT/v1/servers/dcs | python -m json.tool
+
+#Displays the status of dcs connections
+curl -X GET -H "Accept: application/json" http://localhost:$MY_REST_SERVER_PORT/v1/servers/dcs/connections | python -m json.tool
+EOF
+
+     chmod +x $MY_SQROOT/sql/scripts/swrest
 fi
 
 # End of setup for REST

http://git-wip-us.apache.org/repos/asf/incubator-trafodion/blob/5a2eceb6/dcs/bin/stop-dcs.sh
----------------------------------------------------------------------
diff --git a/dcs/bin/stop-dcs.sh b/dcs/bin/stop-dcs.sh
index 9d594d1..682fa92 100755
--- a/dcs/bin/stop-dcs.sh
+++ b/dcs/bin/stop-dcs.sh
@@ -42,6 +42,9 @@ master=`$bin/dcs --config "${DCS_CONF_DIR}" org.trafodion.dcs.zookeeper.ZkUtil /
 errCode=$?
 if [ $errCode -ne 0 ]
 then
+  echo "Zookeeper exception occured, killing all DcsMaster and DcsServers..."
+  "$bin"/dcs-daemon.sh --config "${DCS_CONF_DIR}" stop master 
+  "$bin"/dcs-daemons.sh --config "${DCS_CONF_DIR}" --hosts "${DCS_SERVERS}" stop server 
   exit $errCode
 fi
 

http://git-wip-us.apache.org/repos/asf/incubator-trafodion/blob/5a2eceb6/dcs/conf/log4j.properties
----------------------------------------------------------------------
diff --git a/dcs/conf/log4j.properties b/dcs/conf/log4j.properties
index 1b7f9d6..52e97f1 100644
--- a/dcs/conf/log4j.properties
+++ b/dcs/conf/log4j.properties
@@ -42,7 +42,7 @@ log4j.appender.DRFA.DatePattern=.yyyy-MM-dd
 #log4j.appender.DRFA.MaxBackupIndex=30
 log4j.appender.DRFA.layout=org.apache.log4j.PatternLayout
 # Pattern format: Date LogLevel LoggerName LogMessage
-log4j.appender.DRFA.layout.ConversionPattern=%d{ISO8601} %p %c: %m%n
+log4j.appender.DRFA.layout.ConversionPattern=%d{ISO8601}, %p, %c, Node Number: , CPU: , PIN: , Process Name: , , ,%m%n
 # Debugging Pattern format
 #log4j.appender.DRFA.layout.ConversionPattern=%d{ISO8601} %-5p %c{2} (%F:%M(%L)) - %m%n
 

http://git-wip-us.apache.org/repos/asf/incubator-trafodion/blob/5a2eceb6/dcs/src/main/java/org/trafodion/dcs/VersionAnnotation.java
----------------------------------------------------------------------
diff --git a/dcs/src/main/java/org/trafodion/dcs/VersionAnnotation.java b/dcs/src/main/java/org/trafodion/dcs/VersionAnnotation.java
index 25a0d23..7fdeb37 100644
--- a/dcs/src/main/java/org/trafodion/dcs/VersionAnnotation.java
+++ b/dcs/src/main/java/org/trafodion/dcs/VersionAnnotation.java
@@ -78,12 +78,12 @@ public @interface VersionAnnotation {
   String date();
 
   /**
-   * Get the url for the subversion repository.
+   * Get the url for the repository.
    */
   String url();
 
   /**
-   * Get the subversion revision.
+   * Get the revision.
    * @return the revision number as a string (eg. "451451")
    */
   String revision();

http://git-wip-us.apache.org/repos/asf/incubator-trafodion/blob/5a2eceb6/dcs/src/main/java/org/trafodion/dcs/version/util/VerGen.java
----------------------------------------------------------------------
diff --git a/dcs/src/main/java/org/trafodion/dcs/version/util/VerGen.java b/dcs/src/main/java/org/trafodion/dcs/version/util/VerGen.java
index 473f8cb..de78241 100644
--- a/dcs/src/main/java/org/trafodion/dcs/version/util/VerGen.java
+++ b/dcs/src/main/java/org/trafodion/dcs/version/util/VerGen.java
@@ -170,7 +170,7 @@ public class VerGen {
      *            <li>min - minor version number
      *            <li>micro - minor minor version number
      *            <li>qualifier - optional qualifier (dash followed by qualifier text)
-     *            <li>rev - current SVN revision number
+     *            <li>rev - current revision number
      *            <li>buildDate - date the build
      *            </ul>
      */

http://git-wip-us.apache.org/repos/asf/incubator-trafodion/blob/5a2eceb6/dcs/src/main/resources/dcs-webapps/master/servers.jsp
----------------------------------------------------------------------
diff --git a/dcs/src/main/resources/dcs-webapps/master/servers.jsp b/dcs/src/main/resources/dcs-webapps/master/servers.jsp
index 0e6316d..22cf61e 100644
--- a/dcs/src/main/resources/dcs-webapps/master/servers.jsp
+++ b/dcs/src/main/resources/dcs-webapps/master/servers.jsp
@@ -108,7 +108,7 @@
 <col />
 <col style="width: 20%;"/>
 <tr><th>Attribute Name</th><th>Value</th><th>Description</th></tr>
-<tr><td>Version</td><td><%= version %>, r<%= revision %></td><td> The version and revision</td></tr>
+<tr><td>Version</td><td><%= version %>, <%= revision %></td><td> The version and revision</td></tr>
 <tr><td>Compiled</td><td><%= buildDate %>, <%= user %></td><td>When this version was compiled and by whom</td></tr>
 <tr><td>Start Time</td><td><%= startTime %></td><td>When this server was started</td></tr>
 <tr><td>Listener</td><td><%= port %>:<%= portRange %></td><td>Listener starting port and range</td></tr>
@@ -195,4 +195,4 @@ entries
     }  
     %>
 </body>
-</html>        
\ No newline at end of file
+</html>        

http://git-wip-us.apache.org/repos/asf/incubator-trafodion/blob/5a2eceb6/dcs/src/saveVersion.sh
----------------------------------------------------------------------
diff --git a/dcs/src/saveVersion.sh b/dcs/src/saveVersion.sh
index bee6ee2..11b41da 100644
--- a/dcs/src/saveVersion.sh
+++ b/dcs/src/saveVersion.sh
@@ -32,7 +32,7 @@ outputDirectory=$2
 user=`whoami`
 date=`date`
 cwd=`pwd`
-if [[ -d ../../.git ]]; then
+if [[ -d ../.git ]]; then
     revision=`git log -1 --pretty=format:"%h"`
     hostname=`hostname`
     url="git://${hostname}${cwd}"

http://git-wip-us.apache.org/repos/asf/incubator-trafodion/blob/5a2eceb6/wms/bin/scripts/hp_default_service.py
----------------------------------------------------------------------
diff --git a/wms/bin/scripts/hp_default_service.py b/wms/bin/scripts/hp_default_service.py
deleted file mode 100644
index ce6b210..0000000
--- a/wms/bin/scripts/hp_default_service.py
+++ /dev/null
@@ -1,66 +0,0 @@
-#/**
-#* @@@ START COPYRIGHT @@@
-#
-#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.
-#
-# @@@ END COPYRIGHT @@@
-# */
-from java.lang import System
-from org.trafodion.wms.thrift.generated import Action 
-from org.trafodion.wms.thrift.generated import Operation
-
-def begin():
-    response.getData().setAction(Action.ACTION_CONTINUE)
-#    print 'Thresholds before [%s]' % thresholds.toString()
-#    thresholds.setMaxMemUsage(5)
-#    print 'Thresholds after [%s]' % thresholds.toString()
- 
-
-def update():
-    return
-
-#    jobType = request.getJobType()
-#    if jobType != JobType.HIVE  :
-#        return
-
-#    elapsed = System.currentTimeMillis() - request.getData().getBeginTimestamp()
-#    if elapsed > 60000L :
-#        print 'Canceling...elapsed time [%s] milliseconds' % elapsed
-#        response.getData().setAction(Action.ACTION_CANCEL)
-        
-def end():
-    return
-
-def start():
-    operation = request.getData().getOperation().toString()
-
-    if operation == "OPERATION_BEGIN" :
-        begin()
-    elif operation == "OPERATION_UPDATE" :
-        update()
-    elif operation == "OPERATION_END" :
-        end()
-    else :
-        response.getData().setAction(Action.ACTION_CONTINUE)
-
-#######################################################################
-#                main portion of script starts here
-#######################################################################
-print 'Rcvd request[%s]' % request
-start()
-print 'Send response:[%s]' % response

http://git-wip-us.apache.org/repos/asf/incubator-trafodion/blob/5a2eceb6/wms/bin/scripts/traf_default_service.py
----------------------------------------------------------------------
diff --git a/wms/bin/scripts/traf_default_service.py b/wms/bin/scripts/traf_default_service.py
new file mode 100644
index 0000000..ce6b210
--- /dev/null
+++ b/wms/bin/scripts/traf_default_service.py
@@ -0,0 +1,66 @@
+#/**
+#* @@@ START COPYRIGHT @@@
+#
+#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.
+#
+# @@@ END COPYRIGHT @@@
+# */
+from java.lang import System
+from org.trafodion.wms.thrift.generated import Action 
+from org.trafodion.wms.thrift.generated import Operation
+
+def begin():
+    response.getData().setAction(Action.ACTION_CONTINUE)
+#    print 'Thresholds before [%s]' % thresholds.toString()
+#    thresholds.setMaxMemUsage(5)
+#    print 'Thresholds after [%s]' % thresholds.toString()
+ 
+
+def update():
+    return
+
+#    jobType = request.getJobType()
+#    if jobType != JobType.HIVE  :
+#        return
+
+#    elapsed = System.currentTimeMillis() - request.getData().getBeginTimestamp()
+#    if elapsed > 60000L :
+#        print 'Canceling...elapsed time [%s] milliseconds' % elapsed
+#        response.getData().setAction(Action.ACTION_CANCEL)
+        
+def end():
+    return
+
+def start():
+    operation = request.getData().getOperation().toString()
+
+    if operation == "OPERATION_BEGIN" :
+        begin()
+    elif operation == "OPERATION_UPDATE" :
+        update()
+    elif operation == "OPERATION_END" :
+        end()
+    else :
+        response.getData().setAction(Action.ACTION_CONTINUE)
+
+#######################################################################
+#                main portion of script starts here
+#######################################################################
+print 'Rcvd request[%s]' % request
+start()
+print 'Send response:[%s]' % response


[2/3] incubator-trafodion git commit: Merge remote branch 'origin/master' into wrk-brnch

Posted by su...@apache.org.
Merge remote branch 'origin/master' into wrk-brnch

Conflicts:
	core/Makefile


Project: http://git-wip-us.apache.org/repos/asf/incubator-trafodion/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-trafodion/commit/9d033a10
Tree: http://git-wip-us.apache.org/repos/asf/incubator-trafodion/tree/9d033a10
Diff: http://git-wip-us.apache.org/repos/asf/incubator-trafodion/diff/9d033a10

Branch: refs/heads/master
Commit: 9d033a108ae6815439200c9848b2430d97f38558
Parents: 5a2eceb f3c557c
Author: Anuradha Hegde <he...@dev02.trafodion.org>
Authored: Wed Oct 14 15:23:21 2015 +0000
Committer: Anuradha Hegde <he...@dev02.trafodion.org>
Committed: Wed Oct 14 15:23:21 2015 +0000

----------------------------------------------------------------------
 .rat-excludes                                   |  105 ++
 RAT_README.txt                                  |   67 +
 core/Makefile                                   |    6 +-
 core/bldenvchk.sh                               |   19 +-
 core/conn/jdbc_type2/jdbct2.jar.version         |    1 -
 core/conn/jdbc_type2/macros.gmk                 |    2 +-
 core/conn/jdbc_type4/jdbct4.jar.version         |    1 -
 core/conn/jdbc_type4/lib/.empty-dir             |    0
 .../org/trafodion/jdbc/t4/HPT4DataSource.java   |    2 +-
 .../org/trafodion/jdbc/t4/T4DSProperties.java   |    2 +-
 core/conn/odbc/src/odbc/macros.gmk              |    2 +-
 .../trafciDefaultLookAndFeel.properties         |   23 +
 core/rest/conf/log4j.properties                 |   23 +
 core/rest/conf/realm.properties                 |   23 +
 core/rest/src/test/resources/log4j.properties   |   23 +
 core/sqf/.gitignore                             |    4 +
 core/sqf/Makefile                               |   15 +-
 core/sqf/export/bin64/.empty-dir                |    0
 core/sqf/export/bin64d/.empty-dir               |    0
 core/sqf/export/lib/Parse/RecDescent.pm         |   23 +
 core/sqf/inc/windows/windows.h                  |    1 -
 core/sqf/inc/windows/winnt.h                    |    0
 core/sqf/inc/windows/winperf.h                  |    1 -
 core/sqf/inc/windows/winsock2.h                 |    0
 core/sqf/sqenvcom.sh                            |   61 +-
 core/sqf/sql/Makefile                           |    2 +-
 core/sqf/sql/scripts/get_libhdfs_files          |  222 +++
 core/sqf/sqvers                                 |    2 +-
 core/sqf/src/seatrans/.gitignore                |    1 +
 core/sqf/src/seatrans/hbase-trx/genvers         |   23 +
 .../hbase-trx/hbase-protocol/.classpath         |   12 -
 .../seatrans/hbase-trx/hbase-protocol/.project  |   13 -
 .../tm/hbasetmlib2/HBaseAuditControlPoint.java  |  416 ------
 .../src/seatrans/tm/hbasetmlib2/HBaseTmZK.java  |  247 ----
 .../seatrans/tm/hbasetmlib2/HBaseTxClient.java  | 1375 ------------------
 .../seatrans/tm/hbasetmlib2/HashMapArray.java   |  229 ---
 core/sqf/src/seatrans/tm/hbasetmlib2/Makefile   |   30 +-
 .../seatrans/tm/hbasetmlib2/TmAuditTlog.java    | 1201 ---------------
 .../src/seatrans/tm/hbasetmlib2/TrafInfo.java   |  204 ---
 core/sqf/src/seatrans/tm/hbasetmlib2/pom.xml    |  110 ++
 .../trafodion/dtm/HBaseAuditControlPoint.java   |  416 ++++++
 .../main/java/org/trafodion/dtm/HBaseTmZK.java  |  247 ++++
 .../java/org/trafodion/dtm/HBaseTxClient.java   | 1375 ++++++++++++++++++
 .../java/org/trafodion/dtm/HashMapArray.java    |  229 +++
 .../java/org/trafodion/dtm/TmAuditTlog.java     | 1201 +++++++++++++++
 .../main/java/org/trafodion/dtm/TrafInfo.java   |  204 +++
 core/sql/SqlCompilerDebugger/AboutBox.ui        |   19 +
 .../sql/SqlCompilerDebugger/BreakpointDialog.ui |   19 +
 .../SqlCompilerDebugger/ItemExpressionView.ui   |   19 +
 core/sql/SqlCompilerDebugger/MainWindow.ui      |   19 +
 core/sql/SqlCompilerDebugger/PropDialog.ui      |   19 +
 .../SqlCompilerDebugger/QueryAnalysisView.ui    |   19 +
 core/sql/SqlCompilerDebugger/QueryMemoView.ui   |   19 +
 core/sql/SqlCompilerDebugger/QueryTreeView.ui   |   19 +
 core/sql/SqlCompilerDebugger/RulesDialog.ui     |   19 +
 core/sql/SqlCompilerDebugger/TDBDlgExprList.ui  |   19 +
 core/sql/SqlCompilerDebugger/TDBDlgMdamNet.ui   |   19 +
 core/sql/SqlCompilerDebugger/TDBTreeView.ui     |   19 +
 core/sql/SqlCompilerDebugger/ViewContainer.ui   |   19 +
 core/sql/bin/English.lng                        |    2 -
 .../executor/trafodion-HBaseAccess.jar.version  |    3 -
 core/sql/langman/mxlangman.jar.version          |    3 -
 core/sql/nskgmake/Makerules.build               |    1 -
 core/sql/nskgmake/Makerules.linux               |   62 +-
 core/sql/nskgmake/Makerules.mk                  |    2 +-
 core/sql/nskgmake/tdm_sqlcli/Makefile           |    2 +-
 core/sql/nskgmake/tdm_sqlmxmsg_intl/Makefile    |   25 -
 core/sql/optimizer/mdam.cpp                     |   12 +-
 core/sql/pom.xml                                |   43 +-
 core/sql/qmscommon/QRQueries.cpp                |    4 +-
 core/sql/regress/hive/EXPECTED009               |    8 +-
 core/sql/regress/udr/sampledb                   |   23 +
 core/sql/sqludr/regtest_SEQUENCE.data           |    1 -
 core/sql/sqludr/regtest_SIMPLE_4.xml            |    1 -
 core/sql/ustat/mx_ustat.jar.version             |    3 -
 dcs/conf/realm.properties                       |   23 +
 .../org/trafodion/dcs/VersionAnnotation.java    |   54 +-
 .../org/trafodion/dcs/rest/ServerResource.java  |   56 +-
 .../org/trafodion/dcs/rest/VersionResource.java |   56 +-
 .../trafodion/dcs/rest/WorkloadResource.java    |   56 +-
 .../dcs/rest/model/WorkloadListModel.java       |   56 +-
 .../trafodion/dcs/rest/model/WorkloadModel.java |   56 +-
 .../dcs/rest/provider/JAXBContextResolver.java  |   56 +-
 .../producer/PlainTextMessageBodyProducer.java  |   56 +-
 .../org/trafodion/dcs/script/ScriptContext.java |   37 +-
 .../org/trafodion/dcs/server/ServerManager.java |   37 +-
 .../dcs/util/DcsNetworkConfiguration.java       |   57 +-
 .../java/org/trafodion/dcs/util/JdbcT2Util.java |   37 +-
 .../java/org/trafodion/dcs/util/JdbcT4Util.java |   37 +-
 .../java/org/trafodion/dcs/util/Log4jUtils.java |   37 +-
 .../xslt/configuration_to_asciidoc_chapter.xsl  |   74 +-
 install/installer/tools/ambari_setup            |    2 +-
 install/installer/traf_config_check             |  778 ++++++++++
 install/installer/traf_config_setup             |  440 +-----
 install/installer/traf_hortonworks_mods98       |   14 +-
 install/installer/trafodion_config_default      |   29 +-
 install/installer/trafodion_install             |  226 ++-
 97 files changed, 6009 insertions(+), 4870 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-trafodion/blob/9d033a10/core/Makefile
----------------------------------------------------------------------

http://git-wip-us.apache.org/repos/asf/incubator-trafodion/blob/9d033a10/dcs/src/main/java/org/trafodion/dcs/VersionAnnotation.java
----------------------------------------------------------------------


[3/3] incubator-trafodion git commit: Merge remote branch 'origin/pr/122/head' into mrg_62

Posted by su...@apache.org.
Merge remote branch 'origin/pr/122/head' into mrg_62


Project: http://git-wip-us.apache.org/repos/asf/incubator-trafodion/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-trafodion/commit/7bb805d4
Tree: http://git-wip-us.apache.org/repos/asf/incubator-trafodion/tree/7bb805d4
Diff: http://git-wip-us.apache.org/repos/asf/incubator-trafodion/diff/7bb805d4

Branch: refs/heads/master
Commit: 7bb805d48a38497e1bf94bfc5daf4c25ca5e66eb
Parents: 64c5f79 9d033a1
Author: Suresh Subbiah <su...@apache.org>
Authored: Wed Oct 14 20:26:53 2015 +0000
Committer: Suresh Subbiah <su...@apache.org>
Committed: Wed Oct 14 20:26:53 2015 +0000

----------------------------------------------------------------------
 Makefile                                        |  4 +
 core/Makefile                                   |  6 +-
 .../org/trafodion/rest/VersionAnnotation.java   |  4 +-
 .../org/trafodion/rest/version/util/VerGen.java |  2 +-
 core/sqf/sql/scripts/install_local_hadoop       | 50 +------------
 core/sqf/sql/scripts/install_traf_components    | 79 ++++++++++++++++++--
 dcs/bin/stop-dcs.sh                             |  3 +
 dcs/conf/log4j.properties                       |  2 +-
 .../org/trafodion/dcs/VersionAnnotation.java    |  4 +-
 .../org/trafodion/dcs/version/util/VerGen.java  |  2 +-
 .../resources/dcs-webapps/master/servers.jsp    |  4 +-
 dcs/src/saveVersion.sh                          |  2 +-
 wms/bin/scripts/hp_default_service.py           | 66 ----------------
 wms/bin/scripts/traf_default_service.py         | 66 ++++++++++++++++
 14 files changed, 162 insertions(+), 132 deletions(-)
----------------------------------------------------------------------